Oracle 10g OCM考试(Oracle Certified Master)参考资料.doc

上传人:11****ws 文档编号:3179827 上传时间:2019-05-24 格式:DOC 页数:49 大小:187KB
下载 相关 举报
Oracle 10g OCM考试(Oracle Certified Master)参考资料.doc_第1页
第1页 / 共49页
Oracle 10g OCM考试(Oracle Certified Master)参考资料.doc_第2页
第2页 / 共49页
Oracle 10g OCM考试(Oracle Certified Master)参考资料.doc_第3页
第3页 / 共49页
Oracle 10g OCM考试(Oracle Certified Master)参考资料.doc_第4页
第4页 / 共49页
Oracle 10g OCM考试(Oracle Certified Master)参考资料.doc_第5页
第5页 / 共49页
点击查看更多>>
资源描述

1、一、术语说明db 机:是指在 section 0 阶段进行手动建库的机器。gridcontrol 机:是指在 section 2 阶段进行 grid control 软件安装的机器。RAC 机:是指在 section 7 阶段使用 VNC 连接到远程服务器安装 RAC 时使用的远程机器。奇数机(ODD)与偶数机(EVEN):在真正考试时,每个人面前会有两台机器,一台称为奇数机(ODD) ,一台称为偶数机(EVEN) ,要你在 ODD 机器上做什么或者在 EVEN 机器上做什么,偶数还是奇数是依靠机器的 hostname 最后一位或者两位数字来定的,通常会要求你在奇数机上创建数据库,在偶数机上安

2、装 Grid Control 的 OMS。偶数机上是没有Oracle 软件的,因此 OMS 需要的 Repository 这个数据库也需要创建在奇数机上,再加上之后第二天会要求创建的 Standby 实例,总共会有三个实例运行在奇数机上。二、考试安排及要求(一)时间安排第一天:section 0:创建一个数据库 45 分钟section 1:数据库和网络配置 120 分钟section 2:Gridcontrol 安装配置 120 分钟section 3:数据库备份恢复 60 分钟section 4:数据仓库管理 90 分钟第二天:section 5:数据库管理 120 分钟section 6

3、:数据库性能管理 120 分钟section 7:部署 Oracle RAC 数据库 105 分钟sectoin 8:部署 Dataguard 数据库 60 分钟(二)注意事项1、早点儿到考场,可以挑自己满意的机子,去晚了就只有别人挑剩下的了。正式考试前可以有 15 分钟的时间熟悉考试环境。2、请一定在坐到考试桌前之后,尽快检查你面前的机器,会是两台 RHEL4 的 Linux 服务器,Gnome 的图形界面(喜欢用 KDE 的兄弟们请去熟悉一下 Gnome 的操作) ,有鼠标有键盘,检查你的键盘输入是否顺畅,检查你的鼠标移动是否顺畅,检查机器的电源插座是否插牢,检查 Oracle 10gR2

4、 的软件是否已经安装,检查$ORACLE_HOME 等环境参数是否已经设置好,检查联机文档是否可以正常读取。按照常理来说,这些都不应该出问题,但是万一你运气好碰到有问题的机器,一旦考试开始计时,那损失的就只能是你自己了。哦,为什么是两台机器呢?因为一台是用来创建数据库,而另外一台是用来安装 Grid Control 的 OMS。3、请检查一下两台考试机的硬件配置,重点看一下其内存大小,如果是 2g 大小的,每个数据库实例可以考虑分配 350m 的内存;如果是 1g 大小的,每个数据库实例最多分配 250m的内存。4、考试时可以参考 oracle 的官方文档,在考试机上就有。另外,还有安装介质。

5、5、在进行 section 0,section 1 时注意审题,如果提示对数据库进行备份,请按要求进行备份。在接下来的考试中有可能 oracle 设置陷阱在后面的题要求恢复。6、section0、2、7、8 都是死题,而且都是必考的。并且可能包含如下陷阱:第一,可能需要先恢复,数据库才能用。第二,安装 rac 时,ssh 可能不通。第三,安装 grid control 时,注意 prefill 等。7、时刻注意查看随机自带的 oracle DOC,一些命令操作可以从 doc 中复制、粘贴、修改。8、可以用 Gnome 下的 Text Editor 对一些复制好的命令进行编辑,以提高效率。9、时

6、刻注意 OCM 考试中的各种陷阱。三、考试题库及讲解(一)Section 0:创建数据库(即手动建库)【在 db 机操作】1、手动建库1)确定实例名。export ORACLE_SID=test2)建立密码文件。orapwd file=orapwtest password=oracle3)建立 pfile。cat init.ora|grep -v #|grep -v $ inittest.ora在 inittest.ora 里只包含如下初始化参数:db_name=testprocesses=150controlfiles=(xxxxxx,xxxxxx)db_block_size=8192log

7、_buffer=50000000sga_target=300mundo_management=autoundo_tablespace=undotbsbackground_dump_destcore_dump_destuser_dump_dest4)建立 spfile 并启动实例。sqlsqlplus / as sysdbasqlcreate spfile from pfilesqlstartup nomount5)手工创建数据库(使用 create database 命令)CREATE DATABASE mynewdbUSER SYS IDENTIFIED BY pz6r58USER SYST

8、EM IDENTIFIED BY y1tz5pLOGFILE GROUP 1 (/u01/oracle/oradata/mynewdb/redo01.log) SIZE 100M,GROUP 2 (/u01/oracle/oradata/mynewdb/redo02.log) SIZE 100M,GROUP 3 (/u01/oracle/oradata/mynewdb/redo03.log) SIZE 100MMAXLOGFILES 5MAXLOGMEMBERS 5MAXLOGHISTORY 1MAXDATAFILES 100MAXINSTANCES 1CHARACTER SET US7ASC

9、IINATIONAL CHARACTER SET AL16UTF16DATAFILE /u01/oracle/oradata/mynewdb/system01.dbf SIZE 325M REUSEEXTENT MANAGEMENT LOCALSYSAUX DATAFILE /u01/oracle/oradata/mynewdb/sysaux01.dbf SIZE 325M REUSEDEFAULT TABLESPACE tbs_1(在考试时去掉这条语句)DEFAULT TEMPORARY TABLESPACE tempts1TEMPFILE /u01/oracle/oradata/mynew

10、db/temp01.dbf SIZE 20M REUSEUNDO TABLESPACE undotbs DATAFILE /u01/oracle/oradata/mynewdb/undotbs01.dbfSIZE 200M REUSE AUTOEXTEND ON MAXSIZE UNLIMITED;6)运行相关脚本。CONNECT SYS/password AS SYSDBA/u01/oracle/rdbms/admin/catalog.sql/u01/oracle/rdbms/admin/catproc.sql?/rdbms/admin/catblock.sql?/rdbms/admin/c

11、atoctk.sql?/rdbms/admin/owminst.plbconnect system/oracle?/sqlplus/admin/pupbld.sql2、section0 阶段考试需要注意的具体事项1)按题目要求设置“字符集”2)有 5 块磁盘,建库建在指定位置,一般都是建在文件系统上。3)考试的结果是美国那边直接用脚本连到你的服务器上,通过数据字典抓取结果,然后判断你哪些错了,所以,一定要保证在最后的时候,数据库是 OPEN 的,监考老师说还有 5 分钟结束考试的时候,不要再做什么其它操作了。如果之前你创建完数据库,想要 shutdown以后冷备一下的话,请估算好时间。我听到的

12、案例是冷备刚完成,数据库还未 startup,结果美国那边开始抓取考试结果,因为无法连接数据库,因此第一天上午的 section 得了零分。4)为了减省时间,如果题目里没有明确要求备份,可以先不备份。5)如果有时间,用 root 用户修改/etc/hosts 文件,使该文件里包括 2 个节点的主机名和相应的 ip 地址。3、参考的联机文档1、administrators guide-2 creating a oracle database- Manually Creating an Oracle Database(二)Section 1:数据库和网络的配置【在 db 机操作】1、数据库配置(管

13、理表空间)有如下考题需要注意:一、Create a temporary tablespace group that contains two temporary tablespaces to support batch process about creation of large indexes,and analyzing tables. Use the following specification:1、Temporary tablespace group named TEMP_GRP containing temporary tablespaces TEMP1 and TEMP2.2、M

14、ake TEMP_GRP the default temporary tablespace for all new users.答案:create temporary tablespace temp1 tempfile /u01/app/oradata/temp1.dbf size 50m tablespace group TEMP_GRP;create temporary tablespace temp2 tempfile /u01/app/oradata/temp2.dbf size 50m tablespace group TEMP_GRP;alter database default

15、temporary tablespace TEMP_GRP;select * from database_properties;二、Create a permanent tablespace to store sample test data.Use the following specification:1、Tablespace name of EXAMPLE2、Initial datafile size of 400MB with the file expected to grow to 4GB.3、Initial extent size of 1MB4、Next extent size

16、of 1MB答案:create tablespace example datafile xxxxxxx size 400m autoextend on maxsize 4g extent management local uniform size 1m;三、Create a permanent tablespace to store indexes.Use the following specification:1、Tablespace name of INDX2、File size of 40MB答案:create tablespace indx datafile size 40m;四、Cr

17、eate a permanent tablespace to store data collected from the various Oracle tools.Use the following specification:1、Tablespace name of tools2、File size of 48MB3、Initial extent size of 4MB4、Next extent size of 4MB答案:create tablespace tools datafile size 48m extent management local uniform size 4m;五、C

18、reate a permanent tablespace for storing segments associated with online transaction processing with high insert rates.Due to the potential high volume of concurrent inserts,every effort should be taken to reduce contention such of the tables that will be stored in this tablespace.Use the following

19、specification:1、Tablespace name of OLTP2、File size of 48MB3、Initial extent size of 2MB4、Next extent size of 2MB答案:create tablespace oltp datafile size 48m extent managemnet local uniform size 2m segment space management auto;六、Due to the expected high volumn of transaction, the database should have

20、the following configuration:1、A minimum of 5 redo log groups2、Each redo log group should not be a single point of failure3、File size of 100MB4、Specify the Location such that it minimizes contention and reduces the risk of a single point of failure case of disk drive failure.答案:sqlALTER DATABASE ADD

21、LOGFILE GROUP 4 (/u01/app/oradata/test/log4a.log, /u01/app/oradata/test/log4b.log) SIZE 100m,group 5 (/u01/app/oradata/test/log5a.log,/u01/app/oradata/test/log5b.log) size 100m;sqlalter database add logfile member /u01/app/oradata/shuai/redo1b.log to group 1;注意:日志组的 2 个 member 应该分布在 2 个不同的磁盘上。七、Trip

22、lex the controlfile to minimize recovery in case of disk drive failure.答案:将数据库关闭,然后拷贝控制文件到目标路径,然后改 pfile 中的 control 参数,重新生成 spfile,最后启动数据。八、As user SYS,run the script /home/oracle/scripts/create_bishhr.sql. Ignore any errors concerning OE.But do not ignore any other errors.Investigate the parameter

23、file for reasonable size for each parameter listed. Add additional parameters as you deem necessary to support an optimal database environment. In addition, modify or add the following listed parameters:UTL_FILE_DIR=(/home/oracle,/home/oracle/temp,/home/oracle/scripts)Note:Applications that use Orac

24、le10g features will be running therefore, ensure the database and instance are appropriately configured.答案:主要是根据题目要求调整数据库的初始化参数。九、Backup the database to prepare for complete recovery under all circumstances.答案:给数据库做一个冷备,可以使用操作系统命令直接进行拷贝,最后记着 Open the database.十、管理临时表空间组及更改默认的临时表空间一些相关的命令:ALTER TABLE

25、SPACE lmtemp3 TABLESPACE GROUP ;-指 lmtemp3 不属于任何表空间组。alter database default tablespace tbs1;select * from database_properties;2、网络配置 例题一、如何配置一个非默认端口的监听,并启动它。答案:第一,配置 listener.ora 文件LISTENER=(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=sale-server)(PORT=1421)(ADDRESS=(PROTOCOL=ipc)(KEY=ext

26、proc)SID_LIST_LISTENER=(SID_LIST=(SID_DESC=(GLOBAL_DBNAME=)(ORACLE_HOME=/oracle10g)(SID_NAME=sales)(SID_DESC=(SID_NAME=plsextproc)(ORACLE_HOME=/oracle10g)(PROGRAM=extproc)第二,配置 tnsnames.ora 文件listene1=(DESCRIPTION= (ADDRESS=(PROTOCOL=tcp)(HOST=sales-svr)(PORT=1421)(CONNECT_DATA=(SERVICE_NAME=)第三,配置初

27、始化参数 LOCAL_LISTENER。alter system set LOCAL_LISTENER=listener1 scope=both;第四,启动监听。lsnrctl start二、如何配置共享服务器模式。答案:第一,设置一些初始化参数。alter system set dispatchers=(PROTOCOL=TCP)(DISPATCHERS=2) scope=both;alter system set shared_servers=5 scope=both;alter system set max_shared_servers=10 scope=both;alter syste

28、m set max_dispatchers=5 scope=both;第二,在 tnsnames.ora 文件加入如下内容:shuai=(DESCRIPTION= (ADDRESS=(PROTOCOL=tcp)(HOST=sales-svr)(PORT=1421)(CONNECT_DATA=(SERVICE_NAME=shuai) (server=shared)第三,使用 system 用户连接数据库,方式如下:sqlplus system/oracleshuai第四,查看 system 用户的连入方式。lsnrctl service3、section1 阶段考试需要注意的具体事项无4、参考的

29、联机文档1)administrators guide- 8 Managing Tablespaces- Creating Tablespaces2)administrators guide- 6 Managing the Redo Log-Creating Redo Log Groups and Members3)Net Services Reference- 7 Listener Parameters (listener.ora)4)Net Services Reference- 6 Local Naming Parameters (tnsnames.ora)5)administrators

30、 guide- 4 Managing Oracle Database Processes- Configuring Oracle Database for Shared Server6)SQL Reference- 14 SQL Statements: CREATE CLUSTER to CREATE JAVA- CREATE DIRECTORY7)Net Services Administrators Guide-10 Configuring and Administering the Listener-Registering Information with a Nondefault Listener

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 教育教学资料库 > 精品笔记

Copyright © 2018-2021 Wenke99.com All rights reserved

工信部备案号浙ICP备20026746号-2  

公安局备案号:浙公网安备33038302330469号

本站为C2C交文档易平台,即用户上传的文档直接卖给下载用户,本站只是网络服务中间平台,所有原创文档下载所得归上传人所有,若您发现上传作品侵犯了您的权利,请立刻联系网站客服并提供证据,平台将在3个工作日内予以改正。