skyBuilders timeLines HOWTO Migrate from Windows 2000/IIS/ASP/VBScript/Access|SQLServer to GNU/Linux/Apache/PHP/PostgreSQL

To migrate:

  1. Install the destination site
  2. Migrate database data
    1. Phase 1: Import and map data
    2. Phase 2: Translate relation keys
  3. Change the site name
    1. Database username and database name
    2. Site root directory name
    3. Virtual Host entry
    4. DNS entries
  4. Port non-application files from ASP/SSI to PHP
  5. Test the migrated site
  6. Clean up origin host

I. Install a new site on the destination host:

  1. Using a temporary domain name like temp.skybuilders.com, follow the installation instructions in either How To Install skyBuilders timeLines on RedHat 9.0 (if the destination host has no timelines sites on it yet) or Installing additional timeLines sites on an existing skyHost (otherwise).
  2. Once intallation is complete, a Data Synchronization is necessary. Load Sync.html and click the Sync Now link under the third section, Data Synchronization. Wait for the sync to complete (it should be under thirty seconds).
  3. An edit is necessary in /etc/php.ini, especially for larger sites. Open /etc/php.ini in your favorite editor. Look for the line "memory_limit = 16M" and raise the memory limit to 128M (from the 16M recommended in the installation instructions). Save and Exit.

II. Migrate database data using Migration Manager:

  1. Prepare the origin site for migration by upgrading timelines fully.
  2. In your favorite timelines-compatible browser, load MigrationManager.html from the newly installed destination site (for example temp.skybuilders.com). The address bar should read something like:
       http://temp.skybuilders.com/timelines/MigrationManager.html
    Once the interface loads, three sections of the page should be visible: The Controls section on top, the Listing section bottom left, and the Progress section bottom right.
  3. Enter the origin site name (the fully qualified domain name of a Windows 2000/IIS/ASP/VBScript/Access|SQLServer-based timeLines installation, in our example "origin.skybuilders.com") into the form input labelled Origin FQDN in the Controls section.
  4. Click the Load link in the Controls section to load the list of to-be-imported-and-mapped tables into the Listings section. Next to each table is listed a status of 0 or 1 to indicate whether or not it has been impoted yet.
  5. i. Phase 1: Import and map data
    1. Click the Run link in the Controls section to import and map the data from the first table in the list. The progress of the import will appear in the Progress section. Once the import and mapping is complete, the status indicator for the table will be set to 1.
    2. Wait for the import of the current table to be complete (in the case of the first table in the list, this may be near-instantaneous).
    3. If there is any error in the progress report, submit a bug report and wait for a fix. Otherwise, click the Next link in the Progress section to import the next table.
    4. Repeat the previous three steps until all the tables in the list have been imported. If they have all been imported, an alert will pop up saying that Phase 1 is complete
  6. ii. Phase 2: Translate relation keys
    1. Click the Translate Relations link in the Controls section to translate all relations in all tables. The progress of the translation will appear in the Progress section. If there is any error in the progress report, submit a bug report and wait for a fix. Otherwise, proceed to the next step.

III. Change the site name:

  1. Open an ssh session to the destination host as root.
  2. i. Database username and database name
    1. Log in to the psql command terminal and the postgres user connecting to the databse template1:
         # psql template1 postgres
    2. Run an SQL Query to change the database username from the destination username "temp_skybuilders_com" to the origin site name (with underscores substituted for dots) "origin_skybuilders_com" (note that the column name being updated in the following query is in fact "usename", not "username"):
         => update pg_shadow set usename = 'origin_skybuilders_com' where usename = 'temp_skybuilders_com';
    3. Run an SQL Query to re-set the user's password, which is encrypted using a hash of the username (in this example, substitute the password for <password>:
         => alter user origin_skybuilders_com with password '<password>';
    4. Run an SQL Query to change the database name from the destination database name "temp_skybuilders_com" to the origin database name "origin_skybuilders_com":
         => update pg_database set datname = 'origin_skybuilders_com' where datname = 'temp_skybuilders_com';
    5. Exit the psql command terminal:
         => \q
    6. Restart the postgresql service:
         # service postgresql restart
  3. ii. Site root directory name
    1. Change directory to the directory above the destination site root:
         # cd /var/www
    2. Move the destination directory to its ultimate goal (the origin site name):
         # mv temp.skybuilders.com origin.skybuilders.com
  4. iii. Virtual host entry in the Apache configuration file
    1. Open the Apache confiuration file in your favorite editor:
         # emacs /etc/httpd/conf/httpd.conf
    2. Directly above the Virtual Host section for the destination site, add a new Directory section to enable mod_speling, which will allow case-insenitive URLs. The new directory section should refer to the same directory as the ServerRoot line in the VirtualHost section. It should look something like this:
         <Directory /var/www/origin.skybuilders.com>
            CheckSpelling on
         </Directory>
    3. In the Virtual Host section for the destination site, edit the ServerName line to the origin site name (adding a ServerAlias line if necessary).
    4. Also in the Virtual Host section for the destination site, edit the ServerRoot line to match the new directory path as in step ii. above (trading out the destination site name for the origin site name).
    5. Save the file and exit.
    6. Restart the httpd service:
         # service httpd restart
  5. iv. DNS entries for the Origin Domain Name
    1. Connect to the appropriate Primary Name Server and edit relevant forward and reverse lookup zones for the origin site name and enter the IP Address of the new destination host, then restart the DNS service or get it to reload the zones.

IV. Port non-application files from ASP/SSI to PHP:

  1. On the origin host, open Windows Explorer and navigate to the origin site root directory.
  2. Select all files and directories.
  3. Deselect just the timelines directory.
  4. (Assuming WinZip is installed) Right click on any of the selected files and choose the "Add to Zip" option from the pop-up menu.
  5. In the zip dialog, choose a distinctive name for the zip file using part or all of the origin site name.
  6. Click the Add button to complete the zip process.
  7. Close WinZip.
  8. Open an SFTP client and connect to the destination site, navigating to the destination site root directory on the remote side of the window and the origin site root directory on the local side.
  9. Upload the origin site zip file to the destination site root directory.
  10. Close the SFTP client.
  11. Open an ssh session to the destination host as root and navigate to the destination site root directory.
  12. Unzip the origin site zip file into the destination site root directory:
       # unzip -o origin_skybuilders.zip
  13. Once the unzip is complete, the zip file may be deleted.
  14. In your favorite timelines-compatible browser, load MigrationPorter.html from the destination site (now named as the origin site was, so use the origin site name in the URL). The address bar should read something like:
       http://origin.skybuilders.com/timelines/MigrationPorter.html
    The files port should commence immediately, reporting progress as it goes. If there is any error in the progress report, submit a bug report and wait for a fix. Otherwise, wait for it to complete then move on to the next step.

V. Test the migrated site:

  1. Load the front page, log into timeLines, generally poke around to make sure thing seem to be running. If there is any problem submit a bug report and wait for a fix. Otherwise, move on to the next step.

VI. Clean up origin host:

  1. Remove any IIS Web or FTP Sites associated with the site.
  2. Remove the site root directory from the origin host (this is safe, as all files are backed up).
  3. If the site used SQL Server, remove the database from the RDBMS.

Edit  |  workFlow  |  Subscribe
Language: fr  | it  | de  | es  | pt  | ar  | he  | da  | nl  | zh  | ja  | ko  | none 
Author: dtd
skyCalendar

This Version:
Archived at: https://www.skybuilders.com/Documentation/HowToMigrate.20040405161219.html
Next Version:

Requests
 Version: 4482 | Series: 18131 

Search: Site | Web | Groups