你好,游客 登录 注册 搜索
背景:
阅读新闻

Oracle 10g 中Duplicate 复制数据库

[日期:2012-06-09] 来源:Linux社区  作者:tianyihuyidao [字体:大 中 小]

2、创建复制数据库的相关目录,包括adump、bdump、cdump、udump、oradata/catdb

[Oracle@ORA10G dbs]$ cd /oracle/admin
[oracle@ORA10G dbs]$ mkdir catdb catdb/adump catdb/bdump catdb/cdump catdb/udump
[oracle@ORA10G dbs]$ ll /oracle/admin/
total 8
drwxr-xr-x  7 oracle oinstall 4096 Feb 17 19:29 catdb
drwxr-x---  8 oracle oinstall 4096 Feb 11 19:19 hongye
[oracle@ORA10G dbs]$ mkdir /oracle/oradata/catdb/
[oracle@ORA10G dbs]$ ll /oracle/oradata/catdb/
total 0

3、将ORACLE_SID设置为复制数据库的sid,那么就不需要额外的配置复制数据库的网络文件了,前提是已经配置了目标数据库的网络配置文件,二者必须至少要配其一。

[oracle@ORA10G dbs]$ echo $ORACLE_SID
hongye
[oracle@ORA10G dbs]$ export ORACLE_SID=catdb
[oracle@ORA10G dbs]$ echo $ORACLE_SID
catdb

4、创建复制数据库的密码文件。

[oracle@ORA10G dbs]$ orapwd file=$ORACLE_HOME/dbs/orapwcatdb

Enter password for SYS:

5、登录复制数据库,以nomount方式打开数据库。

[oracle@ORA10G dbs]$ sql

SQL*Plus: Release 10.2.0.5.0 - Production on Thu Feb 17 19:50:57 2011

Copyright (c) 1982, 2010, Oracle.  All Rights Reserved.

IDLE > conn /as sysdba
Connected to an idle instance.
IDLE > startup nomount pfile=$ORACLE_HOME/dbs/initcatdb.ora
ORACLE instance started.

Total System Global Area   83886080 bytes
Fixed Size                  1272096 bytes
Variable Size              58722016 bytes
Database Buffers           16777216 bytes
Redo Buffers                7114752 bytes
IDLE > exit
Disconnected from Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options

linux
相关资讯       Oracle高级培训 
本文评论   查看全部评论 (0)
表情: 表情 姓名: 字数

       

评论声明
  • 尊重网上道德,遵守中华人民共和国的各项有关法律法规
  • 承担一切因您的行为而直接或间接导致的民事或刑事法律责任
  • 本站管理人员有权保留或删除其管辖留言中的任意内容
  • 本站有权在网站内转载或引用您的评论
  • 参与本评论即表明您已经阅读并接受上述条款