OpenSolaris

Discussions Communities Projects Download Source Browser

Home » OpenSolaris Forums » zfs » discuss

Thread: [zfs-discuss] Solaris disk confusion ?

Welcome, Guest Help
Login Login
Guest Settings Guest Settings
Reply to this Thread Reply to this Thread Search Forum Search Forum Back to Thread List Back to Thread List

Permlink Replies: 7 - Last Post: Nov 4, 2009 2:36 PM by: hakanson Threads: [ Previous | Next ]
Jeremy Kister
zfs-01@jeremykister....
[zfs-discuss] Solaris disk confusion ?
Posted: Nov 1, 2009 9:22 PM

  Click to reply to this thread Reply

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@1d,0/pci1022,7450@2/pci1000,10c0@1/sd@b,0:wd
/dev/dsk/c3t11d0s0 ->
../../devices/pci@1d,0/pci1022,7450@2/pci1000,10c0@1/sd@b,0:a

/dev/dsk/c12t1d0 ->
../../devices/pci@0,0/pci1022,7450@b/pci1000,10c0@1/sd@1,0:wd
/dev/dsk/c12t1d0s0 ->
../../devices/pci@0,0/pci1022,7450@b/pci1000,10c0@1/sd@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-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


hakanson

Posts: 172
From: US

Registered: 2/21/06
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 2, 2009 6:23 PM   in response to: Jeremy Kister

  Click to reply to this thread Reply


zfs-01 at jeremykister dot 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


_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Jeremy Kister
zfs-01@jeremykister....
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 3, 2009 6:03 AM   in response to: hakanson

  Click to reply to this thread Reply

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, and

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?

Thanks,

--

Jeremy Kister
http://jeremy.kister.net./



_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


hakanson

Posts: 172
From: US

Registered: 2/21/06
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 3, 2009 12:49 PM   in response to: Jeremy Kister

  Click to reply to this thread Reply

>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, and

zfs-01 at jeremykister dot 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


_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


Jeremy Kister
zfs-01@jeremykister....
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 3, 2009 5:59 PM   in response to: hakanson

  Click to reply to this thread Reply

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-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


hakanson

Posts: 172
From: US

Registered: 2/21/06
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 4, 2009 2:36 PM   in response to: Jeremy Kister

  Click to reply to this thread Reply

zfs-01 at jeremykister dot 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




_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


dd-b

Posts: 283
From: US

Registered: 7/7/06
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 3, 2009 8:00 AM   in response to: hakanson

  Click to reply to this thread Reply


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@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

_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss


cindys

Posts: 405
From: US

Registered: 11/2/05
Re: [zfs-discuss] Solaris disk confusion ?
Posted: Nov 3, 2009 8:58 AM   in response to: dd-b

  Click to reply to this thread Reply

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.
>
_______________________________________________
zfs-discuss mailing list
zfs-discuss at opensolaris dot org
http://mail.opensolaris.org/mailman/listinfo/zfs-discuss





Terms of Use | Privacy | Trademarks | Copyright Policy | Site Guidelines
Your use of this web site or any of its content or software indicates your agreement to be bound by these Terms of Use.
Copyright © 1995-2005 Sun Microsystems, Inc.