Configure Oracle Enterprise Manager 12c In Silent Mode

穆修杰
2023-12-01

    OEM(Oracle Enterprise Manager) 12c在图形界面安装时容易出错,不好判断故障原因。通过静默安装可以实时观察日志文件,如果出现问题可快速定位。


环境介绍


主机名称IP角色备注
oem172.16.120.13OEM服务器Oracle Linux 7.2
dbserver172.16.100.19数据库服务器DB 11.2.0.4 For Oracle Linux 7.2 x86_64


1、数据库设置

根据实际环境,建议调整以下参数的值:

SQL> ALTER SYSTEM SET processes=300 SCOPE=SPFILE;
SQL> ALTER SYSTEM SET session_cached_cursors=200 SCOPE=SPFILE;
SQL> ALTER SYSTEM SET sga_target=2G SCOPE=SPFILE;
SQL> ALTER SYSTEM SET shared_pool_size=600M SCOPE=SPFILE;
SQL> ALTER SYSTEM SET pga_aggregate_target=1G SCOPE=SPFILE;
SQL> ALTER SYSTEM SET job_queue_processes=20 SCOPE=SPFILE;
SQL> ALTER SYSTEM SET processes=500 SCOPE=SPFILE;
SQL> shutdown immediate;
SQL> startup

2、静默安装OEM软件

       在OEM安装包的response文件里,包含了静默文件的模板。software_only.rsp是指只安装OEM软件不配置OEM服务;而new_install.rsp则是配置OEM服务的静默文件模板。

  • 静默文件内容

[root@oem ~]# cat /tmp/software_only.rsp 
RESPONSEFILE_VERSION=2.2.1.0.0
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/u01/app/oraInventory
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=false
MYORACLESUPPORT_USERNAME=abc@125.com
MYORACLESUPPORT_PASSWORD=
INSTALL_UPDATES_SELECTION="skip"
STAGE_LOCATION=
MYORACLESUPPORT_USERNAME_FOR_SOFTWAREUPDATES=
MYORACLESUPPORT_PASSWORD_FOR_SOFTWAREUPDATES=
ORACLE_MIDDLEWARE_HOME_LOCATION=/u01/app/oracle/Middleware
AGENT_BASE_DIR=/u01/app/oracle/Agent
ORACLE_HOSTNAME=oem
FROM_LOCATION="/mnt/linux/oem12c/oms/Disk1/stage/products.xml"
DEINSTALL_LIST={"oracle.sysman.top.oms","12.1.0.5.0"}
REMOVE_HOMES=
b_upgrade=false
EM_INSTALL_TYPE="NOSEED"
CONFIGURATION_TYPE="LATER"
TOPLEVEL_COMPONENT={"oracle.sysman.top.oms","12.1.0.5.0"}
  • 安装过程

[oracle@oem oem12c]$ ./runInstaller -silent -responseFile /tmp/software_only.rsp
Starting Oracle Universal Installer...

Checking Temp space: must be greater than 400 MB.   Actual 27375 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 8191 MB    Passed
Preparing to launch Oracle Universal Installer from /tmp/OraInstall2016-05-30_03-20-58PM. Please wait ...[oracle@oem oem12c]$ 
Installing ORACLE_HOME /u01/app/oracle/Middleware/jdk16
Installation in progress
................
Install successful
Linking in progress

Link successful
Setup in progress

Setup successful
Installing Oracle WebLogic Server

Installing ORACLE_HOME /u01/app/oracle/Middleware/Oracle_BI1
Installation in progress
.................
Install successful
Linking in progress

Link successful
Setup in progress

Setup successful

Installing ORACLE_HOME /u01/app/oracle/Middleware/oms
Installation in progress
................
Install successful
Linking in progress
Error in invoking target 'install' of makefile '/u01/app/oracle/Middleware/Oracle_WT/webcache/lib/ins_calypso.mk'. See '/tmp/OraInstall2016-05-30_03-20-58PM/cloneActions2016-05-30_03-54-54-PM.log' for details.

Link successful
Setup in progress

Setup successful
Applying the required oneoff patches.

Warning: The following configuration scripts need to be executed as the "root" user
  /u01/app/oraInventory/orainstRoot.sh
  /u01/app/oracle/Middleware/oms/allroot.sh
To execute the configuration scripts:
 1. Open a new  terminal window 
 2. Login in as "root" 
 3. Run the scripts 

Enterprise Manager Cloud Control Installation has finished.
  • 执行root脚本

[root@oem ~]# /u01/app/oraInventory/orainstRoot.sh
[root@oem ~]# /u01/app/oracle/Middleware/oms/allroot.sh

到此只成功安装了OEM软件,但未配置OEM服务。


3、配置OEM服务


默认执行ConfigureGC.sh文件,会使用图形界面安装。

  • 静默文件内容

[root@oem ~]# more /tmp/new_install.rsp 
RESPONSEFILE_VERSION=2.2.1.0.0
UNIX_GROUP_NAME=oinstall
INVENTORY_LOCATION=/u01/app/oraInventory
SECURITY_UPDATES_VIA_MYORACLESUPPORT=false
DECLINE_SECURITY_UPDATES=false
MYORACLESUPPORT_USERNAME=abc@125.com
MYORACLESUPPORT_PASSWORD=
INSTALL_UPDATES_SELECTION="skip"
STAGE_LOCATION=
MYORACLESUPPORT_USERNAME_FOR_SOFTWAREUPDATES=
MYORACLESUPPORT_PASSWORD_FOR_SOFTWAREUPDATES=
PROXY_USER=
PROXY_PWD=
PROXY_HOST=
PROXY_PORT=
ORACLE_MIDDLEWARE_HOME_LOCATION=/u01/app/oracle/Middleware
ORACLE_HOSTNAME=oem
AGENT_BASE_DIR=/u01/app/oracle/Agent
WLS_ADMIN_SERVER_USERNAME=weblogic
WLS_ADMIN_SERVER_PASSWORD=abcABC12
WLS_ADMIN_SERVER_CONFIRM_PASSWORD=abcABC12
NODE_MANAGER_PASSWORD=abcABC12
NODE_MANAGER_CONFIRM_PASSWORD=abcABC12
ORACLE_INSTANCE_HOME_LOCATION=/u01/app/oracle/Middleware/gc_inst
CONFIGURE_ORACLE_SOFTWARE_LIBRARY=true
SOFTWARE_LIBRARY_LOCATION=/u01/app/oracle/swlib
DATABASE_HOSTNAME=dbserver
LISTENER_PORT=1521
SERVICENAME_OR_SID=emrep
SYS_PASSWORD=abcABC12
SYSMAN_PASSWORD=abcABC12
SYSMAN_CONFIRM_PASSWORD=abcABC12
DEPLOYMENT_SIZE="MEDIUM"
MANAGEMENT_TABLESPACE_LOCATION=/viros/oradata/emrep/mgmt.dbf
CONFIGURATION_DATA_TABLESPACE_LOCATION=/viros/oradata/emrep/mgmt_ecm_depot1.dbf
JVM_DIAGNOSTICS_TABLESPACE_LOCATION=/viros/oradata/emrep/mgmt_ad4j.dbf
AGENT_REGISTRATION_PASSWORD=abcABC12
AGENT_REGISTRATION_CONFIRM_PASSWORD=abcABC12
STATIC_PORTS_FILE=
#PLUGIN_SELECTION={}
FROM_LOCATION="/mnt/linux/oem12c/oms/Disk1/stage/products.xml"
DEINSTALL_LIST={"oracle.sysman.top.oms","12.1.0.5.0"}
REMOVE_HOMES=
b_upgrade=false
EM_INSTALL_TYPE="NOSEED"
CONFIGURATION_TYPE="ADVANCED"
TOPLEVEL_COMPONENT={"oracle.sysman.top.oms","12.1.0.5.0"}
  • 配置过程

[oracle@oem ~]$ cd /u01/app/oracle/Middleware/oms/sysman/install
[oracle@oem install]$ ./ConfigureGC.sh -silent -responseFile /tmp/new_install.rsp
Starting Oracle Universal Installer...

Checking Temp space: must be greater than 400 MB.   Actual 17148 MB    Passed
Checking swap space: must be greater than 150 MB.   Actual 8191 MB    Passed
...............
Installing plug-in /u01/app/oracle/Middleware/oms/install/tmp_installer/oracle.sysman.cfw/12.1.0.3.0/12.1.0.3.0_OMS_2000_0.zip
You can find the log of this install session at:
 /u01/app/oraInventory/logs/cloneActions2016-05-30_04-29-43-PM.log

Installing ORACLE_HOME /u01/app/oracle/Middleware/plugins/oracle.sysman.cfw.oms.plugin_12.1.0.3.0
Installation in progress

Install successful
Linking in progress

Link successful
Setup in progress
..............
orwarder proxy Port  agent Mode execDeployAgentOnly 
AgentConfiguration:agent configuration has been started
Validating OMS_HOST and EM_UPLOAD_PORT
Performing free port detection..

Getting Inet Addresses for host oem
** Agent Port Check completed successfully.**
Agent Mode is None
AgentConfiguration: Executing emctl deploy agent command...

Timeout value is:600
AgentConfiguration: Executing emctl config agent command...

AgentConfiguration:agent configuration finished with status = true

2016-05-30_06-19-02-PM: Configuration assistant "Agent Configuration Assistant" has Succeeded.

*** The Installation was Successful. ***

This information is also available at: 

        /u01/app/oracle/Middleware/oms/install/setupinfo.txt

See below for information pertaining to your Enterprise Manager installation:

Use the following URL to access:

        1. Enterprise Manager Cloud Control URL: https://oem:7803/em
        2. Admin Server URL: https://oem:7102/console

The following details need to be provided during the additional OMS install:

        1. Admin Server Hostname: oem
        2. Admin Server Port: 7102

You can find the details on ports used by this deployment at : /u01/app/oracle/Middleware/oms/install/portlist.ini

 NOTE:
 An encryption key has been generated to encrypt sensitive data in the Management Repository. If this key is lost, all encrypted data in the Repository becomes unusable. 

 A backup of the OMS configuration is available in /u01/app/oracle/Middleware/gc_inst/em/EMGC_OMS1/sysman/backup on host oem. See Cloud Control Administrators Guide for details on how to back up and recover an OMS.

 NOTE: This backup is valid only for the initial OMS configuration. For example, it will not reflect plug-ins installed later, topology changes like the addition of a load balancer, or changes to other properties made using emctl or emcli. Backups should be created on a regular basis to ensure they capture the current OMS configuration. Use the following command to backup the OMS configuration:
/u01/app/oracle/Middleware/oms/bin/emctl exportconfig oms -dir <backup dir>

由于篇幅原因,这里只贴出部分日志。到此,整个OEM服务配置完成,通过web界面访问即可。


Attention:

            1、以上静默文件的参数根据实际情况进行调整;

             2、每个参数的具体含义请参考安装包里的静默文件模板。

 类似资料:

相关阅读

相关文章

相关问答