6.9. Recovery Issues and Procedures

6.9.1. How to Rebuild the Primary Server's Administration Data Store
6.9.2. How to Replace the Primary Server with a Secondary Server
6.9.3. Secondary Server Recovery

If one of the servers of a failover group fails, the remaining group members operate from the administration data that existed prior to the failure. The recovery procedure depends on the severity of the failure and whether a primary or secondary server has failed.

Note

When the primary server fails, you cannot make administrative changes to the system. For replication to work, all changes must succeed on the primary server.

6.9.1. How to Rebuild the Primary Server's Administration Data Store

Use this procedure to rebuild the primary server's data store from a secondary server, and is performed on the server that was the primary server after it is fully operational again. This procedure uses the same host name for the replacement server.

Caution

Be sure to set umask appropriately before running utldbmcat. Otherwise, unprivileged users can gain access to the utadmin password.

  1. On one of the secondary servers, capture the current data store to a file called /tmp/store

    # /opt/SUNWut/srds/lib/utldbmcat /var/opt/SUNWut/srds/dbm.ut/id2entry.dbb > /tmp/store

    This command provides an LDIF format file of the current data store.

  2. Use FTP to send this file to the /tmp directory on the primary server.

  3. Follow the Sun Ray Software installation instructions.

  4. After running utinstall, configure the server as a primary server for the group.

    Make sure that you use the same admin password and group signature.

    # utconfig
    :
    # utreplica -p secondary-server1 [secondary-server2...]
    
  5. Shut down the Sun Ray services, including the data store.

    # /opt/SUNWut/sbin/utstop
  6. Restore the data.

    # /opt/SUNWut/srds/lib/utldif2ldbm -c -j 10 -i /tmp/store

    This command populates the primary server and synchronizes its data with the secondary server. The replacement server is now ready for operation as the primary server.

  7. Restart Sun Ray services.

    # /opt/SUNWut/sbin/utstart -c
  8. (Optional) Confirm that the data store is repopulated.

    # /opt/SUNWut/sbin/utuser -l
  9. (Optional) Perform any additional configuration procedures.

6.9.2. How to Replace the Primary Server with a Secondary Server

Note

This procedure is also known as promoting a secondary server to primary.

  1. Choose a server in the existing failover group to be promoted and configure it as the primary server.

    # utreplica -u
    # utreplica -p secondary-server1 [secondary-server2...]
    
  2. Reconfigure each of the remaining secondary servers in the failover group to use the new primary server:

    # utreplica -u
    # utreplica -s new-primary-server
    

    This command resynchronizes the secondary server with the new primary server.

Note

This process may take some time to complete, depending on the size of the data store. Since Sun Ray services will be offline during this procedure, you may want to schedule your secondary servers' downtime accordingly. Be sure to perform this procedure on each secondary server in the failover group.

6.9.3. Secondary Server Recovery

If a secondary server fails, administration of the group can continue. A log of updates is maintained and applied automatically to the secondary server once it has recovered. If the secondary server needs to be reinstalled, repeat the steps described in the Sun Ray Software installation instructions.