---- IMPORTANT ----
This article is for general guidance. If you have a working Senzing system with data and insight you do not wish to lose, or are unsure of any steps please contact us for assistance.
Always perform an upgrade test on a non-production environment first!
---- IMPORTANT ----
With a new release there are a few considerations and steps to take to upgrade. The following assumes you are using the default deployment path - /opt/senzing/g2 - if not change to suit your deployment.
- Download the latest Senzing API
wget --trust-server-names https://senzing.com/APILatest
- Backup your existing Senzing deployment
- Uncompress the new API package and if needed move it to /opt/senzing/. You can use the -C argument of tar to uncompress to a destination directory. The package will uncompress to a root path of g2/, to uncompress to /opt/senzing/ if you are not in this path you would add -C /opt/senzing/ to the tar command
tar xvf <senzing_package_name>.tgz
mv g2 /opt/senzing
- If you have a license file move it from the backup to the new deployment
mv /opt/senzing/g2_backup/data/g2.lic /opt/senzing/g2/data
- If you modified G2Project.ini or G2Module.ini make the same changes to the new files
- It's recommended to compare the old and new and not move them, there might be changes to these files between releases
- Changes to these files are usually different database connections strings if you have modified these to point to a different database or increasing the number of threads the engine is using
- If you created your own directories and projects under /opt/senzing/g2/python/demo copy those over
cp -r /opt/senzing/g2_backup/python/demo/<your_dirs_here> /opt/senzing/g2/python/demo
- If you created any other files or backups - for example g2config.json configuration files ensure you copy those over too
- If Senzing has supplied a custom g2config.json file or you have modified your g2config.json file yourself copy this too - if you're unsure please check with us. Modifications are usually made with the G2ConfigTool.py
cp /opt/senzing/g2_backup/python/g2config.json /opt/senzing/g2/python
- Check /opt/senzing/g2/data for schema update files for your database. These are named g2core-schema-xxx-upgrade-y.y-to-z.z.sql where xxx is the supported database name and y.y and z.z indicate the progression of releases, e.g. 1.4-to-1.5.
If there is an upgrade schema script review it with your DBA and apply the changes depending on your database environment and best practices. If you have any questions about the schema changes please contact us
- Don't forget to source the setupEnv file to configure your environment. If Senzing is deployed in a directory other than /opt/senzing/g2, update the setupEnv file first to reflect the deployment path
- Run a test load of the sample data to test the new deployment. This simulates a load but doesn't load any data.
python G2Loader.py -T
Once successfully deployed you can archive or delete the /opt/senzing/g2_backup directory once you are satisfied you no longer need it's contents.
Note: If you were using the embedded sqlite database with G2, the prior version database files are located in /opt/senzing/g2_backup/sqldb if you'd like to keep them.