版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领
文档简介
1、oracle 11gr2 删除节点最佳实践-by YallonKing 20120829oracle 11gr2 删除节点最佳实践目录OS信息:2DB信息:2查看当前资源状态2写入测试数据3删除节点实例(可用DBCA,也可用后边的命令静默删除)4查看数据库状态4删除EM4备份OCR5删除实例(静默状态下)5查看数据库配置信息6查看数据库实例和redo情况6查看节点监听配置信息7更新oracle inventory7删除oracle软件7更新oracle inventory7查看节点状态8禁用节点cluster8查看节点状态9删除节点10查看节点状态10更新oracle inventory10删
2、除GI软件10删除相关目录11更新oracle inventory11删除后的验证11查看节点资源信息12验证测试数据12OS信息:grid11grac1 $ uname -aLinux 11grac1 2.6.32-300.10.1.el5uek #1 SMP Wed Feb 22 17:22:40 EST 2012 i686 i686 i386 GNU/LinuxDB信息:SQL> select * from v$version where rownum<5;BANNER-Oracle Database 11g Enterprise Edition Release 11.2.0
3、.1.0 - ProductionPL/SQL Release 11.2.0.1.0 - ProductionCORE 11.2.0.1.0 ProductionTNS for Linux: Version 11.2.0.1.0 - Production查看当前资源状态grid11grac1 $ crs_stat -tName Type Target State Host -ora.SM1.asm application ONLINE ONLINE 11grac1 ora.C1.lsnr application ONLINE ONLINE 11grac1 ora.ac1.gsd applica
4、tion ONLINE ONLINE 11grac1 ora.ac1.ons application ONLINE ONLINE 11grac1 ora.ac1.vip ora.t1.type ONLINE ONLINE 11grac1 ora.SM2.asm application ONLINE ONLINE 11grac2 ora.C2.lsnr application ONLINE ONLINE 11grac2 ora.ac2.gsd application ONLINE ONLINE 11grac2 ora.ac2.ons application ONLINE ONLINE 11gra
5、c2 ora.ac2.vip ora.t1.type ONLINE ONLINE 11grac2 ora.DATA.dg ora.up.type ONLINE ONLINE 11grac1 ora.ER.lsnr ora.er.type ONLINE ONLINE 11grac1 ora.N1.lsnr ora.er.type ONLINE ONLINE 11grac1 ora.asm ora.asm.type ONLINE ONLINE 11grac1 ora.eons ora.eons.type ONLINE ONLINE 11grac1 ora.gsd ora.gsd.type ONLI
6、NE ONLINE 11grac1 work ora.rk.type ONLINE ONLINE 11grac1 ora.oc4j ora.oc4j.type ONLINE ONLINE 11grac1 ora.ons ora.ons.type ONLINE ONLINE 11grac1 ora.racdb.db ora.se.type ONLINE ONLINE 11grac1 ora.scan1.vip ora.ip.type ONLINE ONLINE 11grac1 grid11grac1 $ srvctl status database -d racdbInstance racdb1
7、 is running on node 11grac1Instance racdb2 is running on node 11grac2写入测试数据oracle11grac1 $ sqlplus /nologSQL*Plus: Release 11.2.0.1.0 Production on Wed Aug 29 10:02:08 2012Copyright (c) 1982, 2009, Oracle. All rights reserved.SQL> conn /as sysdbaConnected.SQL> sho userUSER is "SYS"SQ
8、L> create table test (id number,name varchar2(10);Table created.SQL> insert into test values (1,'yallonking');1 row created.SQL> commit;Commit complete.SQL> select * from test; ID NAME- - 1 yallonking 删除节点实例(可用DBCA,也可用后边的命令静默删除)运行dbca,根据向导删除相关信息(注意执行dbca节点只能删除另一个节点的实例)instance ma
9、nagement-> delete an instance-> 输入sysdba用户的账户和密码-> 选定删除的节点实例oracle11grac1 $ export DISPLAY=192.168.137.1:0.0oracle11grac1 $ dbca查看数据库状态grid11grac1 $ srvctl status database -d racdbInstance racdb1 is running on node 11grac1grid11grac1 $ crsctl check cluster -all*11grac1:CRS-4537: Cluster Rea
10、dy Services is onlineCRS-4529: Cluster Synchronization Services is onlineCRS-4533: Event Manager is online*11grac2:CRS-4537: Cluster Ready Services is onlineCRS-4529: Cluster Synchronization Services is onlineCRS-4533: Event Manager is online*grid11grac1 $ 删除EMoracle11grac1 $ emca -deconfig dbcontro
11、l db -repos drop -cluster STARTED EMCA at Aug 29, 2012 10:29:12 AMEM Configuration Assistant, Version 11.2.0.0.2 ProductionCopyright (c) 2003, 2005, Oracle. All rights reserved.Enter the following information:Database unique name: racdbService name: racdbListener port number: 1521Listener ORACLE_HOM
12、E /u01/11.2.0/grid : Password for SYS user: Password for SYSMAN user: Do you wish to continue? yes(Y)/no(N): yAug 29, 2012 10:29:35 AM oracle.sysman.emcp.EMConfig performINFO: This operation is being logged at /u01/app/oracle/cfgtoollogs/emca/racdb/emca_2012_08_29_10_29_11.log.Aug 29, 2012 10:29:36
13、AM oracle.sysman.emcp.EMDBPreConfig performDeconfigurationWARNING: EM is not configured for this database. No EM-specific actions can be performed.Aug 29, 2012 10:29:45 AM oracle.sysman.emcp.ParamsManager checkListenerStatusForDBControlWARNING: Error initializing SQL connection. SQL operations canno
14、t be performedAug 29, 2012 10:29:45 AM oracle.sysman.emcp.EMReposConfig invokeINFO: Dropping the EM repository (this may take a while) .Aug 29, 2012 10:43:38 AM oracle.sysman.emcp.EMReposConfig invokeINFO: Repository successfully droppedEnterprise Manager configuration completed successfullyFINISHED
15、 EMCA at Aug 29, 2012 10:43:38 AMoracle11grac1 $ 备份OCRroot11grac1 # /u01/11.2.0/grid/bin/ocrconfig -manualbackup11grac1 2012/08/29 10:47:33 /u01/11.2.0/grid/cdata/racscan/backup_20120829_104733.ocrroot11grac1 # 删除实例(静默状态下)oracle11grac1 $ dbca -silent -deleteinstance -nodelist 11grac2 -gdbname racdb
16、-instancename racdb2 -sysdbausername sys -sysdbapassword oracleLook at the log file "/u01/app/oracle/cfgtoollogs/dbca/racdb.log" for further details.查看数据库配置信息oracle11grac1 $ srvctl config database -d racdbDatabase unique name: racdbDatabase name: racdbOracle home: /u01/app/oracle/product/1
17、1.2.0/db_1Oracle user: oracleSpfile: +DATA/racdb/spfileracdb.oraDomain: Start options: openStop options: immediateDatabase role: PRIMARYManagement policy: AUTOMATICServer pools: racdbDatabase instances: racdb1Disk Groups: DATAServices: Database is administrator managed查看数据库实例和redo情况oracle11grac1 $ s
18、qlplus /nologSQL*Plus: Release 11.2.0.1.0 Production on Wed Aug 29 10:51:31 2012Copyright (c) 1982, 2009, Oracle. All rights reserved.SQL> conn /as sysdbaConnected.SQL> select inst_id,instance_name from gv$instance; INST_ID INSTANCE_NAME- - 1 racdb1SQL> select group#,thread# from v$log; GRO
19、UP# THREAD#- - 1 1 2 1 查看节点监听配置信息oracle11grac2 $ srvctl config listener -aName: LISTENERNetwork: 1, Owner: gridHome: <CRS home> /u01/11.2.0/grid on node(s) 11grac2,11grac1End points: TCP:1521被删除节点更新oracle inventoryoracle11grac2 db_1$ /u01/app/oracle/product/11.2.0/db_1/oui/bin/runInstaller -up
20、dateNodeList ORACLE_HOME=$ORACLE_HOME "CLUSTER_NODES=11grac2" -localStarting Oracle Universal Installer.Checking swap space: must be greater than 500 MB. Actual 4094 MB PassedThe inventory pointer is located at /etc/oraInst.locThe inventory is located at /u01/app/oraInventory'UpdateNod
21、eList' was successful.被删除节点删除oracle软件oracle11grac2 db_1$ cd $ORACLE_HOME/deinstalloracle11grac2 deinstall$ ./deinstall -localChecking for required files and bootstrapping .Please wait .更新oracle inventoryoracle11grac1 $ $ORACLE_HOME/oui/bin/runInstaller -updatenodelist ORACLE_HOME=$ORACLE_HOME &q
22、uot;CLUSTER_NODES=11grac1"Starting Oracle Universal Installer.Checking swap space: must be greater than 500 MB. Actual 3854 MB PassedThe inventory pointer is located at /etc/oraInst.locThe inventory is located at /u01/app/oraInventory'UpdateNodeList' was successful.查看节点状态root11grac1 # /
23、u01/11.2.0/grid/bin/olsnodes -s -t11grac1 Active Unpinned11grac2 Active Unpinned禁用节点clusterroot11grac2 # cd /u01/11.2.0/grid/crs/install/root11grac2 install# ./rootcrs.pl -deconfig -force2012-08-29 11:06:54: Parsing the host name2012-08-29 11:06:54: Checking for super user privileges2012-08-29 11:06
24、:54: User has super user privilegesUsing configuration parameter file: ./crsconfig_paramsVIP exists.:11grac1VIP exists.: /11grac1-vip/192.168.137.163/255.255.255.0/eth0VIP exists.:11grac2VIP exists.: /11grac2-vip/192.168.137.164/255.255.255.0/eth0GSD exists.ONS daemon exists. Local port 6100, remote
25、 port 6200eONS daemon exists. Multicast port 18611, multicast IP address 234.228.184.247, listening port 2016ADVM/ACFS is not supported on oraclelinux-release-5-8.0.2ACFS-9201: Not SupportedCRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on '11grac2'CRS-267
26、3: Attempting to stop 'ora.crsd' on '11grac2'CRS-2790: Starting shutdown of Cluster Ready Services-managed resources on '11grac2'CRS-2673: Attempting to stop 'ora.DATA.dg' on '11grac2'CRS-2677: Stop of 'ora.DATA.dg' on '11grac2' succeededCRS-26
27、73: Attempting to stop 'ora.asm' on '11grac2'CRS-2677: Stop of 'ora.asm' on '11grac2' succeededCRS-2792: Shutdown of Cluster Ready Services-managed resources on '11grac2' has completedCRS-2677: Stop of 'ora.crsd' on '11grac2' succeededCRS-2673:
28、 Attempting to stop 'ora.mdnsd' on '11grac2'CRS-2673: Attempting to stop 'ora.gpnpd' on '11grac2'CRS-2673: Attempting to stop 'ora.cssdmonitor' on '11grac2'CRS-2673: Attempting to stop 'ora.ctssd' on '11grac2'CRS-2673: Attempting to sto
29、p 'ora.evmd' on '11grac2'CRS-2673: Attempting to stop 'ora.asm' on '11grac2'CRS-2677: Stop of 'ora.cssdmonitor' on '11grac2' succeededCRS-2677: Stop of 'ora.mdnsd' on '11grac2' succeededCRS-2677: Stop of 'ora.gpnpd' on '11gr
30、ac2' succeededCRS-2677: Stop of 'ora.evmd' on '11grac2' succeededCRS-2677: Stop of 'ora.ctssd' on '11grac2' succeededCRS-2675: Stop of 'ora.asm' on '11grac2' failedCRS-2679: Attempting to clean 'ora.asm' on '11grac2'ORA-01089: immed
31、iate shutdown in progress - no operations are permittedProcess ID: 0Session ID: 0 Serial number: 0CRS-2681: Clean of 'ora.asm' on '11grac2' succeededCRS-2673: Attempting to stop 'ora.cssd' on '11grac2'CRS-2677: Stop of 'ora.cssd' on '11grac2' succeeded
32、CRS-2673: Attempting to stop 'ora.diskmon' on '11grac2'CRS-2673: Attempting to stop 'ora.gipcd' on '11grac2'CRS-2677: Stop of 'ora.gipcd' on '11grac2' succeededCRS-2677: Stop of 'ora.diskmon' on '11grac2' succeededCRS-2793: Shutdown of
33、Oracle High Availability Services-managed resources on '11grac2' has completedCRS-4133: Oracle High Availability Services has been stopped.Successfully deconfigured Oracle clusterware stack on this noderoot11grac2 install# 查看节点状态grid11grac1 $ olsnodes -s -t11grac1 Active Unpinned11grac2 Inac
34、tive Unpinned删除节点root11grac1 # /u01/11.2.0/grid/bin/crsctl delete node -n 11grac2CRS-4661: Node 11grac2 successfully deleted.查看节点状态root11grac1 # /u01/11.2.0/grid/bin/olsnodes -s -t11grac1 Active Unpinned更新oracle inventorygrid11grac2 bin$ pwd/u01/11.2.0/grid/oui/bingrid11grac2 bin$ ./runInstaller -up
35、dateNodeList ORACLE_HOME=$ORACLE_HOME "CLUSTER_NODES=11grac2" CRS=TRUE -local Starting Oracle Universal Installer.Checking swap space: must be greater than 500 MB. Actual 4094 MB PassedThe inventory pointer is located at /etc/oraInst.locThe inventory is located at /u01/app/oraInventory'
36、;UpdateNodeList' was successful.删除GI软件grid11grac2 deinstall$ pwd/u01/11.2.0/grid/deinstallgrid11grac2 deinstall$ ./deinstall -localChecking for required files and bootstrapping .Please wait .删除相关目录root11grac2 install# rm -rf /etc/oraInst.locroot11grac2 install# rm -rf /opt/ORCLfmap/root11grac2 i
37、nstall# rm -rf /u01更新oracle inventorygrid11grac1 bin$ pwd/u01/11.2.0/grid/oui/bingrid11grac1 bin$ ./runInstaller -updateNodeList ORACLE_HOME=$ORACLE_HOME "CLUSTER_NODES=11grac1" CRS=TRUE Starting Oracle Universal Installer.Checking swap space: must be greater than 500 MB. Actual 3826 MB Pa
38、ssedThe inventory pointer is located at /etc/oraInst.locThe inventory is located at /u01/app/oraInventory'UpdateNodeList' was successful.删除后的验证grid11grac1 bin$ cluvfy stage -post nodedel -n 11grac2 -verbosePerforming post-checks for node removal Checking CRS integrity.The Oracle clusterware is healthy on node "11grac1"CRS integrity check passedResult: Node removal check passedPost-check for node removal was successful. 查看节点资源信息grid11grac1 $ crsctl check cluster -all*11grac1:CRS-4537: Cluster Ready Services is onlineCRS-4529: Cluster Synchronization
温馨提示
- 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
- 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
- 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
- 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
- 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
- 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
- 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。
最新文档
- 2025河南驻马店市直公益性岗位招聘16人考试笔试模拟试题及答案解析
- 2025广东东莞市南城第一初级中学招聘1人笔试考试备考题库及答案解析
- 餐饮业店长选拔考试题库及答案
- 汽车行业高级财务经理面试指南及答案
- 建筑设计师面试题集含答案
- 电商运营面试常见问题解答
- 面试题及答案导游服务能力面试题及答案
- 行政管理人员招聘面试题及答案
- 市场总监面试题及市场策略分析含答案
- 交通设施资产评估技巧与问题集
- 探索丝绸之路课件
- 2025秋季国开《经济学(本)》期末考试题库及答案
- (新教材)2026年人教版八年级下册数学 24.3 数据的四分位数 课件
- 2025年甘肃省武威市凉州区大柳镇选聘专业化管理大学生村文书笔试考试备考试题及答案解析
- 戥秤的课件教学课件
- 2025内蒙古润蒙能源有限公司招聘22人考试笔试备考试题及答案解析
- 虚拟现实行业 VR 全景拍摄师岗位招聘考试试卷及答案
- 供应链金融业务操作与风险管理
- 2025年广西学法用法考试试题及答案
- 2025全球包装材料标准BRCGS第7版内部审核全套记录
- 紫外线灯管强度监测课件
评论
0/150
提交评论