Sunday, December 14, 2014
RAC 的 Enterprise Manager 重建。
emca -deconfig dbcontrol db -repos drop -cluster
emca -config dbcontrol db -repos create -cluster
刪除
SQL> drop user sysman cascade;
SQL> drop public synonym SETEMVIEWUSERCONTEXT;
SQL> drop role MGMT_USER;
SQL> drop PUBLIC SYNONYM MGMT_TARGET_BLACKOUTS;
SQL> drop user MGMT_VIEW;
$ emca -deconfig dbcontrol db -repos drop -cluster
STARTED EMCA at Dec 14, 2014 2:59:32 AM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle. All rights reserved.
Enter the following information:
Database unique name: orcl
Service name: orcl
Listener port number: 1521
Listener ORACLE_HOME [ /u01/app/11.2.0/grid ]:
Password for SYS user: 密碼
Password for SYSMAN user: 密碼
----------------------------------------------------------------------
WARNING : While repository is dropped the database will be put in quiesce mode.
----------------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: Y
Dec 14, 2014 2:59:47 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/orcl/emca_2014_12_14_02_59_31.log.
Dec 14, 2014 2:59:48 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngineRemotely
WARNING: Error during db connection : ORA-01045: user SYSMAN lacks CREATE SESSION privilege; logon denied
Dec 14, 2014 2:59:54 AM oracle.sysman.emcp.util.GeneralUtil initSQLEngineRemotely
WARNING: ORA-01045: user SYSMAN lacks CREATE SESSION privilege; logon denied
Dec 14, 2014 2:59:54 AM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControl
WARNING: Error initializing SQL connection. SQL operations cannot be performed
Dec 14, 2014 2:59:54 AM oracle.sysman.emcp.EMDBPreConfig performDeconfiguration
WARNING: EM is not configured for this database. No EM-specific actions can be performed. Some of the possible reasons may be:
1) EM is configured with different hostname then physical host. Set environment variable ORACLE_HOSTNAME=<hostname> and re-run EMCA script
2) ORACLE_HOSTNAME is set. Unset it and re-run EMCA script
Dec 14, 2014 2:59:54 AM oracle.sysman.emcp.EMReposConfig invoke
INFO: Dropping the EM repository (this may take a while) ...
Dec 14, 2014 3:04:03 AM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully dropped
Enterprise Manager configuration completed successfully
FINISHED EMCA at Dec 14, 2014 3:04:03 AM
$ emca -config dbcontrol db -repos create -cluster
STARTED EMCA at Dec 14, 2014 3:05:23 AM
EM Configuration Assistant, Version 11.2.0.3.0 Production
Copyright (c) 2003, 2011, Oracle. All rights reserved.
Enter the following information:
Database unique name: orcl
Service name: orcl
Listener port number: 1521
Listener ORACLE_HOME [ /u01/app/11.2.0/grid ]:
Password for SYS user:
Password for DBSNMP user: 密碼
Password for SYSMAN user: 密碼
Cluster name: ttrac-cluster
Email address for notifications (optional):
Outgoing Mail (SMTP) server for notifications (optional):
ASM ORACLE_HOME [ /u01/app/11.2.0/grid ]:
ASM port [ 1521 ]:
ASM username [ ASMSNMP ]:
ASM user password: 密碼
-----------------------------------------------------------------
You have specified the following settings
Database ORACLE_HOME ................ /u01/app/oracle/product/11.2.0/dbhome_1
Database instance hostname ................ Listener ORACLE_HOME ................ /u01/app/11.2.0/grid
Listener port number ................ 1521
Cluster name ................ ttrac-cluster
Database unique name ................ orcl
Email address for notifications ...............
Outgoing Mail (SMTP) server for notifications ...............
ASM ORACLE_HOME ................ /u01/app/11.2.0/grid
ASM port ................ 1521
ASM user role ................ SYSDBA
ASM username ................ ASMSNMP
-----------------------------------------------------------------
Do you wish to continue? [yes(Y)/no(N)]: Y
Dec 14, 2014 3:19:56 AM oracle.sysman.emcp.EMConfig perform
INFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/orcl/emca_2014_12_14_03_19_08.log.
Dec 14, 2014 3:19:59 AM oracle.sysman.emcp.EMReposConfig createRepository
INFO: Creating the EM repository (this may take a while) ...
Dec 14, 2014 3:27:58 AM oracle.sysman.emcp.EMReposConfig invoke
INFO: Repository successfully created
Dec 14, 2014 3:28:07 AM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepository
INFO: Uploading configuration data to EM repository (this may take a while) ...
Dec 14, 2014 3:28:51 AM oracle.sysman.emcp.EMReposConfig invoke
INFO: Uploaded configuration data successfully
Dec 14, 2014 3:28:51 AM oracle.sysman.emcp.EMDBCConfig instantiateOC4JConfigFiles
INFO: Propagating /u01/app/oracle/product/11.2.0/dbhome_1/oc4j/j2ee/OC4J_DBConsole_ttrac01_orcl to remote nodes ...
Dec 14, 2014 3:28:53 AM oracle.sysman.emcp.EMDBCConfig instantiateOC4JConfigFiles
INFO: Propagating /u01/app/oracle/product/11.2.0/dbhome_1/oc4j/j2ee/OC4J_DBConsole_ttrac02_orcl to remote nodes ...
Dec 14, 2014 3:28:58 AM oracle.sysman.emcp.EMAgentConfig deployStateDirs
INFO: Propagating /u01/app/oracle/product/11.2.0/dbhome_1/ttrac01_orcl to remote nodes ...
Dec 14, 2014 3:29:00 AM oracle.sysman.emcp.EMAgentConfig deployStateDirs
INFO: Propagating /u01/app/oracle/product/11.2.0/dbhome_1/ttrac02_orcl to remote nodes ...
Dec 14, 2014 3:29:02 AM oracle.sysman.emcp.util.DBControlUtil secureDBConsole
INFO: Securing Database Control (this may take a while) ...
Dec 14, 2014 3:29:15 AM oracle.sysman.emcp.util.DBControlUtil startOMS
INFO: Starting Database Control (this may take a while) ...
Dec 14, 2014 3:31:14 AM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: Database Control started successfully
Dec 14, 2014 3:31:14 AM oracle.sysman.emcp.EMDBPostConfig performConfiguration
INFO: >>>>>>>>>>> The Database Control URL is https://ttrac01.localdomain:1158/em <<<<<<<<<<<
Dec 14, 2014 3:31:21 AM oracle.sysman.emcp.EMDBPostConfig showClusterDBCAgentMessage
INFO:
**************** Current Configuration ****************
INSTANCE NODE DBCONTROL_UPLOAD_HOST
---------- ---------- ---------------------
orcl ttrac01 ttrac01.localdomain
orcl ttrac02 ttrac01.localdomain
Dec 14, 2014 3:31:21 AM oracle.sysman.emcp.EMDBPostConfig invoke
WARNING:
************************ WARNING ************************
Management Repository has been placed in secure mode wherein Enterprise Manager data will be encrypted. The encryption key has been placed in the file: /u01/app/oracle/product/11.2.0/dbhome_1/ttrac01_orcl/sysman/config/emkey.ora. Ensure this file is backed up as the encrypted data will become unusable if this file is lost.
***********************************************************
Enterprise Manager configuration completed successfully
FINISHED EMCA at Dec 14, 2014 3:31:22 AM
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment