Follow

How To Change Zenoss Hub Password(s)

Applies To

  • Zenoss 4.2.3

Summary

To change the default password for one or more hubs, follow the one of the procedures below appropriate to your scenario.

Scenario I: A Single-Server Zenoss Deployment

Procedure

A. Log into the Zenoss web UI to change the hub password

  1. Navigate to Advanced > Collectors
  2. Click on the first localhost link
  3. Click on the Edit link in the left-hand navigation bar
  4. Update the ZenHub Password field and click Save

B. Log into the Zenoss master server to update the hub and collector configuration files

  1. Switch to the zenoss user:
    # su - zenoss
  2. Stop Zenoss:
    $ zenoss stop
  3. Go to the Zenoss configuration directory:
    $ cd $ZENHOME/etc
  4. Update the hubpasswd file with the new password:
    $ echo 'admin:NEW-PASSWORD' > hubpasswd
  5. Update the daemon configuration files to use the new password:
    $ sed -i 's/^#*hubpassword .*/hubpassword NEW-PASSWORD/' *.conf
  6. Start Zenoss:
    $ zenoss start

Scenario II: Multiple Hubs with the SAME Hub Password for All Hubs

Procedure

A. Log into the Zenoss web UI to change the hub passwords

  1. Navigate to Advanced > Collectors
  2. For each Hub:
    1. Click on the link to the hub
    2. Click on the Edit link in the left-hand navigation bar
    3. Update the ZenHub Password field with the new password and click Save

B. Log into the Zenoss master server to update hub and collector configuration files

  1. Switch to the zenoss user:
    # su - zenoss
  2. Update the hubpasswd file with the new password:
    $ echo 'admin:NEW-PASSWORD' > $ZENHOME/etc/hubpasswd
  3. Update all hubs and collectors with the new configuration:
    $ dc-admin update
    Note: Depending on the number of remote hubs and collectors. this may be a lengthy process.
    Note: If you have customized any settings in $ZENHOME/etc/global.conf, we strongly recommend that you verify those settings on all remote hubs and collectors once the update is complete.

Scenario III: Multiple Hubs with a DIFFERENT Hub Password for Each Hub

Procedure

A. Log into the Zenoss web UI to change the hub passwords

  1. Navigate to Advanced > Collectors
  2. For each hub:
    1. Click on the link to the hub
    2. Click on the Edit link in the left-hand navigation bar
    3. Update the ZenHub Password field with the new password and click Save

B. Log into the Zenoss master server to update hub and collector configuration files

  1. Switch to the zenoss user:
    # su - zenoss
  2. Update the hub password for the master server as set in step A.2 above:
    $ echo 'admin:NEW-HUB-PASSWORD' > $ZENHOME/etc/hubpasswd
  3. Update all hubs and collectors with the new password and regenerate their configuration files:
    $ dc-admin update
    Note: depending on the number of remote hubs and collectors. this may be a lengthy process
    Note: If you have customized any settings in $ZENHOME/etc/global.conf, we strongly recommend that you verify those settings on remote hubs and collectors once the update is complete
  4. Get a list of all the remote hubs:
    $ dc-admin --collector-pattern NONE list | grep -v localhost
  5. Run the following command for each remote hub, specifying the appropriate hub-specific password as set in step A.2.c above:
    $ ssh Hub-Hostname 'echo "admin:NEW-HUB-PASSWORD" > $ZENHOME/etc/hubpasswd'
  6. Restart the Zenoss daemons on all remote hubs and collections:
    $ dc-admin --no-master restart

C. Notes on subsequent configuration changes

  1. When adding a new hub:
    1. Be sure to specify a new Hub Password in the Add Hub diallog
    2. Once the hub has been added successfully, run the following command on the master server as the zenoss user:
      $ ssh Hub-Hostname 'echo "admin:NEW-HUB-PASSWORD" > $ZENHOME/etc/hubpasswd; zenoss restart'
  2. After performing a global update using dc-admin update (for example, after installing a patch set or ZenPack):
    • Repeat steps and B.4 – B.6 above on the master server as the zenoss user
Was this article helpful?
0 out of 0 found this helpful

Comments

Powered by Zendesk