[CentOS] how to prevent files and directories from being deleted?

Jonathan Billings billings at negate.org
Mon Oct 9 15:54:26 UTC 2017


On Mon, Oct 09, 2017 at 12:38:41PM +0200, hw wrote:
> I´m not whining, and it´s not my fault that someone came up with the
> extremely stupid idea to use a ramdisk for /var/run.  It´s also not my
> fault that lighttpd appears not to be packaged the way it would need to
> be, and the same goes for the mariadb packages provided for Centos by
> the mariadb people.
> 
> Perhaps you should complain to whomever made this change for not waiting
> until all packages have been modified and to the package managers who
> didn´t modify them before actually deploying it, for not to mention the
> stupidity of the idea, rather than accusing me of whining.

I think that the important learning points today are:

1.) CentOS7 (and any other distro that uses systemd) will have /run as
a tmpfs filesystem, and /var/run points to /run on CentOS7, so even if
you think this disagrees with the FHS, that's the way it is for
CentOS.

2.) If you are using non-CentOS packages (and that includes EPEL) to
run a service, you might need to create your own tmpfiles.d files.
This is just a fact of life now.  You can also file bugs against the
software telling them that /var/run is ephemeral so don't store
important files there.

3.) Systemd developers aren't going to sit around and wait for
developers to change how they put files.  They've made a lot of
significant changes to how systems are managed, for better or for
worst, and as people who maintain CentOS systems, we've got to learn
to use it appropriately.

There's a lot of conversations that end, "This is how it's done."
"But that's stupid!" "Well, tough, that's how it is..." when managing
computers, and I'm sure this won't be the last like it.  (I remember
early in my career wondering why creat() was spelled that way...)

-- 
Jonathan Billings <billings at negate.org>



More information about the CentOS mailing list