Description of problem: Bacula director seems to fail to start on F17 if it was configured to use MySql on F16. It appears to be trying to connect to Postgres though the bacula configuration file has not changed. Version-Release number of selected component (if applicable): bacula 5.2.6-2.fc17 How reproducible: Only tried it on my bacula host Steps to Reproduce: 1. Configure bacula on F16 using mysql 2. Upgrade to F17 Actual results: Bacula director exits logging messages that it could not open the catalog database, referencing line dird.c:959 postgresql.c:248 unable to connect to postgres server. Example: Jun 3 14:39:20 zen systemd[1]: Unit bacula-dir.service entered failed state. Jun 3 14:39:50 zen bacula-dir[2726]: bacula-dir: dird.c:954 Could not open Catalog "MyCatalog", database "bacula". Jun 3 14:39:50 zen bacula-dir[2726]: bacula-dir: dird.c:959 postgresql.c:248 Unable to connect to PostgreSQL server. Database=bacula User=bacula Jun 3 14:39:50 zen bacula-dir[2726]: Possible causes: SQL server not running; password incorrect; max_connections exceeded. Jun 3 14:39:50 zen bacula-dir[2726]: 03-Jun 14:39 bacula-dir ERROR TERMINATION Jun 3 14:39:50 zen bacula-dir[2726]: Please correct configuration file: /etc/bacula/bacula-dir.conf Jun 3 14:39:50 zen systemd[1]: bacula-dir.service: main process exited, code=exited, status=1 Expected results: Director to start correctly using its configured mysql server as it always has. Postgres is not running on this machine and never has been. Backups were running correctly immediately before the F17 upgrade. Additional Info: Specifying the mysql driver explicitly in the config file with dbdriver="dbi:mysql"; ..... does not help.
Are your "alternatives" settings right? # alternatives --display bacula-dir
Hmmm. That doesn't display anything. Does bacula use alternatives? I can't see evidence of this in the systemd unit. It just execs /usr/sbin/bacula-dir The packaging has definitely changed from F16 though so you could be right. What would I configure?
Ah yes, I seem to remember the packaging may have changed for F-17 and it's just the backend library that needs handling now (see README.Fedora from the bacula-common docs area): # alternatives --display libbaccats.so
Hello, Bacula has changed drastically regarding backend and libraries from 5.0x (f16) to 5.2.x (f17). Database backends are now handled by a single library and that is what is needed to manage the catalog. Just type: # alternatives --config libbaccats.so and choose your library backends; no changes are required in the config files. Regards, --Simone
Ok, that appears to be it. It seems to pick postgres regardless of which director rpm was installed in f16. I also had to run the db upgrade script from v12 to 14 manually after setting the alternative. The director is now up. Thanks for the help!
I'm building now the package in Koji for 5.2.7, when it is available in updates-testing please bear the following: The symlink library name has changed because we discovered a bug during version upgrades. Please issue the following before upgrading: alternatives --remove /usr/lib64/libbaccats-mysql-5.2.6.so alternatives --remove /usr/lib64/libbaccats-sqlite3-5.2.6.so alternatives --remove /usr/lib64/libbaccats-postgresql-5.2.6.so And then set again your preference database with: # alternatives --config libbaccats.so There are 3 programs which provide 'libbaccats.so'. Selection Command ----------------------------------------------- 1 /usr/lib64/libbaccats-mysql.so + 2 /usr/lib64/libbaccats-sqlite3.so * 3 /usr/lib64/libbaccats-postgresql.so Enter to keep the current selection[+], or type selection number: