Actions
DrupalDrushUpdate » History » Revision 34
« Previous |
Revision 34/50
(diff)
| Next »
Andreas Kohlbecker, 07/04/2016 04:29 PM
Updating EDIT DataPortal multisite installations with Drush¶
Requirements
dataportal-admin installed
Important
- *WARNING !!!! * do not upgrade the zen theme !!!!
Step by step
- jump into the drupal root folder
cd ${DRUPAL_HOME}
- Set all portals into maintenance mode
dataportals-drush vset -y maintenance_mode 1
- make sure all databases are updated
dataportals-drush updatedb
- If drush freezes at some point you may want to check that the CDM-Server which is configured for the portal in question is available. If the server is absent this will prevent drush from proceeding.
make sure the update mudule is enabled for all sites
dataportals-drush pm-enable update --yes
- remove the symbolic links in the profiles folder in the drupal root, these symlinks would otherwise cause problems in drush when creating the backup
cd profiles rm CDM_* cd ..
- Choose the URL of a dataportal which is NOT using the zen based base theme and run the following command for one dataportal installations
drush -l <site-url> up
Examples for edit-test and edit-prod:
drush -l http://test.e-taxonomy.eu/dataportal/preview/palmae-test/ up drush -l http://www.palmweb.org/ up
- restore the symbolic links in the profiles folder. In the following example we assume that the dataportal module is installed in
../sites/_dataportal-production/modules/
cd profiles ln -s ../sites/_dataportal-production/modules/cdm_dataportal/profile/CDM_Portal ln -s ../sites/_dataportal-production/modules/cdm_dataportal/profile/CDM_Portal_Testing cd ..
- fix ownership
chown -R www-data:www-data ./ # in case the ./sites/_jenkins-workspace exists: chown -R jenkins:www-data ./sites/_jenkins-workspace
- restore the .htaccess and robots.txt files by merging the files that have been copied to the
~/drush-backups/..../drupal
folder by merging them with the new files. Do not just copy them over. You can use vimdiff for this, here is a brief tutorial
cp ~/drush-backups/drupal7_dataportal_production_palmae/TIMESTAMP/drupal/.htaccess .htaccess-last cp ~/drush-backups/drupal7_dataportal_production_palmae/TIMESTAMP/drupal/robots.txt robots.txt-last vimdiff .htaccess .htaccess-last vimdiff robots.txt robots.txt-last
- now update database for all other sites of the multisite installations
dataportals-drush updatedb --yes
- check for missing updates in all portals and update portals for which pending updates have been detected individually
dataportals-drush ups
test the sites
Turn off the maintenance mode in all portals except those which are listed in http://wiki.bgbm.org/bdinotes/index.php/EDITDataPortalList#edit-test as "Undisclosed Portals (must be in maintenance mode)"
dataportals-drush vset -y maintenance_mode 0
IMPORTANT*: Immediately disable the *Undisclosed Portals!!!!!
- if everything is ok you can remove backup folders which are usually in ~/drush-backups/
Updated by Andreas Kohlbecker over 7 years ago · 34 revisions