SPIP

[ar] [ast] [bg] [br] [ca] [co] [cpf] [cs] [da] [de] [en] [eo] [es] [eu] [fa] [fon] [fr] [gl] [id] [it] [ja] [lb] [nl] [oc] [pl] [pt] [ro] [ru] [sk] [sv] [tr] [vi] [zh] Espace de traduction

Download

How to upgrade SPIP

November 2003 — updated on : November 2010

All the versions of this article:

Upgrading SPIP to a newer version is very simple. Nonetheless, we offer the procedure below as a way to ensure that you avoid any obvious errors.


The following procedure may seem overly complicated, but we have deliberately used as much detail as possible to help you avoid any errors. In practice, upgrading SPIP is quite simple and can be carried out in a few minutes.

1. Backup your database.

Before doing any significant modification to an information processing system, you should always make a backup as a precaution.
Note: this is only a precaution, but still a wise one. You are not obliged to do it, and the backup file will probably not be used for anything since the upgrade proceeds is most likely to complete without any problems at all!

It is the same logic as when you upgrade your computer’s operating system (to install a new version of Windows, MacOS or Linux); you backup your important documents, but you know that if the upgrade goes okay, you will not need to reinstall these documents.

The procedure is explained fully in this article: "Backing up your data".

However, the following mention is very important indeed: backup your database before upgrading, but do not restore it! Indeed, we have noted that many users have backed up their database, carried out the upgrade and then restored their files from that same backup; this is a major procedural error and their sites inevitably displayed errors. The backup is simply a precaution in case of a major problem occurring during the upgrade, but if the operation proceeds normally (which is almost always the case!), you should NOT restore this backup. (The backup is carried out using the database structure that corresponds to your prior version of SPIP; if you restore it after the update, you will be restoring it into a structure which has changed, thus causing problems). This backup can therefore only be used with the correct version of SPIP: remember to note down beforehand what that version was and to download that prior version of SPIP if you want to be able to restore everything back to its original condition as it was before if you run into any unfortunate major problems. If you are inheriting an old site from another webmaster, also bear in mind that it is quite feasible that the SPIP code itself has been modified as well, as so a full FTP file off-site copy of the entire system is your only sure guarantee that you can restore everything accurately - this is not normally necessary, because most people don’t edit the core SPIP code, but it should be mentioned here nonetheless.

If your site can not endure a loss of service which may range from one hour to a day or two (serious problems only), then it is important that you perform the update on your local machine first, in order to sort out any problems that may occur before updating the new version online. IT would be best if the local system had the same configuration as your Web site, but even if not, it’s still better that you have already tested the feasibility of the upgrade without hitting any major bugs with your template files and any additional changes you may have made.

2. Install the new version of SPIP

The organisation of the files and directories having changed significantly between versions SPIP 1.8, 1.8.1 and SPIP 1.9 and then again between versions SPIP 1.9 and SPIP 2.0 (or SPIP 2.1), the specific update procedures are detailed in the articles "Upgrading to SPIP 1.9" and "Updating from 1 .9 .x to 2 .0 .x".

The actual upgrade starts here.

The principle is very simple; you just need to install the SPIP files again, exactly as you did for the first installation. You can do this either with "spip_loader" which will perform an automatic installation of the files, or more traditionally by unzipping SPIP on your own hard disk and uploading all the files to your server by FTP.

Note: it is not necessary to remove any files from the previous version. It is neither necessary nor is it advised; indeed, if you remove the old files, you will need to set all of SPIP’s configuration settings again (to set the database connection details, etc), which is a useless procedure if you are satisfied to overwrite the old files with the new ones. By erasing the old files, you are even likely to erase the images contained in your articles! Therefore, keep it simple: don’t erase anything before installing the new files; the new ones will automatically overwrite the old ones...

3. Start the update of your database

Once all the new files have been installed (by FTP, or automatically with "spip_loader"), return to the private area of your site.

Note: make sure you wait until all the files are completely installed. If you try to intervene on your site during the file transfer, you will obtain incoherent results.

In your private area, you will see a message (which varies depending on the version jump you are performing) of the type: "Technical Message: the upgrade procedure should be run to adapt the database to the new version of SPIP. If you are a site administrator, please click on this link".

As an administrator, follow the link to begin the update of the SPIP database. An FTP authentication screen will be displayed, similar to the backup procedure referred to above. This is intended to safeguard the database.

image 420 x 225

As for the backup, copy the name indicated by this screen and, using your FTP client, create a new directory or file in the tmp directory, unless you have a special configuration (prior to SPIP 1.9 this was the "ecrire/data" directory) with the name you have just copied. Your new folder will be of the form "admin_xxxxx".

Click on the "reload this page" button and the database will be updated, after which you will be returned to the private area.

That’s it, the upgrade is complete.

Allow us to repeat our warning, because it is a classic error: Do not restore the database from the backup made earlier. This backup now corresponds to an old database structure, so it is now unusable with your current system. If the operation proceeded correctly, you may even destroy this old backup.

In the event of snags!

-  In certain places of the private area (and sometimes on the public site), I obtain error messages such as "file not found", "file missing", or other messages indicating an incomplete or missing file.

There may have been problems transferring your files via FTP. Using your FTP client, check the sizes of the affected files; in particular, if a file has a size of 0 KB, reinstall the file.

-  I obtain many error messages.

Again reinstall all of the files via FTP - some of them may have been omitted in the transfer process.

-  My site almost functions correctly, but certain functions do not work, the authors encounter problems whereas administrators do not, etc.

Check the SPIP user’s mailing list. First off, consult the list archives to see whether your problem has been encountered already.

If not, send precise details of your problem to the list, including the following details: which host, version upgraded from/to; do not forget to mention if this problem existed in the previous version. If your problem is a new bug, the developers will work quickly to try to resolve it.

Some additional useful links (in French):
-  SPIP FAQ
-  FAQ Spikini
-  Updating your SPIP site

P.S.

Remember to also check the compatibility of the other contributions and plugins that you use to make sure they work with the new version of SPIP. Where necessary, get the new versions of those plugins and update them too when necessary.


Show the template of this page Site powered by SPIP | Translation area | Private area