123ArticleOnline Logo
Welcome to 123ArticleOnline.com!
ALL >> Web-Hosting >> View Article

How To Move Your Serendipity Blog To A New Server

Profile Picture
By Author: Jon Murray
Total Articles: 23
Comment this article
Facebook ShareTwitter ShareGoogle+ ShareTwitter Share

{{{Moving to a new server is never easy or painless no matter how much work a software company (or open source project) has taken to make paths relative and isolate server specific settings. The fine authors of the Serendipity blog engine have done a very good job with these abstractions, but there are a couple of tricks and tips which will help you out if you need to move to a new server and/or a new domain name.|With these 8 easy steps you'll have your Serendipity Blog moved in no time. This will require some knowledge on your part of mysql, text editors, ftp and maybe even unix security but if I can do it, so can you.

The first thing you need to do is make sure your security on your new server is set up correctly. For my case I had to move about 20 web sites from a shared hosting account (where security was managed for me) to a dedicated hosting account (where I had to implement the security myself). I am not going to elaborate on what I had to do for my security requirements, but for yours you will need to make sure that the appropriate directories have write access from PHP (or more likely the web server that ...
... PHP is running under). If you have a shared hosting account you can pretty much assume that this is taken care of for you and the files you upload via FTP will be given write access by apache.

Once your security issues are sorted out you are ready to move your stuff. What I did is I FTP'd all the files from my installation to my local drive. From there I would be free to modify what is needed. I also created an export from MySQL using myPHPAdmin. When I created my export I chose drop database and drop table options, this way my new database was being created right from scratch. If you are installing to an existing database on your new server clearly you don't want the drop database option. I also pulled down this generated .sql file to my local box.

Now for the fun, a couple of quick steps and you'll be ready to start the move.

1. Go into the generated .sql file and do a search for your old path. For example mine was something like /home/a/b/c/jonny/html/serendipity/ then modify all instances of this string to where your new install is going to be. For example, my new install dir is something like /home/mma/public_html/

i.e. search and replace old install path with new install path in MySQL file.

2. If you are changing your table prefixes on your new install (you probably aren't), then change all these instances. My old was serendipity_mma_ and I decided to keep that, so no changes were necessary.

3. If you are changing your domain name, then make all of those changes. My old domain name was mma.gocurious.com and my new one is www.ufcresultslive.com, so I did the search and replace on all of those. Technically I didn't need to do this step as I am redirecting all traffic from my old domain to my new one anyway, but it's better to have it changed.

4. You are now finished with the .sql file, save it and remember where it is. You will need to upload and apply it later.

5. We now need to fix your serenendipity_config_local.php file. This is the file in serendipity which contains your database information (name and password), database prefix (serendipity_mma_ in my case) and all the other goodies that serendipity needs to connect to the db. Make sure that these values correspond to your values on your new database. You can now save your serendipity_config_local.php file.

6. You can now upload (probably via FTP or SFTP) your serendipity files to the new server.

7) We need to build your new database. How you do this will be specific to the tools that you have access to. If you are moving to a dedicated host then you can simply upload the .sql file and apply it via the MySQL command line tools. If you are moving to a new shared host then the myPHPAdmin import will only handle up to 2 meg. If your db is larger than 2 meg you will need to get a tool known as BigDump. Note that I have not used BigDump myself, but have read that it works quite well. BigDump essentially splits your sql into < 2MB chunks and applies them.

8) You're almost done, you've updated your config file, built your new db with all the changed info and uploaded it all to the server. All you need to do now is change your domain to point to the new server and wait for the change to take effect.

That's it. Congratulations you should have now succesfully moved Serendipity to your new server. When I did all of this my security wasn't set up properly, so I had to chmod some files temporarily to make them writable. The most notable was the config which was 700 I believe and since my FTP user and web user aren't the same I didn't have write access. Serendipity is nice enough to tell you when it can't write to a file.

Note: Always make sure that your new server is up and running and stable before cancelling your old account or deleting your files off your old server. I made that mistake and was down for about a day with a problem as a result. If I'd left my files on the old server I could have just switched my domain to point back at it while I figured the new problem.

Total Views: 289Word Count: 988See All articles From Author

Add Comment

Web Hosting Articles

1. Investing In A Business Website For Growth
Author: Liam Mackie

2. Domain Name Registration: A Beginner's Guide To Get Started Today
Author: Joshi Aarohi

3. Choose The Right Email Hosting Provider
Author: Lee Wood

4. Maximizing Your Online Business: A Comprehensive Guide To Wordpress Ecommerce Development
Author: Egrove systems

5. Managed Wordpress Hosting Vs. Shared Hosting: Which Should You Choose?
Author: Nitish

6. Why Is Hostagle Best Domain And Hosting Provider?
Author: lakshay

7. How To Choose Fastest Wordpress Hosting For Your Website Complete Guide
Author: Nitish Kumar

8. Hostagle
Author: vishu

9. Docker With Kubernetes Web Hosting
Author: Nitish Kumar

10. Why Website Maintenance Service Is Essential For Your Business
Author: Egrove systems

11. Himalayan Host: Your Premier Destination For Wordpress Hosting & Reseller Hosting In Nepal
Author: himalayanhost

12. Himalayan Host: Leading Provider Of Web Hosting And Domain Registration In Nepal
Author: himalayanhost

13. Driving Ecommerce Success With A Top Ecommerce Agency In Melbourne
Author: themerchantbuddy

14. Enhance Your Online Presence With Top-notch Website Maintenance Services In India
Author: Web Rank

15. Leading Web Hosting And Domain Registration Provider In Dubai
Author: intohost

Login To Account
Login Email:
Password:
Forgot Password?
New User?
Sign Up Newsletter
Email Address: