Going 2.9.2 to 3.1... can I upgrade to a different folder?

Going 2.9.2 to 3.1... can I upgrade to a different folder?

by Fred Proctor -
Number of replies: 5

Hi all,


I'm fairly new to Moodle so please bear with me. 

I am upgrading Moodle ver 2.9.2 to 3.1 hosted on a GoDaddy site that runs Linux. I've been reading over the 3.1 upgrade documentation. When I upgrade, I'm wanting to change the "moodle" folder from its current location since it is nested within the file structure of a different LMS software (done before I came onboard).  

In the midst of doing this upgrade, can I specify a new "moodle" folder location on the same server? Would this be a migration instead? I noticed that in the config.php, there is no mention to pathing of this folder. My "moodledata" folder will remain as is and so its corresponding pathing as specified in the config.php would remain unchanged. Is there anything else I need to edit/change for a smooth transition? Would the URL automatically find the folder in a new location on the same server?


Thanks,

Fred

Average of ratings: -
In reply to Fred Proctor

Re: Going 2.9.2 to 3.1... can I upgrade to a different folder?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

Yep - shouldn't be a problem. 

The only thing you'll need to worry about is changing whatever on GoDaddy points the URL (of your Moodle site) to it's location in the file system. That will need to reflect the new location. Not knowing anything about GoDaddy I can't help you there. 

However, you are quite correct, there's nothing in config.php that needs to know the install location and (with the above caveat) it should 'just work'.

In reply to Fred Proctor

Re: Going 2.9.2 to 3.1... can I upgrade to a different folder?

by Ken Task -
Picture of Particularly helpful Moodlers

Ok, while it should 'just work' ;) ... it is, IMHO, kinda like a 'migration' where one is moving to a different service/server.   It's a move of code.   But, doing an upgrade at the same time, should one run into issues (hopefully not), what's the problem?   The move?  or the upgrade?

Specs of your hosting meet what's required for 3.1.highest?  version PHP, MySQL/DB, etc...

Think I'd do the move and get that working first.    Then do the upgrade.

Uhhhh ... just in case ... *backup* DB, code, and data directory first.

'spirit of sharing', Ken


In reply to Fred Proctor

Re: Going 2.9.2 to 3.1... can I upgrade to a different folder?

by Rick Jerz -
Picture of Particularly helpful Moodlers Picture of Testers

If I was you, I would install a complete new version of Moodle, manually.  It's not that hard.

1) Create a new database.  Maybe call it moodle3.

2) Create a new moodledata folder.  Maybe call it moodledata3.

3) Download and unpack your new moodle to a folder, maybe call it moodle3.

Then, start your new moodle and make sure that it works.  Next, install add-ins.

Finally, replace the moodle3 database and moodledata folders with your old moodle data.

Yes, this is the quick summary, but it's one way to do things (safely.)

Also, make sure to always backup your current moodle before experimenting.

In reply to Rick Jerz

Re: Going 2.9.2 to 3.1... can I upgrade to a different folder?

by Fred Proctor -

Many thanks for all the input. However, I had to get things going before seeing any replies here. I ended up leaving the folders in place, and did the upgrade without issue. We were relieved when the upgrade process had no effect on our Joomla site that was live. I'll conduct Migration next. For that, really all I need to move is the "moodle" folder up one level in the file structure. 

The one thing that stopped me from doing this before the upgrade was I'm still digging to find where my predecessors placed the index.html so I can edit where to point to the new directory. 


Fred

In reply to Fred Proctor

Re: Going 2.9.2 to 3.1... can I upgrade to a different folder?

by Howard Miller -
Picture of Core developers Picture of Documentation writers Picture of Particularly helpful Moodlers Picture of Peer reviewers Picture of Plugin developers

If, say, your root web directory is pointed to by http://fred.com/ (and typing that in gets you Joomla) and, further, Moodle lives at http://fred.com/moodle because it is simply in a subdirectory of that, then....

...you should hopefully be able to create a "virtual directory" (I found... https://uk.godaddy.com/help/create-virtual-directory-4141) that maps http://fred.com/moodle to some arbitrary physical directory. That is, you move the Moodle files but you do not change the URL that pointed to them.

Everybody happy.