Starting a database instance is divided into two steps: The first step, start monitoring, and the second step, start the DB instance. I. How to start a DB instance 1. Go to Sqlplus launch instance [[email protected] ~]$ su-oracle--"Switch to Oracle User" PASSW Ord:[[email protected] ~]$ lsnrctl Start--"Turn on monitoring" Lsnrctl for Linux:version 10.2.0.1.0 -Production on 14-oct-2009 19:06:40copyright (c) 1991, 2005, Oracle. All rights reserved. Starting/home/oracle/product/10g/bin/tnslsnr:please wait ... Tnslsnr for linux:version 10.2.0.1.0-productionsystem parameter file is/home/oracle/product/10g/network/admin/ Listener.oralog messages Written to/home/oracle/product/10g/network/log/listener.loglistening on: (DESCRIPTION= ( Address= (PROTOCOL=IPC) (KEY=EXTPROC2)) Listening on: (Description= (address=) (PROTOCOL=TCP) (Host=redhat) )) Connecting to (Description= (address= (PROTOCOL=IPC) (KEY=EXTPROC2)) STATUS of the LISTENER------------------------Alias listenerversion Tnslsnr for linux:version 10. 2.0.1.0-productionstartDate 14-oct-2009 19:06:40uptime 0 days 0 hr. 0 min. 0 sectrace Level OFFSE Curity on:local OS authenticationsnmp offlistener Parameter File/home/oracle/pro Duct/10g/network/admin/listener.oralistener Log file/home/oracle/product/10g/network/log/listener.loglistening En Dpoints Summary ... (Description= (address= (PROTOCOL=IPC) (KEY=EXTPROC2))) (Description= (address= (protocol=tcp) (Host=redhat) (port=1522))) Services Summary ... Service "Plsextproc" has 1 instance (s). Instance "Plsextproc", status UNKNOWN, have 1 handler (s) for the This service ... The command completed successfully[[email protected] ~]$ sqlplus/nolog--"Go to Sqlplus" Sql*plus:release 10.2.0.1.0-production on Wed Oct 19:06:45 2009Copyright (c) 1982, 2005, Oracle. All rights reserved. Sql> conn/as SYSDBA--"Connect to Sysdba" Connected to an idle instance. Sql&gT Startup--"Start db instance" ORACLE instance started. Total System Global area 285212672 bytesfixed size 1218968 bytesvariable size 88082024 bytesdatabase buffers 1 88743680 Bytesredo buffers 7168000 bytesdatabase mounted. Database opened. sql> shutdown Immediate--"Close DB instance" database closed. Database dismounted. ORACLE instance shut down. Sql> exitdisconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.1.0-productionwith the partitioning, OLAP and Data Mining options[[email protected] ~]$ lsnrctl stop--"Turn off listening" Lsnrctl for Linux:version 10.2.0.1.0-production on 14-oct-2009 19:08:06copyright (c) 1991, 2005, Oracle. All rights reserved. Connecting to (Description= (address= (PROTOCOL=IPC) (KEY=EXTPROC2))) The command completed successfully 2. Starting and shutting down the DB instance with Dbstart and Dbshut starts the listener lsnrctl start instance Dbstart It is easier to start the database with the Dbstart command, but install or on LinuxAfter Acle, the first time you use the Dbstart command you may report the following error: Oracle_home_listner is not SET, unable to Auto-start ORACLE Net listenerusage:/u01/app/or Acle/oracle/product/10.2.0/db_1/bin/dbstart oracle_home Reason: There is a problem with Oracle_home_listner settings in Dbstart and Dbshut script files, Open two files respectively found: With VI editing dbstart,oracle_home_listner=$1, modified to oracle_home_listner= $ORACLE _home and then save the exit, at this time run Dbstart, has no error, But there is no response, PS a process, no Oracle process, stating that the Oracle instance does not start properly. The reason is that in the/etc/oratab setup problem, we vi, found that zgz:/home/oracle/product/10g:n last set is "n" (I have only one instance of the environment, so only a single line of configuration statements), we need to modify "n" to "Y ”。 After the work done, Dbstart can be used normally: [[email protected] bin]$ lsnrctl Start--"Start monitoring" Lsnrctl F or linux:version 10.2.0.1.0-production on 14-oct-2009 19:44:53copyright (c) 1991, 2005, Oracle. All rights reserved. Starting/home/oracle/product/10g/bin/tnslsnr:please wait ... Tnslsnr for linux:version 10.2.0.1.0-productionsystem parameter file is/home/oracle/product/10g/network/admin/ Listener.oralog messages Written to/home/oracle/product/10g/network/log/listener.loglistEning on: (Description= (Address= (PROTOCOL=IPC) (KEY=EXTPROC2)) Listening on: (Description= (Address= (PROTOCOL=TCP) ( Host=redhat) (port=1522)) Connecting to (Description= (address= (PROTOCOL=IPC) (KEY=EXTPROC2))) STATUS of the LISTENER------------------------Alias listenerversion Tnslsnr for linux:version 10. 2.0.1.0-productionstart Date 14-oct-2009 19:44:53uptime 0 days 0 hr. 0 min. 0 sectrace Level offsecurity on:local OS authenticationsnmp offlistener Paramet ER file/home/oracle/product/10g/network/admin/listener.oralistener Log File/home/oracle/product/10g/network/lo g/listener.loglistening Endpoints Summary ... (Description= (address= (PROTOCOL=IPC) (KEY=EXTPROC2))) (Description= (address= (protocol=tcp) (Host=redhat) (port=1522))) Services Summary ... Service "Plsextproc" has 1 instance (s). Instance "Plsextproc", status UNKNOWN, have 1 handler (s) for the This service... The command completed successfully[[email protected] bin]$ Dbstart--"Start db instance" Proce Ssing Database Instance "Zgz": Log file/home/oracle/product/10g/startup.log[[email protected] bin]$ Dbshut --"Close db instance" [[[email protected] bin]$ lsnrctl stop--"Turn off monitoring" LSNRC TL for linux:version 10.2.0.1.0-production on 14-oct-2009 19:45:33copyright (c) 1991, 2005, Oracle. All rights reserved. Connecting to (Description= (address= (PROTOCOL=IPC))) The command KEY=EXTPROC2 completed II, How to get the DB instance and Linux system started together with the following statement in/etc/rc.d/rc.local to implement the same system boot instance: Su-oracle-c "lsnrctl start" su-oracle-c "Dbstart"
Start Oracle under Linux