LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   *BSD (http://www.linuxquestions.org/questions/%2Absd-17/)
-   -   Mount UFS partitions (not slices) from linux /etc/fstab (http://www.linuxquestions.org/questions/%2Absd-17/mount-ufs-partitions-not-slices-from-linux-etc-fstab-425047/)

JZL240I-U 03-15-2006 09:14 AM

Mount UFS partitions (not slices) from linux /etc/fstab
 
Sorry if this has been asked before, but I had no useable results in my searches.

I have a FreeBSD slice as /dev/hda3 on my machine, with ad0s3a as /, ad0s3b as swap etc. as proposed by the BSD install routine.

From my Linux installation I can mount ad0s3a in a "BSD-root" directory, but not the rest of the partitions in the slice.

Is it impossible to do that from /etc/fstab or are there special tricks (like in GRUB) to make them accessible from linux (e.g. /dev/hda3e)?

jomen 03-15-2006 03:52 PM

One thought I have:
in the kernel-config there are options that look like what you would need to do what you describe:
in: --> File systems --> Miscellaneous filesystems --> there is read only support for UFS
and in: --> Partition Types --> Advanced partition selection --> there is BSD disklabel (FreeBSD partition tables) support
and some other choices...
If these things are compiled into the kernel you might be able to do what you want...?

JZL240I-U 03-16-2006 03:13 AM

Quote:

Originally Posted by jomen
...there is BSD disklabel (FreeBSD partition tables) support and some other choices...
If these things are compiled into the kernel you might be able to do what you want...?

Yes, but how? I mean, what option would I use in /etc/fstab? "man" doesn't tell...

JZL240I-U 03-20-2006 08:43 AM

Bump ;)
Anyone?

JZL240I-U 03-24-2006 07:36 AM

Solved
 
Solution:

Code:

cat /proc/partitions
shows major and minor numbers, #blocks and name. All these partitions can be mounted, typing a "/dev/" in front of the name and the usual mount options.

Code:

fdisk -l  ==>{doesn't list the BSD Partitions}
In my case the partitions hidden from fdisk were something like /dev/hda17 up to /dev/hda22. My "old" partitions had the maximum number of /dev/hda16. Obviously the BSD partitions were appended to the usual partitions like from a second logical partition.

So I am curious what will happen, when I create a new partition with fdisk -- I don't think anything untoward will happen, maybe I have to change /etc/fstab and give the BSD-partitions new numbers, physically they reside in /dev/hda3 and thus should be protected...

Anyhow, this then seems to be the way how to proceed :).

JZL240I-U 04-25-2006 04:15 AM

Quote:

Originally Posted by JZL240I-U
...So I am curious what will happen, when I create a new partition with fdisk -- I don't think anything untoward will happen, maybe I have to change /etc/fstab and give the BSD-partitions new numbers, physically they reside in /dev/hda3 and thus should be protected...

I tried it. I got my new partition allright and nothing was deleted, but all the numbers of the BSD-slices were incremented by one :mad:.

One can live with that but it's certainly not nice.

primo 04-26-2006 02:59 AM

What options are you trying in /etc/fstab ?
I would not care about the high numbers. You may create those with mknod. With "ls -l /dev/hda*" you get the pattern.

Anyway here are mine:
Code:

/dev/hda2 /mnt/bsd-usr  ufs auto,ro,ufstype=ufs2,nodev,nosuid  0 0
/dev/hda4 /mnt/bsd      ufs auto,ro,ufstype=ufs2,nodev,nosuid  0 0



All times are GMT -5. The time now is 04:34 PM.