Re-Installing installhasvss

After you install installhasvss on a companion server, you should only re-run this script if the stored procedures it creates are corrupted, or if you need to install a newer version of installhasvss. dbcc ha_admin (' ', state_machine) temporarily moves the companion to single-server mode so the installhasvss can safely reinstall or update the stored procedures. If you attempt to run installhasvss without running dbcc ha_admin, the companion issues the following error message:

Server is not in single-server mode.
Please run dbcc ha_admin (' ', 'state_machine', 'halt') and try again

NoteBecause dbcc ha_admin moves the companion to single-server mode, you should only run this command when there is no concurrent activity.

Preform the following to re-install installhasvss:

  1. Make a note of the srvnetname for the SYB_HACMP entry in sysservers. When it is configured for Sybase Failover, SYB_HACMP points to the companion server’s svrnetname (for example, the srvnetname for the SYB_HACMP entry on companion server MONEY1 is PERSONNEL1). If the local node crashes while you are re-running installhasvss, this name is removed from sysservers, and you will have to replace it manually.

  2. Run dbcc ha_admin to move the companion to single-server mode:

    dbcc ha_admin (' ', 'state_machine', 'halt')
    

    Where '  ' is used for a placeholder.

  3. Re-run installhasvss. After installhasvss finishes, the companion server reverts to its original mode.

If the node crashes after you perform step 2, above, the srvnetname of the remote server is removed from sysservers. If this occurs, add the name of the remote server to sysservers by issuing:

sp_addserver SYB_HACMP, null, 'remote_server_svrnetname'

Run dbcc ha_admin to return the companion server to its original mode:

dbcc ha_admin (' ', 'state_machine', 'restart')