[pacman-dev] Lock file location

Dan McGee dpmcgee at gmail.com
Mon Jun 11 10:40:15 EDT 2007

Just thinking about this while changing some other stuff this morning
(permissions checking by libalpm and pacman). Here is the current
"default" situation:
DB Path: /var/lib/pacman/<dbname>
Lock file: /var/run/pacman.lck

Remember that the lock file formerly resided in /tmp/, but that is not
exactly a FHS-prescribed path. My proposal is this- when we create a
lock file, it is for one purpose- to lock the database. Perhaps we
should indicate this a bit better, and have one less path that needs
to be manually configured, by simply making the lock file a part of
the DB and generalizing the lock method to something that could
eventually use any backend? In an extreme case, we could lock each
individual DB seperately, but for now, a single lock file here:
would seem to suffice. Is this acceptable to everyone? The benefit it
gives us is if this location is writable, the DB is surely writable by
the user running pacman, and we can remove the dependence on the
pacman user being root. We will still need to do some permission
checking on install/pre-install, but I'll think about that later. :)


More information about the pacman-dev mailing list