Reputation: 4414
I have a three year old or so MAMP install (a copy of the application folder and all its contents, databases, etc.) with a three year old MediWiki (version 1.19) installed on it, several pages, and a few images. I would like to know how I can access those pages (or at least the content on them) and import them or copy them over to a fresh install I made today with the latest versions of MAMP and MediaWiki.
I already tried copying the database folder (MAMP/db/mysql/my_database; contains .frm files) from the old install to the same location in the new install but it doesn't seem to have changed anything. I even looked at the contents of the tables with phpMyAdmin but I didn't find any of the old content. Where do I go from here?
I installed MAMP on my MacBook Pro running OSX Yosemite. I'm hosting locally (e.g. using localhost
). I am able to install a fresh MediaWiki on my localhost MAMP server and it works fine (there's just no content).
UPDATE: After seeing this I changed $wgMainCacheType = CACHE_ACCEL
to $wgMainCacheType = CACHE_ANYTHING
in the MediaWiki local settings file and now I get an error page that looks like this:
Do I need to somehow upgrade my databases? They are old after all. How should I go about doing this?
Upvotes: 0
Views: 401
Reputation: 176
Advice : for this kind of software, use a Virtual Machine, it will save your time : my own mediawiki is running for 8 years under debian, hosted on a several different Apple machines.
But for now, if you still have the former stack running :
0 . (always) save your database content + files
for the database : https://www.youtube.com/watch?v=NnOE0KWHGkY
for the files : tar cfvz my-old-mediawiki.tar.gz path-to-mediawiki-directory
This will allow you to rollback if something goes wrong
this will produce an xml file.
Save your images somewhere on your file system
you now have exported your pages and files
3) Switch stack
check that the new virgin mediawiki is working well
import your pages
you now have a similar wiki, minus the files
keep in mind also to reinstall any extensions installed previously.
Upvotes: 1
Reputation: 325
Shutdown mysql
Just copying the MAMP/db/mysql/my_database is not enough
Copy the contents of your db folder and below to the new MAMP db folder
Note i assume your new MAMP is pretty virgin
Poached it from here :
http://joejoomla.com/sound-off/157-how-to-upgrade-mamp.html
Start new mysql
Will incl necessary config files
It is not as if you should have expected MAMP to recurse directories
It needs config files from old and you don't have them yet
I have never done it on MAMP
Edit: Concerning warning that resulted
Make sure that XCache is installed with the new version of PHP. The most likely cause is the new version of PHP simply doesn't have xcache installed. You can do this by creating a php file with just the code
<?php phpinfo(); ?>
and then viewing it in a web browser.
Setting $wgMainCacheType = CACHE_NONE
; will disable all caching, which would prevent the error, but make things slow.
Upvotes: 1