I have a bit of a gray area here. I created a new fresh virtual server and am attempting to use the WordPress Duplicator plugin to transfer my site which means using the plugin on the former host to generate a zip of site files & an installer.php file that is accessed via domain.com/installer.php, however all I end up with is an error 500. I am not sure if it is an issue with it timing out too quickly or something else but either way I am not sure what I’d try. Also any alternative method suggestions to transferring an existing WordPress site? Thanks in advance to all who reply!
I’ve done a whole lot of WordPress migrations over the years. I never use a plugin to do it…it’s too damned much trouble to get them to work right.
I usually use the Virtualmin WordPress Install Script to setup WordPress on the Virtualmin system. The WordPress Install Script is not currently in Virtualmin GPL, but is in Virtualmin 6 which is coming in a few days…the alpha release is available now, but it’s not really recommended for newbies…give it a couple days, and it’ll be tested enough to make its way into the main repos. Once WordPress is up and running, I make a list of the plugins and themes in use, and install all of those into the new installation; I usually like to take this opportunity to make sure I have the latest of all of the plugins.
Once I’ve replicated the plugins and themes as closely as I can, I then import the database, and manually look at the wp-config.php to make sure I bring across anything important. Again, I take this as an opportunity to clean up old config options, so I don’t copy it over willy-nilly…I only bring over something if it is needed. Most important stuff is in the database, so it won’t matter much what’s in config.
Finally, once the new WordPress install is mostly ready…I’ll use the Webmin MySQL module to import the database with the Execute SQL function.
Log into WordPress at this point, and see if it wants to perform a database update (if this new installation is a newer version than you were copying from, it will). Then poke around to make sure all your users and content came across.
This seems like a lot, I know, but it really only takes a little time. An hour, maybe two or three if you’re not really familiar with these concepts. In my experience, the site copiers take longer than this fiddling with the stuff they break or the stuff they assume will be the same across installations that isn’t (as you’ve noticed).
Joe you’re nothing short of awesome! Huge appreciation for your response and explanation. If you don’t mind me bugging you a little more I do have a couple follow up questions.
Q1: Technically could I just download from the official site and install it?
Q2: could you explain a little more on wp-config because mine seems to look pretty respectable other than obviously omitting the SQL login
Q3: I have heard different mysql databases can conflict. Is this true? Mine seems to differ from the current (/hopefully soon former) host.
Q4: Stupid question… during what step would you recommend copying over the old files to public_html?
Again, a huge thanks and gratitude for all your help!
I recenty migrated a WP site from shared hosting to a Vitualmin Virtual server.
These are the steps I did,
- create a mysql db
- have the user credentials to hand
- ftp the entire contents of your old public_html folder to you new public_html folder
- open up wp-config.php locally and find
and put in the new values.
- ftp the updtaed file over.
- using your FTP client find the .htaccess files in public_html and put “_OLD” on the end of it. Same for the one in wp_admin folder.
Should be good to go after that.
Hope it helps
Much much appreciation for your reply. I started with a simple test page that just had some simple text to let me know it was now pointing to me and not my old host (it pointed to me since yesterday). I then followed yours (Dibs) with a dash of Joe’s directions and for a second I got an error 500, then it seemed to work perfectly which I heaved a sigh of relief, so I decided to test it and uploaded a stupid picture of a cat, checked my ftp, and didn’t see it. I checked the old webserver and sure enough, for some reason it was right there. Some how, despite having had it point correctly to me it now points back to the old one? What is weird as well is it now says:
Warning - errors were found in this domain’s DNS records : This domain has email enabled, but none of the MX records point to it. Either the MX records should be corrected, or the email feature disabled if mail is hosted externally.
It is now showing either Error 404 or 500, not sure what is going on but I’ll check logs / experiment a little more later on. (I am sort of writing this in the middle of the night, so don’t think I am awake enough not to mess stuff up hehe)
I completely re-did the whole virtual server from scratch and noticed the DNS records now includes ns1.MyOtherDomain.tld & root.ns1.MyOtherDomain.tld in the SOA, is that even right? Also the Name Server showed ns1.MyOtherDomain.tld so I changed it to domain.tld similar to how it was on MyOtherDomain.tld, it showed my test page fine ironically enough but I uploaded my site files it now just gives a steady error 500. I am also getting “End of script output before headers: index.php” & “mod_fcgid: error reading data from FastCGI server”, which I’ll address tomorrow along side doing some more research / playing with it and post it here for record if I can ever get it in case it helps some one else… or alternatively I’m likely just a bumbling idiot noob in which case much appreciation for any and all help.
I would just backup your existing WP site using an FTP client and backup the whole public_html folder - that’s what I did.
Do a bckup of the mysql DB using myphpadmin or similar.
For the moment - disable the mail for domain feature. Keep things really simple.
Then follow the instructions I posted and see how you go.