[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

RFD: use transient /var/run (tmpfs) or not?


I mounted /var/run on tmpfs to have it completely transient, 
performance boots, but mostly to wipe it out across system reboots.

An issue came up:

Some packages use subdirectories in /var/run and their fail to start if
those do not exist (e.g. mysql-server). See bug #272589

Some packages have init scripts checking for existence of /var/run
subdirectories and creating them if they don't exist at startup time.
(e.g. ssh, autofs).

For package hotplug I filled a bug some time ago which solved this issue 
(bug #228911, archived).

However, as mentioned in bug #272589, it is not clear whether directories
can be lost across reboot.

FHS says about /var/run:

/var/run : Run-time variable data

This directory contains system information data describing the system
since it was booted. Files under this directory must be cleared (removed
or truncated as appropriate) at the beginning of the boot process.
Programs may have a subdirectory of /var/run; this is encouraged for
programs that use more than one run-time file. [42] Process identifier
(PID) files, which were originally placed in /etc, must be placed in
/var/run. The naming convention for PID files is <program-name>.pid. For
example, the crond PID file is named /var/run/crond.pid.

I would like to know your opinion about this issue. Should debian packages
using subdirectories in /var/run/ check for their existence and create
them on startup, if they do not exist?

Imho they should. But as long as there are probably more packages where
it's an issue, and as long as FHS is not clear about this statement, I'd
like you to discuss this and make a decision.


Matus UHLAR - fantomas, uhlar@fantomas.sk ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
"One World. One Web. One Program." - Microsoft promotional advertisement
"Ein Volk, ein Reich, ein Fuhrer!" - Adolf Hitler

Reply to: