Here is how to upgrade Drupal Core. From 7.x - 7.x. To upgrade from drupal 7.x to drupal 8.x is a different process not covered in this article.
When there is a security update available you will know when you go to the house icon at the top left of the admin menu. You will want to go there at least weekly and click updates; also click run cron. The warnings for new updates to drupal core will appear after you run cron.
When you see the "Your version of drupal is not up to date" it means it is time to upgrade. Before proceeding you will want to do a couple of things.
1. Go into xen center and take a snapshot of your site in case the upgrade is not successful. That way you will have a backup copy that is only a click away.
2. To prep the site to be upgraded go to the admin menu at the top of your screen when logged in as an administrator: select -->Configuration >>Development>>Maintenance Mode. From the screen that appears mark the check box to "Put the site into maintenance mode" and click "Save Configuration."
Note that after you do this the site will be unnaccesible to the public --> but they will receive the display message that the site is in maintenance mode.
3.Now prepare to upgrade drupal core. To begin you will need to go to drupal.org and download the latest version of drupal. Remember this applies to in-version upgrades. When it is time to go from drupal 7 to drupal 8 do not follow these instructions.
4. After you download the version of drupal you are upgrading to--in our case today we are going from drupal 7.3 to drupal 7.7 (it is always ok to skip from 7.x to 7.x -- even if it is 7.1 to 7.9)
5. Go ahead and extract the zip file to it's own folder on your local machine. Give it a descriptive name such as drupal_7.7.
7. Once you have extracted the new version of drupal core to your local machine keep aware of where it is because soon we will be using ftp to drag the appropriate folders from our local machine to our drupal web server.
8. Now we need to prep our web server to prepare for the upgrade. Most all of the changes to drupal core that occur during the upgrade will not over-ride our existing site design and content. However we need to isolate and save the files that do affect our sites design, and the files that reside in folders on the site (not in the database). So we will take these folders and files and also save them to the drupal folder on our local machine we downloaded, extracted and named in steps 4-5.
9. Go ahead and open up win scp (preferred) so we can do some secure file transfers between our drupal site web server and our local machine.
10. Here are the files we need to copy from our web server to the local folder and overwrite the contents of the local server to preserve our sites design and special folders. Make sure on the server side of win scp (the right side) you are in the sites root folder: var/www/drupal
Then you can see the sites folders and some site-specific files. Please note that most of these files and folders are drupal core, but we also have some folders currently that are not drupal folders -- such as policies, restyle gc, and a few others that you will see listed below.
Now make sure that on the local side of the win scp interface you can see the drupal folder that you extracted and name in steps 4-5.
Simply drag and drop the files listed below to the drupal folder on our local machine. When it asks if you should over-ride you can safely say yes and "apply to all instances in this queue."
Here are the files and folders to drag and drop. If it helps you you may wish to do a checklist to make sure they all get transferred:
employability_lab
StudentAcademicRecords_employee_training
sexual_harassment_awareness_training2007
themes
slideshow-for-bd_files
sites
restylegc
policies
mapIcons
mapfiles
images2008
images
.htaccess
.gitignore
go______-webfont.woff
go______-webfont.ttf
go______-webfont.svg
go______-webfont.eot
cataneon-webfont.woff
cataneon-webfont.ttf
styles.css
scc_map_redux_copy
scc_map_redux.html
drushrc.php
**read below to find out more about the ?why? of these file transfers.
Now we have our Drupal folder all taken care of on our local machine. It is ready to be deployed.
On the server side of our win scp interface click on the up arrow to go up on level to our www/ directory. here you will see our folder called drupal. Now on the left side of our win scp interface lets click on the drupal folder on the local machine you created in steps 4 and 5 and dragged the material to in step 10. Select all of the files and folders click the first one, hold the shift key, click the last one and all folders and files are selected.
it is safe when prompted whether or not to over-ride to select "overwrite all"
If you get error messages regarding permissions you can safely skip all.
It will take a few moments to complete the file transfer. Sit back and relax! After the file transfer has taken place go back to the site in the web browser. Go to Configuration >> Development >> Maintenance Mode. Unclick the "Put site into maintenance mode" checkbox and then click the "save configuration button at the bottom"
Now navigate to the home page.
Now go to the home icon on the left of the admin menu at the top of your screen. First of all "flush all caches".
Then you will go to the same home icon and "Run Cron."
Then you will go to the same home icon and "Run Updates"
The updates window will suggest you back up your database and code --> you don't need to do that because we took care of that in step 1.
It is safe to click continue and then click "Run Updates"
After the updates have run you are good to go. You should once more run cron after the updates (this typically will take care of any small issues that may appear as alerts after the DB is updated.)
Now you are good to GO. Take another snapshot in xen center and specify the title after 7.x upgrade.
**here is the why of the file and folder transfers:
these folders:
- employability_lab
- StudentAcademicRecords_employee_training
- sexual_harassment_awareness_training2007
- slideshow-for-bd_files
- policies
are subdirectories that contain their own little web apps. The slideshow-for-bd-files (board of trustees) are a powerpoint app that can most likely be discarded --just be sure to search for board of trustees slideshow in the site and remove the links.
employability lab is served up to job hunters and should remain in subdirectory. sexual harrassment training has been requested to be redone so that folder and site links to it can be removed as the alternative is developed and employed. Policies are linked to throughout the site, however they should eventually be ported into the drupal CMS as a content type. StudentAcademicRecords* is another folder linked to that should eventually be developed and ported into the CMS.
this group of files:
- go______-webfont.woff
- go______-webfont.ttf
- go______-webfont.svg
- go______-webfont.eot
- cataneon-webfont.woff
- cataneon-webfont.ttf
are used to embed non web safe fonts that appear in the header. They will definitely change and may be removed as our new logo and logotype are implemented.
This folder:
is a part of drupal core that I have modified. This allows us to have our unique looking site without introducing the problems that can come about when implementing a sub-theme. This folder will always need to be preserved using the process outlined above.
This file:
is a hidden file that may be used to implement site security, so it is best practice to follow the above procedures for this one every time.
This file
is a hidden file that doesn't really apply, but still follow the above steps to be safe.
These folders involve the custom programmed google maps interactive and must alway be handled according to the above procedure.
- restylegc
- mapIcons
- mapfiles
These files are also the interactive google maps related content:
- scc_map_redux.html
- styles.css
These are custom image folders that may eventually need to be discarded. Have a look first.
The folder:
is where our custom files and modules are within drupal core. ALWAYS follow the procedure for this folder.
And this file:
has to be there for drush to work. ALWAYS follow the process outlined above for this file.