Solved is tmpfs /var/run/user in fstab possible?

So I need to use tmpfs for /var/run so I can have hyprland running on ZFS.
It works, but it feels kinda dirty to hijack the whole /var/run while I only need /var/run/user/ for hyprland to run.

Is it possible to somehow mount /var/run/user instead of /var/run in fstab?
 
got it working by mounting tmpfs /var/run/user via rc.local
I had no idea you can do that, rc.local is pretty goated
 
/var/run/ is basically a scratch directory that stores anything required within runtime only, so "basically" it can be completely erased on shutdown.

But some ports abuses it to have permanent directory, thus, /etc/rc.d/var_run script exists (need configuration in /etc/rc.conf).

The purpose of the script is to create directory hierarchy data and re-creates the hierarchy on boot. If I recall correctly, you'll need to run service var_run save before configuring /var/run to be tmpfs.

In my humble opinion, ALL ports that wants promising subdirectory under /var/run should have rc.d script (basically in /usr/local/etc/rc.d, as ports are not base) and create it on startup. Some may be to just created the directory if nonexistent or cleanup if any remnants remained, though.
 
Was there really a necessity of having /var/run on tmpfs by hyprland?. i use some other wayland compositor and there is no such requirement. However I do tend to agree that /var/run can be indeed ephemeral and on tmpfs, however /var in default installation is a zfs mount so you need to alter defaults to achieve this
 
Back
Top