http://qs321.pair.com?node_id=1104168


in reply to Where to put an application database?

If you think that stuff getting blown away from /tmp isn't the case so much any more then you're in for a nasty surprise.

However, if your code isn't running as root, the logical place to put its data is in the application's home directory. It's fairly common for significant applications to have their own user, which has a home directory somewhere outside /home. For example my mail sewer runs as ...

Debian-exim:x:105:105::/var/spool/exim4:/bin/false

Note the home directory. Obviously this sort of thing has to be set up by root, but the application need not run as root.