Backing up, restoring, and transferring CMSMS
The following is a test of how painless (or painful) process of backing up and restoring CMSMS is. This is in addition to the instructions here.
The process is far from trivial, and has several non-intuitive steps. However, I did manage to restore both to a localhost (XAMPP), and a subfolder on my server.
The following is what I think the complete list of things that must be backed up manually (if you are paranoid, or are planning on deleting the original directory soon, you might consider FTP downloading absolutely all files off your site in addition to the database):
- database export (several times and several options). Also note database prefix.
- uploads folder
- list of modules that you have installed
- files in directory: config.php (for any custom settings that you have made). .htaccess (any custom changes) (this will also contain pretty URL rewrite. not modifying the rewrite path can break your site, and possibly other sites in subfolders). favicon.ico both file AND the setting for its location will not transfer with the database transfer. robots.txt (any custom changes). Version of CMSMS used
- Any custom files and folders on your server that CMSMS did not put there. This includes, but is not limited to, Google Webmaster verification file, any possible user images in /images (they aren't supposed to be here, but some people think that this folder is for user images), any CSS files in the root directory. Also watch out for any folders that do not belong to CMSMS, but someone has uploaded to the server.
A) If you have not installed CMSMS in the destination server/directory, then first import the database, find out what the SQL table name is from phpMyAdmin, and then set this as the database name and/or prefix in the installation settings. Also, do not "Create Tables", and do not "Install sample content and templates". (those will come with the database)
B) If you have already installed CMSMS in the destination server/directory, then you might have specified the wrong database name and/or prefix. You might have also specified to install sample content and templates. In that case, you will have the default 4 page website. Then, import the database, find out the database prefix, go into config.php and change database settings. You can then delete ("drop" in phpMyAdmin) the sample/4-page database. Then, go to Content>Pages and verify that the pages have transferred. Weird: admin panel shows pages, but your site just displays one page home page from the default/sample website. Solution: go to Content>Pages, click on the correct home page to edit it, then hit submit without making any changes, and it appears on site.
Before creating a backup of a site, it is very important to take the following steps to avoid problems in the future.
1) Remember that pretty URLs and site operation in general depends on the rewrite rule in .htaccess. If you will be moving the installation, modify settings accordingly. Also, subfolders on the same server might depend on that single .htaccess for their operation.
2) Remember that there are a lot of paths specified in config.php and they need to be modified if anything is moved or changed.
3) Bring site down. This is necessary to avoid cache errors.
4) Clear cache
5) Backup site as described on top of this page
6) Download a full FTP backup of your website. In case things go wrong (they do).
If you are upgrading a site that is several versions old, you will need to use the overwrite method.
7) Upload the installation file to your server.
8) It is best to use the Shell (SSH) overwrite method
9) Run install/upgrade.php to upgrade, not /install
10) Do not upgrade your site to 1.8 if you have multiple content blocks with the same name in your template.
IF you are creating a copy of a website or moving a website, make sure to do the following:
7) AFTER YOU BACK UP THE ORIGINAL SITE, AND COPY OLD SITE CONTENTS AND BEFORE YOU RUN ANY FILES, VIEW ANY PAGES, ETC MAKE SURE TO GO INTO THE NEW CONFG.PHP FILE AND POINT IT TO ANOTHER DATABASE!
8) After you copy the database, encoding might have to be changed on step 6 or 7.
I can do all of this for you - get it done by someone who knows what they are doing, and who will do it fast and properly.
˅˅˅ Additional valuable information is available at one of the links below: ˅˅˅
Did you like the article? Let Google Search know by clicking this button:
Page last modified 28-Aug-11 16:35:16 EDT