[arch-general] [PATCHES] About /var/run/ and /var/lock/ checks in daemons

Gerardo Exequiel Pozzi vmlinuz386 at yahoo.com.ar
Sat Feb 14 15:59:30 EST 2009


Xavier wrote:
> Now we already have 2 devs, JGC and Pierre who seem to be against this
> proposal, and who recommended you to just populate /var/run and others
> based on an initial directory.
> Then two users reported they were already using tmpfs with no
> problems. Jan Spakula posted his modified rc.sysinit and rc.shutdown,
> and Nicolas said he just wrote a separate rc script to do that syncing
> job.
> I am not against your proposal, but you did not make clear what its
> advantages are, and why it is worth the additional complexity?
>
>   
As I said earlier, depending on how we interpret the standards of the FHS.

And here I __apologize__, my English for write is not very good because
it is not my native language, in fact I am using the google translator
to help me (hehe), so if in any part of my message tone offense was not,
not is my intention offend any user and your proposed solutions. [@]

If the initial content of the /var/run must be completely empty at boot
or must persist directories but not files.
This can be seen in the behavior of various programs. Some create the
appropriate directory in /var/run and work well, but fail if no other
before.
Some programs, when completed, left files in there, and others are "well
educated" and delete its contents. So, here comes in the task of the
startup script to delete those files.
My personal interpretation is that the directories in there, are
generated at runtime, and these can be eliminated without any problems.
(Clearly this is not true, as I said above many programs fail)

Well, therefore, the benefit of each program is responsible for creating
the temporary directory, if that does not exist, it allows two things:
* The contents of the directory can be deleted without any exceptions.
* This directory can be mounted as tmpfs with the simple addition of a
line in the fstab and also has the advantage of removing the need to
erase the contents in the boot.
This behavior of erase or not, could be controlled with a simple check
fstab or switch in rc.conf (this also applies to /var/lock (1777) and
the most problematic for deletion: the "Mr /tmp")
* Any other purpose.

[@] Ok that cleared, I will say this: The solution of copying
temporal/run-time data of the /var/run for mounting this as tmpfs i do
not think a clean solution, but if it works of course :)
My idea behind this is that each program do its work to function properly.

Thanks for your time ;)


-- 
Gerardo Exequiel Pozzi ( djgera )
http://www.djgera.com.ar
KeyID: 0x1B8C330D
Key fingerprint = 0CAA D5D4 CD85 4434 A219  76ED 39AB 221B 1B8C 330D



More information about the arch-general mailing list