The following instructions assume you have completed the steps for Installing the operations center and have a new operations center accessible.
Prerequisites
-
Make sure that the destination operations center is running the same or a more recent version of CloudBees CI.
-
If the client controller is using operations center SSO, the disconnection will cause the client controller to switch to the fallback Security Realm that should allow users to still be able to sign in. Review the Single sign-on fallback behavior guide to ensure that this is set up properly. Otherwise, the controller will not be accessible when disconnected, and in that case, security would need to be disabled temporarily to reconnect the controller. Refer to How do I login to Jenkins when I locked myself out? to restore access.
-
If the destination operations center is using
https
, make sure it is trusted by the client controller. Otherwise, add the required certificate(s) to the client controller’s truststore. Refer to How to install a new SSL certificate on Traditional Platforms? for more information.
Disconnect client controller from the UI
-
Navigate to the client controllers
page. -
Uncheck the
checkbox and select Save. -
Back up the
config.xml
andnectar-rbac.xml
of the client controller item (available in the directory$CJOC_HOME/jobs/<pathToClientcontrollerItem>/
) on the operations center. -
Navigate to the operations center
page and select Release. -
Navigate to the new operations center and create a new client controller item.
-
Connect the client controller by either:
-
Pushing connection details.
-
Copy/pasting the connection details as documented in Setting up your new client controller.
-
-
If there was an RBAC configuration for the controller item, restore the RBAC configuration on the new operations center from the backed up
nectar-rbac.xml
by restoring that file into the new operations center filesystem at$CJOC_HOME/jobs/<pathToClientcontrollerItem>/nectar-rbac.xml
, then restart the operations center (or use ). For more information on how to restore the RBAC configuration, refer to How to save RBAC configuration when a client controller needs to be renamed?.
If client controller is not accessible from the UI
If you do not have access to the UI or cannot sign in to the client controller after disconnecting it, do the following:
-
On the current operations center, backup the
config.xml
andnectar-rbac.xml
of the client controller item (available in the directory$CJOC_HOME/jobs/<pathToClientcontrollerItem>/
). -
Navigate to the Disconnect and Release the client controller.
page and refer to -
On the controller, stop the client controller.
-
In the client controller file system, delete the following:
-
$JENKINS_HOME/license.xml
-
$JENKINS_HOME/operations-center-cloud*
-
$JENKINS_HOME/operations-center-client*
-
$JENKINS_HOME/com.cloudbees.opscenter.client.plugin.OperationsCenterRootAction.xml
-
-
Disable security in the client controller by editing
$JENKINS_HOME/config.xml
.-
Locate this line:
<useSecurity>true</useSecurity>
-
Change it to:
<useSecurity>false</useSecurity>
This method is risky if your instance is accessible to others because it allows unrestricted access to all information, including secret credentials and all jobs. This method should only be used when you isolate network access to the instance during the timeframe when security is disabled. If using Configuration as Code for controllers, Configuration as Code needs to be disabled temporarily. Remove the -Dcore.casc.config.bundle=…
argument.
-
-
Start the client controller.
-
On the new operations center, create a new client controller item.
-
Connect the client controller by either:
-
Pushing connection details.
-
Copy/pasting the connection details as documented in Setting up your new client controller.
-
-
If there was an RBAC configuration for the controller item, restore the RBAC configuration on the new operations center from the backed up
nectar-rbac.xml
by restoring that file into the new operations center filesystem at$CJOC_HOME/jobs/<pathToClientcontrollerItem>/nectar-rbac.xml
, then restart the operations center
For more information on how to restore the RBAC configuration, refer to How to save RBAC configuration when a client controller needs to be renamed?.
For additional information, refer to the following: