Cool Solutions

ZCM: Moving the Primary Server



By:

January 27, 2009 11:07 am

Reads:11,609

Comments:0

Score:Unrated

We are moving from ZENworks 7 to ZCM very shortly, and unfortunately for us what we used as our test environment for ZCM very quickly became the server we wanted to use (all the content was as we wanted it), except the hardware wasn’t! Short of re-converting all our applications again (a rather large and uninviting task), how do you move a primary server (including embedded database) from one place to another?

Initial machine:
XEN Virtual machine
SLES10SP1 32bit
2GB RAM
ZCM 10.1.1 using the embedded Sybase database

Production machine:
XEN virtual machine
SLES10SP1 64bit
4GB RAM
ZCM 10.1.1 using the embedded Sybase database

Note: although the below should work with devices already connected to the ZCM server, this was done with no devices (other than the single primary server). We plan to have many peer-primary and satellite servers, but this is just getting things ready to roll.

So we had re-built all our applications, policies, etc on our test box – how do we move that all to the new server?

First step – backup everything required on the current machine:

  1. Copy the certificates used by ZCM somewhere.

    We used an external certificate authority, so it was just a matter of copying/FTP’ing the three certificates (SSL certificate, SSL private key, and root CA key) off the test system. If you used an internal certificate authority have a look at ZENworks Server and Certificate Authority Backup and Restore documentation: http://www.novell.com/documentation/zcm10/zcm10_system_admin/index.html?page=/documentation/zcm10/zcm10_system_admin/data/bam65st.html

  2. Backup the database.

    To manually create a backup of the database, at a command prompt:

    • Store the admin password (so you don’t get prompted again):
    • Zman admin-store-credential administrator
    • Create some folders:
    • Mkdir /root/zcm_backups
    • Mkdir /root/zcm_backups/dbBackup
    • Take a backup of the database
    • Zman database-backup /root/zcm_backups/dbBackup
    • You should end up with two files –
    • Zenworks_zone_name.db
    • Zenworks_zone_name.log

    Copy/FTP them somewhere safe!

  3. Backup the ZENworks server. (server configuration and identity information)

    At a command prompt (as root):

    Zman zenserver-backup /root/zcm_backups/zone_backup.bak
    Note: you will be prompted for an administrator username and password, then a passphrase (of at least 10 characters) – you’ll need the passphrase later on so write it down somewhere!)

    Copy/FTP that file somewhere as well.

  4. Backup the content-repo.

    There are many ways to do this, I used NFS to put the data in an intermediate location, ready to be copied back to the new server –

    Edited /etc/exports (on the test ZCM server) and added this line:

    /data (rw,no_root_squash)
    Note: in my case /data had /data/content-repo under it, you could also just mount /data/content-repo directly if you wanted.

    Started the NFS server:

    rcnfsserver start

    Then on the intermediate machine:

    Mkdir /mnt/nfs
    Mount :/data /mnt/nfs
    Cp –R /mnt/nfs/content-repo /tmp/content-repo
    
    

That should be all you need – you should now have (somewhere other than your ZCM server)

  1. the three certificate files (or whatever gets generated by the ZENworks certificate authority backup)
  2. the two database files
  3. the zenworks server .bak file
  4. a copy of the content-repo directory

The next step is to build the new server, install ZCM, and then import all the above data onto our new machine.

  1. Shutdown your test ZCM server. You need to use the same IP address and DNS name for the new system, so we don’t want IP conflicts?
  2. Install SLES10SP1 + patch up to date. I’ll leave those steps up to you – I assume you know how to do that.
  3. Before installing ZCM I copied the three certificate files onto the new machine.
    Mkdir /var/certs

    And FTP’ed the files into that directory.

  4. Next I copied the ZCM ISO onto the machine, mounted and installed it.
    Mkdir /mnt/iso
    Mount –o loop ZCM_10.1.0.iso
    Cd /mnt/iso
    ./setup.sh –e
    
    

    Although I’m not sure if it’s required, I used the same zone name as my previous install.

  5. Under XEN with SLES10SP1 64bit the zenagent fails to load – to fix follow this TID 7000913: ZENworks Agent Daemon fails to load on XEN 64bit guest OS.
  6. Logged into the ZCC and did a system update to 10.1.1
  7. Restore the ZENworks server.

    Copy/FTP the zone backup made above to /root/zcm_backups, then:

    Zman zenserver-restore /root/zcm_backups/zone_backup.bak

    When prompted, enter a ZENworks administrator username and password.

    When prompted, enter the passphrase you entered when creating the backup.

  8. Restore the database.

    Copy/FTP the database backup you created earlier to /root/zcm_backups/dbBackup, then:

    Change to /opt/novell/zenworks/bin, and enter the following command:

    ./ZenworksLinuxDBRestore.sh –F "/root/zcm_backup/dbBackup/zenworks_zone_name.db"
  9. Restore the content-repo.

    Up to you how you do this, with NFS or from another backup.

You should now have a working ZENworks server again!

Pages of interest:

Server backup and restore forum discussion:
http://forums.novell.com/novell-product-support-fo…

Novell documentation:


0 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 50 votes, average: 0.00 out of 5 (0 votes, average: 0.00 out of 5)
You need to be a registered member to rate this post.
Loading ... Loading ...

Categories: Uncategorized

Disclaimer: This content is not supported by Novell. It was contributed by a community member and is published "as is." It seems to have worked for at least one person, and might work for you. But please be sure to test it thoroughly before using it in a production environment.

Comment

RSS