Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 12 Jan 2017 13:12:23 +0100
From:      Christian Schwarz <me@cschwarz.com>
To:        freebsd-ports@freebsd.org
Subject:   Preferred directory for server data (/var/db/pkgname?)
Message-ID:  <20170112121223.fupbtizrp3ne5ouz@csarch>

next in thread | raw e-mail | index | archive | help
What is the correct directory for storing the state of a server application?

That might be

 - the data directory of a database server
   (MySQL uses /var/db/mysql
    Postgres uses /var/db/postgres)
 - Configuration managed by the application, not the admin
   (Quassel uses /var/db/quasselcore)
 - net-im/prosody curiously uses /usr/local/var/lib/prosody
   to store application-managed state data [1]

I am writing this because I stumbled over the net-im/prosody path,
which I think is not intuitive given the behavior of other ports.

But before I submit my patch for this, I would like to know if there is an
actual policy in place.

Taking a look at hier(7):

>/var/          multi-purpose log, temporary, transient, and spool files
>
>				[...]
>
>                db/            miscellaneous automatically generated
>                               system-specific database files

Doesn't seem like the above cases match this description.

Interestingly, the Arch Linux hier(7) has an entry for this kind of data:

> /var/lib/<package>
>        State data for packages and subsystems (optional).

What do you think?

--
Christian Schwarz



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20170112121223.fupbtizrp3ne5ouz>