Upgrading tarball installations
There are two steps to upgrading a LedgerSMB 1.5.x to 1.6:
- Upgrade the software
- Upgrade the company database
The last step must be executed for each company database that's set up.
These steps also apply when upgrading a 1.4 installation running Starman. To upgrade 1.4 installations not running on Starman, or to upgrade from earlier versions, please see Upgrading to Ledgersmb 1.5. Note that the default configuration for 1.4 runs CGI, not Starman.
Before upgrading, it is recommended to backup your databases.
Note that all the steps below are prefixed with the 'sudo' command, but can be executed as 'root' directly as well.
Upgrading the software
These are the steps to follow, assuming an installation from tarball:
Stop the LedgerSMB application server (e.g. Starman) $ sudo service starman-ledgersmb stop
Back up the old software by moving it out of the way (assuming you installed in /usr/local/ledgersmb): $ sudo mv /usr/local/ledgersmb /usr/local/ledgersmb.backup
Untar the tarball into /usr/local/ledgersmb: $ sudo tar xf ledgersmb-1.6.x.tar.gz --directory /usr/local
Copy the configuration file from the old installation: $ sudo cp /usr/local/ledgersmb.backup/ledgersmb.conf /usr/local/ledgersmb/
Upgrade the LedgerSMB Starman SysV or systemd scripts (the new scripts can be found in /usr/local/ledgersmb/conf/systemd/ ) $ sudo cp /usr/local/ledgersmb/conf/systemd/ledgersmb_starman.service /etc/systemd/system/ledgersmb.service $ sudo systemctl daemon-reload
Start the LedgerSMB application server again (Starman example given, as before): $ sudo service starman-ledgersmb start
Upgrading the company database
After the software has been upgraded, the company database(s) must be upgraded. Otherwise, when a user logs in on a database with a different version compared to the software, a "Database version mismatch" error will be generated.
To upgrade the company database from the Web UI, navigate to the setup.pl page (e.g. when you're hosting your LedgerSMB on https://localhost/ and normally log in through https://localhost/login.pl, navigate to https://localhost/setup.pl). Log into setup.pl with the database admin credentials (the "lsmb_dbadmin" user, if you followed the installation instructions).
After login, setup.pl will show a screen with the following at the top:
Logged in as lsmb_dbadmin
LedgerSMB 1.5 db found
By clicking the "Yes" button, the company database upgrade process will be executed.
Repeat this process for all company databases.
If upgrading from 1.4, rather than 1.5, note that the text will show "LedgerSMB 1.4 db found" instead.