You are on page 1of 8

Oracle Database – Login Methods

Page | 1
Document Change History

Document control sheet


If you have any questions regarding this document or a suggestion for improvements, please contact:

+61
Document Owner DIVANSHU CHOPRA Phone 406914380

Document Authorization
Name/Title Signature Date
Prepared
Divanshu Chopra
by:
Modified
by:
Reviewed Jaivardhan Singh th
4 January 2018
by: Bairaria
Accepted
by:

Version History
Version Author Issue Purpose Date
Divanshu Restructuring and
V1.0
Chopra finalization
Taranjit Singh th
V1.1 Review and updates 28 July 2017
Boonga
Jaivardhan th
V1.2 Review and updates 4 January 2018
Singh Bairaria

The following people can also be contacted in relation to this document:


Title Name Telephone Email
Taranjit Singh TaranjitSin.Boonga@endeavourenergy.com.au
DBA +919910068809
Boonga
Jaivardhan JaivardhanS.Bairaria@endeavourenergy.com.au
DBA +918742831841
Singh Bairaria

Peer Reviewers
Review
Title Name Date
Outcome
th No Updates
DBA Taranjit Singh Boonga 28 july 2017
Required
th
4 January Reviewed, no
DBA Jaivardhan Singh Bairaria
2018 updates required.

Page | 2
Glossary
S.No Abbreviation Description
1 DBA Database Administrator
2 RAC Real Application Cluster
3 OMS Outage Management System

Page | 3
Table of Contents
Oracle Database – Login Methods................................................................................................................. 1
1. Introduction .......................................................................................................................................... 5
1. Overview ........................................................................................................................................... 5
2. Purpose/Requirement ...................................................................................................................... 5
3. Achievements after the Task ............................................................................................................ 5
2. Login to Exadata Database .................................................................................................................... 6
3. Login to OMS Database ......................................................................................................................... 7
4. Login to UNIX and TRUE64 Servers........................................................................................................ 8

Page | 4
1. Introduction
In Endeavour Energy environment, Oracle databases are categorized into three categories
considering clustering and non-clustering. These categories are:

1. RAC on Exadata servers

2. OMS servers in RAC (non-Exadata servers)

3. Standalone

The login methodology, which is different for databases in each category, is described in
detail in this document.

1. Overview
The database servers in Endeavour Energy environment consists of Exadata RAC, non-
Exadata RAC, and standalone servers. Therefore, the methodology to login to
databases hosted on these servers is different depending on the database server. This
document describes the login methodology for databases in each type of server.

2. Purpose/Requirement
This document is for the Database Administrators supporting Endeavour Energy
Oracle landscape. Purpose of this document is to help DBAs to login to Oracle
databases on each type of database server in Endeavour Energy environment.

3. Achievements after the Task


Purpose Login to Oracle databases on different types of servers
Task Follow Steps from section II
Results Login successfully on different types of Oracle databases

Page | 5
2. Login to Exadata Database
Logon to server using putty, depending upon on which node of RAC server you are logging,
instance number will vary.
This is an example of connecting database hosted on HWEXAP1DB01 server.
Once you are logged in to the server go to /home directory of oracle user

cd /home/oracle

Do listing of the files

ls –ltr *.sh

You will find below scripts. Depending on the environment (Prod/Test/Dev) run the
respective script.

-rwxr-xr-x 1 oracle oinstall 232 Oct 28 2013 setenv.sh


-rw-r--r-- 1 oracle oinstall 3834 Nov 12 2013 settest4.sh
-rwxrwxrwx 1 oracle oinstall 3831 Nov 14 2013 setpro4.sh
-rw-r--r-- 1 oracle oinstall 3831 Nov 14 2013 setdev4.sh

***********************************PROD**********************************
********
[oracle@hwexap1db01 ~]$ . setpro4.sh ELLPRD1
ORACLE_SID=ELLPRD1
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=/u01/app/oracle/product/11.2.0.4/ProdHome_1
[oracle@hwexap1db01 ~]$ sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Tue Mar 17 14:35:58 2015

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

Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management,
OLAP,
Data Mining and Real Application Testing options

SQL>
****************************************TEST*****************************
***********
[oracle@hwexap1db01 ~]$ . settest4.sh FUSETST1
ORACLE_SID=ELLPRD1
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=/u01/app/oracle/product/11.2.0.4/TestHome_1
[oracle@hwexap1db01 ~]$ sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Tue Mar 17 14:35:58 2015

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

Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management,
OLAP,
Data Mining and Real Application Testing options

SQL>

Page | 6
***********************************************DEV**********************************
***************************
[oracle@hwexap1db01 ~]$ . setdev4.sh GK6DEV1
ORACLE_SID=ELLPRD1
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=/u01/app/oracle/product/11.2.0.4/DevHome_1
[oracle@hwexap1db01 ~]$ sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Tue Mar 17 14:35:58 2015

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

Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management,
OLAP,
Data Mining and Real Application Testing options

SQL>

NOTE: If you are logged on the second node of the cluster then instance number will
change from 1 to 2. For example, ELLPRD2, FUSETST2 and GK6DEV2.

3. Login to OMS Database


Logon to server using putty, depending upon on which node of RAC server you are logging,
instance number will vary.
This is an example of connecting database hosted on HWRHOMSPRDR1 server.
Once you are logged in to the server go to /home directory of oracle user

cd /home/oracle

hwrhomsprdr1-oracle>. setenv OMSPRD1


The Oracle base remains unchanged with value /u01/app/oracle
OMSPRD1
ORACLE_BASE=/u01/app/oracle
ORACLE_HOME=/u01/app/oracle/product/11.2.0/db_prd
ORACLE_SID=OMSPRD1
hwrhomsprdr1-oracle>

hwrhomsprdr1-oracle>
hwrhomsprdr1-oracle>sqlplus "/as sysdba"

SQL*Plus: Release 11.2.0.3.0 Production on Tue Mar 17 14:04:11 2015

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

Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management,
OLAP,
Data Mining and Real Application Testing options

SQL>

Page | 7
NOTE: If you are logged on the second node of the cluster then instance number will
change from 1 to 2. For example

. setenv OMSPRD2

4. Login to UNIX and TRUE64 Servers


Log in to server using putty using your own credentials. This is an example of connecting
database on UXDEV13 server and same is applicable for all Unix and Tru-64 servers
Once logged in to the server do sudo to oracle user and enter Oracle password.
uxdev13:(pratag):/home/logica/pratag $ su - oracle
Password:

Run below command on the server.

uxdev13:oracle@GISREL > . oraenv


ORACLE_SID = [GISREL] ?

It will prompt you to enter the database name to which you want to connect
uxdev13:oracle@GISREL > . oraenv
ORACLE_SID = [GISREL] ? BANTST1
The Oracle base for ORACLE_HOME=/Banner/BANTST/oracle/product/9.2.0 is
/Banner/BANTST/oracle/product/9.2.0
uxdev13:oracle@BANTST1 > sqlplus "/as sysdba"

SQL*Plus: Release 9.2.0.8.0 - Production on Tue Mar 17 14:40:50 2015

Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.

Connected to:
Oracle9i Enterprise Edition Release 9.2.0.8.0 - 64bit Production
With the Partitioning, OLAP and Oracle Data Mining options
JServer Release 9.2.0.8.0 - Production

SQL>

NOTE: If anyone has root access on these servers then password prompt will not come after doing
sudo to Oracle user.

Page | 8

You might also like