Subject: pkg/32204: bacula's postgresql-skripts not owned by pgsql
To: None <firstname.lastname@example.org, email@example.com,>
From: None <firstname.lastname@example.org>
Date: 11/30/2005 22:41:00
>Synopsis: bacula's postgresql-skripts not owned by pgsql
>Arrival-Date: Wed Nov 30 22:41:00 +0000 2005
>Originator: Stefan SCHUMACHER
>Release: NetBSD 3.0-Beta
NetBSD kaishakunin.homeunix.org 3.0_BETA NetBSD 3.0_BETA (KAISHAKUNIN) #2: Fri Nov 4 22:05:12 CET 2005 email@example.com:/usr/src/obj/sys/arch/i386/compile/KAISHAKUNIN i386
pkgsrc/sysutils/bacula installs skripts to setup the required PostgreSQL database. Those skripts (/usr/pkg/libexec/bacula/*postgresql*) are owned by root.wheel and can therefor not be executed by "pgsql".
PostgreSQL doesn't allow "root" to execute postmaster, so the skripts must be run by "pgsql". "pgsql" cannot access those skripts unless they are chgrp'ed to "pgsql".
This is a little bit tricky for sysadmins not that familiar with PostgreSQL user concepts.
Install bacula and try to setup the PostgreSQL database with the *postgresql* skripts as "pgsql".
chgrp pgsql /usr/pkg/libexec/bacula/*postgresql*
Another way would be to create the PostgreSQL-database automagically from pkgsrc when installing bacula. Currently "catalog-pgsql" as option is supported, maybe the database creation should be added to the Makefile or at least an option "create-pgsql-database" could be added.