Xray Single Node Manual RPM/Debian Upgrade

JFrog Installation & Setup Documentation

Content Type
Installation & Setup
ft:sourceType
Paligo

Upgrading from Xray 3.16.2 to 3.69.3 in Debian Installations

When you upgrade from Xray 3.16.2 to higher versions, Xray service might not come up after installation. This is because of an incompatible Erlang package in RabbitMQ. You must remove the Erlang package from your installation before you proceed with the upgrade.

If you upgraded to a higher version, run the following commands.

dpkg --purge --force-all esl-erlang
cd jfrog-xray-<version>-deb/third-party/rabbitmq
dpkg -i esl-erlang_23.2.3-1_ubuntu_bionic_amd64.deb
systemctl start xray.service

Upgrading to Xray 3.70.0 or later from an Xray version prior to 3.70.0

If you are upgrading to Xray 3.70.0 or later from an Xray version prior to 3.70.0, your installation contains RabbitMQ 3.8.x. Feature flags in RabbitMQ have to be enabled before you can upgrade, since Xray 3.70.0 and later contains RabbitMQ 3.11.x and later.

Before you proceed with the upgrade, go to RabbitMQ Upgrade to version 3.11.x and set feature flags in RabbitMQ.

Install/Upgrade Xray 3.70.0 to 3.74.0 with RPM

Xray installation/upgrade might fail because of the missing package libltdl. If you face the error, you can download and install the package, and proceed with the installation/upgrade of Xray.

  1. Download Xray (RPM or Debian).

  2. Stop the current server.

    systemd OS

    systemctl stop xray.service

    systemv OS

    service xray stop
  3. Store the RabbitMQ password securely before you proceed with the upgrade.

    You can find the password inside the file, $JFROG_HOME/app/bin/rabbitmq/rabbitmq.conf.

  4. Extract the contents of the compressed archive and go to the extracted folder.

    tar -xvf jfrog-xray-<version>-<rpm|deb>.tar.gz
    cd jfrog-xray-<version>-<rpm|deb>

    Note

    Starting from Xray 3.8.x, RabbitMQ bundled with Xray has been upgraded, and it requires an upgrade of the Erlang library. This library can be found on $JFROG_HOME/xray/app/third-party. For more information, see Installing Erlang.

    Note

    To upgrade the dependencies for RabbitMQ, you will need to upgrade socat/erlang by using "--replacefiles" to work around a file conflict error.

  5. Install Xray as a service on Red Hat compatible Linux distributions, as a root user.

    RPM

    yum -y install ./xray/xray.rpm

    Debian

    dpkg -i ./xray/xray.deb
  6. Update the RabbitMQ password inside the file, $JFROG_HOME/app/bin/rabbitmq/rabbitmq.conf, with the password that you previously stored.

  7. Start Xray.

    systemd OS

    systemctl start xray.service

    systemv OS

    systemctl start xray
  8. Access Xray from your browser at: http://<jfrogUrl>/ui/, go the Xray tab in the Application module in the UI.

  9. Check Xray Log.

    tail -f $JFROG_HOME/xray/var/log/console.log
RabbitMQ Upgrade to version 3.11.x

Xray version 3.70.0 and later includes RabbitMQ version 3.11.x later. An upgrade to Rabbit MQ 3.11.x requires feature flags to be enabled. For more information, refer to Required Feature Flags in RabbitMQ 3.11.0.

Enable Feature Flags in Linux Installations

You need to manually run the migration operation for RabbitMQ before you start Xray upgrade for your Linux installation (RPM, Debian, and Linux Archive).

Run the following command in the nodes that run RabbitMQ.

sudo -H -u xray bash -c 'export RABBITMQ_FEATURE_FLAGS="drop_unroutable_metric,empty_basic_get_metric,implicit_default_bindings,maintenance_mode_status,quorum_queue,stream_queue,user_limits,virtual_host_metadata"'
sudo -H -u xray bash -c '/opt/jfrog/xray/app/third-party/rabbitmq/sbin/rabbitmqctl enable_feature_flag all'