Archived community.zenoss.org | full text search
Skip navigation
Currently Being Moderated

Migrating Between Zenoss Installations

VERSION 1 
Created on: Oct 7, 2010 3:05 PM by Matt Ray - Last Modified:  Oct 7, 2010 6:27 PM by Matt Ray

When migrating between installers of the same version and archtitecture (ie. 32->32 bit), there are a number of issues you need to watch for.  These instructions are fairly accurate, but feel free to clarify or make updates as you find them.

 

  1. Backup Zenoss.
    1. Go to Settings -> ZenPacks in the web interface and make note of any non-standard/custom ZenPacks.
    2. Login to Zenoss Appliance using SSH.
      # su - zenoss
      $ cd $ZENHOME/bin
      $ wget http://dev.zenoss.org/svn/trunk/bin/rrdToXml.py
      $ chmod 755 rrdToXml.py
      $ rrdToXml.py
      $ zenbackup --file=~/zenoss_backup.tar.gz
      
    3. Transfer the backup file.
      1. If you are migrating in place you will need to copy this backup file to a temporary location not on this server.
      2. If you are migrating to new hardware you can copy the backup directly to that system.
  2. Perform a standard Zenoss installation on the new server according to the installation guide. The Zenoss version must be the same as what is running on the appliance.
  3. Install all of the previously noted non-standard/custom ZenPacks on the new server.
  4. Login as root to new Zenoss server using SSH.
    1. Stop Zenoss on the new server.
      # service zenoss stop
      
    2. Restore the backup to the new server.
      # su - zenoss
      $ zenrestore --dbuser=zenoss --dbpass=zenoss --file=zenoss_backup.tar.gz
      $ cd $ZENHOME/bin
      $ wget http://dev.zenoss.org/svn/trunk/bin/xmlToRRD.py
      $ chmod 755 xmlToRRD.py
      $ xmlToRRD.py
      
    3. Fix paths.
      $ cd $ZENHOME/etc
      $ replace '/home/zenoss' "$ZENHOME" -- *
      $ replace '/usr/lib/zope' "$ZENHOME" -- *
      $ replace '/usr/bin/python' "$ZENHOME/bin/python" -- *
      
    4. Fix hard-coded hostnames.
      $ replace $(grep hubhost zenping.conf | awk '{ print $2 }') 'localhost' -- *
      
    5. Start Zenoss.
      $ zenoss start
      
  5. Check for any hard-coded paths within the system with this zendmd script. You'd just switch /home/zenoss to something like /usr/local/zenoss/zenoss or whatever the appropriate value is for your install.
    for s in zport.portal_skins.objectValues():
        try:
            path = s.getDirPath()
            if '/home/zenoss' in path:
                s.manage_properties(path.replace('/home/zenoss', '/opt/zenoss'))
        except:
            pass
    
Comments (0)