Tuesday, September 2, 2008

Enable Database Enterprise Manager Console on R12

First login as applmgr user, shutdown all application tier process using adstpall.sh.
Login as oracle user to linux. Source the database environment.
Ensure REMOTE_LOGIN_PASSWORDFILE=EXCLUSIVE is set in the init.ora for the database using this command: SQL> show parameter REMOTE_LOGIN_PASSWORDFILE;
Create a password file using this command on linux: orapwd file=$ORACLE_HOME/dbs/orapw$ORACLE_SID password=change_on_install entries=5
Then execute this command: emca -config dbcontrol db -repos recreate -SID ITB -PORT 1521 -DBCONTROL_HTTP_PORT 5500
(remember to change SID and port if needed).
You will be asked some question:
SYS password: the default is change_on_install
DBSNMP password: dbsnmp
SYSMAN password: sysman
Email: enter your email address (optional)
SMTP server: enter your smtp server
SYSMAN schema will be dropped and recreate.
While dropping the scema, database will be quisced. Database sessions that blocking the quiescing process must be killed.
Use sqlplus to identify the sessions:
SQL> select bl.sid, serial#, user, osuser, type, program from v$blocking_quiesce bl, v$session se where bl.sid = se.sid;
Make note on SID and SERIAL#.
Kill the session using this sql command:
SQL> alter system kill session 'SID,SERIAL#' immediate;
(don't forget to change SID and SERIAL#).
On create schema process you may need to increase the size of SYSAUX tablespace.
After the process completed you can access the enterprise manager on internet browser using this URL:
http://hostname:5500/em
You may also have to run $ORACLE_HOME/root.sh as root to avoid ERROR: NMO not setuid-root. Just answer no if overwrite is asked.


1 comment: