Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm having trouble restoring the images folder from a backup of my MediaWiki.

I made a backup of my MediaWiki (MediaWiki 1.15.1, PHP 5.3.2, and MySQL 5.1.41), reformatted my computer, and reinstalled MediaWiki again (MediaWiki 1.17.0, PHP 5.3.2 and MySQL 5.1.41). I was able to successfully restore the database from the backup (by calling mysql -u root -p -D my_wiki < backupfile.sql).

Everything works fine up to this point; I'm able to view the text from my articles, but I've got no images. The trouble comes when trying to restore the images. I copied the images from the backup into the /var/www/mediawiki/images/ folder, but the images don't show up in the Wiki.

When I visit one of the URLs which should point to an image (for example http://localhost/mediawiki/images/1/1e/image.jpg) I get a message saying "Forbidden. You don't have permission to access..." This would lead me to believe it's a problem with permissions, but I gave all users read access to the images folder (by calling chmod -R a+r images), and still I get the same message.

I'm a Ubuntu 10.04 user. It may be worth noting that my MediaWiki was orginally located at /var/lib/mediawiki/ and is now located at /var/www/mediawiki/. However, this shouldn't matter, as I haven't actually restored the LocalSettings.php file or anything yet.

share|improve this question
up vote 1 down vote accepted

You need to use the scripts in your MediaWiki maintenance folder to export and import the images. Instructions are available here:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.