First, start monitoring and database
[[email protected] oracle]# su oraclebash-4.1$ lsnrctl start
The results are as follows, starting successfully:
lsnrctl for linux: version 11.2.0.1.0 - production on 04-apr-2014 16:15:25Copyright (c) 1991, 2009, oracle. all rights reserved. Starting /home/oracle/product/11.2/db_1/bin/tnslsnr: please wait ... tnslsnr for linux: version 11.2.0.1.0 - productionsystem parameter File is /home/oracle/product/11.2/db_1/network/admin/listener.oralog messages written to /home/oracle/diag/tnslsnr/JTWF/listener/alert/log.xmlListening on: (description= ( Address= (PROTOCOL=TCP) (HOST=JTWF) (port=1521)) connecting to (description= (address= (PROTOCOL=TCP) ( HOST=JTWF) (port=1521)) Status of the listener------------------------alias Listenerversion &nBsp; tnslsnr for linux: version 11.2.0.1.0 - ProductionStart Date 04-APR-2014 16:15:25Uptime 0 days 0 hr. 0 min. 0 sectrace level offSecurity ON: Local OS AuthenticationSNMP offlistener parameter file /home/oracle/product/11.2/db_1/network/admin /listener.oralistener log&nbSp file /home/oracle/diag/tnslsnr/jtwf/listener/alert/ log.xmllistening endpoints summary... (description= (address= (PROTOCOL=tcp) (HOST=JTWF) ( port=1521)) the listener supports no servicesthe command completed Successfully
2. Start the database:
Su oraclebash-4.1$ sqlplus/nolog
The results are as follows:
Sql*plus:release 11.2.0.1.0 Production on Fri Apr 4 16:15:52 2014Copyright (c) 1982, D, Oracle. All rights reserved. Sql>
Log in as SYSDBA and execute command startup
Sql> Conn/as sysdbaconnected to an idle instance. Sql> Startup
The results are as follows:
ORACLE instance started. Total System Global area 839282688 bytesfixed size 2217992 bytesvariable size 578815992 bytesdatabase Buffers 251658240 Bytesredo buffers 6590464 bytesdatabase mounted. Database opened. Sql>
1. Close the database
Su oracle[[email protected] oracle]# su oraclebash-4.1$ sqlplus/nolog
Landing Sqlplus, the results are as follows:
Sql*plus:release 11.2.0.1.0 Production on Fri Apr 4 15:10:59 2014Copyright (c) 1982, D, Oracle. All rights reserved. Sql>
Sql>conn/as sysdbaconnected.
To close the database:
sql> shutdown immediatedatabase closed. Database dismounted. ORACLE instance shut down.
After you close the database, if you execute a query command, the following error is reported:
Sql> SELECT * FROM Vio_business_request;select * from Vio_business_request*error to line 1:ora-01034:oracle not Availa Bleprocess id:14138session id:75 Serial number:503sql>
Exit Sqlplus:
Sql> exit disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.1.0-64bit productionwith the part Itioning, OLAP, Data Mining and Real application testing options
bash-4.1$ lsnrctl Stop//Oracle User execution Lsnrctl for linux:version 11.2.0.1.0-production on 04-apr-2014 15:17:00copyright (c) 1991, Oracle. All rights reserved. Connecting to (Description= (address= (protocol=tcp) (HOST=JTWF)) the command port=1521 successfullybash-4.1$ lsnrctl stoplsnrctl for linux:version 11.2.0.1.0-production on 04-apr-2014 15:17:00Copyright (c) 1991, Oracle. All rights reserved. Connecting to (Description= (address= (protocol=tcp) (HOST=JTWF)) the command port=1521 completed
This article is from the "Technical Achievement Dream" blog, please be sure to keep this source http://pizibaidu.blog.51cto.com/1361909/1612354
Startup and shutdown monitoring, database for oracle11g R2 under CentOS