From: Kay Sievers <kay.sievers@vrfy.org>
To: linux-hotplug@vger.kernel.org
Subject: Re: disk/by-label + label-change
Date: Tue, 12 Dec 2006 18:34:49 +0000 [thread overview]
Message-ID: <1165948489.5631.12.camel@pim.off.vrfy.org> (raw)
In-Reply-To: <E1Gu9g7-001DrH-HV@alf1.lmb.internal>
On Tue, 2006-12-12 at 17:51 +0000, T. Horsnell wrote:
> >On 12/12/06, T. Horsnell <tsh@mrc-lmb.cam.ac.uk> wrote:
> >> If a disk with a persistence-entry in /dev/disk/by-label
> >> is re-labelled with tune2fs, the by-label entry isnt
> >> updated to match the new label and when the disk is mounted
> >> with a 'mount -L ',
> >
> >You are writing to a raw sector of the disk, no part of the system
> >will notice that you did this and have changed something. You need to
> >tell the kernel to emit an event by doing:
> > echo "add" > /sys/block/sda/uevent
> >and the link will get updated.
>
> OK, thanks. But shouldnt tune2fs do this when it updates the label?
> I guess I should make my own tune2fs script and do it there.
Right, that shouldn't be part of the tool that writes to the disk, it
can't know if it's safe to update the links.
> >> the mounted-device shows up as something
> >> like:
> >>
> >> [root@dev1 ~]# mount
> >> /dev/hdb2 on / type ext3 (rw)
> >> proc on /proc type proc (rw)
> >> sysfs on /sys type sysfs (rw)
> >> devpts on /dev/pts type devpts (rw,gid=5,modeb0)
> >> tmpfs on /dev/shm type tmpfs (rw)
> >> none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw)
> >> sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw)
> >> >>>> /dev/.tmp-8-17 on /test type ext3 (rw)
> >>
> >> Is this as it should be?
> >
> >Looks like you mounted the device with a PROGRAM rule, right? This is
> >definitely not what it "should be". :)
>
> I do no mounting in udev, its all in fstab. I never thought to
> do it in a udev PROGRAM rule...
But who is using udev's temporary device node for mount then?
/dev/.tmp-8-17 on /test type ext3 (rw)
That usually only exists during the udev event processing.
Kay
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CIDÞVDEV
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
Linux-hotplug-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
next prev parent reply other threads:[~2006-12-12 18:34 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-12-12 15:36 disk/by-label + label-change T. Horsnell
2006-12-12 15:55 ` Kay Sievers
2006-12-12 17:51 ` T. Horsnell
2006-12-12 18:34 ` Kay Sievers [this message]
2006-12-13 15:36 ` T. Horsnell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1165948489.5631.12.camel@pim.off.vrfy.org \
--to=kay.sievers@vrfy.org \
--cc=linux-hotplug@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox