From owner-freebsd-net@FreeBSD.ORG Wed Feb 19 17:38:28 2014 Return-Path: Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 5E1DB101 for ; Wed, 19 Feb 2014 17:38:28 +0000 (UTC) Received: from h2.funkthat.com (gate2.funkthat.com [208.87.223.18]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.freebsd.org (Postfix) with ESMTPS id 35F2D1075 for ; Wed, 19 Feb 2014 17:38:27 +0000 (UTC) Received: from h2.funkthat.com (localhost [127.0.0.1]) by h2.funkthat.com (8.14.3/8.14.3) with ESMTP id s1JHcOhs005618 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 19 Feb 2014 09:38:25 -0800 (PST) (envelope-from jmg@h2.funkthat.com) Received: (from jmg@localhost) by h2.funkthat.com (8.14.3/8.14.3/Submit) id s1JHcOYc005617; Wed, 19 Feb 2014 09:38:24 -0800 (PST) (envelope-from jmg) Date: Wed, 19 Feb 2014 09:38:24 -0800 From: John-Mark Gurney To: lucian@lastdot.org Subject: Re: Where has my /dev/label gone? Message-ID: <20140219173824.GI34851@funkthat.com> Mail-Followup-To: lucian@lastdot.org, Erich Dollansky , freebsd-net@freebsd.org References: <20140219175643.0e744028@X220.alogt.com> <20140219201420.7d2f7e1c@X220.alogt.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.4.2.3i X-Operating-System: FreeBSD 7.2-RELEASE i386 X-PGP-Fingerprint: 54BA 873B 6515 3F10 9E88 9322 9CB1 8F74 6D3F A396 X-Files: The truth is out there X-URL: http://resnet.uoregon.edu/~gurney_j/ X-Resume: http://resnet.uoregon.edu/~gurney_j/resume.html X-TipJar: bitcoin:13Qmb6AeTgQecazTWph4XasEsP7nGRbAPE X-to-the-FBI-CIA-and-NSA: HI! HOW YA DOIN? can i haz chizburger? X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.2.2 (h2.funkthat.com [127.0.0.1]); Wed, 19 Feb 2014 09:38:25 -0800 (PST) Cc: freebsd-net@freebsd.org, Erich Dollansky X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 19 Feb 2014 17:38:28 -0000 lucian@lastdot.org wrote this message on Wed, Feb 19, 2014 at 12:24 +0000: > Erich Dollansky writes: > > >On Wed, 19 Feb 2014 11:54:40 +0000 > >lucian@lastdot.org wrote: > > > >> Erich Dollansky writes: > >> > >> > On Wed, 19 Feb 2014 09:10:53 +0000 > >> > Lucian wrote: > >> > > >> > > I set up some labels (glabel label blah /dev/partition) and they > >> > > show up fine in /dev/label, but once I reboot out of single user > >> > > mode and into nornal mode /dev/label is gone. > >> > > > >> > > What am I missing? > >> > > >> > Bermuda triangle? > >> > > >> > It sounds strange. Ok, you this in the single user mode. Why? What > >> > devices did you label? > >> > > >> > Hopefully not the devices in use. This does not work from my point > >> > of view. You would have to use another label type then. > >> > >> I did this in single user because according to the docs you can't do > >> it on a "live system". > >> http://www.freebsd.org/doc/handbook/geom-glabel.html > > > >do you have this in your kernel? > > > >options GEOM_LABEL > > > >You can also load the module at boot time with an entry > >in /boot/loader.conf. > > > >Erich > > I have GEOM_LABEL loaded, but I noticed something strange. > If I boot in single user, I can create and see the labels under /dev/label, > however if I remount the / filesystem RW then /dev/label disappears. > BUT, if I just replace my / partition in fstab with the seemingly missing > label (eg /dev/label/rootfs) then the system boots up fine and /dev/label > is again available to `ls`. Strange stuff, it should be covered in the > handbook... > Problem solved, I guess. This is correct, but it's not for the reason people are saying... The label is in the partition, say ada0s1a... When you mount ada0s1a for writing (which also sets exclusive access, not just reading), all children geoms will wither away because you won't be able to open the children for reading as the mounted partition has exclusive access.. If you later were to remount the partition read-only (I'm not sure if this drops exclusive/write access, but if it does), then the labels will show up again, assuming the file system didn't overwrite the label... -- John-Mark Gurney Voice: +1 415 225 5579 "All that I will do, has been done, All that I have, has not."