Delete Host from OMS using Database API | Removing a target from OMS

Posted By Sagar Patil

I wanted to remove one my client node from OMS. I used following GUI option but it returned errors  as below

I clicked “Remove” tab which returned error message “There are other monitored targets on this Host. Before removing this Host, you must first remove all the other targets”

How to Fix this?

Run following SQL at OMR

select distinct target_name,target_type  from SYSMAN.MGMT$TARGET where target_name like ‘%HOSTNAME%’

TARGET_NAME,                  TARGET_TYPE
bmau0.uk.pri.o2.com,          host
bmau0.uk.pri.o2.com:1831,   oracle_emd
bmau0:1831,                     oracle_emd
LISTENER_TEST0_bmau0,    oracle_listener
LISTENER_TEST_bmau0,      oracle_listener
LISTENER_DBAS_bmau0,      oracle_listener

Now use following API to remove each of these targets from OMR

exec sysman.mgmt_admin.cleanup_agent(‘bmau0.uk.pri.o2.com:3872′);
exec sysman.mgmt_admin.cleanup_agent(‘bmau0.uk.pri.o2.com:1831′);

Leave a Reply

You must be logged in to post a comment.

2 Responses to “ WebSphere Security: Switch off username/password prompt while shutting down services ”

  1. Encrypt Websphere password for startServer.sh and stopServer.sh

    The soap.client.props file is located at Dmgr as well as Node directories under clustered environment

    vi /opt/IBM/WebSphere/AppServer/profiles/Profile01/dmgr/properties/soap.client.props
    vi /opt/IBM/WebSphere/AppServer/profiles/Profile01/Node/properties/soap.client.props
    fill in entries for ‘com.ibm.SOAP.loginUserid’ and ‘com.ibm.SOAP.loginPassword’.

    Run Command :
    PropFilePasswordEncoder.sh soap.client.props com.ibm.SOAP.loginPassword

    [was61@properties]$ /opt/IBM/WebSphere/AppServer/profiles/Profile01/Node/bin/PropFilePasswordEncoder.sh /opt/IBM/WebSphere/AppServer/profiles/Profile01/Node/properties/soap.client.props com.ibm.SOAP.loginPassword
    Create a backup file of the original properties file which contains unencoded passwords? (y/n)
    y
    NOTE: Backup file /opt/IBM/WebSphere/AppServer/profiles/Profile01/Node/properties/soap.client.props.bak contains unencoded passwords

    I can see files :
    soap.client.props.bak : Plain Passwords
    soap.client.props : Encrypted Passwords

    vi soap.client.props updated with encrypted password :
    com.ibm.SOAP.loginUserid=user1
    com.ibm.SOAP.loginPassword={xor}KCw+OzI2MQ==

    vi soap.client.props.bak:
    com.ibm.SOAP.loginUserid=user1
    com.ibm.SOAP.loginPassword=password1

  2. In the very first line it was startManager.sh that was triggered.Not after this attempt it was triggered again,per your content.Why so ?Also,what is the need to run startManager.sh while we have “startServer.sh Dmgr ” ?

Top of Page

Top menu