Removing K2 node from K2 farm

Just a quick note on removal of a node(s) from K2 servers farm. When you run K2 uninstall on one of the nodes, and obviously when you suddenly lose one of your nodes (server failure without ability to restore it), information about it still stored in K2 database and additional steps are required in that scenario.

To reiterate, just running K2 uninstall on the node does not remove references to the node from K2 database.

To clear that up there is a stored procedure Server.kClusterDown which removes references to the node you removing from all the relevant tables:

Server.ProcInst
Server.DestQueue
Server.Async
Server.IPCAsync
Server.ClusterMessage

It sets Running=0 for node you want to remove in Server.Server table, and then updates all references to the server ID of the server you want to delete with ID of server which you keep.

You run this stored procedure specifying IDs (note: IDs not sever names) from Server.Server table as a parameters:

@ServerID = NEW SERVERID / ID OF THE SERVER WHICH STAYS IN YOUR FARM
@ClusterServerID = OLD SERVERID / ID OF THE SERVER WHICH YOU REMOVE FROM YOUR FARM
@ServerDownTimeout = 0

As usual before attempting any direct modifications on K2 system database you should back it up beforehand.

2 thoughts on “Removing K2 node from K2 farm

    1. Mikhail Post author

      Process is the same respectively of number of servers in your farm, you just stop K2 service on a server to be decommissioned/removed and then use stored procedure with correct server ID, once this stored procedure is executed you should make sure that K2 is removed from that server or server itself is removed to avoid starting K2 services on it by mistake afterwards.

      Reply

Leave a Reply to Mikhail Cancel reply

Your email address will not be published. Required fields are marked *