Rodrigo E. De León Plicet
2009-May-31 09:32 UTC
[zfs-discuss] ZFS rollback, ORA-00322: log 1 of thread 1 is not current copy (???)
Hi. Using ZFS-FUSE. $SUBJECT happened 3 out of 5 times while testing, just wanna know if someone has seen such scenario before. Steps: ------------------------------------------------------------ root at localhost:/# uname -a Linux localhost 2.6.24-24-generic #1 SMP Wed Apr 15 15:54:25 UTC 2009 i686 GNU/Linux root at localhost:/# zpool upgrade -v This system is currently running ZFS pool version 13. The following versions are supported: VER DESCRIPTION --- -------------------------------------------------------- 1 Initial ZFS version 2 Ditto blocks (replicated metadata) 3 Hot spares and double parity RAID-Z 4 zpool history 5 Compression using the gzip algorithm 6 bootfs pool property 7 Separate intent log devices 8 Delegated administration 9 refquota and refreservation properties 10 Cache devices 11 Improved scrub performance 12 Snapshot properties 13 snapused property For more information on a particular version, including supported releases, see: http://www.opensolaris.org/os/community/zfs/version/N Where ''N'' is the version number. root at localhost:/# mv u01 u01.bak root at localhost:/# for i in 1 2 3 4; do dd if=/dev/zero of=disk$i bs=1024k count=2048; done root at localhost:/# du -k disk* 2099204 disk1 2099204 disk2 2099204 disk3 2099204 disk4 root at localhost:/# zpool create coolpool /disk1 /disk2 /disk3 /disk4 root at localhost:/# zpool status pool: coolpool state: ONLINE scrub: none requested config: NAME STATE READ WRITE CKSUM coolpool ONLINE 0 0 0 /disk1 ONLINE 0 0 0 /disk2 ONLINE 0 0 0 /disk3 ONLINE 0 0 0 /disk4 ONLINE 0 0 0 errors: No known data errors root at localhost:/# zfs create -o mountpoint=/u01 coolpool/u01 root at localhost:/# cp -av /u01.bak/* /u01/ root at localhost:/# zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT coolpool 7.94G 6.43G 1.51G 80% ONLINE - root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.43G 1.39G 18K /coolpool coolpool/u01 6.43G 1.39G 6.43G /u01 root at localhost:/# ls -l /u01/oradata/orcl/ total 2339863 -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control01.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control02.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control03.ctl -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo01.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:27 redo02.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo03.rdo -rw-r----- 1 oracle oinstall 473964544 2009-05-31 03:27 sysaux01.dbf -rw-r----- 1 oracle oinstall 159391744 2009-05-31 03:27 sysaux02.dbf -rw-r----- 1 oracle oinstall 602939392 2009-05-31 03:27 system01.dbf -rw-r----- 1 oracle oinstall 214966272 2009-05-31 03:27 system02.dbf -rw-r----- 1 oracle oinstall 125837312 2009-05-31 03:26 temp01.dbf -rw-r----- 1 oracle oinstall 601890816 2009-05-31 03:27 undotbs01.dbf -rw-r----- 1 oracle oinstall 105914368 2009-05-31 03:27 users01.dbf root at localhost:/# zfs snapshot coolpool/u01 at ok root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.43G 1.39G 18K /coolpool coolpool/u01 6.43G 1.39G 6.43G /u01 coolpool/u01 at ok 0 - 6.43G - oracle at localhost:/> sqlplus / as sysdba SQL*Plus: Release 11.1.0.6.0 - Production on Sun May 31 03:38:02 2009 Copyright (c) 1982, 2007, Oracle. All rights reserved. Connected to an idle instance. SQL> startup ORACLE instance started. Total System Global Area 418484224 bytes Fixed Size 1300324 bytes Variable Size 218106012 bytes Database Buffers 192937984 bytes Redo Buffers 6139904 bytes Database mounted. Database opened. SQL> CREATE TABLE FOO(BAR NUMBER); Table created. SQL> INSERT INTO FOO VALUES (1); 1 row created. SQL> COMMIT; Commit complete. SQL> shutdown immediate Database closed. Database dismounted. ORACLE instance shut down. SQL> exit Disconnected from Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production With the Partitioning, OLAP, Data Mining and Real Application Testing options root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.44G 1.37G 18K /coolpool coolpool/u01 6.44G 1.37G 6.43G /u01 coolpool/u01 at ok 12.4M - 6.43G - root at localhost:/# zfs rollback coolpool/u01 at ok root at localhost:/# ls -l /u01/oradata/orcl/ total 2339863 -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control01.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control02.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control03.ctl -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo01.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:27 redo02.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo03.rdo -rw-r----- 1 oracle oinstall 473964544 2009-05-31 03:27 sysaux01.dbf -rw-r----- 1 oracle oinstall 159391744 2009-05-31 03:27 sysaux02.dbf -rw-r----- 1 oracle oinstall 602939392 2009-05-31 03:27 system01.dbf -rw-r----- 1 oracle oinstall 214966272 2009-05-31 03:27 system02.dbf -rw-r----- 1 oracle oinstall 125837312 2009-05-31 03:26 temp01.dbf -rw-r----- 1 oracle oinstall 601890816 2009-05-31 03:27 undotbs01.dbf -rw-r----- 1 oracle oinstall 105914368 2009-05-31 03:27 users01.dbf root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.43G 1.39G 18K /coolpool coolpool/u01 6.43G 1.39G 6.43G /u01 coolpool/u01 at ok 0 - 6.43G - oracle at localhost:/> sqlplus / as sysdba SQL*Plus: Release 11.1.0.6.0 - Production on Sun May 31 03:45:43 2009 Copyright (c) 1982, 2007, Oracle. All rights reserved. Connected to an idle instance. SQL> startup ORACLE instance started. Total System Global Area 418484224 bytes Fixed Size 1300324 bytes Variable Size 218106012 bytes Database Buffers 192937984 bytes Redo Buffers 6139904 bytes Database mounted. ORA-00322: log 1 of thread 1 is not current copy ORA-00312: online log 1 thread 1: ''/u01/oradata/orcl/redo01.rdo'' ------------------------------------------------------------ Why? Thanks for your time. Regards. -------------- next part -------------- root at localhost:/# uname -a Linux localhost 2.6.24-24-generic #1 SMP Wed Apr 15 15:54:25 UTC 2009 i686 GNU/Linux root at localhost:/# zpool upgrade -v This system is currently running ZFS pool version 13. The following versions are supported: VER DESCRIPTION --- -------------------------------------------------------- 1 Initial ZFS version 2 Ditto blocks (replicated metadata) 3 Hot spares and double parity RAID-Z 4 zpool history 5 Compression using the gzip algorithm 6 bootfs pool property 7 Separate intent log devices 8 Delegated administration 9 refquota and refreservation properties 10 Cache devices 11 Improved scrub performance 12 Snapshot properties 13 snapused property For more information on a particular version, including supported releases, see: http://www.opensolaris.org/os/community/zfs/version/N Where ''N'' is the version number. root at localhost:/# mv u01 u01.bak root at localhost:/# for i in 1 2 3 4; do dd if=/dev/zero of=disk$i bs=1024k count=2048; done root at localhost:/# du -k disk* 2099204 disk1 2099204 disk2 2099204 disk3 2099204 disk4 root at localhost:/# zpool create coolpool /disk1 /disk2 /disk3 /disk4 root at localhost:/# zpool status pool: coolpool state: ONLINE scrub: none requested config: NAME STATE READ WRITE CKSUM coolpool ONLINE 0 0 0 /disk1 ONLINE 0 0 0 /disk2 ONLINE 0 0 0 /disk3 ONLINE 0 0 0 /disk4 ONLINE 0 0 0 errors: No known data errors root at localhost:/# zfs create -o mountpoint=/u01 coolpool/u01 root at localhost:/# cp -av /u01.bak/* /u01/ root at localhost:/# zpool list NAME SIZE USED AVAIL CAP HEALTH ALTROOT coolpool 7.94G 6.43G 1.51G 80% ONLINE - root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.43G 1.39G 18K /coolpool coolpool/u01 6.43G 1.39G 6.43G /u01 root at localhost:/# ls -l /u01/oradata/orcl/ total 2339863 -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control01.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control02.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control03.ctl -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo01.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:27 redo02.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo03.rdo -rw-r----- 1 oracle oinstall 473964544 2009-05-31 03:27 sysaux01.dbf -rw-r----- 1 oracle oinstall 159391744 2009-05-31 03:27 sysaux02.dbf -rw-r----- 1 oracle oinstall 602939392 2009-05-31 03:27 system01.dbf -rw-r----- 1 oracle oinstall 214966272 2009-05-31 03:27 system02.dbf -rw-r----- 1 oracle oinstall 125837312 2009-05-31 03:26 temp01.dbf -rw-r----- 1 oracle oinstall 601890816 2009-05-31 03:27 undotbs01.dbf -rw-r----- 1 oracle oinstall 105914368 2009-05-31 03:27 users01.dbf root at localhost:/# zfs snapshot coolpool/u01 at ok root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.43G 1.39G 18K /coolpool coolpool/u01 6.43G 1.39G 6.43G /u01 coolpool/u01 at ok 0 - 6.43G - oracle at localhost:/> sqlplus / as sysdba SQL*Plus: Release 11.1.0.6.0 - Production on Sun May 31 03:38:02 2009 Copyright (c) 1982, 2007, Oracle. All rights reserved. Connected to an idle instance. SQL> startup ORACLE instance started. Total System Global Area 418484224 bytes Fixed Size 1300324 bytes Variable Size 218106012 bytes Database Buffers 192937984 bytes Redo Buffers 6139904 bytes Database mounted. Database opened. SQL> CREATE TABLE FOO(BAR NUMBER); Table created. SQL> INSERT INTO FOO VALUES (1); 1 row created. SQL> COMMIT; Commit complete. SQL> shutdown immediate Database closed. Database dismounted. ORACLE instance shut down. SQL> exit Disconnected from Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production With the Partitioning, OLAP, Data Mining and Real Application Testing options root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.44G 1.37G 18K /coolpool coolpool/u01 6.44G 1.37G 6.43G /u01 coolpool/u01 at ok 12.4M - 6.43G - root at localhost:/# zfs rollback coolpool/u01 at ok root at localhost:/# ls -l /u01/oradata/orcl/ total 2339863 -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control01.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control02.ctl -rw-r----- 1 oracle oinstall 9781248 2009-05-31 03:27 control03.ctl -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo01.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:27 redo02.rdo -rw-r----- 1 oracle oinstall 26214912 2009-05-31 03:26 redo03.rdo -rw-r----- 1 oracle oinstall 473964544 2009-05-31 03:27 sysaux01.dbf -rw-r----- 1 oracle oinstall 159391744 2009-05-31 03:27 sysaux02.dbf -rw-r----- 1 oracle oinstall 602939392 2009-05-31 03:27 system01.dbf -rw-r----- 1 oracle oinstall 214966272 2009-05-31 03:27 system02.dbf -rw-r----- 1 oracle oinstall 125837312 2009-05-31 03:26 temp01.dbf -rw-r----- 1 oracle oinstall 601890816 2009-05-31 03:27 undotbs01.dbf -rw-r----- 1 oracle oinstall 105914368 2009-05-31 03:27 users01.dbf root at localhost:/# zfs list NAME USED AVAIL REFER MOUNTPOINT coolpool 6.43G 1.39G 18K /coolpool coolpool/u01 6.43G 1.39G 6.43G /u01 coolpool/u01 at ok 0 - 6.43G - oracle at localhost:/> sqlplus / as sysdba SQL*Plus: Release 11.1.0.6.0 - Production on Sun May 31 03:45:43 2009 Copyright (c) 1982, 2007, Oracle. All rights reserved. Connected to an idle instance. SQL> startup ORACLE instance started. Total System Global Area 418484224 bytes Fixed Size 1300324 bytes Variable Size 218106012 bytes Database Buffers 192937984 bytes Redo Buffers 6139904 bytes Database mounted. ORA-00322: log 1 of thread 1 is not current copy ORA-00312: online log 1 thread 1: ''/u01/oradata/orcl/redo01.rdo''