oracle的启动过程(2)

发表于:2013-08-08来源:博客园作者:虫师点击数: 标签:oracle
现在进入了数据库的mount状态,我们通过mount启动的时候,下面会多一句提示Database mounted. 数据库准备就绪。 open状态 opening the database includes the following ta

  现在进入了数据库的mount状态,我们通过mount启动的时候,下面会多一句提示“Database mounted.” 数据库准备就绪。

  open状态

  opening the database includes the following tasks

  opening the online data log files

  opening the onling redo log files

  If any of the datafiles or noline redo log files are not present when you attempt to open the database ,the oracle server returns an error.

  During this final stage,the oracle server verfies that all the data files and online redo log files can be opened and checks the consistency of the database . If necessary , the SMON background process initiates instance recovery.

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

  打开数据库包括下列任务:

  打开在线数据日志文件

  打开联机重做日志文件

  如果任何数据文件或非线性重做日志文件不存在,当您试图打开的数据库,服务器返回错误。

  在这最后阶段,该服务器验证所有数据文件和联机重做日志文件可以打开并检查数据库的一致性。如果需要,该系统监控进程开始实例恢复。

复制代码

  [ora10@localhost dbs]$ sqlplus /nolog

  SQL*Plus: Release 10.2.0.1.0 - Production on Wed Jul 25 21:50:55 2012

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

  SQL> conn /as sysdba

  Connected to an idle instance.

  SQL> startup

  ORACLE instance started.

  Total System Global Area 205520896 bytes

  Fixed Size 1218532 bytes

  Variable Size 79693852 bytes

  Database Buffers 121634816 bytes

  Redo Buffers 2973696 bytes

  Database mounted.

  Database opened.

复制代码

  在上面的命令中,startup后面不加其它信息的话,系统会为我们直接启动到第4个状态。

  数据库关闭的三种方式

  1、shutdown normal

  正常方式关闭数据库。

  2、shutdown immediate

  立即方式关闭数据库。

  在SVRMGRL中执行shutdown immediate,数据库并不立即关闭,

  而是在Oracle执行某些清除工作后才关闭(终止会话、释放会话资源),

  当使用shutdown不能关闭数据库时,shutdown immediate可以完成数据库关闭的操作。

  3、shutdown abort

  直接关闭数据库,正在访问数据库的会话会被突然终止,

  如果数据库中有大量操作正在执行,这时执行shutdown abort后,重新启动数据库需要很长时间。

原文转自:http://www.cnblogs.com/fnng/archive/2012/07/24/2607482.html