I''ve got Solaris 10u7 + patches as of 20090918 running on a V40z. I have two existing zpools - rpool and dbzpool. I''m trying to make a third pool with some new disks, however solaris is very unhappy about one of them, for some reason.. # format -e c12t1d0 selecting c12t1d0 [disk formatted] /dev/dsk/c3t11d0s0 is part of active ZFS pool dbzpool. Please see zpool(1M). It is true that c3t11d0 is part of dbzpool. But why is solaris upset about c3t11 when i''m working with c12t1 ?? So i checked the device links, and all looks fine: /dev/dsk/c3t11d0 -> ../../devices/pci at 1d,0/pci1022,7450 at 2/pci1000,10c0 at 1/sd at b,0:wd /dev/dsk/c3t11d0s0 -> ../../devices/pci at 1d,0/pci1022,7450 at 2/pci1000,10c0 at 1/sd at b,0:a /dev/dsk/c12t1d0 -> ../../devices/pci at 0,0/pci1022,7450 at b/pci1000,10c0 at 1/sd at 1,0:wd /dev/dsk/c12t1d0s0 -> ../../devices/pci at 0,0/pci1022,7450 at b/pci1000,10c0 at 1/sd at 1,0:a i tried: fdisk -B /dev/rdsk/c12t1d0 dd if=/dev/zero of=/dev/rdsk/c12t1d0p0 bs=1024k dd if=/dev/zero of=/dev/rdsk/c12t1d0s2 bs=1024k but Solaris still has some association between c3t11 and c12t1. zfs won''t let me use it either: # zpool create testpool c12t1d0 invalid vdev specification use ''-f'' to override the following errors: /dev/dsk/c3t11d0s0 is part of active ZFS pool dbzpool. Please see zpool(1M). Clearly, these are separate disks: # smartctl -a /dev/rdsk/c3t11d0 | grep Serial Serial number: 3KR3Y92800009741MFNA # smartctl -a /dev/rdsk/c12t1d0 | grep Serial Serial number: 3KR2FXB700007651PJE6 any ideas?? -- Jeremy Kister http://jeremy.kister.net./
zfs-01 at jeremykister.com said:> # format -e c12t1d0 selecting c12t1d0 [disk formatted] /dev/dsk/c3t11d0s0 is > part of active ZFS pool dbzpool. Please see zpool(1M). > > It is true that c3t11d0 is part of dbzpool. But why is solaris upset about > c3t11 when i''m working with c12t1 ?? So i checked the device links, and all > looks fine: > . . .Could it be that c12t1d0 was at some time in the past (either in this machine or another machine) known as c3t11d0, and was part of a pool called "dbzpool"?> i tried: > fdisk -B /dev/rdsk/c12t1d0 > dd if=/dev/zero of=/dev/rdsk/c12t1d0p0 bs=1024k > dd if=/dev/zero of=/dev/rdsk/c12t1d0s2 bs=1024k > > but Solaris still has some association between c3t11 and c12t1.You''ll need to give the same "dd" treatment to the end of the disk as well; ZFS puts copies of its labels at the beginning and at the end. Oh, and you can "fdisk -E /dev/rdsk/c12t1d0" to convert to a single, whole-disk EFI partition (non-VTOC style). Regards, Marion
On 11/2/2009 9:23 PM, Marion Hakanson wrote:> Could it be that c12t1d0 was at some time in the past (either in this > machine or another machine) known as c3t11d0, and was part of a pool > called "dbzpool"?quite possibly. but certainly not this host''s dbzpool.> You''ll need to give the same "dd" treatment to the end of the disk as well; > ZFS puts copies of its labels at the beginning and at the end. Oh, andim not sure what you mean here - I thought p0 was the entire disk in x86 - and s2 was the whole disk in the partition. what else should i overwrite? Thanks, -- Jeremy Kister http://jeremy.kister.net./
On Mon, November 2, 2009 20:23, Marion Hakanson wrote:> You''ll need to give the same "dd" treatment to the end of the disk as > well; > ZFS puts copies of its labels at the beginning and at the end.Does anybody else see this as rather troubling? Obviously it''s dangerous to get in the habit of doing this as a routine operation, which to read advice here is how people are thinking of it. It seems to me that something in ZFS''s protective procedures is missing or astray or over-active -- being protective is good, but there needs to be a way to re-use a disk that''s been used before, too. And frequently people are at a loss to even understand what the possible conflict might be. Maybe a doubling of the -f option should give as full an explanation as possible of what the evidence shows as previous use, and then let you override it if you really really insist? Or some other option? Or an entirely separate utility (or script)? What I basically want, I think, is a standard way to get an explanation of exactly what ZFS thinks the conflict in my new proposed use of a disk might be -- and then a standard and as-safe-as-possible way to tell it to go ahead and use the disk. -- David Dyer-Bennet, dd-b at dd-b.net; http://dd-b.net/ Snapshots: http://dd-b.net/dd-b/SnapshotAlbum/data/ Photos: http://dd-b.net/photography/gallery/ Dragaera: http://dragaera.info
Hi David, This RFE is filed for this feature: http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=6893282 Allow the zpool command to wipe labels from disks Cindy On 11/03/09 09:00, David Dyer-Bennet wrote:> On Mon, November 2, 2009 20:23, Marion Hakanson wrote: > >> You''ll need to give the same "dd" treatment to the end of the disk as >> well; >> ZFS puts copies of its labels at the beginning and at the end. > > Does anybody else see this as rather troubling? Obviously it''s dangerous > to get in the habit of doing this as a routine operation, which to read > advice here is how people are thinking of it. > > It seems to me that something in ZFS''s protective procedures is missing or > astray or over-active -- being protective is good, but there needs to be a > way to re-use a disk that''s been used before, too. And frequently people > are at a loss to even understand what the possible conflict might be. > > Maybe a doubling of the -f option should give as full an explanation as > possible of what the evidence shows as previous use, and then let you > override it if you really really insist? Or some other option? Or an > entirely separate utility (or script)? > > What I basically want, I think, is a standard way to get an explanation of > exactly what ZFS thinks the conflict in my new proposed use of a disk > might be -- and then a standard and as-safe-as-possible way to tell it to > go ahead and use the disk. >
>I said: >> You''ll need to give the same "dd" treatment to the end of the disk as well; >> ZFS puts copies of its labels at the beginning and at the end. Oh, andzfs-01 at jeremykister.com said:> im not sure what you mean here - I thought p0 was the entire disk in x86 - > and s2 was the whole disk in the partition. what else should i overwrite?Sorry, yes, you did get the whole slice overwritten. Most people just add a "count=10" or something similar, to overwrite the beginning of the drive, but your invocation would overwrite the whole thing. If the disk is going to be part of whole-disk zpool, I like to make sure there is not an old VTOC-style partition table on there. That can be done either via some "format -e" commands, or with "fdisk -E", to put an EFI label on there. Anyway, I agree with the desire for "zpool" to be able to do this itself, with less possibility of human error in partitioning, etc. Glad to hear there''s already an RFE filed for it. Regards, Marion
On 11/3/2009 3:49 PM, Marion Hakanson wrote:> If the disk is going to be part of whole-disk zpool, I like to make > sure there is not an old VTOC-style partition table on there. That > can be done either via some "format -e" commands, or with "fdisk -E", > to put an EFI label on there.unfortunately, fdisk won''t help me at all: # fdisk -E /dev/rdsk/c12t1d0p0 # zpool create -f testp c12t1d0 invalid vdev specification the following errors must be manually repaired: /dev/dsk/c3t11d0s0 is part of active ZFS pool dbzpool. Please see zpool(1M). and i can''t find anything in format that lets me do anything: # format -e c12t1d0 selecting c12t1d0 [disk formatted] /dev/dsk/c3t11d0s0 is part of active ZFS pool dbzpool. Please see zpool(1M). [...] format> label Cannot label disk when partitions are in use as described. I wonder if getting my hands on a pre-sol10 x86 format binary would help... -- Jeremy Kister http://jeremy.kister.net./
zfs-01 at jeremykister.com said:> unfortunately, fdisk won''t help me at all: > # fdisk -E /dev/rdsk/c12t1d0p0 > # zpool create -f testp c12t1d0 > invalid vdev specification > the following errors must be manually repaired: > /dev/dsk/c3t11d0s0 is part of active ZFS pool dbzpool. Please see zpool(1M).Hmm. Did you do the "devfsadm -Cv" as someone else suggested? I think I would do that both before and after the "fdisk -E". Then give the "dd" treatment again, with the EFI-style partion label in place. I''ve sometimes had to do the "dd" treatment with both VTOC and EFI labels on the same drive in order to make ZFS forget it had ever been used in a pool. Regards, Marion