Jan Damborsky
2009-Dec-09 12:41 UTC
[zfs-discuss] How to destroy ZFS pool with dump on ZVOL
Hi ZFS guys, when playing with one of recent version of OpenSolaris GUI installer, I have tried to restart it after previous failure. However, the installer failed when trying to destroy previously created ZFS root pool. It was discovered that this is due to the fact that dump ZFS volume could not be released and thus subsequent ''zpool destroy'' command failed (as expected): # zpool destroy -f rpool cannot destroy ''rpool'': pool is busy # zfs list rpool/dump NAME USED AVAIL REFER MOUNTPOINT rpool/dump 750M 9.93G 750M - # dumpadm Dump content: kernel pages Dump device: /dev/zvol/dsk/rpool/dump (dedicated) Savecore directory: /var/crash/opensolaris Savecore enabled: no Save compressed: on There was a discussion which happened on zfs-discuss mailing list some time ago about how dump ZVOL could be release and the recommended approach was to try to move it to swap ZVOL - the attempt failed, but dump ZVOL was released. That no longer seems to work: # swap -l swapfile dev swaplo blocks free /dev/zvol/dsk/rpool/swap 8,1 8 2287608 2287608 # dumpadm -d swap dumpadm: no swap devices could be configured as the dump device # dumpadm Dump content: kernel pages Dump device: /dev/zvol/dsk/rpool/dump (dedicated) Savecore directory: /var/crash/opensolaris Savecore enabled: no Save compressed: on Bug 13180 was filed against OpenSolaris installer to track this issue. Could I please ask somebody from ZFS team to help install folks understand what changed and how the installer has to be modified, so that it can destroy ZFS root pool containing dump on ZVOL ? Thank you very much, Jan
Jeffrey Huang
2009-Dec-14 05:50 UTC
[zfs-discuss] [caiman-discuss] How to destroy ZFS pool with dump on ZVOL
Hi, Jan, ? 2009/12/9 20:41, Jan Damborsky ??:> # dumpadm -d swap > dumpadm: no swap devices could be configured as the dump device > # dumpadm > Dump content: kernel pages > Dump device: /dev/zvol/dsk/rpool/dump (dedicated) > Savecore directory: /var/crash/opensolaris > Savecore enabled: no > Save compressed: on > > > Bug 13180 was filed against OpenSolaris installer to track this issue. > > Could I please ask somebody from ZFS team to help install folks understand > what changed and how the installer has to be modified, so that it can > destroy ZFS root pool containing dump on ZVOL ?I am doing the destroy ZVOL and zpool work a lot in my test cases. What I required is the testing machine needs 2 hard disk, and add the 2nd disk as swap under micro root: # swap -a /dev/dsk/c2t1d0s0 then # dumpadm -d swap will pass, and I can do installation again and again. But I am also hoping to get more neatly solution than requiring an additional storage. Rgs Jeffrey
Jan Damborsky
2009-Dec-14 07:48 UTC
[zfs-discuss] [caiman-discuss] How to destroy ZFS pool with dump on ZVOL
Hi Jeffrey, Jeffrey Huang wrote:> Hi, Jan, > > ? 2009/12/9 20:41, Jan Damborsky ??: >> # dumpadm -d swap >> dumpadm: no swap devices could be configured as the dump device >> # dumpadm >> Dump content: kernel pages >> Dump device: /dev/zvol/dsk/rpool/dump (dedicated) >> Savecore directory: /var/crash/opensolaris >> Savecore enabled: no >> Save compressed: on >> >> >> Bug 13180 was filed against OpenSolaris installer to track this issue. >> >> Could I please ask somebody from ZFS team to help install folks >> understand >> what changed and how the installer has to be modified, so that it can >> destroy ZFS root pool containing dump on ZVOL ? > > I am doing the destroy ZVOL and zpool work a lot in my test cases. > What I required is the testing machine needs 2 hard disk, and add the 2nd > disk as swap under micro root: > # swap -a /dev/dsk/c2t1d0s0 > then > # dumpadm -d swap > will pass, and I can do installation again and again.Yep, I use similar approach - I create one spare slice on target disk and then use it in the same way as you suggested.> > But I am also hoping to get more neatly solution than requiring an > additional storage.Agreed - the solution for this problem is now being communicated with ZFS team. Thanks ! Jan