存貯在asm中的ocr/votedisk/asm磁碟組損害的恢復
本實驗目的是利用ocr備份恢復存貯在asm中的ocr/votedisk/asm磁碟
環境redhat6.5 oracle11.2.0.3兩節點RAC
SQL> show parameter spfile
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
spfile string +SYS/hp580-cluster/asmparamete
rfile/registry.253.873908213
SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Real Application Clusters and Automatic Storage Management options
[grid@hp580-5 ~]$ crsctl status res -t
--------------------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
--------------------------------------------------------------------------------
Local Resources
--------------------------------------------------------------------------------
ora.DATA.dg
ONLINE ONLINE hp580-4
ONLINE ONLINE hp580-5
ora.FRA.dg
ONLINE ONLINE hp580-4
ONLINE ONLINE hp580-5
ora.LISTENER.lsnr
ONLINE ONLINE hp580-4
ONLINE ONLINE hp580-5
ora.SYS.dg
ONLINE ONLINE hp580-4
ONLINE ONLINE hp580-5
ora.asm
ONLINE ONLINE hp580-4 Started
ONLINE ONLINE hp580-5 Started
ora.gsd
OFFLINE OFFLINE hp580-4
OFFLINE OFFLINE hp580-5
ora.net1.network
ONLINE ONLINE hp580-4
ONLINE ONLINE hp580-5
ora.ons
ONLINE ONLINE hp580-4
ONLINE ONLINE hp580-5
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.LISTENER_SCAN1.lsnr
1 ONLINE ONLINE hp580-4
ora.LISTENER_SCAN2.lsnr
1 ONLINE ONLINE hp580-5
ora.LISTENER_SCAN3.lsnr
1 ONLINE ONLINE hp580-5
ora.cvu
1 ONLINE ONLINE hp580-5
ora.hp580-4.vip
1 ONLINE ONLINE hp580-4
ora.hp580-5.vip
1 ONLINE ONLINE hp580-5
ora.oc4j
1 ONLINE ONLINE hp580-5
ora.orcl.db
1 ONLINE ONLINE hp580-4 Open
2 ONLINE ONLINE hp580-5 Open
ora.scan1.vip
1 ONLINE ONLINE hp580-4
ora.scan2.vip
1 ONLINE ONLINE hp580-5
ora.scan3.vip
1 ONLINE ONLINE hp580-5
[grid@hp580-5 ~]$ ocrcheck
Status of Oracle Cluster Registry is as follows :
Version : 3
Total space (kbytes) : 262120
Used space (kbytes) : 2968
Available space (kbytes) : 259152
ID : 1794026097
Device/File Name : +sys
Device/File integrity check succeeded
Device/File not configured
Device/File not configured
Device/File not configured
Device/File not configured
Cluster registry integrity check succeeded
Logical corruption check bypassed due to non-privileged user
[grid@hp580-5 ~]$ crsctl query css votedisk
## STATE File Universal Id File Name Disk group
-- ----- ----------------- --------- ---------
1. ONLINE 1600c0ff5c084fa9bf2bb00d1381d589 (/dev/asm-diskg) [SYS]
Located 1 voting disk(s).
[grid@hp580-5 ~]$ asmcmd
ASMCMD> lsdsk -t -G sys
Create_Date Mount_Date Repair_Timer Path
09-MAR-15 09-MAR-15 0 /dev/asm-diskg
ASMCMD> exit
[grid@hp580-5 ~]$
[root@hp580-5 bin]# ./ocrconfig -manualbackup
hp580-5 2015/03/10 10:20:26 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup_20150310_102026.ocr
hp580-4 2014/12/12 10:59:56 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup_20141212_105956.ocr
[root@hp580-5 bin]# ./ocrconfig -showbackup
hp580-5 2015/03/10 08:45:49 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup00.ocr
hp580-5 2015/03/10 04:45:48 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup01.ocr
hp580-5 2015/03/10 00:45:48 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup02.ocr
hp580-4 2015/03/08 12:41:41 /g01/app/11.2.0/grid/cdata/hp580-cluster/day.ocr
hp580-4 2015/03/02 08:41:18 /g01/app/11.2.0/grid/cdata/hp580-cluster/week.ocr
hp580-5 2015/03/10 10:20:26 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup_20150310_102026.ocr
hp580-4 2014/12/12 10:59:56 /g01/app/11.2.0/grid/cdata/hp580-cluster/backup_20141212_105956.ocr
備份好後我們破壞ocr所在磁碟
[root@hp580-5 bin]# su - grid
[grid@hp580-5 ~]$ dd if=/dev/zero of=/dev/asm-diskg bs=4096 count=1
1+0 records in
1+0 records out
4096 bytes (4.1 kB) copied, 0.000330643 s, 12.4 MB/s
[grid@hp580-5 ~]$ exit
logout
[root@hp580-5 bin]# ./crsctl stop crs
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'hp580-5'
CRS-2673: Attempting to stop 'ora.crsd' on 'hp580-5'
CRS-2790: Starting shutdown of Cluster Ready Services-managed resources on 'hp580-5'
CRS-2673: Attempting to stop 'ora.LISTENER.lsnr' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.cvu' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN2.lsnr' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.SYS.dg' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.orcl.db' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN3.lsnr' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.oc4j' on 'hp580-5'
CRS-2677: Stop of 'ora.cvu' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.cvu' on 'hp580-4'
CRS-2677: Stop of 'ora.LISTENER.lsnr' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.hp580-5.vip' on 'hp580-5'
CRS-2677: Stop of 'ora.LISTENER_SCAN2.lsnr' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.scan2.vip' on 'hp580-5'
CRS-2677: Stop of 'ora.LISTENER_SCAN3.lsnr' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.scan3.vip' on 'hp580-5'
CRS-2677: Stop of 'ora.hp580-5.vip' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.hp580-5.vip' on 'hp580-4'
CRS-2677: Stop of 'ora.scan2.vip' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.scan2.vip' on 'hp580-4'
CRS-2677: Stop of 'ora.scan3.vip' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.scan3.vip' on 'hp580-4'
CRS-2676: Start of 'ora.cvu' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.orcl.db' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.DATA.dg' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.FRA.dg' on 'hp580-5'
CRS-2676: Start of 'ora.hp580-5.vip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.DATA.dg' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.FRA.dg' on 'hp580-5' succeeded
CRS-2676: Start of 'ora.scan2.vip' on 'hp580-4' succeeded
CRS-2672: Attempting to start 'ora.LISTENER_SCAN2.lsnr' on 'hp580-4'
CRS-2676: Start of 'ora.scan3.vip' on 'hp580-4' succeeded
CRS-2672: Attempting to start 'ora.LISTENER_SCAN3.lsnr' on 'hp580-4'
CRS-2676: Start of 'ora.LISTENER_SCAN2.lsnr' on 'hp580-4' succeeded
CRS-2676: Start of 'ora.LISTENER_SCAN3.lsnr' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.oc4j' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.oc4j' on 'hp580-4'
CRS-2676: Start of 'ora.oc4j' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.SYS.dg' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.asm' on 'hp580-5'
CRS-2677: Stop of 'ora.asm' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.ons' on 'hp580-5'
CRS-2677: Stop of 'ora.ons' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.net1.network' on 'hp580-5'
CRS-2677: Stop of 'ora.net1.network' on 'hp580-5' succeeded
CRS-2792: Shutdown of Cluster Ready Services-managed resources on 'hp580-5' has completed
CRS-2677: Stop of 'ora.crsd' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.crf' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.ctssd' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.evmd' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.asm' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.mdnsd' on 'hp580-5'
CRS-2677: Stop of 'ora.crf' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.evmd' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.mdnsd' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.ctssd' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.asm' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.cluster_interconnect.haip' on 'hp580-5'
CRS-2677: Stop of 'ora.cluster_interconnect.haip' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.cssd' on 'hp580-5'
CRS-2677: Stop of 'ora.cssd' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.gipcd' on 'hp580-5'
CRS-2677: Stop of 'ora.gipcd' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.gpnpd' on 'hp580-5'
CRS-2677: Stop of 'ora.gpnpd' on 'hp580-5' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'hp580-5' has completed
CRS-4133: Oracle High Availability Services has been stopped.
[root@hp580-5 bin]# crsctl start crs
-bash: crsctl: command not found
[root@hp580-5 bin]# ./crsctl start crs
CRS-4123: Oracle High Availability Services has been started.
[root@hp580-5 bin]# su - grid
[grid@hp580-5 ~]$ crsctl status res -t
CRS-4535: Cannot communicate with Cluster Ready Services
CRS-4000: Command Status failed, or completed with errors.
[grid@hp580-5 ~]$ crsctl status res -t -init
--------------------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.asm
1 ONLINE OFFLINE Instance Shutdown
ora.cluster_interconnect.haip
1 ONLINE OFFLINE
ora.crf
1 ONLINE ONLINE hp580-5
ora.crsd
1 ONLINE OFFLINE
ora.cssd
1 ONLINE OFFLINE STARTING
ora.cssdmonitor
1 ONLINE ONLINE hp580-5
ora.ctssd
1 ONLINE OFFLINE
ora.diskmon
1 OFFLINE OFFLINE
ora.evmd
1 ONLINE OFFLINE
ora.gipcd
1 ONLINE ONLINE hp580-5
ora.gpnpd
1 ONLINE ONLINE hp580-5
ora.mdnsd
1 ONLINE ONLINE hp580-5
[grid@hp580-5 ~]$ exit
檢視GRID的alert日誌
[gpnpd(50190)]CRS-2328:GPNPD started on node hp580-5.
2015-03-10 10:27:52.107
[cssd(50259)]CRS-1713:CSSD daemon is started in clustered mode
2015-03-10 10:27:53.887
[ohasd(50054)]CRS-2767:Resource state recovery not attempted for 'ora.diskmon' as its target state is OFFLINE
2015-03-10 10:27:56.302
[cssd(50259)]CRS-1714:Unable to discover any voting files, retrying discovery in 15 seconds; Details at (:CSSNM00070:) in /g01/app/11.2.0/grid/log/hp580-5/cssd/ocssd.log
2015-03-10 10:28:11.474
[cssd(50259)]CRS-1714:Unable to discover any voting files, retrying discovery in 15 seconds; Details at (:CSSNM00070:) in /g01/app/11.2.0/grid/log/hp580-5/cssd/ocssd.log
2015-03-10 10:28:26.546
[cssd(50259)]CRS-1714:Unable to discover any voting files, retrying discovery in 15 seconds; Details at (:CSSNM00070:) in /g01/app/11.2.0/grid/log/hp580-5/cssd/ocssd.log
2015-03-10 10:28:41.631
[cssd(50259)]CRS-1714:Unable to discover any voting files, retrying discovery in 15 seconds; Details at (:CSSNM00070:) in /g01/app/11.2.0/grid/log/hp580-5/cssd/ocssd.log
2015-03-10 10:28:56.717
檢視ocssd日誌
2015-03-10 10:27:17.407: [ CSSD][2364802816]clssgmExecuteClientRequest(): type(6) size(684) only connect and exit messages are allowed before lease acquisition proc(0x7f24840570b0) client(0x7f2484020190)
2015-03-10 10:27:17.408: [ CSSD][2364802816]clssgmDiscEndpcl: gipcDestroy 0x401b
2015-03-10 10:27:17.840: [ GPNP][2362259200]clsgpnp_profileCallUrlInt: [at clsgpnp.c:2104] get-profile call to url "ipc://GPNPD_hp580-5" disco "" [f=0 claimed- host: cname: seq: auth:]
2015-03-10 10:27:17.854: [ GPNP][2362259200]clsgpnp_profileCallUrlInt: [at clsgpnp.c:2234] Result: (0) CLSGPNP_OK. Successful get-profile CALL to remote "ipc://GPNPD_hp580-5" disco ""
2015-03-10 10:27:17.854: [ CSSD][2362259200]clssnmReadDiscoveryProfile: voting file discovery string(/dev/asm*)
2015-03-10 10:27:17.854: [ CSSD][2362259200]clssnmvDDiscThread: using discovery string /dev/asm* for initial discovery
2015-03-10 10:27:17.854: [ SKGFD][2362259200]Discovery with str:/dev/asm*:
2015-03-10 10:27:17.854: [ SKGFD][2362259200]UFS discovery with :/dev/asm*:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]Fetching UFS disk :/dev/asm-diskc:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]Fetching UFS disk :/dev/asm-diskd:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]Fetching UFS disk :/dev/asm-diskf:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]Fetching UFS disk :/dev/asm-diskg:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]Fetching UFS disk :/dev/asm-diske:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]Fetching UFS disk :/dev/asm-diskb:
2015-03-10 10:27:17.885: [ SKGFD][2362259200]OSS discovery with :/dev/asm*:
2015-03-10 10:27:17.886: [ SKGFD][2362259200]Handle 0x7f2478133d00 from lib :UFS:: for disk :/dev/asm-diskc:
2015-03-10 10:27:17.886: [ SKGFD][2362259200]Handle 0x7f2478136d00 from lib :UFS:: for disk :/dev/asm-diskd:
2015-03-10 10:27:17.887: [ SKGFD][2362259200]Handle 0x7f2478137530 from lib :UFS:: for disk :/dev/asm-diskf:
2015-03-10 10:27:17.887: [ SKGFD][2362259200]Handle 0x7f2478137d60 from lib :UFS:: for disk :/dev/asm-diskg:
2015-03-10 10:27:17.888: [ SKGFD][2362259200]Handle 0x7f24781349f0 from lib :UFS:: for disk :/dev/asm-diske:
2015-03-10 10:27:17.888: [ SKGFD][2362259200]Handle 0x7f2478135490 from lib :UFS:: for disk :/dev/asm-diskb:
2015-03-10 10:27:17.888: [ SKGFD][2362259200]Lib :UFS:: closing handle 0x7f2478133d00 for disk :/dev/asm-diskc:
2015-03-10 10:27:17.889: [ SKGFD][2362259200]Lib :UFS:: closing handle 0x7f2478136d00 for disk :/dev/asm-diskd:
2015-03-10 10:27:17.889: [ SKGFD][2362259200]Lib :UFS:: closing handle 0x7f2478137530 for disk :/dev/asm-diskf:
2015-03-10 10:27:17.889: [ SKGFD][2362259200]Lib :UFS:: closing handle 0x7f2478137d60 for disk :/dev/asm-diskg:
2015-03-10 10:27:17.889: [ SKGFD][2362259200]Lib :UFS:: closing handle 0x7f24781349f0 for disk :/dev/asm-diske:
2015-03-10 10:27:17.889: [ SKGFD][2362259200]Lib :UFS:: closing handle 0x7f2478135490 for disk :/dev/asm-diskb:
2015-03-10 10:27:17.889: [ CSSD][2362259200]clssnmvDiskVerify: Successful discovery of 0 disks
2015-03-10 10:27:17.889: [ CSSD][2362259200]clssnmCompleteInitVFDiscovery: Completing initial voting file discovery
2015-03-10 10:27:17.889: [ CSSD][2362259200]clssnmvFindInitialConfigs: No voting files found
2015-03-10 10:27:17.889: [ CSSD][2362259200](:CSSNM00070:)clssnmCompleteInitVFDiscovery: Voting file not found. Retrying discovery in 15 seconds
2015-03-10 10:27:18.409: [ CSSD][2364802816]clssscSelect: cookie accept request 0x7f24840570b0
確認磁碟壞,開始恢復
[root@hp580-5 bin]# ./crsctl stop crs -f
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'hp580-5'
CRS-2673: Attempting to stop 'ora.cssdmonitor' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.crf' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.mdnsd' on 'hp580-5'
CRS-2677: Stop of 'ora.cssdmonitor' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.crf' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.gipcd' on 'hp580-5'
CRS-2677: Stop of 'ora.mdnsd' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.gipcd' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.gpnpd' on 'hp580-5'
CRS-2677: Stop of 'ora.gpnpd' on 'hp580-5' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'hp580-5' has completed
CRS-4133: Oracle High Availability Services has been stopped.
[root@hp580-5 bin]# ./crsctl start
Usage:
crsctl start resource {
Start designated resources
where
resName [...] One or more blank-separated resource names
-w Resource filter
-all All resources
-n Server name
-k Resource cardinality ID
-d Resource degree ID
-env Attribute overrides for this command
-f Force option
-i Fail if request cannot be processed immediately
crsctl start crs [-excl [-nocrs]|-nowait]
Start OHAS on this server
where
-excl Start Oracle Clusterware in exclusive mode
-nocrs Start Oracle Clusterware in exclusive mode without starting CRS
-nowait Do not wait for OHAS to start
crsctl start cluster [[-all]|[-n
Start CRS stack
where
Default Start local server
-all Start all servers
-n Start named servers
server [...] One or more blank-separated server names
crsctl start ip -A {
Start an IP on the given interface with specified net mask
Where
IP_name Name which resolves to an IP. If it is not a fully qualified domain name then standard name search will be used.
IP_address IP address
net_mask Subnet mask for the IP to start
interface_name Interface on which to start the IP
crsctl start testdns [-address
Start a test DNS listener that listens on the given address at the given port and for specified domain
Where
IP_address IP address to be used by the listener (defaults to hostname)
port The port on which the listener will listen. Default value is 53.
domain The domain query for which to listen. By default, all domain queries are processed.
-once Flag indicating that DNS listener should exit after one DNS query packet is received
-v Verbose output
[root@hp580-5 bin]# ./crsctl start crs -excl -nocrs
CRS-4123: Oracle High Availability Services has been started.
CRS-2672: Attempting to start 'ora.mdnsd' on 'hp580-5'
CRS-2676: Start of 'ora.mdnsd' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.gpnpd' on 'hp580-5'
CRS-2676: Start of 'ora.gpnpd' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.cssdmonitor' on 'hp580-5'
CRS-2672: Attempting to start 'ora.gipcd' on 'hp580-5'
CRS-2676: Start of 'ora.cssdmonitor' on 'hp580-5' succeeded
CRS-2676: Start of 'ora.gipcd' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.cssd' on 'hp580-5'
CRS-2672: Attempting to start 'ora.diskmon' on 'hp580-5'
CRS-2676: Start of 'ora.diskmon' on 'hp580-5' succeeded
CRS-2676: Start of 'ora.cssd' on 'hp580-5' succeeded
CRS-2679: Attempting to clean 'ora.cluster_interconnect.haip' on 'hp580-5'
CRS-2672: Attempting to start 'ora.ctssd' on 'hp580-5'
CRS-2681: Clean of 'ora.cluster_interconnect.haip' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.cluster_interconnect.haip' on 'hp580-5'
CRS-2676: Start of 'ora.ctssd' on 'hp580-5' succeeded
CRS-2676: Start of 'ora.cluster_interconnect.haip' on 'hp580-5' succeeded
CRS-2672: Attempting to start 'ora.asm' on 'hp580-5'
CRS-2676: Start of 'ora.asm' on 'hp580-5' succeeded
[root@hp580-5 bin]# ./crsctl status res -t -init
--------------------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.asm
1 ONLINE INTERMEDIATE hp580-5 OCR not started
ora.cluster_interconnect.haip
1 ONLINE ONLINE hp580-5
ora.crf
1 OFFLINE OFFLINE
ora.crsd
1 OFFLINE OFFLINE
ora.cssd
1 ONLINE ONLINE hp580-5
ora.cssdmonitor
1 ONLINE ONLINE hp580-5
ora.ctssd
1 ONLINE ONLINE hp580-5 OBSERVER
ora.diskmon
1 OFFLINE OFFLINE
ora.evmd
1 OFFLINE OFFLINE
ora.gipcd
1 ONLINE ONLINE hp580-5
ora.gpnpd
1 ONLINE ONLINE hp580-5
ora.mdnsd
1 ONLINE ONLINE hp580-5
[grid@hp580-5 ~]$ sqlplus /nolog
SQL*Plus: Release 11.2.0.3.0 Production on Wed Mar 11 13:43:04 2015
Copyright (c) 1982, 2011, Oracle. All rights reserved.
SQL> connect / as sysasm
Connected.
SQL> create diskgroup SYS external redundancy disk '/dev/asm-diskg' attribute 'COMPATIBLE.ASM' = '11.2.0.0.0';
create diskgroup SYS external redundancy disk '/dev/asm-diskg' attribute 'COMPATIBLE.ASM' = '11.2.0.0.0'
*
ERROR at line 1:
ORA-15018: diskgroup cannot be created
ORA-15017: diskgroup "SYS" cannot be mounted
ORA-15003: diskgroup "SYS" already mounted in another lock name space
SQL> create diskgroup SYS external redundancy disk '/dev/asm-diskg' attribute 'COMPATIBLE.ASM' = '11.2.0.0.0';
create diskgroup SYS external redundancy disk '/dev/asm-diskg' attribute 'COMPATIBLE.ASM' = '11.2.0.0.0'
*
ERROR at line 1:
ORA-15018: diskgroup cannot be created
ORA-15033: disk '/dev/asm-diskg' belongs to diskgroup "SYS"
SQL>
需關閉另一個節點
[root@hp580-4 ~]# crsctl stop crs -f
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'hp580-4'
CRS-2673: Attempting to stop 'ora.crsd' on 'hp580-4'
CRS-2790: Starting shutdown of Cluster Ready Services-managed resources on 'hp580-4'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN1.lsnr' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.hp580-4.vip' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.oc4j' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.cvu' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN3.lsnr' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.LISTENER.lsnr' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.SYS.dg' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.orcl.db' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.LISTENER_SCAN2.lsnr' on 'hp580-4'
CRS-2677: Stop of 'ora.hp580-4.vip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.LISTENER_SCAN1.lsnr' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.scan1.vip' on 'hp580-4'
CRS-2677: Stop of 'ora.LISTENER_SCAN3.lsnr' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.scan3.vip' on 'hp580-4'
CRS-2677: Stop of 'ora.LISTENER.lsnr' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.hp580-5.vip' on 'hp580-4'
CRS-2677: Stop of 'ora.LISTENER_SCAN2.lsnr' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.scan2.vip' on 'hp580-4'
CRS-2677: Stop of 'ora.scan1.vip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.scan3.vip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.hp580-5.vip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.scan2.vip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.orcl.db' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.DATA.dg' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.FRA.dg' on 'hp580-4'
CRS-2677: Stop of 'ora.FRA.dg' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.DATA.dg' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.oc4j' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.cvu' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.SYS.dg' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.asm' on 'hp580-4'
CRS-2677: Stop of 'ora.asm' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.ons' on 'hp580-4'
CRS-2677: Stop of 'ora.ons' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.net1.network' on 'hp580-4'
CRS-2677: Stop of 'ora.net1.network' on 'hp580-4' succeeded
CRS-2792: Shutdown of Cluster Ready Services-managed resources on 'hp580-4' has completed
CRS-2677: Stop of 'ora.crsd' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.mdnsd' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.ctssd' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.evmd' on 'hp580-4'
CRS-2673: Attempting to stop 'ora.asm' on 'hp580-4'
CRS-2677: Stop of 'ora.evmd' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.mdnsd' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.asm' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.cluster_interconnect.haip' on 'hp580-4'
CRS-2677: Stop of 'ora.cluster_interconnect.haip' on 'hp580-4' succeeded
CRS-2677: Stop of 'ora.ctssd' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.cssd' on 'hp580-4'
CRS-2677: Stop of 'ora.cssd' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.crf' on 'hp580-4'
CRS-2677: Stop of 'ora.crf' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.gipcd' on 'hp580-4'
CRS-2677: Stop of 'ora.gipcd' on 'hp580-4' succeeded
CRS-2673: Attempting to stop 'ora.gpnpd' on 'hp580-4'
CRS-2677: Stop of 'ora.gpnpd' on 'hp580-4' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'hp580-4' has completed
CRS-4133: Oracle High Availability Services has been stopped.
[root@hp580-4 ~]#
SQL> create diskgroup SYS external redundancy disk '/dev/asm-diskg' attribute 'COMPATIBLE.ASM' = '11.2.0.0.0';
create diskgroup SYS external redundancy disk '/dev/asm-diskg' attribute 'COMPATIBLE.ASM' = '11.2.0.0.0'
*
ERROR at line 1:
ORA-15018: diskgroup cannot be created
ORA-15033: disk '/dev/asm-diskg' belongs to diskgroup "SYS"
SQL> alter diskgroup sys mount;
Diskgroup altered.
SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Real Application Clusters and Automatic Storage Management options
[grid@hp580-5 ~]$ exit
logout
[root@hp580-5 ~]# crsctl status res -t -init
--------------------------------------------------------------------------------
NAME TARGET STATE SERVER STATE_DETAILS
--------------------------------------------------------------------------------
Cluster Resources
--------------------------------------------------------------------------------
ora.asm
1 ONLINE INTERMEDIATE hp580-5 OCR not started
ora.cluster_interconnect.haip
1 ONLINE ONLINE hp580-5
ora.crf
1 OFFLINE OFFLINE
ora.crsd
1 OFFLINE OFFLINE
ora.cssd
1 ONLINE ONLINE hp580-5
ora.cssdmonitor
1 ONLINE ONLINE hp580-5
ora.ctssd
1 ONLINE ONLINE hp580-5 OBSERVER
ora.diskmon
1 OFFLINE OFFLINE
ora.evmd
1 OFFLINE OFFLINE
ora.gipcd
1 ONLINE ONLINE hp580-5
ora.gpnpd
1 ONLINE ONLINE hp580-5
ora.mdnsd
[root@hp580-5 bin]# ./ocrconfig -restore /g01/app/11.2.0/grid/cdata/hp580-cluster/backup_20150310_102026.ocr
[root@hp580-5 bin]# ./crsctl replace votedisk +sys
Successful addition of voting disk 9fb64dd00b684fa5bfa14798ff7d60e9.
Successfully replaced voting disk group with +sys.
CRS-4266: Voting file(s) successfully replaced
[root@hp580-5 bin]# su - grid
[grid@hp580-5 ~]$ sqlplus /nolog
SQL*Plus: Release 11.2.0.3.0 Production on Wed Mar 11 11:27:38 2015
Copyright (c) 1982, 2011, Oracle. All rights reserved.
SQL> connect / as sysdba
Connected.
SQL> create spfile='+sys' from pfile='/tmp/pfile.ora';
File created.
SQL> exit
Disconnected from Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Real Application Clusters and Automatic Storage Management options
[grid@hp580-5 ~]$ exit
logout
[root@hp580-5 bin]# ./crsctl stop crs -f
CRS-2791: Starting shutdown of Oracle High Availability Services-managed resources on 'hp580-5'
CRS-2673: Attempting to stop 'ora.mdnsd' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.ctssd' on 'hp580-5'
CRS-2673: Attempting to stop 'ora.asm' on 'hp580-5'
CRS-2677: Stop of 'ora.mdnsd' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.asm' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.cluster_interconnect.haip' on 'hp580-5'
CRS-2677: Stop of 'ora.ctssd' on 'hp580-5' succeeded
CRS-2677: Stop of 'ora.cluster_interconnect.haip' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.cssd' on 'hp580-5'
CRS-2677: Stop of 'ora.cssd' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.gipcd' on 'hp580-5'
CRS-2677: Stop of 'ora.gipcd' on 'hp580-5' succeeded
CRS-2673: Attempting to stop 'ora.gpnpd' on 'hp580-5'
CRS-2677: Stop of 'ora.gpnpd' on 'hp580-5' succeeded
CRS-2793: Shutdown of Oracle High Availability Services-managed resources on 'hp580-5' has completed
CRS-4133: Oracle High Availability Services has been stopped.
[root@hp580-5 bin]# ./crsctl start crs
CRS-4123: Oracle High Availability Services has been started.
[root@hp580-5 bin]# ps -ef|grep grid
root 9138 1 2 11:29 ? 00:00:02 /g01/app/11.2.0/grid/bin/ohasd.bin reboot
grid 9253 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/oraagent.bin
grid 9265 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/mdnsd.bin
grid 9275 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/gpnpd.bin
root 9286 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/orarootagent.bin
grid 9289 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/gipcd.bin
root 9303 1 6 11:30 ? 00:00:04 /g01/app/11.2.0/grid/bin/osysmond.bin
root 9314 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/cssdmonitor
root 9331 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/cssdagent
grid 9343 1 1 11:30 ? 00:00:01 /g01/app/11.2.0/grid/bin/ocssd.bin
root 9376 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/ologgerd -M -d /g01/app/11.2.0/grid/crf/db/hp580-5
root 9438 1 0 11:30 ? 00:00:00 /g01/app/11.2.0/grid/bin/octssd.bin reboot
grid 9578 1 0 11:31 ? 00:00:00 asm_pmon_+ASM2
grid 9580 1 0 11:31 ? 00:00:00 asm_psp0_+ASM2
grid 9582 1 1 11:31 ? 00:00:00 asm_vktm_+ASM2
grid 9586 1 0 11:31 ? 00:00:00 asm_gen0_+ASM2
grid 9588 1 0 11:31 ? 00:00:00 asm_diag_+ASM2
grid 9590 1 0 11:31 ? 00:00:00 asm_ping_+ASM2
grid 9592 1 1 11:31 ? 00:00:00 asm_dia0_+ASM2
grid 9594 1 0 11:31 ? 00:00:00 asm_lmon_+ASM2
grid 9596 1 0 11:31 ? 00:00:00 asm_lmd0_+ASM2
grid 9598 1 0 11:31 ? 00:00:00 asm_lms0_+ASM2
grid 9602 1 0 11:31 ? 00:00:00 asm_lmhb_+ASM2
grid 9604 1 0 11:31 ? 00:00:00 asm_mman_+ASM2
grid 9606 1 0 11:31 ? 00:00:00 asm_dbw0_+ASM2
grid 9608 1 0 11:31 ? 00:00:00 asm_lgwr_+ASM2
grid 9610 1 0 11:31 ? 00:00:00 asm_ckpt_+ASM2
grid 9612 1 0 11:31 ? 00:00:00 asm_smon_+ASM2
grid 9614 1 1 11:31 ? 00:00:00 asm_rbal_+ASM2
grid 9616 1 0 11:31 ? 00:00:00 asm_gmon_+ASM2
grid 9618 1 0 11:31 ? 00:00:00 asm_mmon_+ASM2
grid 9620 1 0 11:31 ? 00:00:00 asm_mmnl_+ASM2
grid 9622 1 0 11:31 ? 00:00:00 asm_lck0_+ASM2
grid 9624 1 1 11:31 ? 00:00:00 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
root 9636 1 3 11:31 ? 00:00:00 /g01/app/11.2.0/grid/bin/crsd.bin reboot
grid 9637 1 3 11:31 ? 00:00:00 /g01/app/11.2.0/grid/bin/evmd.bin
root 9644 6946 0 11:31 pts/0 00:00:00 grep grid
[root@hp580-5 bin]# ps -ef|grep oracle
grid 9624 1 0 11:31 ? 00:00:00 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 9659 1 2 11:31 ? 00:00:00 oracle+ASM2_ocr (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 9663 1 0 11:31 ? 00:00:00 oracle+ASM2_asmb_+asm2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 9667 1 0 11:31 ? 00:00:00 oracle+ASM2_o000_+asm2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
oracle 9768 1 2 11:31 ? 00:00:00 /g01/app/11.2.0/grid/bin/oraagent.bin
grid 9830 1 0 11:31 ? 00:00:00 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 9833 1 0 11:31 ? 00:00:00 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
grid 9837 1 0 11:31 ? 00:00:00 oracle+ASM2 (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
root 9963 6946 0 11:31 pts/0 00:00:00 grep oracle
[root@hp580-5 bin]#
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/26870952/viewspace-1456009/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- ASM之OCR所在磁碟組損壞後的恢復ASM
- 遷移ocr/votedisk/asm spfile所在磁碟組ASM
- asm磁碟組中的磁碟頭資訊丟失恢復實驗ASM
- Oracle asm磁碟損壞異常恢復OracleASM
- RAC 11G ASM磁碟損壞恢復ASM
- 針對11.2 RAC丟失OCR和Votedisk所在ASM Diskgroup的恢復手段ASM
- 恢復表空間到不同的ASM磁碟組ASM
- RAC共享磁碟物理路徑故障導致OCR、Votedisk所在ASM磁碟組不可訪問的案例分析ASM
- ASM重新命名包含OCR/vote file的磁碟組ASM
- 在ASM磁碟組中刪除一個磁碟ASM
- Oracle 11g RAC ASM VOTEDISK所在磁碟全部丟失重大故障恢復OracleASM
- asm磁碟組建立錯誤,用中轉儲存,重建磁碟組ASM
- 11gR2 基於ASM磁碟組的資料庫恢復ASM資料庫
- votedisk在ASM diskgroup上的存放規律ASM
- asm 磁碟組 增刪磁碟組ASM
- ASM磁碟組限制ASM
- Oracle Database 12c RAC損壞ocr和votedisk恢復實驗OracleDatabase
- Oracle database 11g rac損壞ocr和votedisk恢復實驗OracleDatabase
- ASM磁碟組丟失member kfed修復ASM
- 修改ASM磁碟組的屬性ASM
- ASM磁碟頭資訊損壞和修復(kfed/dd)ASM
- 【資料庫資料恢復】ASM磁碟組掉線的Oracle資料庫資料恢復案例資料庫資料恢復ASMOracle
- 遷移ASM磁碟組ASM
- 遷移OCR和VotingDisk並刪除原ASM磁碟組ASM
- oracle asm 儲存 a磁碟組中的資料檔案 遷移到b磁碟組實施步驟OracleASM
- 在Oracle10g 新增ASM磁碟組OracleASM
- ASM磁碟組更換磁碟的操作方法ASM
- ASM之磁碟組中目錄檔案的管理ASM
- ASM 磁碟組的建立及擴容ASM
- 【ASM】Oracle asm刪除磁碟組注意事項ASMOracle
- ASM中磁碟組許可權問題ASM
- 【資料庫資料恢復】Oracle資料庫ASM磁碟組掉線如何恢復資料?資料庫資料恢復OracleASM
- 【ASM】ASM磁碟頭被重寫,如何修復ASM
- oracle rac 在asm下的備份與恢復OracleASM
- 使用CREATE DISKGROUP語句建立ASM磁碟組,提示找不到相應的ASM磁碟ASM
- ORACLE RAC重建ASM磁碟組OracleASM
- ASM磁碟組修改重建操作ASM
- ASM磁碟組空間不足ASM