Memory disk permissions

I have FreeBSD 9.0-RELEASE installed on a Soekris Engineering NET5501, which boots off an 8GB compact flash, primarily as a small Asterisk system.

The operating system boots in read only mode to avoid too many writes to the compact flash, this was achieved by setting the following parameters in /etc/fstab:
Code:
# Device          Mountpoint          FsType          Options      Dump      Pass#
/dev/ada0p2    /                         ufs                 ro              1             1
I had issues with the system running out of space on and needed to increase the default memory disk size, this was done by adding the following to /etc/fstab:
Code:
/dev/ada0p2  /    ufs ro 1 1
/dev/md0     /var ufs rw 0 0
/dev/md1     /tmp ufs rw 0 0
and making the following changes to /etc/rc.conf:
Code:
mdconfig_md0="-t swap -s 64m"
mdconfig_md1="-t swap -s 32m"
The problem I have now is that on boot up the system mounts /tmp with permissions 755 and so asterisk cannot write to the tmp partition when receiving faxes.

The manual fix is to: chown -R 777 /tmp which fixes the issue until reboot, could anyone provide a tip on how to make this persistent so the system always boots with /tmp permissions as 777?

Thanks in advance
 
The manual fix is to: chown -R 777 /tmp which fixes the issue until reboot, could anyone provide a tip on how to make this persistent so the system always boots with /tmp permissions as 777?
Permissions for /tmp/ should be 1777. The sticky(7) bit has to be set too.

Not sure if this is the solution but try this in /etc/fstab:
Code:
/dev/md1     /tmp ufs rw,mode=1777 0 0

And please note that FreeBSD 9.0 is end-of-life since March 2013 and not supported any more. That means no security updates and no guarantee ports build correctly.
 
Back
Top