互联网服务

ontape恢复报错

1)零级(一级或二级)备份$>ontape -s -L 0$>ontape -s -L 1$>ontape -s -L 22)逻辑日志备份$>ontape -a  3)备份恢复ywjhdbs DBSPACE$>ontape -r -D ywjhdbs   ontape -t [informix@eagle ~]$ onstat -dYour evaluation license will expire on 2014-11...显示全部
1)零级(一级或二级)备份
$>ontape -s -L 0
$>ontape -s -L 1
$>ontape -s -L 2
2)逻辑日志备份
$>ontape -a  
3)备份恢复ywjhdbs DBSPACE
$>ontape -r -D ywjhdbs   ontape -t


[informix@eagle ~]$ onstat -d
Your evaluation license will expire on 2014-11-13 00:00:00

IBM Informix Dynamic Server Version 11.50.FC9TL -- On-Line -- Up 00:01:22 -- 157388 Kbytes

Dbspaces
address          number   flags      fchunk   nchunks  pgsize   flags    owner    name
4b687028         1        0x60001    1        1        2048     N  B     informix rootdbs
4c637de0         2        0x60001    2        1        2048     N  B     informix phydbs
4c94dcf0         3        0x60001    3        1        2048     N  B     informix logdbs
4c94de88         4        0x60001    4        1        2048     N  B     informix tempdbs01
4cc9b498         5        0x60001    5        1        2048     N  B     informix tempdbs02
4cb3fc20         6        0x60001    6        1        2048     N  B     informix userdbs
4c9ba6a0         7        0x60001    7        1        2048     N  B     informix ywjhdbs
7 active, 2047 maximum

Chunks
address          chunk/dbs     offset     size       free       bpages     flags pathname
4b6871c0         1      1      0          100000     38311                 PO-B- /opt/IBM/informix/dbspaces/rootdbs
4cd29d60         2      2      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/phydbs
4c810580         3      3      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/logdbs
4cb96c20         4      4      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/tempdbs01
4cc9b630         5      5      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/tempdbs02
4cb3fdb8         6      6      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/userdbs
4c9ba838         7      7      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/ywjhdbs
7 active, 32766 maximum

NOTE: The values in the "size" and "free" columns for DBspace chunks are
      displayed in terms of "pgsize" of the DBspace to which they belong.

Expanded chunk capacity mode: always



[informix@eagle archive0]$ ontape -s -L 0
Your evaluation license will expire on 2014-11-13 00:00:00
10 percent done.
100 percent done.
File created: /opt/IBM/informix/archive0/eagle.com_0_L0

Please label this tape as number 1 in the arc tape sequence.
This tape contains the following logical logs:

2

Program over.
[informix@eagle archive0]$ ontape -s -L 1
Your evaluation license will expire on 2014-11-13 00:00:00
100 percent done.
File created: /opt/IBM/informix/archive0/eagle.com_0_L1

Please label this tape as number 1 in the arc tape sequence.
This tape contains the following logical logs:

2

Program over.
[informix@eagle archive0]$ ontape -s -L 2
Your evaluation license will expire on 2014-11-13 00:00:00
100 percent done.
File created: /opt/IBM/informix/archive0/eagle.com_0_L2

Please label this tape as number 1 in the arc tape sequence.
This tape contains the following logical logs:

2

Program over.
[informix@eagle archive0]$ ls  -altrh
total 34M
drwxr-xr-x 31 informix informix 4.0K Aug 28 00:59 ..
-rw-rw----  1 informix informix  17M Aug 28 09:57 eagle.com_0_L0
-rw-rw----  1 informix informix 8.1M Aug 28 09:57 eagle.com_0_L1
-rw-rw----  1 informix informix 8.1M Aug 28 09:57 eagle.com_0_L2
drwxrwxr-x  2 informix informix 4.0K Aug 28 09:57 .
[informix@eagle archive0]$ ontape -a
Your evaluation license will expire on 2014-11-13 00:00:00

Performing automatic backup of logical logs.

File created: /opt/IBM/informix/archive0/eagle.com_0_Log0000000001
Do you want to back up the current logical log? (y/n) y
File created: /opt/IBM/informix/archive0/eagle.com_0_Log0000000002

Program over.
[informix@eagle archive0]$ ls -altrh
total 51M
drwxr-xr-x 31 informix informix 4.0K Aug 28 00:59 ..
-rw-rw----  1 informix informix  17M Aug 28 09:57 eagle.com_0_L0
-rw-rw----  1 informix informix 8.1M Aug 28 09:57 eagle.com_0_L1
-rw-rw----  1 informix informix 8.1M Aug 28 09:57 eagle.com_0_L2
-rw-rw----  1 informix informix 9.9M Aug 28 09:57 eagle.com_0_Log0000000001
-rw-rw----  1 informix informix 7.8M Aug 28 09:57 eagle.com_0_Log0000000002
drwxrwxr-x  2 informix informix 4.0K Aug 28 09:57 .
[informix@eagle archive0]$



[informix@eagle dbspaces]$ onstat -d
Your evaluation license will expire on 2014-11-13 00:00:00

IBM Informix Dynamic Server Version 11.50.FC9TL -- On-Line (CKPT INP) -- Up 00:00:39 -- 149196 Kbytes
Blocked:OVERRIDE_DOWN_SPACE

Dbspaces
address          number   flags      fchunk   nchunks  pgsize   flags    owner    name
4b687028         1        0x40001    1        1        2048     N  B     informix rootdbs
4b6875e0         2        0x40001    2        1        2048     N  B     informix phydbs
4b687778         3        0x40001    3        1        2048     N  B     informix logdbs
4b687910         4        0x40001    4        1        2048     N  B     informix tempdbs01
4b687aa8         5        0x40001    5        1        2048     N  B     informix tempdbs02
4b687c40         6        0x40001    6        1        2048     N  B     informix userdbs
4b687dd8         7        0x40005    7        1        2048     ND B     informix ywjhdbs
7 active, 2047 maximum

Chunks
address          chunk/dbs     offset     size       free       bpages     flags pathname
4b6871c0         1      1      0          100000     38303                 PO-B- /opt/IBM/informix/dbspaces/rootdbs
4c4ad028         2      2      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/phydbs
4c4ad218         3      3      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/logdbs
4c4ad408         4      4      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/tempdbs01
4c4ad5f8         5      5      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/tempdbs02
4c4ad7e8         6      6      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/userdbs
4c4ad9d8         7      7      0          500        0                     PD-B- /opt/IBM/informix/dbspaces/ywjhdbs
7 active, 32766 maximum

NOTE: The values in the "size" and "free" columns for DBspace chunks are
      displayed in terms of "pgsize" of the DBspace to which they belong.

Expanded chunk capacity mode: always


[informix@eagle tmp]$ ontape -r -D ywjhdbs
Your evaluation license will expire on 2014-11-13 00:00:00
Restore will use level 0 archive file /opt/IBM/informix/archive0/eagle.com_0_L0. Press Return to continue ...


Archive Tape Information

Tape type:      Archive Backup Tape
Online version: IBM Informix Dynamic Server Version 11.50.FC9TL
Archive date:   Thu Aug 28 09:57:25 2014
User id:        informix
Terminal id:    /dev/pts/0
Archive level:  0
Tape device:    /opt/IBM/informix/archive0/
Tape blocksize (in k): 32
Tape size (in k): system defined for directory
Tape number in series: 1
Continue restore? (y/n)y

Spaces to restore:1 [ywjhdbs                                                                                                                         ]
Restore a level 1 archive (y/n) y
Ready for level 1 tape
Restore will use level 1 archive file /opt/IBM/informix/archive0/eagle.com_0_L1. Press Return to continue ...


Archive Tape Information

Tape type:      Archive Backup Tape
Online version: IBM Informix Dynamic Server Version 11.50.FC9TL
Archive date:   Thu Aug 28 09:57:33 2014
User id:        informix
Terminal id:    /dev/pts/0
Archive level:  1
Tape device:    /opt/IBM/informix/archive0/
Tape blocksize (in k): 32
Tape size (in k): system defined for directory
Tape number in series: 1
Restore a level 2 archive (y/n) y
Ready for level 2 tape
Restore will use level 2 archive file /opt/IBM/informix/archive0/eagle.com_0_L2. Press Return to continue ...


Archive Tape Information

Tape type:      Archive Backup Tape
Online version: IBM Informix Dynamic Server Version 11.50.FC9TL
Archive date:   Thu Aug 28 09:57:39 2014
User id:        informix
Terminal id:    /dev/pts/0
Archive level:  2
Tape device:    /opt/IBM/informix/archive0/
Tape blocksize (in k): 32
Tape size (in k): system defined for directory
Tape number in series: 1
Do you want to restore log tapes? (y/n)y

Roll forward should start with log number 2
Restore will use log backup file /opt/IBM/informix/archive0/eagle.com_0_Log0000000002. Press Return to continue ...
后面没有反映


现用onstat -d 看表空间不是离线状态,但关库再起库就起不来了


[informix@eagle dbspaces]$ onstat -d
Your evaluation license will expire on 2014-11-13 00:00:00

IBM Informix Dynamic Server Version 11.50.FC9TL -- On-Line (CKPT INP) -- Up 00:04:08 -- 149196 Kbytes
Blocked:OVERRIDE_DOWN_SPACE

Dbspaces
address          number   flags      fchunk   nchunks  pgsize   flags    owner    name
4b687028         1        0x40001    1        1        2048     N  B     informix rootdbs
4b6875e0         2        0x40001    2        1        2048     N  B     informix phydbs
4b687778         3        0x40001    3        1        2048     N  B     informix logdbs
4b687910         4        0x40001    4        1        2048     N  B     informix tempdbs01
4b687aa8         5        0x40001    5        1        2048     N  B     informix tempdbs02
4b687c40         6        0x40001    6        1        2048     N  B     informix userdbs
4b687dd8         7        0x40801    7        1        2048     NL B     informix ywjhdbs
7 active, 2047 maximum

Chunks
address          chunk/dbs     offset     size       free       bpages     flags pathname
4b6871c0         1      1      0          100000     38303                 PO-B- /opt/IBM/informix/dbspaces/rootdbs
4c4ad028         2      2      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/phydbs
4c4ad218         3      3      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/logdbs
4c4ad408         4      4      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/tempdbs01
4c4ad5f8         5      5      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/tempdbs02
4c4ad7e8         6      6      0          500        447                   PO-B- /opt/IBM/informix/dbspaces/userdbs
4c4ad9d8         7      7      0          500        447                   PI-B- /opt/IBM/informix/dbspaces/ywjhdbs
7 active, 32766 maximum

NOTE: The values in the "size" and "free" columns for DBspace chunks are
      displayed in terms of "pgsize" of the DBspace to which they belong.

Expanded chunk capacity mode: always收起
参与2

查看其它 1 个回答annla的回答

annlaannla软件开发工程师ChiMei Hospital
程序都很正常, 最後 ywjhdbs 狀態變成 PI-B- 有點奇怪
你要不要試試~
Restore L0 + L1 + LL  (跳過 L2)
或者
Restore L0 + LL  (跳過 L1 和 L2)
IT其它 · 2014-08-28
浏览843

回答者

annla
软件开发工程师ChiMei Hospital

annla 最近回答过的问题

回答状态

  • 发布时间:2014-08-28
  • 关注会员:0 人
  • 回答浏览:843
  • X社区推广