[isf-wifidog] Auth Server Upgrade

Benoit Grégoire bock at step.polymtl.ca
Mer 10 Jan 21:33:29 EST 2007


On Wednesday 10 January 2007 15:14, Gabe Sawhney wrote:
> I dunno how others do it, but I upgraded our auth server last week
> (from one that was even older than yours), this way:
>
> - download from svn into a new folder, in the same apache virtual
> server space (i.e. auth.wirelesstoronto.ca/newauth)
> - create a new postgres database called wifidog-new (or whatever)
> - pg_dump wifidog > wifidog.sql
> - psql wifidog-new < wifidog.sql

That will prompty destroy all the Binary blobs (such as those in the Image 
content type) on many versions of postgres.

Use the sql/backup_database.sh and sql/restore_database.sh scripts instead.

> - run the install.php script as if it was a new install, and it
> upgrades the schema

Unless you missed a step, the wifidog-new is never used for anything, and not 
modified bit the install script.

> - bail on the install.php script after the schema upgrade ('cause
> otherwise it tries to create a new admin account)

It's more reliable to just go to the auth server home page to update the 
schema.  The corresponding code in install.php will be deleted, and it may 
not be safe.

> >From now on we'll be better about keeping it updated, so I'll just do
>
> svn updates to the live site.
>
> If the process above seems bonkers to anyone, please let me know -- I
> promise to put the info on the wiki.  <smile>

Basically, the recommended process goes:
1-Read the Changelog (seriously)
2-Use sql/backup_database.sh before the upgrade
3-Testing (optionnal, but recommended)
3.1-Checkout lastest SVN on a developement machine (not the same one as your 
server, unless you really know what you are doing: you need to modify 
config.php to point to a different DB, and you cant's use the restore script 
directly 
3.2-Restore your live database on the development machine.  Check if 
everything seems in order (good tests are loging-in, viewing your most 
complicated portal and opening the Reusable content library).  For a more 
complete test (especially if you didn't upgrade in months), plug a gateway to 
your development server and login, and try creating a new account.
4-Run svn update on your live server
5-Go to your auth server home page to make sure the schema has been updated 
(it may already have been by a random user accessing the auth server)
6-If the Changelog mentionned dependency changes (or if unsure), start the 
install script till the dependencies page.

-- 
Benoit Grégoire
Technologies Coeus inc.
-------------- section suivante --------------
Une pièce jointe non texte a été nettoyée...
Nom: non disponible
Type: application/pgp-signature
Taille: 189 octets
Desc: non disponible
Url: http://listes.ilesansfil.org/pipermail/wifidog/attachments/20070110/980d9c16/attachment.pgp


Plus d'informations sur la liste de diffusion WiFiDog