Updating Zammad

Note

Please backup your Zammad instance before update! You can learn how to back up Zammad on Backup and Restore.

Source update

1. Check your dependencies

Before proceeding, double-check that your system environment matches Zammad’s requirements.

2. Download Zammad to your system

Get the latest stable release of Zammad here, or find an older version at https://ftp.zammad.com.

$ cd /opt
$ sudo wget https://ftp.zammad.com/zammad-latest.tar.gz
$ sudo tar -C zammad -xzf zammad-latest.tar.gz
$ sudo chown -R zammad /opt/zammad
$ sudo su - zammad

3. Install all dependencies

zammad@host $ cd zammad
zammad@host $ gem install bundler
  • For PostgreSQL (note, the option says “without … mysql”):
zammad@host $ bundle install --without test development mysql
  • For MySQL (note, the option says “without … postgres”):
zammad@host $ bundle install --without test development postgres

4. Stop Zammad services

Stop the application server, websocket server and scheduler.

5. Upgrade your database

zammad@host $ export RAILS_ENV=production
zammad@host $ export RAILS_SERVE_STATIC_FILES=true # only if you use no HTTP reverse proxy
zammad@host $ rake db:migrate
zammad@host $ rake assets:precompile

6. Start Zammad services

Start the application server, websocket server and scheduler.

7. Go and login to Zammad

Update with RPM

1. Stop Zammad

$ sudo systemctl stop zammad

3. Update Zammad

$ sudo yum update zammad

Note: The package will automatically execute maintenance tasks like database changes and will restart Zammad for you.

4. Start Zammad

$ sudo systemctl start zammad

5. Go and log in to Zammad

Update with DEB

Note: Please backup your Zammad instance before update!

1. Stop Zammad

$ sudo systemctl stop zammad

3. Update Zammad

$ apt-get update
$ apt-get upgrade

Note: The package will automatically execute maintenance tasks like database changes and will restart Zammad for you.

4. Start Zammad

$ sudo systemctl start zammad

5. Go and log in to Zammad

Updating elasticsearch

If you want to upgrade your elasticsearch installation, please take a look at the elasticsearch documentation as it will have the most current information for you.

If, for whatever reason, you need to rebuild your search index after upgrading, use:

$ zammad run rake searchindex:rebuild

Warning

This step may fail if Zammad is under heavy load: Elasticsearch locks the indices from deletion if you’re pumping in new data, like receiving a new ticket. (This only applies to single-node deployments, not clusters.)

If it does, try killing Zammad first:

$ systemctl stop zammad
$ zammad run rake searchindex:rebuild
$ systemctl start zammad