4

Is is possible to use the Enterprise Manager Command Line Interface (EMCLI) to change the Oracle Home Path?

We recently upgraded many databases, listeners, and ASMs, and I'd like to automate this process:

  1. Select the target
  2. Go to Target Setup --> Monitoring Configuration
  3. Change "Oracle Home Path", click Next, click Submit.

I looked through the EMCLI Verb Reference and could not find a way to do this.

1
+50

Assuming your DB target name as seen in EM is ORCL11.WORLD and you want to set it's Monitoring Configuration's Oracle Home to /oracle/product/11.2.0.4, the syntax would be the following:

emcli modify_target -type='oracle_database' -name='ORCL11.WORLD' -properties='OracleHome:/oracle/product/11.2.0.4'

Probably would be similar approach for Listeners, ASM, etc.

Version note: This worked for me on EM 12cR4.

  • On Windows this command only worked with double quotes instead of single quotes. Thanks! – Jon Heller Mar 3 '15 at 4:29
0

emcli modify_target -type='oracle_listener' -name='LISTENER_mx0102.orademo.com' -properties='Machine:mx0102.orademo.com'; Target "LISTENER_m0102.orademo.com:oracle_listener" modified successfully

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.