tmpfs not working

Hi, I mount /tmp as tmpfs and then loaded the driver from /boot/loader.conf, but the system still writes to disk. Why is this happening?
 
Could you paste what df -h, mount | column -t and cat /etc/fstab say? It's hard to help someone without any information to go on.
 
It's not using tmpfs. It's still mounted on a partition on the disk.

You don't need to have anything in /boot/loader.conf. The driver will be loaded automatically if you have a valid /etc/fstab entry, which I suspect is missing in your case.
 
I tried with both 1777 and 777, it's the same.
mount
Code:
tmpfs on /tmp (tmpfs, local)
plus ZFS datasets.

df -h
Code:
Filesystem Size Used Avail Capacity Mounted on
Tmpfs 6,8G 4.0K 6,8G 0% /tmp
Strange fact is that the /tmp ZFS dataset shows 16M used.
 
If there's data in /tmp remove that first before mounting tmpfs(5) on it, make sure it's completely empty (it's best to do this in single user mode). Remove the ZFS /tmp filesystem. And the correct permissions are 1777, not 777. You need the sticky(7) bit too.
 
SirDice said:
Remove the ZFS /tmp filesystem.
It's probably that; tmpfs is mounted first then ZFS mounts over it. I wanted to check the output of mount to make sure before suggesting it.

rcorder /etc/rc.d/* /usr/local/etc/rc.d/*
Code:
/etc/rc.d/mdconfig
/etc/rc.d/hostid_save
/etc/rc.d/mountcritlocal # fstab mounting
/etc/rc.d/zfs            # zfs mounting
/etc/rc.d/var
/etc/rc.d/cleanvar
 
Back
Top