Skip to content

Updating non-appliance deployments to release 6.10.0

Use the instructions on this page to update Resource Manager deployments that are not based on a virtual appliance. The instructions on this page support updates from release 6.9.0 to 6.10.0.

Updates from Resource Manager 6.8.0 have been minimally tested. Release 6.10.0 contains many changes since 6.8.0, so update to 6.9.0 first when you can. RHEL 8 and CentOS 7 are not supported: move the hosts to Rocky Linux 9, AlmaLinux 9, or RHEL 9 before you update Control Center.

To perform some of the procedures on this page, you need:

  • A workstation with internet access.
  • Permission to download files from delivery.zenoss.io. Customers can request permission by filing a ticket at the Zenoss Support site.
  • A secure network copy program.

Upgrade Control Center first

These instructions do not include steps for updating Control Center or the host operating system. Resource Manager 6.10.0 requires Control Center 2.1.0. Update Control Center on every host first. For the procedure, see Updating Control Center to release 2.1.0. For the changes in that release, see the Control Center 2.1.0 release notes.

Updating from Control Center 1.11.0 changes Control Center

The update to Control Center 2.1.0 adds registry authentication on every host and clears the Control Center internal services HBase data. This removes the Control Center internal metric history only. It does not remove Resource Manager device metrics. The Control Center update guide describes both steps.

Prepare to update


Verify normal operation, create backup

Follow these steps to prepare your deployment:

  1. Verify that Resource Manager is operating normally.

    1. Log in to the Control Center browser interface as ccuser.

    2. In the Application column of the Applications table, click Zenoss.resmgr.

    3. Verify that all of the services in the IP Assignments table have valid IP addresses.

    4. Scroll down to the Services table, and then verify that none of the child services have failing health checks.

  2. Check the integrity of Resource Manager databases. For more information, see Using Zenoss Toolbox.

  3. Create a backup of Resource Manager with the Control Center backup feature.

Install the base image, if necessary

The Resource Manager update script relies on specific content that is typically found within the base image of the installed release. For example, if the base image was installed on RM 6.9, then RM 6.9 is necessary for the script to run successfully.

This base image contains essential components and configurations that the script uses during the update process. However, if the layers of the base image have been flattened to optimize storage and performance after the initial installation, then some important metadata, such as labels, may be lost. The upgrade script might not be able to locate the necessary content within the base image and the script will fail to execute properly.

Follow these steps to determine whether the base image is present, and to download and import it, if necessary.

  1. Log in to the Control Center host as root or as a user with superuser privileges.

  2. Search for the base image.

    docker images | grep -E 'zenoss/resmgr'
    
    • If the command returns a result, the base image is present. Continue to the next procedure.

    • If the command returns no result, the base image is absent. Perform the remaining steps of this procedure.

  3. In a web browser, navigate to delivery.zenoss.io, and then log in.

  4. Download the self-installing base image file for the currently installed release of Resource Manager, release 6.9.0.

    install-zenoss-resmgr_6.9_6.9.0_1.run
    
  5. Copy the file to the Control Center master host.

  6. Log in to the master host as root or as a user with superuser privileges.

  7. Change directory to the directory where the image file is located.

  8. Add execute permission to the image file and then import it.

    chmod +x ./install-zenoss-resmgr*run && yes | ./install-zenoss-resmgr*run
    
  9. Verify the base image is present.

    docker images | grep -E 'zenoss/resmgr'
    

Download and import Resource Manager image files

Use this procedure to download files required to update Resource Manager and then to copy the files to a Control Center master host.

Follow these steps:

  1. In a web browser, navigate to delivery.zenoss.io, and then log in.

  2. Download the self-installing Docker image files for Resource Manager 6.10.0.

    install-gcr.io-zing-registry-188222-resmgr_6.10:6.10.0_<build>.run
    install-gcr.io-zing-registry-188222-mariadb-resmgr:6.10.0_<build>.run
    install-zenoss-serviced-isvcs_v80.run
    install-zenoss-isvcs-zookeeper_v18.run
    install-zenoss-hbase:24.0.12.run
    install-zenoss-opentsdb:24.0.12.run
    install-zenoss-memcached:cc38f31.run
    install-zenoss-redis:760f98c.run
    install-zenoss-rabbitmq:5ccc9e3.run
    install-zenoss-metric-consumer:dc5433f.run
    install-zenoss-query:aa78191.run
    install-zenoss-solr:1.1.9.run
    install-zenoss-zproxy:1.0.12.run
    

    If your deployment includes Zenoss Service Impact (Zenoss Service Dynamics only), also download the Impact image file.

    install-zenoss-impact_5.7:5.7.0.run
    
  3. Copy the files to the Control Center master host.

  4. Log in to the master host as root or as a user with superuser privileges.

  5. Copy or move the archive files to /root.

  6. Add execute permission to the files.

    chmod +x /root/*.run
    
  7. Change directory to /root.

    cd /root
    
  8. Import the images.

    for image in install-*.run
    do
      /bin/echo -en "\nLoading $image..."
      yes | ./$image
    done
    
  9. List the images in the registry.

    docker images
    

    The result should include one image for each archive file.

  10. Optional: Delete the archive files, if desired.

    rm -i ./install-*.run
    
  11. Copy the update scripts from the new Resource Manager image to a directory in /root.

    docker run -it --rm -v /root:/mnt/root gcr.io/zing-registry-188222/resmgr_6.10:6.10.0_<build> rsync -a /root/6.10.x /mnt/root
    

Verify the internal services image

Resource Manager 6.10.0 runs the zenoss/serviced-isvcs:v80 internal services image. The Control Center 2.1.0 update sets it with SERVICED_ISVCS_IMAGE on the master host. Confirm that the master host runs it.

  1. Log in to the Control Center master host as a user with serviced CLI privileges.

  2. Display the internal services images. The result includes zenoss/serviced-isvcs:v80.

    serviced version | grep Images
    

    If the result shows another version, such as v77, set SERVICED_ISVCS_IMAGE=zenoss/serviced-isvcs:v80 in /etc/default/serviced on the master host, and then restart Control Center with systemctl restart serviced.

Optional: Manage custom MariaDB passwords

If you are using custom database passwords for the mariadb-events and mariadb-model services, the passwords must be managed before starting the update process for Resource Manager.

Follow these steps to determine whether custom passwords are in use:

  1. Log in to the Control Center master host as a user with serviced CLI privileges.

  2. Display the MariaDB passwords.

    serviced service list Zenoss.resmgr | awk '/(zep|zodb).*-password/'
    

    When the default passwords are in use, the result looks like this:

         "global.conf.zep-admin-password": "",
         "global.conf.zep-password": "zenoss",
         "global.conf.zodb-admin-password": "",
         "global.conf.zodb-password": "zenoss",
    

You can manage the passwords with either of the following methods:

Perform the update


Stop Resource Manager

Follow these steps:

  1. Log in to the Control Center master host as a user with serviced CLI privileges.

  2. Check the status of Resource Manager.

    serviced service status Zenoss.resmgr --show-fields 'Name,ServiceID,Status'
    
    • If the status of all services is stopped, this procedure is complete. Continue to the next procedure.

    • If the status is running, perform the remaining steps.

  3. Stop Resource Manager.

    serviced service stop Zenoss.resmgr
    
  4. Check the status of Resource Manager.

    serviced service status Zenoss.resmgr --show-fields 'Name,ServiceID,Status'
    

    Repeat the command until the status of all services is stopped.

Optional: Keep your changes to the Resource Manager image

By default, the update replaces the Resource Manager image, and changes that you committed into the image are lost. Examples of such changes are a ZenPack that Zenoss doesn't ship, a patch to a Zenoss file, a Python module installed with pip, or a file under /etc. To keep them, update with the --preserve-image-layers option of upgrade-resmgr.sh. Perform this procedure first.

The option keeps the files that you added in the new Resource Manager image. It doesn't keep a change to a file that the new image also ships. The update reports these files as conflicts, and you make those changes again after the update.

Before you begin, make sure that the master host has:

  • python3 installed.
  • Free disk in /root/6.10.x of about three times the size of the Resource Manager image (about twice for the dry run).
  • Free Docker data space of about twice the size of the Resource Manager image.

Follow these steps:

  1. Log in to the Control Center master host as root or as a user with superuser privileges.

  2. Run a dry run. It changes nothing and writes the report /root/6.10.x/rebase-report.txt.

    /root/6.10.x/upgrade-resmgr.sh -n --preserve-image-layers
    
  3. Read the report. It lists the following groups:

    • Kept: your files that the new image holds.
    • Dropped: files that the update doesn't need to keep. Class A is a ZenPack file that the update restores. Class B is a .pth, log, or lock file. Class C is compiled Python code or a cache. Unchanged copies and removed paths are counted only.
    • Conflicts D: you changed a Zenoss file, or added a file that the new image also ships. Your copy is not kept.
    • Conflicts E: you removed a file that the new image ships. The removal is not kept.

    A row whose old and new Zenoss hashes are equal names a file that a service writes when it starts. Usually you don't need to act on these rows.

  4. If the report lists D conflicts, save your copies of those files now. The report gives only the path and the hashes of each file. After the update, the old image remains only in the pre-upgrade snapshot, and it is lost when the snapshot is removed.

    a. Find the current Resource Manager image.

    ```sh
    TENANT=localhost:5000/$(serviced service list "Zenoss.resmgr/Zenoss/User Interface/Zope" --format '{{.ImageID}}')
    echo $TENANT
    ```
    

    b. Copy each file in a D row to /root/rebase-conflicts. The commands change no image and no service.

    ```sh
    REPORT=/root/6.10.x/rebase-report.txt
    OUT=/root/rebase-conflicts
    mkdir -p $OUT
    cid=$(docker create $TENANT true)
    awk '$1=="D" {print $2}' $REPORT | while read p; do
      mkdir -p "$OUT/$(dirname "$p")"
      docker cp "$cid:/$p" "$OUT/$p" 2>/dev/null || echo "not in the image: $p"
    done
    docker rm $cid
    cp $REPORT $OUT/
    find $OUT -type f | wc -l
    ```
    
    The count is one file for each D row, plus the copy of the report. An E row names a
    file that you removed, so there is nothing to save for it.
    

    c. Optional: To see what you changed in a Zenoss file, save the old Zenoss copy and compare the two. Replace <path> with the path from the D row.

    ```sh
    VENDOR=$(awk '/^Old vendor image:/ {print $4}' $REPORT)
    docker run --rm --entrypoint cat $VENDOR /<path> > $OUT/<path>.vendor
    diff -u $OUT/<path>.vendor $OUT/<path>
    ```
    
  5. In the next procedure, start the update script with the --preserve-image-layers option.

Note the following limits:

  • The option is tested on updates from Resource Manager 6.9.0.
  • If you roll back to the pre-upgrade snapshot after an update with this option, don't run the update with the option again. The second run stops, because the first run changed the services migration script.
  • The appliance update doesn't use this option. To use it on an appliance, run the script by hand.

Update Resource Manager

Follow these steps to update Resource Manager.

  1. Log in to the Control Center master host as root or as a user with superuser privileges.

  2. Start the update script.

    /root/6.10.x/upgrade-resmgr.sh
    

    The update process begins. The following message appears frequently and can be ignored:

    sync.go:85: ERR Failed to publish events caused by: EOF
    

    If you changed the Resource Manager image and want to keep the changes, run the script with the --preserve-image-layers option instead. First complete the steps in Optional: Keep your changes to the Resource Manager image.

    /root/6.10.x/upgrade-resmgr.sh --preserve-image-layers
    

    With this option, the script saves the current Resource Manager image and the new image, compares their files, writes a new image that carries your changes, and loads it. This step takes several minutes. The time depends on the size of the Resource Manager image and of your own changes, not on the amount of monitoring data, because the databases are stored in Control Center volumes, not in the image. Don't interrupt the script while this step runs.

    The script prints a line with the time for each phase of the step, for example HH:MM:SS Preserve image layers: saving the tenant image .... When the step ends, it prints the new image tag (Rebased tag:), the location of the report (Report:), and the number of conflicts (Conflicts:). Read the full report in /root/6.10.x/rebase-report.txt before you continue. To put back a change that the report lists as a conflict, see Optional: Restore a conflicting change after the update.

  3. (Optional) While the script runs, you might encounter an error. Use the following list to identify the error or errors and apply the recommended solution.

  4. Stop Resource Manager. Some Resource Manager services are started during the update, and they must be stopped.

    serviced service stop Zenoss.resmgr
    

Perform post-update tasks


Remove the pre-upgrade snapshot and start Resource Manager

The Resource Manager update script uses Control Center to create and tag a snapshot of the system before it begins the update process. Tagged snapshots persist until they are explicitly removed, and grow over time. When you are satisfied the new release is working properly, remove the pre-update snapshot.

  1. Log in to the Control Center master host as a user with serviced CLI privileges.

  2. Display a list of all Control Center snapshots, with their tags.

    serviced snapshot list -t
    

    Example result, truncated to save space:

    Snapshot                         Description  Tags
    xm5mtezbyo2_20160211-220535.480               preupgrade-resmgr-6.10.0
    

    The snapshot identifier is shown in the first column.

  3. Remove the pre-update snapshot.

    Replace Snapshot-ID with the identifier of the pre-update snapshot returned in the previous step:

    serviced snapshot remove Snapshot-ID
    
  4. Start Resource Manager.

    serviced service start Zenoss.resmgr
    

Rebuild device configurations

Device configurations that were built before the update stay current afterward. Until each device changes, collectors keep using objects that the old ZenPack code built. For example, CiscoMonitor status thresholds fail. To rebuild all device configurations, expire them.

  1. After Resource Manager starts, log in to the Control Center master host as a user with serviced CLI privileges.

  2. Attach to the zope service as the zenoss user.

    serviced service attach zope/0 su - zenoss
    
  3. Expire all device configurations. Do not give a device argument.

    configcache device expire
    

    At the prompt Recreate all device configurations. Are you sure (y/N)?, enter y. The command reports how many device configurations it expired, and the configurations rebuild within a minute.

  4. Exit the zope service.

    exit
    

Optional: Restore a conflicting change after the update

If you updated with --preserve-image-layers and the report listed D conflicts, make those changes again in the new image. Don't copy a saved file over the new file. The saved file holds the old Zenoss code around your change.

  1. For each file in /root/rebase-conflicts, check whether the new release already includes your change. Compare your change with the same file in the new image. A support patch is often part of a later release.

    The path can differ in the new image. For example, /opt/zenoss/Products in Resource Manager 6.8 is /opt/zenoss/lib/python2.7/site-packages/Products in 6.9 and later.

  2. Log in to the Control Center master host as a user with serviced CLI privileges.

  3. Open a shell in the zope service that saves its changes. Replace <name> with a name for the change.

    serviced service shell -i -s <name> zope bash
    
  4. Make the change in the new file, and then exit the shell.

  5. Commit the change to the Resource Manager image.

    serviced snapshot commit <name>
    
  6. Restart the services that use the changed file.

If you use quilt to manage patches, note that the update keeps the quilt metadata in /opt/zenoss/.pc and /opt/zenoss/patches. A quilt pop can fail after the update.

Optional: Install the application template

The most recent Resource Manager application template is not included in non-appliance updates and is not needed. Use the following procedure if you plan to delete a deployed application template and then redeploy a newer version of the template. (For example, in a development or staging environment.)

Follow these steps

  1. In a web browser, navigate to the delivery.zenoss.io site, and then log in.

  2. Download the template package file.

    zenoss-resmgr-service-6.10.0-1.noarch.rpm
    
  3. Copy the package file to the Control Center master host.

  4. Log in to the Control Center master host as root or as a user with superuser privileges.

  5. Change directory to the directory where the template package file is located.

  6. Install the template.

    yum install ./zenoss-resmgr-service-6.10.0-1.noarch.rpm
    

    The template file is stored in /opt/serviced/templates.