拼吾爱程序人生

首页 » 数据库编程 » Oracle » 启动或关闭 Oracle 数据库的归档(ARCHIVELOG)模式
cobra - 2008-8-10 10:39:00
1.shutdown normal或shutdown immediate关闭数据库

[oracle@jumper oracle]$ sqlplus "/ as sysdba"


SQL*Plus: Release 9.2.0.4.0 - Production on Sat Oct 15 15:48:36 2005


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


Connected to:

Oracle9i Enterprise Edition Release 9.2.0.4.0 - Production

With the Partitioning option

JServer Release 9.2.0.4.0 - Production


SQL> shutdown immediate;

Database closed.

Database dismounted.

ORACLE instance shut down.



2.启动数据库到mount状态

SQL> startup mount;

ORACLE instance started.


Total System Global Area 101782828 bytes

Fixed Size 451884 bytes

Variable Size 37748736 bytes

Database Buffers 62914560 bytes

Redo Buffers 667648 bytes

Database mounted.



3.启用或停止归档模式

如果要启用归档模式,此处使用

alter database archivelog 命令。

SQL> alter database archivelog;

Database altered.


SQL> alter database open;


Database altered.


SQL> archive log list;

Database log mode Archive Mode

Automatic archival Enabled

Archive destination /opt/oracle/oradata/conner/archive

Oldest online log sequence 148

Next log sequence to archive 151

Current log sequence 151



如果需要停止归档模式,此处使用:

alter database noarchivelog 命令。

SQL> shutdown immediate;

Database closed.

Database dismounted.

ORACLE instance shut down.

SQL> startup mount;

ORACLE instance started.


Total System Global Area 101782828 bytes

Fixed Size 451884 bytes

Variable Size 37748736 bytes

Database Buffers 62914560 bytes

Redo Buffers 667648 bytes

Database mounted.

SQL> alter database noarchivelog;


Database altered.


SQL> alter database open;


Database altered.


SQL> archive log list;

Database log mode No Archive Mode

Automatic archival Enabled

Archive destination /opt/oracle/oradata/conner/archive

Oldest online log sequence 149

Current log sequence 152


(文/陈林  出处/赛迪网)

 您可能对 [Oracle] 的这些文章也感兴趣:

Oracle比SQL Server更好吗?
Oracle的SQL语句优化
研究人员找到新方法黑掉Oracle数据库
慎用Windows优化大师对Oracle服务器执行优化
Oracle新技术提高了Linux 的实用性和商业价值
Oracle许可证制度与审计的恶梦
ORACLE数据表的设计和管理
Oracle宣布WebLogic套件
Oracle的事务处理
用Quick Slice获取Oracle进程的线程状态
利用Oracle重做日志文件保障数据安全
Oracle数据库中时间数据类型的操作技巧
1
查看完整版本: 启动或关闭 Oracle 数据库的归档(ARCHIVELOG)模式
Modify by pin5i DZNT_ExpandPackage 2.1.3296 2007-2009 pin5i.com
 Total Unique Visitors: