How to install and maintain Drupal with comprehensive web hosting

Management of Drupal installations on our comprehensive web hosting service generally requires access using SSH. View our How to connect using SSH / SFTP guide for information on suitable clients.

Expand All

  1. Connect using SSH to access.nsms.ox.ac.uk and login with your site administrator credential. Then change into the htdocs folder and begin the installation:
    $ cd <site-name>/htdocs/
    $ drush dl drupal-7
    $ cd drupal-<number>
    $ mv * .??* ..
    $ cd ..
    $ rm -rf drupal-<number>
    
  2. You could then edit the .htaccess file to prepend some lines to restrict access to the site until it is ready to launch, e.g.:
    <IfModule mod_authz_core.c>
    Require ip 129.67.0.0/16
    Require ip 163.1.0.0/16
    Require ip 192.76.8.0/26
    </IfModule>
    <IfModule !mod_authz_core.c>
    Order allow,deny
    Allow from 129.67.0.0/16
    Allow from 163.1.0.0/16
    Allow from 192.76.8.0/26
    </IfModule>
    
  3. Use a web browser to visit your site, then set it up:
    Standard or minimal number of modules pre-enabled - these can be changed later
    Select English
    Enter the database name, database username and password, then select Advanced Options and enter the database host, e.g. nsmsdbXX.nsms.ox.ac.uk
    Use a unique outgoing site email address, e.g. do-not-reply@<site-name>
    Enter details of a maintenance account - this should have the email address of the site administrator

  4. Once the site is ready to launch, alter the .htaccess file again if require to allow public access

For full install instructions see https://www.drupal.org/documentation/install

  1. Connect to access.nsms.ox.ac.uk, then put the site into maintenance mode and clear the caches:
    $ cd <site-name>/htdocs/
    $ drush vset --yes maintenance_mode 1
    $ drush cc all
  2. Back up the database:
    $ mysqldump -u siteXXXX_YYYY -h nsmsdbXX.nsms.ox.ac.uk -p database-name > ../home/name-of-file.dump
  3. Check the drupal version:
    $ drush core-status --fields="Drupal version"
  4. Backup site files that the update process will overwrite with defaults:
    $ cp .htaccess ../home/
    $ cp robots.txt ../home/
    
  5. Update drupal core (this can take a few minutes, be patient):
    $ drush up drupal

    Note that this creates a "drush-backups" folder in your home directory on access.nsms.ox.ac.uk, which is not backed up or accessible to other users, and is not part of your website.

  6. Compare the two files backed up earlier, to check that nothing important has been overwritten:
    $ diff .htaccess ../home/.htaccess
    $ diff robots.txt ../home/robots.txt
    
  7. Take the site out of maintenance mode:
    $ drush vset --yes maintenance_mode 0
    $ drush cc all
  8. Check that the site works, then update individual modules one at a time. If a plugin or other code cannot be updated or is no longer supported, then consider whether it is safe to use.

For full details see the official Drupal upgrade guide.

Get support


If you cannot find the solution you need here then we have other ways to get IT support

Get IT support