From owner-freebsd-stable@FreeBSD.ORG Mon Aug 3 21:06:58 2009 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id DCFEC1065670; Mon, 3 Aug 2009 21:06:58 +0000 (UTC) (envelope-from tzim@tzim.net) Received: from golanth.tzim.net (golanth.tzim.net [91.121.152.31]) by mx1.freebsd.org (Postfix) with ESMTP id A31088FC12; Mon, 3 Aug 2009 21:06:58 +0000 (UTC) (envelope-from tzim@tzim.net) Received: from carenath.tzim.net ([82.67.108.3] helo=[192.168.0.200]) by golanth.tzim.net with esmtpsa (TLSv1:AES256-SHA:256) (Exim 4.69 (FreeBSD)) (envelope-from ) id 1MY48n-000GYP-GE; Mon, 03 Aug 2009 22:28:17 +0200 Message-ID: <4A774861.7040200@tzim.net> Date: Mon, 03 Aug 2009 22:28:17 +0200 From: Arnaud Houdelette User-Agent: Thunderbird 2.0.0.22 (Windows/20090605) MIME-Version: 1.0 To: "Ralf S. Engelschall" References: <20090803200826.GA32931@engelschall.com> In-Reply-To: <20090803200826.GA32931@engelschall.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Authenticated-User: tzim@tzim.net X-Authenticator: plain Cc: freebsd-stable@freebsd.org Subject: Re: System is on da0s1, but unable to use da0s2 at all?! X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Aug 2009 21:06:59 -0000 Ralf S. Engelschall wrote: > I've a server installed under a fresh FreeBSD 7.2-STABLE and on a single > UFS filesystem da0s1a. Surprisingly, I cannot access the unused da0s2 > slice (where I want to place the ZFS pool onto): > > | # id > | uid=0(root) gid=0(wheel) groups=0(wheel),5(operator) > | # uname -a > | FreeBSD en4.engelschall.com 7.2-STABLE FreeBSD 7.2-STABLE #0: Sat Aug > | 1 21:06:34 CEST 2009 root@en4.engelschall.com:/usr/obj/usr/src/sys/EN4 > | # sysctl kern.geom.debugflags > | kern.geom.debugflags: 16 > | # df > | Filesystem 1K-blocks Used Avail Capacity Mounted on > | /dev/da0s1a 507630 442508 24512 95% / > | devfs 1 1 0 100% /dev > | # fdisk da0 > | ******* Working on device /dev/da0 ******* > | parameters extracted from in-core disklabel are: > | cylinders=35139 heads=255 sectors/track=32 (8160 blks/cyl) > | > | Figures below won't work with BIOS for partitions not in cyl 1 > | parameters to be used for BIOS calculations are: > | cylinders=35139 heads=255 sectors/track=32 (8160 blks/cyl) > | > | Media sector size is 512 > | Warning: BIOS sector numbering starts with sector 1 > | Information from DOS bootblock is: > | The data for partition 1 is: > | sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) > | start 32, size 1052608 (513 Meg), flag 80 (active) > | beg: cyl 0/ head 1/ sector 1; > | end: cyl 128/ head 254/ sector 32 > | The data for partition 2 is: > | sysid 165 (0xa5),(FreeBSD/NetBSD/386BSD) > | start 1052608, size 285673472 (139489 Meg), flag 0 > | beg: cyl 128/ head 254/ sector 1; > | end: cyl 321/ head 254/ sector 32 > | The data for partition 3 is: > | > | The data for partition 4 is: > | > | # dd if=/dev/zero of=/dev/da0s2 bs=1024 count=100 > | dd: /dev/da0s2: Operation not permitted > | # zpool create zp1 /dev/da0s2 > | cannot create 'zp1': permission denied > > As you can see, even with the usual kern.geom.debugflags workaround > (which GEOM knows about and then usually lets one use a "used" provider) > I'm not able to access da0s2 at all. But da0s2 is not used at all (it is > not even formatted). > > Does anybody has any ideas why da0s2 is not available just because the > system is running from da0s1? When I boot from a fixit CDROM I can > access da0s2 just fine, of course... > > How can I now put my ZFS pool onto da0s2? I even have done the > "zpool create" from the fixit CDROM and then copied over the > /boot/zfs/zfs.cache file. But then ZFS also has the same problem: it > cannot access da0s2 one booted into the regular system... > > -- > rse@FreeBSD.org Ralf S. Engelschall > FreeBSD.org/~rse rse@engelschall.com > FreeBSD committer www.engelschall.com > > _______________________________________________ > freebsd-stable@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-stable > To unsubscribe, send any mail to "freebsd-stable-unsubscribe@freebsd.org" > > If I read correctly fdisk's output, your two slices overlap with 32 sectors. 1rst : start 32, size 1052608 ( so end = 1052608 + 32 ) 2nd : start 1052608 (which is < 1rst end ) BTW you could also use a bsdlabel on 1rst slice (using whole disk) to put your zfs pool on. Arnaud.