Re: naming convention: loopX
On Thu, Jul 21, 2011 at 09:58:38PM -0400, Andrew wrote:
> I was particularly considering Klaus's /init script which relies on the
> name "/dev/loop0" for knoppix-data, and the fact that earlier versions of
> knoppix did not have the /dev/loop/ directory.
Well, frankly, I am unsure whether /dev/loop/X or /dev/loopX is more
"correct". With older devfs, it seemed that /dev/loop/X was the way to
go for, but currently udev does not even create any blockdev nodes in
/dev for loop at all. Because of that, I added /dev/loop0 as well as
/dev/loop/0 as static files, in order to catch both naming conventions.
For manually assigning files with losetup, the device name is not
relevant, only the major and minor device numbers matter. I wasn't aware
of the fact that "mount" could get in trouble with automatic loopback
If asked which one I prefer, this would be /dev/loop0 instead of
/dev/loop/0 , but just because it saves one letter to type. ;-)
I don't think we actually use /dev/loop/X in any script, rather than
/dev/loopX, so I would also tend to just delete the /dev/loop directory
with its contents, unless someone knows a reason why this is wrong.
> > --- On Thu, 7/21/11, cvevans <firstname.lastname@example.org> wrote:
> >> OTOH creating /dev/loop/1 to
> >> /dev/loop/100 solves the mount failure,
> >> and you have 100 loop devices without cluttering /dev.
> >> as root:
> >> for i in `seq 1 100`; do mknod /dev/loop/$i b 7 $i; done
> >> cvevans
> > Oh no, everywhere the documentation has already use the /dev/loopX as the
> > naming convention, are we going to go "reverse gear" and use back the
> > /dev/loop/X naming convention ?
> > 'mount' is trying to be backward compatible by detecting the presence of
> > old naming convention. That does not mean a whole bunch of old device file
> > names have to be created.
> > The original poster has already suggested a clean fix.
> > Remove /dev/loop directory and move on !