Question about mount
Alexander Griesser
alexander.griesser at lkh-vil.or.at
Mon Mar 27 02:50:26 PST 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Jean Wolter wrote:
>> In previous busybox releases I could do the following:
>>
>> mount -n -o remount,rw /
>
> The following works here with 1.1.1
>
> busybox mount -o remount,rw /dev/root /
Ah, ok, that works here for me too, thank you.
Today I spent quite some time reading the mount sourcecode and
I think I found code that should do the following:
If mount gets only one parameter, it is the directory where the
filesystem has to be mounted -> the mountpoint.
If so, check /etc/fstab to get all other credentials for this
mountpoint and finally do the mount.
If the mountpoint can't be found in /etc/fstab, try to mount
the last entry in /etc/fstab and that is exact that, what happens.
The following behaviour is really strange, at least some parts
of the output are definetly wrong:
My fstab:
[lxtc3861 - ~ #] cat /etc/fstab
# /etc/fstab: static file system information.
#
# <file system> <mount point> <type> <options> <dump>
<pass>
/dev/hda3 / ext3 defaults 0 0
proc /proc proc defaults 0 0
tmpfs /var/tmp tmpfs defaults,size=100M 0 0
none /proc/bus/usb usbfs defaults 0 0
/dev/hda1 /system ext3 defaults 0 0
Currently mounted filesystems:
[lxtc3861 - ~ #] mount
/dev/root on / type ext3 (rw)
proc on /proc type proc (rw,nodiratime)
sysfs on /sys type sysfs (rw)
none on /proc/bus/usb type usbfs (rw)
devpts on /dev/pts type devpts (rw)
tmpfs on /var/tmp type tmpfs (rw)
I can mount and unmount /system (/dev/hda1) with the following
commands:
[lxtc3861 - ~ #] mount /system
[lxtc3861 - ~ #] umount /system
But if I try to mount / I get the following error:
[lxtc3861 - ~ #] mount /
mount: Mounting /dev/hda1 on /system failed: No such device
[lxtc3861 - ~ #]
According to the output, mount tries to mount /dev/hda1 on /system and
that should work, according to my previous try.
'umount /' "works" as it does mount the root-filesystem readonly.
As /dev/root does not exist on the filesystem I assume its value is
derived from the root= kernel boot parameter, right?
That would definetly solve my problem then...
But the above behaviour seems strange to me.
ciao,
- --
Alexander Griesser (Netzwerkadministration)
E-Mail: alexander.griesser at lkh-vil.or.at | Web: http://www.lkh-vil.or.at
KABEG LKH Villach | Nikolaigasse 43 | 9500 Villach
Tel.: +43 4242 208 3061 | Fax.: +43 4242 971 3061
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFEJ8Ny66HVD6KUm1oRAq0JAJ4wJpy+sNq6/wQR4KxmMTSXZM3E0ACeOuHl
Uu5SRxUiKDa7JRLRJIGw6JQ=
=uO9J
-----END PGP SIGNATURE-----
More information about the busybox
mailing list