Adding separate var partition to SG-4680 appliance



  • Greetings pfSense forums
    I've recently started installing pfSense appliance boxes onto the fleet of ships I support as the primary WAN router. They are going great guns. Have had 1 issue where it would appear the /var/log directory has been filled on an appliance which I swapped out. no big deal. I've still yet to scrutinize why the /var/log filled but that's coming.

    Long story short, the appliance is the SG-4680 which has a single intel mSATA drive. LBA is 58gig. I've checked the default "out of box" partitions using the "disktype" linux command on Ubuntu.  command output as so (condensed):

    • Partition 1: 27.96 GB type 0xA5 (FreeBSD)

    • Partition a: 19.96 GB type 7 (4.2BSD fast file system) mounted at "/" (root)

    • Partition b: 8GB type 1 (swap)

    • Partition c: 27.96 GB type 0 (unused)

    Is the disktype command reporting the volume structure correctly for the default SG-4680 appliance? I'll assume so givent eh mSATA is Logical Block Address of 58GB.  I'd like to move the /var directory to Partition c (unused). Can I assume FreeBSD follows a similar structure to Linux with using a /etc/fstab file to mounting partitions at boot? can I simply use the mkfs and tune2fs commands for this?

    Sorry to post a potentially obvious question. My experience is all Linux based as opposed to FreeBSD.



  • FreeBSD is very similar to Linux as far as the var in the filesystem.

    If you bought your boxes with Support, they may be able to help in getting you a quick solution.
    Otherwise, if you do a manual install you have full control over what partitions and what sizes you can create for pfSense.
    The other way is to create a new partition by hand , copy the contents from the current var and then update /etc/fstab to point var to the new partition (just like Linux).

    Just a thought about your filling drive problem, a :du -hd -1 /var will point you in the direction of the particular var folder that filled up your partition (again, very similar to Linux).



  • thanks Divsys
    the disk usage command screamed that /var/log was the culprit consuming all the free disk space. I will dig deeper and rotate the logs…after Easter. My intention is to move the /var dir to the separate free space partition on the internal mSATA drive. There's plenty of disk space there so why not!?

    have a great Easter everyone.  ;D


Log in to reply