• No results found

How To Startup an Oracle Database

N/A
N/A
Protected

Academic year: 2021

Share "How To Startup an Oracle Database"

Copied!
3
0
0

Loading.... (view fulltext now)

Full text

(1)

For a DBA, starting up and shutting down of oracle database is a routine and basic operation. Sometimes Linux administrator or programmer may end-up doing some basic DBA operations on development database. So, it is important for non-DBAs to understand some basic database administration activities.

In this article, let us review how to start and stop an oracle database.

How To Startup an Oracle Database

1. Login to the system with oracle username

Typical oracle installation will have oracle as username and dba as group. On Linux, do su to oracle as shown below.

/home/voyager => su – oracle Password:

Welcome to dc02vg0141na.hosted.exlibrisgroup.com

2. Connect to oracle sysdba

Make sure ORACLE_SID (should be VGER) and ORACLE_HOME are set properly, something like what is shown below.

/oracle/app/oracle/product/11.2.0/db_1/network/admin => env | grep ORA ORACLE_BASE=/oracle/app/oracle ORACLE_HOME=/oracle/app/oracle/product/11.2.0/db_1 ORACLE_PATH=.:/opt/bin:/usr/bin: ORACLE_SID=VGER ORA_CONFIG=/oracle/app/oracle/product/11.2.0/db_1/dbs ORA_LOG=/oracle/app/oracle/diag/rdbms/vger/VGER/trace ORA_NET=/oracle/app/oracle/product/11.2.0/db_1/network/admin

1. At the operating system prompt, enter the following command to start SQL Command Line and connect to the database:

2. SQLPLUS / AS SYSDBA

The slash (/) indicates that the database should authenticate you with operating system authentication.

NOTE! Be very, very careful when you’re in oracle as sysdba. It is the oracle equivalent of root. Always know what you are doing and why. Never mess

about! You need to use it here because the normal “read-only” user can’t do shutdowns and startups.

/oracle/app/oracle/product/11.2.0/db_1/network/admin => whoami oracle

(2)

/oracle/app/oracle/product/11.2.0/db_1/network/admin => sqlplus / as sysdba SQL*Plus: Release 11.2.0.1.0 Production on Sun Jan 1 10:01:16 2012

3. Start Oracle Database

SQL> startup

ORACLE instance started.

Total System Global Area 384143360 bytes Fixed Size 2213616 bytes

Variable Size 268437776 bytes Database Buffers 109051904 bytes Redo Buffers 4440064 bytes Database mounted.

Database opened.

How To Shutdown Oracle Database

Following three methods are available to shutdown the oracle database: 1. Normal Shutdown

2. Shutdown Immediate 3. Shutdown Abort

1. Normal Shutdown

Don’t use this. It takes too long and sometimes doesn’t work at all!

During normal shutdown, before the oracle database is shut down, oracle will wait for all active users to disconnect their sessions. As the parameter name (normal) suggest, use this option to shutdown the database under normal conditions.

SQL> shutdown; Database closed. Database dismounted.

ORACLE instance shut down. SQL>

2. Shutdown Immediate

During immediate shutdown, before the oracle database is shut down, oracle will rollback active transaction and disconnect all active users. Use this option when there is a problem with your database and you don’t have enough time to request users to log-off.

(3)

SQL> shutdown immediate; Database closed.

Database dismounted.

ORACLE instance shut down. SQL>

3. Shutdown Abort

During shutdown abort, before the oracle database is shutdown, all user sessions will be terminated immediately. Uncomitted transactions will not be rolled back. Use this option only during emergency situations when the “shutdown” and “shutdown immediate” doesn’t work.

SQL> shutdown abort;

ORACLE instance shut down. SQL>

References

Related documents

Thus, what we may claim to have shown is that, given the membership relation and, for convenience, the pairing operator, as primitives, one can construct a strictly adequate

Chapter 6 challenges the widespread view that it is impossible to give a model-theoretic semantics for absolute quantification simply by providing such a semantics in NFU p.

Support for conversion of both PL/SQL Named blocks like Stored Procedures, Functions, Triggers, Packages etc.. as well as Anonymous blocks

Apart from letting us know whether the listener is up or down, you can also find the following valuable information from the lsnrctl status command output..  Listner Start Date

interface, the analysts should have similar design opportunities. The, by the analyst designed, interface should contain summarized information from both internal and external

Detta kapitel kommer att redogöra för eventuella kostnadsrelaterade skillnader mellan Oracle 10.2.0.3 samt Microsoft SQL Server 2005.. Grundläggande sammanställning av utomstående

Lena Öijen (2014): Collaboration between higher and school education: a study of the Regional Development Centre as associate.. Örebro Studies in

the more common term diversity is, however, used exclusively.. 1 Introduction 3 The most renowned ensemble techniques are probably bagging, boosting and stacking, all of