Is it appropriate to mount /var and /usr on ext2fs partition ?

Code:
>df -h
Filesystem     Size    Used   Avail Capacity  Mounted on
/dev/ad4s3a    496M    119M    337M    26%    /
devfs          1.0K    1.0K      0B   100%    /dev
/dev/ad4s3e    496M    6.7M    449M     1%    /tmp
/dev/ad4s3f     14G    7.8G    5.4G    59%    /usr
/dev/ad4s3d    1.4G    171M    1.1G    13%    /var
/dev/ad4s7      30G    3.5G     26G    12%    /media/F
/dev/ad4s8      30G    172M     28G     1%    /media/G

>mount
/dev/ad4s3a on / (ufs, local)
devfs on /dev (devfs, local, multilabel)
/dev/ad4s3e on /tmp (ufs, local, soft-updates)
/dev/ad4s3f on /usr (ufs, local, soft-updates)
/dev/ad4s3d on /var (ufs, local, soft-updates)
/dev/ad4s7 on /media/F (msdosfs, local)
/dev/ad4s8 on /media/G (ext2fs, local)

The /dev/ad4s8 is an empty partition. Now i want to move /var and /usr to it. Do i need to format /dev/ad4s8 to UFS ?

Sincerely!
 
It's better if you try under VM first. IIRC, ext2 doesn't support chflags(2), some libs and cmds that reside under /usr use schg (SF_IMMUTABLE) flag.
 
No, you should partition /dev/ad4s8 with at least one partition (ad8s1d) and then format that as UFS. Preferably into two, one for /var and the other for /usr.

However, I'd recommend not putting /usr onto a separate filessytem. Keep / and /usr together on one filesystem (ie, don't put /usr onto a separate partition), as that is the complete FreeBSD OS, and it's nice to have it all available during single-user mode without having to mount anything extra. Makes troubleshooting a lot simpler.

Instead, make separate filesystems for /usr/local, /usr/src, /usr/obj, and /usr/ports.
 
phoenix said:
No, you should partition /dev/ad4s8 with at least one partition (ad8s1d) and then format that as UFS. Preferably into two, one for /var and the other for /usr.

However, I'd recommend not putting /usr onto a separate filessytem. Keep / and /usr together on one filesystem (ie, don't put /usr onto a separate partition), as that is the complete FreeBSD OS, and it's nice to have it all available during single-user mode without having to mount anything extra. Makes troubleshooting a lot simpler.

Instead, make separate filesystems for /usr/local, /usr/src, /usr/obj, and /usr/ports.
That's an interesting way of doing it which had never occurred to me. I generally place /usr/ports and /usr/home onto their own partition, mainly out of convenience, but you do have a point about /usr/src and /usr/obj, I'm sure that cuts down significantly on the risk of filesystem corruption to important files.

IMHO it's a good idea to give /usr/home it's own partition, just so that you can easily back it up and not have to worry about damage to other partitions causing files there to become corrupt.
 
Can you tell I have no idea what I'm gibbering about?

hedwards said:
That's an interesting way of doing it which had never occurred to me. I generally place /usr/ports and /usr/home onto their own partition, mainly out of convenience, but you do have a point about /usr/src and /usr/obj, I'm sure that cuts down significantly on the risk of filesystem corruption to important files.

IMHO it's a good idea to give /usr/home it's own partition, just so that you can easily back it up and not have to worry about damage to other partitions causing files there to become corrupt.

The only issue I have with putting /usr/obj/ on a separate filesystem from /usr/ on a single disk is that installworld will read/write thousands of times, whereas it seems (to my besotted mind) that with them on the same filesystem, a simple link/unlink is all that is required.

I guess if you have enough memory putting /usr/obj/ onto a tmpfs(5) might be an option, if you're not rebooting between buildworld & installworld.
 
hedwards said:
IMHO it's a good idea to give /usr/home it's own partition, just so that you can easily back it up and not have to worry about damage to other partitions causing files there to become corrupt.

Most people use /home as the mountpoint for a separate filesystem, and not /usr/home. :)
 
phoenix said:
Most people use /home as the mountpoint for a separate filesystem, and not /usr/home. :)
Heh, I suppose that does make somewhat more sense in the case of emergency. I usually do it that way because the symbolic link goes that direction already. One less thing to think about, plus in an emergency, I generally don't mount my home directory anyways.
 
phoenix said:
No, you should partition /dev/ad4s8 with at least one partition (ad8s1d) and then format that as UFS. Preferably into two, one for /var and the other for /usr.

However, I'd recommend not putting /usr onto a separate filessytem. Keep / and /usr together on one filesystem (ie, don't put /usr onto a separate partition), as that is the complete FreeBSD OS, and it's nice to have it all available during single-user mode without having to mount anything extra. Makes troubleshooting a lot simpler.

Instead, make separate filesystems for /usr/local, /usr/src, /usr/obj, and /usr/ports.
In fact, i never do such a thing manually! So would you mind introducing it in detail especially the command options i should use.

thanks!
 
Back
Top