wiki:ToolUpgrade

Upgrading server software

The BOINC server software (scheduler, daemons, web pages) is continually improved and debugged. We recommend that projects upgrade whenever a new server_stable version is released. There may also be points where upgrades are mandatory to continue working with current client software. We maintain a list of recent changes.

The steps required to upgrade are as follows:

  1. (Optional) Stop the project.
  2. Download (using Git) the server_stable branch (or the trunk). Compile it in your BOINC source directory (called `source' below).
  3. Recompile all project-specific back end programs (validators, assimilators).
  4. Run the upgrade script:
    $ cd source/tools
    $ ./upgrade project_name
    
    The upgrade script copies files from the source/html/, source/sched and source/tool

directories to the corresponding project directories and selected files from source/py/BOINC' to the project bin' directory.

  1. Start the project, and check log files to make sure everything is OK. Run the BOINC client and test basic functions (attaching to project, getting work).

Options

You can update only the web code (PHP files), using:

$ ./upgrade --web_only  project_name

You can update everything except the web code using:

$ ./upgrade --server_only project_name

The default project root directory is $HOME/projects/project_name. If this is not where your project lives, you can give the full path of the project root:

$ ./upgrade /path/to/projects/project_name

You can run upgrade from a directory other than boinc/tools by specifying the BOINC source directory:

$ ~/boinc/tools/upgrade --srcdir ~/boinc

Updating the database structure

Starting with Git changeset 9383a77, database updates are performed automatically by upgrade. Older updates must be done as follows.

$ cd project/html/ops

and look at the file db_update.php. This has a number of functions in it with names like

update_8_05_2005()

Each function performs a particular database update. You must perform all updates, in sequence, starting from your last server software upgrade. If you are not sure when that was, you can use mysql to see that current format of your database. For example, to see the fields in the user table, type

$ mysql project_name
mysql> explain user;

To do a particular update, edit db_update.php so that (at the bottom) it calls that function. Then do

$ php db_update.php

Repeat this for the necessary updates, in increasing chronological order.

Last modified 12 years ago Last modified on Jan 19, 2013, 2:57:31 PM