To change the SYSMAN password:
Stop the agent monitoring the target OMS and Repository in order to avoid that the SYSMAN account is locked during the process of changing the password.
If you have only one OMS connected to the repository, the agent to stop is the one which is on the same node as the OMS.
If you have multiple OMS connected to the same Repository, you need to figure out which agent is monitoring the target OMS and Repository. This is usually the agent installed with the first OMS installed, but it is worth to check it, as there may have been configuration changes in your Grid Control architecture.
- Find the agent monitoring the target "OMS and Repository"
How to find which agent is monitoring the target "OMS and Repository" when there are multiple OMS connected to the same Grid Control Repository
The target "OMS and Repository" is monitored by the Grid Control agent installed as part of a Grid Control installation.
When the agent is installed, it automatically adds and configure the target type oracle_emrep to its file $ORACLE_HOME/sysman/emd/targets.xml.
When you install an additional OMS, the agent automatically installed with the OMS does not monitor the target "OMS and Repository", as it is already monitored by the agent installed with the first OMS.
If you check the file $ORACLE_HOME/sysman/emd/targets.xml, you will not find any target of type "oracle_emrep" there.
However you may want to remove the first OMS (definitely or to relocate/replace it for example) and in that case you will have rediscovered the target "OMS and Repository" with an existing agent.
If you have several OMS connected to the repository and if you change several times your architecture or if the Grid Control administrators are not available, you may wonder which agent, among all the agents monitoring an OMS, is monitoring the target "OMS and Repository".
Login to the Grid Control console
- From the top right menu, click on the Setup link.
- Select the tab "Agents"
- From the bottom of the Agents page,click on the Related Link "Find Agents For Targets"
- From the page "Find Agents For Targets", select "OMS and Repository" in the Drop Down list of the field Type, then click Go
- The monitoring agent is displayed in the column " Agent Name"
As you may have several agents installed on a node, the agent name is of the form host:port.
- Connect to the node where the agent is installed with the oracle account and stop the agent
(ORACLE_HOME is set and ORACLE_HOME/bin is in the $PATH)
$ emctl stop agent
Stop all the OMS instances that are associated with the repository
From each node where an OMS is running, logged in as oracle account, do:
$ cd OMS $OH/opmn/bin
$ ./opmnctl stopall
Change the SYSMAN password in the file emoms.properties - Backup the file emoms.properties
$ cd $ORACLE_HOME/sysman/config
$ cp emoms.properties emoms.properties.orig - Edit the file emoms.properties and change the following lines
oracle.sysman.eml.mntr.emdRepPwd=new_password
oracle.sysman.eml.mntr.emdRepPwdEncrypted=FALSE
Change the SYSMAN password in the database hosting the repository: - Set the $ORACLE_SID environment variable to point to the EM Repository Database.
- Logon to the Repository Database with SQL*Plus as a dba user and issue the command:
SQL> alter user sysman identified by newpassword;
- NOTE: When you restart the OMS, the FALSE setting will change to TRUE and the password will become encrypted in the file
Restart each of the OMS's - From each node where an OMS is running, logged in as oracle account, do:
$ cd OMS $OH/opmn/bin
$ ./opmnctl startall
- Check that the password is encrypted in the file $ORACLE_HOME/sysman/config/emoms.properties
- the value of the parameter oracle.sysman.eml.mntr.emdRepPwd is encrypted
- the value of the parameter oracle.sysman.eml.mntr.emdRepPwdEncrypted is TRUE.
Change the SYSMAN password for the agent monitoring the target "OMS and Repository" - Login to the Grid Control Console
- From the top right menu, click on the link Setup
- Select the tab"Management Services and Repository"
- From the bottom of the page "Overview", click on the link "Monitoring Configuration"
You will get the following error message:
Communication from the Oracle Management Service host to the Agent host failed. Refer to help for details. IOException in sending Request :: Connection refused
This is because the Agent is not started. Click OK. - Restart the Agent stopped in Step 1
Connect to the node where the agent is installed with the oracle account and start the agent
(ORACLE_HOME is set and ORACLE_HOME/bin is in the $PATH)
We did not start it before in order to avoid the SYSMAN account to be locked, which can prevent us from logging to the Grid Control console.
$ emctl start agent
- Go back to the Grid Control console and click again on the link "Monitoring Configuration" once the agent is started.
In the Monitoring Configuration page, change the value in the field "Repository password" - Click OK
This will update the targets.xml of the monitoring agent with the new SYSMAN password.