Upgrade Vertica

Before running the upgrade script, be sure to review the tasks described in Before You Upgrade.

To upgrade your database to a new Vertica version, complete the following steps:

  1. Perform a full backup of your existing database. This precautionary measure lets you restore from the backup, if the upgrade is unsuccessful. If the upgrade fails, you can reinstall the previous version of Vertica and restore your database to that version.

  2. Use admintools to stop the database.

  3. On each host where an additional package is installed, such as the R language pack, uninstall it. For example:

    rpm -e vertica-R-lang
    
  4. Make sure you are logged in as root or sudo and use one of the following commands to run the RPM package installer:

    • If you are root and installing an RPM:

      # rpm -Uvh pathname
      
    • If you are using sudo and installing an RPM:

      $ sudo rpm -Uvh pathname
      
    • If you are using Debian:

      $ sudo dpkg -i pathname
      
  5. On the same node on which you just installed the RPM, run update_vertica as root or sudo. This installs the RPM on all the hosts in the cluster. For example:

    • Red Hat or CentOS:

      # /opt/vertica/sbin/update_vertica --rpm /home/dbadmin/vertica-23.4.x.x86_64.RHEL6.rpm --dba-user mydba
      
    • Debian:

      # /opt/vertica/sbin/update_vertica --deb /home/dbadmin/vertica-amd64.deb --dba-user mydba
      

    The following requirements and restrictions apply:

    • The DBADMIN user must be able to read the RPM or DEB file when upgrading. Some upgrade scripts are run as the DBADMIN user, and that user must be able to read the RPM or DEB file.

    • Use the same options that you used when you last installed or upgraded the database. You can find these options in /opt/vertica/config/admintools.conf, on the install_opts line. For details on all options, see Install Vertica with the installation script.

    • Omit the --hosts/-s host-list parameter. The upgrade script automatically identifies cluster hosts.

    • If the root user is not in /etc/sudoers, an error appears. The installer reports this issue with S0311. See the Sudoers Manual for more information.

  6. Start the database. The start-up scripts analyze the database and perform necessary data and catalog updates for the new version.

    If Vertica issues a warning stating that one or more packages cannot be installed, run the admintools --force-reinstall option to force reinstallation of the packages. For details, see Reinstalling packages.

    When the upgrade completes, the database automatically restarts.

  7. Manually restart any nodes that fail to start.

  8. Perform another database backup.

Upgrade duration

Duration depends on average in-memory size of catalogs across all cluster nodes. For every 20GB, you can expect the upgrade to last between one and two hours.

You can calculate catalog memory usage on all nodes by querying system table RESOURCE_POOL_STATUS:

=> SELECT node_name, pool_name, memory_size_kb FROM resource_pool_status WHERE pool_name = 'metadata';

Post-upgrade tasks

After you complete the upgrade, review post-upgrade tasks in After you upgrade.