Chinaunix首页 | 论坛 | 博客
  • 博客访问: 256544
  • 博文数量: 37
  • 博客积分: 0
  • 博客等级: 民兵
  • 技术积分: 378
  • 用 户 组: 普通用户
  • 注册时间: 2015-12-19 22:03
文章分类
文章存档

2018年(9)

2017年(11)

2016年(17)

我的朋友

分类: Oracle

2017-09-13 11:23:32

1.cmd命令窗口使用sqlplus连接到sql,用archive log list命令查询是否开启归档模式,我这里已开了归档模式;
C:\Users\Administrator>sqlplus

SQL*Plus: Release 11.2.0.1.0 Production on 星期三 9月 13 11:14:02 2017
Copyright (c) 1982, 2010, Oracle.  All rights reserved.

请输入用户名:  system/oracle@orcl as sysdba
连接到:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

SQL> archive log list;

数据库日志模式             非存档模式
自动存档             禁用
存档终点            USE_DB_RECOVERY_FILE_DEST
最早的联机日志序列     21
当前日志序列           23
2.关闭数据库
SQL> shutdown immediate;

数据库已经关闭。
已经卸载数据库。
ORACLE 例程已经关闭。
3.然后连接到空闲例程,启动数据库到mount状态,开启归档模式,并打开数据库
SQL> conn / as sysdba

已连接到空闲例程。

SQL> startup mount;

ORACLE 例程已经启动。
Total System Global Area 1288949760 bytes
Fixed Size                  1376520 bytes
Variable Size             335548152 bytes
Database Buffers          939524096 bytes
Redo Buffers               12500992 bytes
数据库装载完毕。

SQL> alter database archivelog;

数据库已更改。

SQL> archive log list;

数据库日志模式            存档模式
自动存档             启用
存档终点            USE_DB_RECOVERY_FILE_DEST
最早的联机日志序列     21
下一个存档日志序列   23
当前日志序列           23

SQL> alter database open;

数据库已更改。
阅读(1850) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~