Re: How are directories managed.
On Tue, Apr 12, 2011 at 7:26 AM, Paul Elliott
> This may be a FAQ but I could not find the answer in the documentation:
> How are directories managed? When does a directory get deleted? What is the
> lifetime of a directory? Is a directory owned by a specific package?
In case of apache2, config files present in /etc/apache2/ are "in"
apache2.2-common package. Removing this package deletes /etc/apache2/
and all files under it.
> Which packages are alowed to deposit files in a specific directory? What exactly
> are the rules?
That is specified in the debian policy.
> If a package wants to put files in a directory, how does the package "know"
> that the directory will live longer than the file?
You cant "put" files in a directory that does not exist. touch
/etc/foo/bar would fail if foo does not exist. Also you cant delete a
non empty directory, so a package can assume that directory will live
longer than the file(s) that it contain.