Re: mounting a label segfaults?
Hi Darin,
I'm not on debian-user and I don't even use debian, but I ran into the
same problem and thought I'd pass on what I figured out (I ran across
your post while googling).
On Sun, 27 Jul 2003, Darin Strait wrote:
> Running 2.4.21-2-686 and tracking unstable.
>
> Every few months, I try re-arranging my USB2/Firewire drives. I wind up trying
> to get mount -L label to work, only to fail and give up. FWIW, "335" are the
> last three digits from the serial number on the case of the drive.
>
> kiyone:/etc# grep 335 /etc/fstab
> label=/335 /mnt/335 ext3 noauto,rw 0 0
That should be LABEL=/335.
> kiyone:/etc# e2label /dev/sda1
> /335
>
> kiyone:/etc# ls -l /mnt
> total 12
> drwxr-xr-x 2 root root 4096 Jul 27 13:05 335
> drwxr-xr-x 2 root root 4096 May 20 04:08 sda1
> drwxr-xr-x 2 root root 4096 Jun 16 12:47 sdb1
>
> kiyone:/etc# mount -L /335
> Segmentation fault
>
> kiyone:/etc# mount -L 335
> Segmentation fault
>
> kiyone:/etc# mount -L335
> Segmentation fault
After investigating the source for mount, I discovered that the
underlying problem is not having devfs mounted.
Since I didn't want to run operationally with devfs, here's what
I did. I have DEVFS support built into the kernel but not automatically
mounted:
gwiz% grep DEVFS /usr/src/linux/.config
CONFIG_DEVFS_FS=y
# CONFIG_DEVFS_MOUNT is not set
# CONFIG_DEVFS_DEBUG is not set
I then created the following entry in /etc/fstab:
none /dev2 devfs defaults 0 0
and did a "mkdir /dev2". If not rebooting first, also do a "mount /dev2".
Finally I did:
cd /dev
ln -s /dev2/scsi
All of the above will let mount find the device files such as
/dev/scsi/host0/bus0/target1/lun0/part5.
Once this is done, you should be able to do the "mount -L /335" or
"mount /mnt/335" (using your /etc/fstab entry).
If you run with devfs automatically mounted then it should just work
without doing anything special.
-Bill
Reply to: