From: "Linda A. Walsh" <lvm@tlinx.org>
To: LVM general discussion and development <linux-lvm@redhat.com>
Subject: [linux-lvm] Inconsistent naming needs to be fixed (was Re: Inconsistent naming...?)
Date: Sun, 17 Jul 2011 19:38:33 -0700 [thread overview]
Message-ID: <4E239CA9.40702@tlinx.org> (raw)
In-Reply-To: <4E1D77A7.4030801@tlinx.org>
Linda A. Walsh wrote:
> Alasdair G Kergon wrote:
>> On Sun, Jul 10, 2011 at 06:31:27PM -0700, Linda A. Walsh wrote:
>>> Notice the device name. notice how the single dashes are now
>>> displayed as two dashes?!?!
>> Roughly: a dash is the separator we chose, and we double it to escape a
>> real dash. But we still need to extend our escaping mechanism to handle
>> characters that udev states it doesn't support in primary device names
>> but which the old /dev did used to support (and so we still do).
>
> Roughly, if I give a script the mount point of a logical device, how
> can I find out the name of the LV it is on?
Ok, I think I bass-ackwards way of hacking around this -- but my
solution is unique to my usage and conventions.
In my 'application' (meaning 'usage'), I start with a mount-point
of a volume I want to take a snapshot of. I want to map that mount
point back to the original dev. It's not straightforward when the
device in /proc/mounts, isn't the real device NOR is it the name I
used! I.e. real dev = /dev/dm-[0-x], name i used /dev/VG/LV.
What /proc/mounts shows: /mapper/dev/<mangled VG>-<mangled LV>.
So who's responsible for that mess of code so we can get /proc to
either, show the value I used (when I mount by LABEL I see the 'real'
devices in mounts -- not /dev/disk-by-label/<label>. It isn't consistent
but it's worse, as it choose a name that's gone through some
'translation'...
Am I being more clear about why this create problems (besides
being confusing and just looking bad (because my computer has
to come up with it's own name for a dev -- neither the one
I used nor the real name?
Now, I can kludge around this, by knowing some different pieces
of information unique to my app/situation, but in the general case,
it would be unpredictable, and that's bad, as I'd like to release these
scripts if I can get them working to my satisfaction.
Can the situation with /proc/mounts be fixed?
prev parent reply other threads:[~2011-07-18 2:38 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-11 1:31 [linux-lvm] Inconsistent naming...? Linda A. Walsh
2011-07-11 2:16 ` Alasdair G Kergon
2011-07-11 2:27 ` Linda A. Walsh
2011-07-18 5:52 ` Luca Berra
[not found] ` <4E2538E1.9040806@tlinx.org>
2011-07-19 15:39 ` [linux-lvm] mount's (&udev's) dirty little naming problem -- (was Inconsistent naming...?) Luca Berra
2011-07-11 2:58 ` [linux-lvm] Inconsistent naming...? Alasdair G Kergon
2011-07-13 10:47 ` Linda A. Walsh
2011-07-13 15:39 ` Stuart D. Gathman
2011-07-13 16:11 ` Alasdair G Kergon
2011-07-13 17:34 ` Males, Jess
2011-07-13 18:47 ` Alasdair G Kergon
2011-07-14 4:05 ` Linda A. Walsh
2011-07-18 2:38 ` Linda A. Walsh [this message]
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=4E239CA9.40702@tlinx.org \
--to=lvm@tlinx.org \
--cc=linux-lvm@redhat.com \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.