Drupal Upgrade Plan 2008

From OSGeo
Revision as of 03:27, 28 October 2007 by Wiki-Wolf (talk | contribs) (New page: Upgrading the OSGeo Drupal CMS is a complicated task further complicated by the use of multi-site configuration. To upgrade from current 4.7.x to the newest 5.3 version the following steps...)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Upgrading the OSGeo Drupal CMS is a complicated task further complicated by the use of multi-site configuration. To upgrade from current 4.7.x to the newest 5.3 version the following steps should be taken (doubles as a check list):

Preliminary tasks

DNS Changes

  1. create entry CNAME dev.osgeo.net test.osgeo.net.
  2. create entry CNAME edu.osgeo.net test.osgeo.net.
  3. create entry CNAME fdo-test.osgeo.net test.osgeo.net.
  4. create entry CNAME mapbender-test.osgeo.net test.osgeo.net.
  5. create entry CNAME mapguide-test.osgeo.net test.osgeo.net.

osgeo1 server tasks

  1. Make a script to remove write access. This script shall alter the permission table to take away all write and admin access from all roles. (The user 1 (admin) will still have write access).

osgeo2 server tasks

  1. download Drupal 4.7.8
  2. Download Drupal 5.3 and modules:
    • basicevent
    • blog
    • captcha
    • content (CCK)
      • date
      • imagefield
      • number
      • link
      • optionwidgets
      • text
    • diff
    • event
    • feedback
    • help
    • image
      • image_gallery
    • insert_block
    • ldapauth
      • ldapdata
      • ldapgroups
    • locale
      • localizer
        • localizerblock
        • localizermenu
        • localizernode
        • localizertaxonomy
        • localizeruser
        • localizerviews
    • menu
    • page
    • path
    • path_image
    • pearwiki_filter
    • profile
    • recent_changes
    • search
    • statistics
    • story
    • syndication
    • taxonomy
    • tinymce
      • imce
    • upload
    • views
      • views_rss
      • views_theme_wizard
      • views_ui
      • webfm
  3. create new directory structure
    • /var/www/drupal-5.3 (extracted from the tarball)
    • /var/www/drupal (symlnk to above)
    • /var/www/osgeo (symlink contents of drupal here)
      • /var/www/osgeo/files
    • /var/www/fdo (like osgeo)
    • /var/www/mapguide
    • /var/www/mapbender

Actual Upgrade sequence

  1. Make a Backup of all 4 Drupal databases and the files.
  2. Make all Drupal sites read-only by taking away write access (run a script)
  3. Extract osgeo1 files to /var/www/drupal
  4. Create a new databases for the sites
    • drupal_osgeo
    • drupal_fdo
    • drupal_mapguide
    • drupal_mapbender
  5. Move old drupal test.osgeo.net to run on dev.osgeo.net
    1. Add dev.osgeo.conf to Apache
    2. Point osgeo.conf to /var/www/drupal
    3. Point fdo.conf to /var/www/drupal
    4. Point mapguide.conf to /var/www/drupal
    5. Point mapbender.conf to /var/www/drupal
  6. Upgrade Drupal to 4.7.8
    1. Untar drupal-4.7.8 to /var/www/drupal-4.7.8
    2. Log in as 'admin' to osgeo site
    3. Log in as 'admin' to fdo site
    4. Log in as 'admin' to mapguide site
    5. Log in as 'admin' to mapbender site
    6. Disable all non-core modules on osgeo (with mysql update) [see below]
    7. Disable all non-core modules on fdo (with mysql update) [see below]
    8. Disable all non-core modules on mapguide (with mysql update) [see below]
    9. Disable all non-core modules on mapbender (with mysql update) [see below]
    10. Switch to bluemarine theme (Drupal standard) on osgeo (with mysql update) [see below]
    11. Switch to bluemarine theme (Drupal standard) on fdo (with mysql update) [see below]
    12. Switch to bluemarine theme (Drupal standard) on mapguide (with mysql update) [see below]
    13. Switch to bluemarine theme (Drupal standard) on mapbender (with mysql update) [see below]
    14. mv /var/www/drupal /var/www/drupal-old
    15. ln -s /var/www/drupal-4.7.8 /var/www/drupal
    16. rm -rf /var/www/drupal-4.7.8/sites
    17. mv /var/www/drupal-old/sites /var/www/drupal-4.7.8
    18. point browser to test.drupal.org/update.php
    19. point browser to fdo-test.drupal.org/update.php
    20. point browser to mapguide-test.drupal.org/update.php
    21. point browser to mapbender-test.drupal.org/update.php
  7. Upgrade to 5.3
    1. log in as admin
    2. Untar drupal-5.3 to /var/www/drupal-5.3
    3. ln -s /var/www/drupal-5.3 /var/www/drupal
    4. rm -rf /var/www/drupal-5.3/sites
    5. mv /var/www/drupal-4.7.8/sites /var/www/drupal-5.3
    6. point browser to test.drupal.org/update.php
    7. point browser to fdo-test.drupal.org/update.php
    8. point browser to mapguide-test.drupal.org/update.php
    9. point browser to mapbender-test.drupal.org/update.php
  8. install missing modules
  9. enable required modules


dev.osgeo.conf

 <VirtualHost 66.223.95.243:80>
   ServerName dev.osgeo.net
   DocumentRoot /var/www/html
   ErrorLog /var/log/httpd/osgeo-error_log
   CustomLog /var/log/httpd/osgeo-access_log common
  <Directory "/var/www/html">
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    Allow from all
  </Directory>
 </VirtualHost>


edu.osgeo.conf

 <VirtualHost 66.223.95.243:80>
   ServerName edu.osgeo.net
   DocumentRoot /var/www/moodle
   ErrorLog /var/log/httpd/osgeo-error_log
   CustomLog /var/log/httpd/osgeo-access_log common
  <Directory "/var/www/moodle">
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    Allow from all
  </Directory>
 </VirtualHost>


fdo-test.osgeo.conf

 <VirtualHost 66.223.95.243:80>
   ServerName dev.osgeo.net
   DocumentRoot /var/www/fdo
   ErrorLog /var/log/httpd/osgeo-error_log
   CustomLog /var/log/httpd/osgeo-access_log common
  <Directory "/var/www/fdo">
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    Allow from all
  </Directory>
 </VirtualHost>


mapbender.osgeo.conf

 <VirtualHost 66.223.95.243:80>
   ServerName mapbender-test.osgeo.net
   DocumentRoot /var/www/mapbender
   ErrorLog /var/log/httpd/osgeo-error_log
   CustomLog /var/log/httpd/osgeo-access_log common
  <Directory "/var/www/mapbender">
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    Allow from all
  </Directory>
 </VirtualHost>

mapguide.osgeo.conf

 <VirtualHost 66.223.95.243:80>
   ServerName mapguide-test.osgeo.net
   DocumentRoot /var/www/mapguide
   ErrorLog /var/log/httpd/osgeo-error_log
   CustomLog /var/log/httpd/osgeo-access_log common
  <Directory "/var/www/mapguide">
    Options Indexes FollowSymLinks
    AllowOverride all
    Order allow,deny
    Allow from all
  </Directory>
 </VirtualHost>

SQL to disable all non-core modules

alter table system set status=0 where where name != 'aggregator' and
	name != 'block' and name != 'blog' andname != 'blogapi' and
	name != 'book' and name != 'comment' and name != 'contact' and
	name != 'drupal' and name != 'filter' and name != 'forum' and
	name != 'help' and name != 'legacy' and name != 'locale' and
	name != 'menu' and name != 'node' and name != 'path' and
	name != 'ping' and name != 'poll' and name != 'profile' and
	name != 'search' and name != 'statistics' and name != 'taxonomy' and
	name != 'throttle' and name != 'tracker' and name != 'upload' and
	name != 'user' and name != 'watchdog' and name != 'bluemarine';

SQL to set bluemarine as the default theme

alter table variable set value='s:10:"bluemarine";' where name='theme_default';