Files not available after move

Files not available after move

by Linus Bahun -
Number of replies: 5

Hello all! 

We moved a Moodle installation to a new server this weekend. Since then, attachments are no longer accessible (for example, a PDF file in a course) and images no longer display in the system.

Moodle Version is Moodle 3.8.4

I am urgently looking for a solution so that classes can continue on Monday.

With kind regards

(Edited by Helen Foster to remove link at poster's request - original submission Sunday, 31 January 2021, 4:58 PM)

Average of ratings: -
In reply to Linus Bahun

Re: Files not available after move

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
How exactly did you move? Following https://docs.moodle.org/38/en/Moodle_migration ? What are the servers, source and target? Is the source Moodle still intact?
In reply to Visvanath Ratnaweera

Re: Files not available after move

by Linus Bahun -
Thank you so much for responding. I am not totally sure but we'll find out and I let you know.

Admin-Page displays the following warning:

SECURITY WARNING!

Your dataroot directory is in the wrong location and is exposed to the web. This means that all your private files are available to anyone in the world, and some of them could be used by a cracker to obtain unauthorised administrative access to your site!

You must move dataroot directory to a new location that is not within your public web directory, and update the $CFG->dataroot setting in your config.php accordingly.


(Edited by Helen Foster to remove link at poster's request - original submission Sunday, 31 January 2021, 5:23 PM)

In reply to Linus Bahun

Re: Files not available after move

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
> Your dataroot directory is in the wrong location
You have messed up something during the move. Study the MoodleDoc page I referred carefully and compare with your notes during the move. I hope, your original site is still intact.
In reply to Visvanath Ratnaweera

Re: Files not available after move

by Linus Bahun -
Yeah, the old Installation is still on the old server. We'll root the Domain back to the old Server with DNS and try it one more time with the instruction you referred to. Thank you!
In reply to Linus Bahun

Re: Files not available after move

by Visvanath Ratnaweera -
Picture of Particularly helpful Moodlers Picture of Translators
That's relief.
wink

BTW, you know that you don't have to touch the global DNS during the migration. It is enough to twist the local DNS, the one in your desktop. In Unix/Linux it is the /etc/hosts file. Windows also has the equivalent somewhere deep inside its directory structure.