just do it
分类: 系统运维
2012-10-22 19:56:12
ts-db1# df -h
文件系统 大小 用了 可用 容量 挂接在
/dev/md/dsk/d0 8.7G 3.5G 5.0G 42% /
/proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
fd 0K 0K 0K 0% /dev/fd
swap 13G 40K 13G 1% /var/run
dmpfs 13G 0K 13G 0% /dev/vx/dmp
dmpfs 13G 0K 13G 0% /dev/vx/rdmp
swap 13G 8K 13G 1% /tmp
df: 不能 statvfs /oraredo: I/O错误
/dev/dsk/c1t10d0s5 3.0G 912M 2.0G 32% /patrol
df: 不能 statvfs /orahome: I/O错误
ts-db1# vxdctl enable
ts-db1# vxreattach
vxreattach: 命令没有找到
ts-db1# vxdisk list
DEVICE TYPE DISK GROUP STATUS
Disk_4 auto:sliced oradg02 oradg online
Disk_5 auto:sliced - - online
Disk_6 auto:sliced - - online
Disk_7 auto:sliced oradg01 oradg online
Disk_9 auto:sliced - - online
Disk_11 auto:sliced - - online
c1t0d0s2 auto:none - - online invalid
c1t1d0s2 auto:none - - online invalid
c1t10d0s2 auto:none - - online invalid
c1t11d0s2 auto:none - - online invalid
- - oradg03 oradg failed was:Disk_6
- - oradg04 oradg failed was:Disk_5
- - oradg05 oradg failed was:Disk_9
- - oradg06 oradg failed was:Disk_11
ts-db1# cd /etc/vx
ts-db1# cd bin
ts-db1# ls
egettxt* vxcxcld* vxparms.SunOS_5.9*
strtovoff* vxdarestore* vxpartadd*
ugettxt* vxdevlist* vxpartinfo*
vxa5kchk* vxdevpromnm* vxpartrm*
vxapslice* vxdisksetup* vxpartrmall*
vxbadcxcld* vxdiskunsetup* vxprtvtoc*
vxbaddxcld* vxdxcld* vxr5check*
vxbootsetup* vxedvtoc* vxr5vrfy*
vxcached* vxedvtoc.SunOS_5.10* vxreattach*
vxcap-part* vxedvtoc.SunOS_5.8* vxrelocd*
vxcap-vol* vxedvtoc.SunOS_5.9* vxresize*
vxcdsconvert* vxeeprom* vxroot*
vxcheckda* vxencap* vxrootmir*
vxchksundev* vxevac* vxslicer*
vxckdiskrm* vxgetrootdisk* vxspare*
vxclustadm* vxldiskcmd* vxsparecheck*
vxclustipc* vxmirror* vxsplitlines*
vxcntrllist* vxmksdpart* vxswapctl*
vxconfigbackup* vxnewdmname* vxtaginfo*
vxconfigbackupd* vxparms* vxunreloc*
vxconfigrestore* vxparms.SunOS_5.10* vxunroot*
vxconvarrayinfo* vxparms.SunOS_5.8*
ts-db1# pwd
/usr/lib/vxvm/bin
ts-db1# /usr/lib/vxvm/bin/vxreattach
ts-db1# vxdisk list
DEVICE TYPE DISK GROUP STATUS
Disk_4 auto:sliced oradg02 oradg online
Disk_5 auto:sliced oradg04 oradg online
Disk_6 auto:sliced oradg03 oradg online
Disk_7 auto:sliced oradg01 oradg online
Disk_9 auto:sliced oradg05 oradg online
Disk_11 auto:sliced oradg06 oradg online
c1t0d0s2 auto:none - - online invalid
c1t1d0s2 auto:none - - online invalid
c1t10d0s2 auto:none - - online invalid
c1t11d0s2 auto:none - - online invalid
ts-db1# vxprint -ht
Disk group: oradg
DG NAME NCONFIG NLOG MINORS GROUP-ID
ST NAME STATE DM_CNT SPARE_CNT APPVOL_CNT
DM NAME DEVICE TYPE PRIVLEN PUBLEN STATE
RV NAME RLINK_CNT KSTATE STATE PRIMARY DATAVOLS SRL
RL NAME RVG KSTATE STATE REM_HOST REM_DG REM_RLNK
CO NAME CACHEVOL KSTATE STATE
VT NAME NVOLUME KSTATE STATE
V NAME RVG/VSET/CO KSTATE STATE LENGTH READPOL PREFPLEX UTYPE
PL NAME VOLUME KSTATE STATE LENGTH LAYOUT NCOL/WID MODE
SD NAME PLEX DISK DISKOFFS LENGTH [COL/]OFF DEVICE MODE
SV NAME PLEX VOLNAME NVOLLAYR LENGTH [COL/]OFF AM/NM MODE
SC NAME PLEX CACHE DISKOFFS LENGTH [COL/]OFF DEVICE MODE
DC NAME PARENTVOL LOGVOL
SP NAME SNAPVOL DCO
dg oradg default default 2000 1229748695.17.ts-db1
dm oradg01 Disk_7 auto 32511 1887305728 -
dm oradg02 Disk_4 auto 27583 1824383040 -
dm oradg03 Disk_6 auto 3839 7323648 -
dm oradg04 Disk_5 auto 32511 1887305728 -
dm oradg05 Disk_9 auto 32511 1402863616 -
dm oradg06 Disk_11 auto 32511 1887305728 -
v archivelog - DISABLED ACTIVE 1885339648 SELECT - fsgen
pl archivelog-01 archivelog DISABLED RECOVER 1885339648 CONCAT - RW
sd oradg04-01 archivelog-01 oradg04 0 1885339648 0 Disk_5 ENA
v orahomevol - DISABLED ACTIVE 6994001920 SELECT - fsgen
pl orahomevol-01 orahomevol DISABLED RECOVER 6994001920 CONCAT - RW
sd oradg01-01 orahomevol-01 oradg01 0 1885339648 0 Disk_7 ENA
sd oradg02-01 orahomevol-01 oradg02 0 1822425088 1885339648 Disk_4 ENA
sd oradg05-01 orahomevol-01 oradg05 0 1400897536 3707764736 Disk_9 ENA
sd oradg06-01 orahomevol-01 oradg06 0 1885339648 5108662272 Disk_11 ENA
v oraredovol - DISABLED ACTIVE 7311360 SELECT - fsgen
pl oraredovol-01 oraredovol DISABLED RECOVER 7311360 CONCAT - RW
sd oradg03-01 oraredovol-01 oradg03 0 7311360 0 Disk_6 ENA
ts-db1# vxvol -g oradg -f startall
ts-db1# vxprint -ht
Disk group: oradg
DG NAME NCONFIG NLOG MINORS GROUP-ID
ST NAME STATE DM_CNT SPARE_CNT APPVOL_CNT
DM NAME DEVICE TYPE PRIVLEN PUBLEN STATE
RV NAME RLINK_CNT KSTATE STATE PRIMARY DATAVOLS SRL
RL NAME RVG KSTATE STATE REM_HOST REM_DG REM_RLNK
CO NAME CACHEVOL KSTATE STATE
VT NAME NVOLUME KSTATE STATE
V NAME RVG/VSET/CO KSTATE STATE LENGTH READPOL PREFPLEX UTYPE
PL NAME VOLUME KSTATE STATE LENGTH LAYOUT NCOL/WID MODE
SD NAME PLEX DISK DISKOFFS LENGTH [COL/]OFF DEVICE MODE
SV NAME PLEX VOLNAME NVOLLAYR LENGTH [COL/]OFF AM/NM MODE
SC NAME PLEX CACHE DISKOFFS LENGTH [COL/]OFF DEVICE MODE
DC NAME PARENTVOL LOGVOL
SP NAME SNAPVOL DCO
dg oradg default default 2000 1229748695.17.ts-db1
dm oradg01 Disk_7 auto 32511 1887305728 -
dm oradg02 Disk_4 auto 27583 1824383040 -
dm oradg03 Disk_6 auto 3839 7323648 -
dm oradg04 Disk_5 auto 32511 1887305728 -
dm oradg05 Disk_9 auto 32511 1402863616 -
dm oradg06 Disk_11 auto 32511 1887305728 -
v archivelog - ENABLED ACTIVE 1885339648 SELECT - fsgen
pl archivelog-01 archivelog ENABLED ACTIVE 1885339648 CONCAT - RW
sd oradg04-01 archivelog-01 oradg04 0 1885339648 0 Disk_5 ENA
v orahomevol - ENABLED ACTIVE 6994001920 SELECT - fsgen
pl orahomevol-01 orahomevol ENABLED ACTIVE 6994001920 CONCAT - RW
sd oradg01-01 orahomevol-01 oradg01 0 1885339648 0 Disk_7 ENA
sd oradg02-01 orahomevol-01 oradg02 0 1822425088 1885339648 Disk_4 ENA
sd oradg05-01 orahomevol-01 oradg05 0 1400897536 3707764736 Disk_9 ENA
sd oradg06-01 orahomevol-01 oradg06 0 1885339648 5108662272 Disk_11 ENA
v oraredovol - ENABLED ACTIVE 7311360 SELECT - fsgen
pl oraredovol-01 oraredovol ENABLED ACTIVE 7311360 CONCAT - RW
sd oradg03-01 oraredovol-01 oradg03 0 7311360 0 Disk_6 ENA
ts-db1# mount /archivelog
UX:vxfs mount: ERROR: V-3-21268: /dev/vx/dsk/oradg/archivelog is corrupted. needs checking
ts-db1# fsck -F vxfs /dev/vx/dsk/oradg/archivelog
log replay in progress
replay complete - marking super-block as CLEAN
ts-db1# mount -F vxfs /dev/vx/dsk/oradg/archivelog /archivelog
ts-db1# df -h
文件系统 大小 用了 可用 容量 挂接在
/dev/md/dsk/d0 8.7G 3.5G 5.0G 42% /
/proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
fd 0K 0K 0K 0% /dev/fd
swap 13G 40K 13G 1% /var/run
dmpfs 13G 0K 13G 0% /dev/vx/dmp
dmpfs 13G 0K 13G 0% /dev/vx/rdmp
swap 13G 8K 13G 1% /tmp
df: 不能 statvfs /oraredo: I/O错误
/dev/dsk/c1t10d0s5 3.0G 912M 2.0G 32% /patrol
df: 不能 statvfs /orahome: I/O错误
/dev/vx/dsk/oradg/archivelog
899G 572G 307G 66% /archivelog
ts-db1# umount /oraredo
ts-db1# mount /oraredo
UX:vxfs mount: ERROR: V-3-21268: /dev/vx/dsk/oradg/oraredovol is corrupted. needs checking
ts-db1# fsck -F vxfs /dev/vx/dsk/oradg/oraredovol
log replay in progress
replay complete - marking super-block as CLEAN
ts-db1# mount -F vxfs /dev/vx/dsk/oradg/oraredovol /oraredo
ts-db1# umount /orahome
UX:vxfs umount: ERROR: V-3-21705: /orahome cannot unmount : 设备忙
ts-db1# umount -f /orahome
ts-db1# mount /orahome
UX:vxfs mount: ERROR: V-3-21268: /dev/vx/dsk/oradg/orahomevol is corrupted. needs checking
ts-db1# fsck -F vxfs /dev/vx/dsk/oradg/orahomevol
UX:vxfs fsck: WARNING: V-3-20837: file system had I/O error(s) on user data.
log replay in progress
replay complete - marking super-block as CLEAN
ts-db1# mount -F vxfs /dev/vx/dsk/oradg/orahomevol /orahome
ts-db1# df -h
文件系统 大小 用了 可用 容量 挂接在
/dev/md/dsk/d0 8.7G 3.5G 5.0G 42% /
/proc 0K 0K 0K 0% /proc
mnttab 0K 0K 0K 0% /etc/mnttab
fd 0K 0K 0K 0% /dev/fd
swap 13G 40K 13G 1% /var/run
dmpfs 13G 0K 13G 0% /dev/vx/dmp
dmpfs 13G 0K 13G 0% /dev/vx/rdmp
swap 13G 8K 13G 1% /tmp
/dev/dsk/c1t10d0s5 3.0G 912M 2.0G 32% /patrol
/dev/vx/dsk/oradg/archivelog
899G 572G 307G 66% /archivelog
/dev/vx/dsk/oradg/oraredovol
3.5G 122M 3.2G 4% /oraredo
/dev/vx/dsk/oradg/orahomevol
3.3T 2.3T 940G 72% /orahome
ts-db1# su - oracle
Sun Microsystems Inc. SunOS 5.9 Generic May 2002
You have new mail.
$ lsnrctl stat
LSNRCTL for Solaris: Version 9.2.0.6.0 - Production on 22-10月-2012 18:08:08
Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.210.63)(PORT=1521)))
TNS-12541: TNS:无监听器
TNS-12560: TNS: 协议适配器错误
TNS-00511: 无监听器
Solaris Error: 146: Connection refused
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.200.15)(PORT=1521)))
TNS-12541: TNS:无监听器
TNS-12560: TNS: 协议适配器错误
TNS-00511: 无监听器
Solaris Error: 146: Connection refused
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC)))
TNS-12541: TNS:无监听器
TNS-12560: TNS: 协议适配器错误
TNS-00511: 无监听器
Solaris Error: 146: Connection refused
$ lsnrctl start
LSNRCTL for Solaris: Version 9.2.0.6.0 - Production on 22-10月-2012 18:08:15
Copyright (c) 1991, 2002, Oracle Corporation. All rights reserved.
启动/orahome/oracle/product/9.2.0/bin/tnslsnr:请稍候...
TNSLSNR for Solaris: Version 9.2.0.6.0 - Production
系统参数文件为/orahome/oracle/product/9.2.0/network/admin/listener.ora
写入/orahome/oracle/product/9.2.0/network/log/listener.log的日志信息
监听:(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.210.63)(PORT=1521)))
监听:(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.200.15)(PORT=1521)))
监听:(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.210.63)(PORT=1521)))
LISTENER 的 STATUS
------------------------
别名 LISTENER
版本 TNSLSNR for Solaris: Version 9.2.0.6.0 - Production
启动日期 22-10月-2012 18:08:15
正常运行时间 0 天 0 小时 0 分 0 秒
跟踪级别 off
安全性 OFF
SNMP OFF
监听器参数文件 /orahome/oracle/product/9.2.0/network/admin/listener.ora
监听器日志文件 /orahome/oracle/product/9.2.0/network/log/listener.log
监听端点概要...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.210.63)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.200.15)(PORT=1521)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC)))
服务摘要..
服务 "PL***tProc" 包含 1 个例程。
例程 "PL***tProc", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
服务 "bims" 包含 1 个例程。
例程 "bims", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
命令执行成功
$ sqlplus /nolog
SQL*Plus: Release 9.2.0.6.0 - Production on 星期一 10月 22 18:08:29 2012
Copyright (c) 1982, 2002, Oracle Corporation. All rights reserved.
SQL> conn /as sysdba
已连接到空闲例程。
SQL> start nomount
SP2-0310: 无法打开文件"nomount.sql"
SQL> startup nomount
ORACLE 例程已经启动。
Total System Global Area 4448559432 bytes
Fixed Size 737608 bytes
Variable Size 1224736768 bytes
Database Buffers 3221225472 bytes
Redo Buffers 1859584 bytes
SQL> alter database mount standby database;
数据库已更改。
SQL> ALTER DATABASE recover managed standby database disconnect from session;
数据库已更改。
SQL> exit
从Oracle9i Enterprise Edition Release 9.2.0.6.0 - 64bit Production
With the Partitioning, Oracle Label Security, OLAP and Oracle Data Mining options
JServer Release 9.2.0.6.0 - Production中断开
$ cd admin/bims/bdump
$ tail -f alert*.log
Standby Database mounted.
Completed: alter database mount standby database
Mon Oct 22 18:11:05 2012
ALTER DATABASE recover managed standby database disconnect from session
Attempt to start background Managed Standby Recovery process
MRP0 started with pid=15
MRP0: Background Managed Standby Recovery process started
Media Recovery Log /archivelog/1_548770.arc
Mon Oct 22 18:11:12 2012
Completed: ALTER DATABASE recover managed standby database di