Tuesday, September 25, 2018

db setup with OEM Db Console-UAT


1.bash profile:

# Get the aliases and functions

if [ -f ~/.bashrc ]; then

        . ~/.bashrc

fi

 

# User specific environment and startup programs

 

PATH=$PATH:$HOME/.local/bin:$HOME/bin

 

export PATH

export PATH

. /uatdb/app/oraascp/db/11.2.0/ASR_tjpsb007.env

export ORACLE_HOME=/uatdb/app/oraascp/db/11.2.0/

export PATH=$ORACLE_HOME/bin:$PATH

export LD_LIBRARY_PATH=$ORACLE_HOME/lib:$LD_LIBRARY_PATH

export ORACLE_SID=ASR

export ORACLE_UNQNAME=ASR1

export TNS_ADMIN=$ORACLE_HOME/network/admin

export HOSTNAME=TJPSB007.ebs.in

#export ORACLE_HOSTNAME=TJPSB007

export DB_DOMAIN=ebs.in

 

 

 

 


 

 

 

 

2.

Setup display in vnc.

 


 

3.Change vnc password:

Vncserver

Vncpasswd

4.Listener setup

 

 

 


UAT =

  (DESCRIPTION_LIST =

    (DESCRIPTION =

      (ADDRESS = (PROTOCOL = TCP)(HOST = TJPSB007.ebs.in)(PORT = 1531))

    )

  )

 

SID_LIST_UAT =

  (SID_LIST =

    (SID_DESC =

      (ORACLE_HOME= /ORADB/app/orauat/11.2.0)

      (SID_NAME = UAT)

    )

  )

 

STARTUP_WAIT_TIME_UAT = 0

CONNECT_TIMEOUT_UAT = 10

TRACE_LEVEL_UAT = OFF

 

LOG_DIRECTORY_UAT = /ORADB/app/orauat/11.2.0/network/admin

LOG_FILE_UAT = UAT

TRACE_DIRECTORY_UAT = /ORADB/app/orauat/11.2.0/network/admin

TRACE_FILE_UAT = UAT

ADMIN_RESTRICTIONS_UAT = ON

SUBSCRIBE_FOR_NODE_DOWN_EVENT_UAT = OFF

 

 

# added parameters for bug# 9286476

LOG_STATUS_UAT  =  ON

INBOUND_CONNECT_TIMEOUT_UAT = 60

 

# ADR is only applicable for 11gDB

DIAG_ADR_ENABLED_UAT  = ON

ADR_BASE_UAT = /ORADB/app/orauat/11.2.0/admin/UAT_tjpsb007

 

 

IFILE=/ORADB/app/orauat/11.2.0/network/admin/UAT_tjpsb007/listener_ifile.ora

 

 

 

 

5.tnsnames.ora

 

 


UAT=

        (DESCRIPTION=

                (ADDRESS=(PROTOCOL=tcp)(HOST=TJPSB007.ebs.in)(PORT=1531))

            (CONNECT_DATA=

                (SERVICE_NAME=UAT)

                (INSTANCE_NAME=UAT)

            )

        )

 

UAT_FO=

        (DESCRIPTION=

                (ADDRESS=(PROTOCOL=tcp)(HOST=TJPSB007.ebs.in)(PORT=1531))

            (CONNECT_DATA=

                (SERVICE_NAME=UAT)

                (INSTANCE_NAME=UAT)

            )

        )

 

UAT_LOCAL=

        (DESCRIPTION=

                (ADDRESS=(PROTOCOL=tcp)(HOST=TJPSB007.ebs.in)(PORT=1531))

        )

 

UAT_BALANCE=

        (DESCRIPTION=

            (ADDRESS_LIST=

                (LOAD_BALANCE=YES)

                (FAILOVER=YES)

                (ADDRESS=(PROTOCOL=tcp)(HOST=TJPSB007.ebs.in)(PORT=1531))

            )

            (CONNECT_DATA=

                (SERVICE_NAME=UAT)

            )

        )

 

UAT_REMOTE=

        (DESCRIPTION=

            (ADDRESS_LIST=

                (ADDRESS=(PROTOCOL=tcp)(HOST=TJPSB007.ebs.in)(PORT=1531))

            )

        )

 

extproc_connection_data =

    (DESCRIPTION=

         (ADDRESS_LIST =

             (ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROCUAT))

        )

        (CONNECT_DATA=

            (SID=PLSExtProc)

            (PRESENTATION = RO)

        ) )

 

IFILE=/ORADB/app/orauat/11.2.0/network/admin/UAT_tjpsb007/UAT_tjpsb007_ifile.ora

 

 

 

 

Check Listener:

 


>show parameter local;

local_listener                       string      UAT_LOCAL

 

SQL> show parameter local_listener;

>alter system set local_listener='(ADDRESS = (PROTOCOL=TCP)(HOST=172.16.2.65)(PORT=1531))';

>ALTER SYSTEM SET LOCAL_LISTENER='UAT';

>alter system register;

>tnsping UAT

ALTER SYSTEM SET LOCAL_LISTENER='UAT' scope=both sid='*' ;

alter system register;

 

 

 

 

 

 


[orauat@TJPSB007 ~]$ tnsping UAT

TNS Ping Utility for Linux: Version 11.2.0.4.0 - Production on 12-SEP-2018 14:52:18

Copyright (c) 1997, 2013, Oracle.  All rights reserved.

Used parameter files:

/ORADB/app/orauat/11.2.0/network/admin/UAT_tjpsb007/sqlnet_ifile.ora

Used TNSNAMES adapter to resolve the alias

Attempting to contact (DESCRIPTION= (ADDRESS=(PROTOCOL=tcp)(HOST=TJPSB007.ebs.in)(PORT=1531)) (CONNECT_DATA= (SERVICE_NAME=UAT) (INSTANCE_NAME=UAT)))

OK (0 msec)

 

 

 

 


6.Change password file:

orapwd file=orapw$ORACLE_SID password=manager1 entries=5

 

O_H/db

orapwd file=orapw$ORACLE_SID password=manager1 entries=5

orapwUAT

 

 


How To Drop, Create And Recreate Database Control (dbconsole) Web Site in Releases 10g and 11g (Doc ID 278100.1)

 

 

How To Check Pre-requisites for Successful Execution of EMCA Commands in Single Instance Database Environment (Doc ID 1113343.1)

 

Master Note for Enterprise Manager Configuration Assistant (EMCA) in Single Instance Database Environment (Doc ID 1099271.1)

 


EMCA Release 10.1 to 11.1 Puts the Database in Quiesce And No New Connections or Operations Can Be Performed During the DB Control Repository Creation (Doc ID 375946.1)

 

 

 

 

emca -deconfig dbcontrol db -repos drop

<ORACLE_HOME>bin/emca -config dbcontrol db -repos create

<ORACLE_HOME>bin/emca -config dbcontrol db -repos recreate

 

1set password for sys

Dbsnmp----SQL> alter user dbsnmp account unlock;

alter user dbsnmp identified by dbsnmp;

 

 

Sysman—1st time not required.this will configure confirm password.

Sys123(small letter).

 

 

 

 

[orauat@TJPSB007 bin]$ emca -config dbcontrol db -repos create

 

STARTED EMCA at Sep 12, 2018 3:06:37 PM

EM Configuration Assistant, Version 11.2.0.3.0 Production

Copyright (c) 2003, 2011, Oracle.  All rights reserved.

 

Enter the following information:

Database SID: UAT

Listener port number: 1531

Listener ORACLE_HOME [ /ORADB/app/orauat/11.2.0 ]:

Password for SYS user:

Password for DBSNMP user:

Password for SYSMAN user:

Password for SYSMAN user: Email address for notifications (optional): sys123

Invalid email.

Email address for notifications (optional):

Outgoing Mail (SMTP) server for notifications (optional):

-----------------------------------------------------------------

 

You have specified the following settings

 

Database ORACLE_HOME ................ /ORADB/app/orauat/11.2.0

 

Local hostname ................ TJPSB007.ebs.in

Listener ORACLE_HOME ................ /ORADB/app/orauat/11.2.0

Listener port number ................ 1531

Database SID ................ UAT

Email address for notifications ...............

Outgoing Mail (SMTP) server for notifications ...............

 

-----------------------------------------------------------------

Do you wish to continue? [yes(Y)/no(N)]: Y

Sep 12, 2018 3:07:25 PM oracle.sysman.emcp.EMConfig perform

INFO: This operation is being logged at /ORADB/app/orauat/11.2.0/cfgtoollogs/emca/UAT/emca_2018_09_12_1                                                                 5_06_37.log.

Sep 12, 2018 3:07:26 PM oracle.sysman.emcp.EMReposConfig createRepository

INFO: Creating the EM repository (this may take a while) ...

Sep 12, 2018 3:18:14 PM oracle.sysman.emcp.EMReposConfig invoke

INFO: Repository successfully created

Sep 12, 2018 3:18:17 PM oracle.sysman.emcp.EMReposConfig uploadConfigDataToRepository

INFO: Uploading configuration data to EM repository (this may take a while) ...

Sep 12, 2018 3:19:37 PM oracle.sysman.emcp.EMReposConfig invoke

INFO: Uploaded configuration data successfully

Sep 12, 2018 3:19:40 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole

INFO: Securing Database Control (this may take a while) ...

Sep 12, 2018 3:19:54 PM oracle.sysman.emcp.util.DBControlUtil secureDBConsole

INFO: Database Control secured successfully.

Sep 12, 2018 3:19:55 PM oracle.sysman.emcp.util.DBControlUtil startOMS

INFO: Starting Database Control (this may take a while) ...

Sep 12, 2018 3:20:22 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration

INFO: Database Control started successfully

Sep 12, 2018 3:20:22 PM oracle.sysman.emcp.EMDBPostConfig performConfiguration

INFO: >>>>>>>>>>> The Database Control URL is https://TJPSB007.ebs.in:5500/em <<<<<<<<<<<

Sep 12, 2018 3:20:25 PM 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: /ORADB/app/orauat/11.2.0/TJPSB007.ebs.in_UAT/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 Sep 12, 2018 3:20:25 PM

 

No comments:

Post a Comment

[ERROR]: The value of s_patch_service_name is not set correctly in atleast one of the context files.

[ERROR]: The value of s_patch_service_name is not set correctly in atleast one of the context files. I got the issue below wh...