Bug 218126

Summary: sysutils/bareos-server 16.2.5 hangs forever on boot
Product: Ports & Packages Reporter: Matthias Petermann <matthias>
Component: Individual Port(s)Assignee: Jose Alonso Cardenas Marquez <acm>
Status: Closed FIXED    
Severity: Affects Some People CC: matthias
Priority: --- Flags: bugzilla: maintainer-feedback? (acm)
Version: Latest   
Hardware: amd64   
OS: Any   

Description Matthias Petermann 2017-03-25 21:04:38 UTC
Hello,

currently I experience a bareos-server related problem which:

 1) causes system to hang on boot (when enabled in rc.conf)
 2) renders a previously working bareos installation unusable

Here is what I found out so far:

When I start the director by:

    # service bareos-dir onestart

it only prints out:

    Performing sanity check on bareos-dir configuration:

and hangs there forever. This is problematic because this also causes the server to hang on boot.

On the other hand, when I perform the commands from /usr/local/etc/rc.d/bareos-dir manually the director starts up correctly and appears to be in working condition:

    # bareos-dir -u bareos -g bareos -v

(I dropped the -t flag as this seems to cause the freeze?).

When I comment out the start_precmd and restart_precmd from the rc.d script, I get the error referenced in Bug 217141. Then, after changing bareos_dir_config from:

    bareos_dir_config="/usr/local/etc/bareos/bareos-dir.d"
    
to

    bareos_dir_config="/usr/local/etc/bareos"
    
the daemon starts up correctly. Is anyone able to reproduce this issue?

Best regards,
Matthias
Comment 1 commit-hook freebsd_committer freebsd_triage 2017-04-21 17:48:04 UTC
A commit references this bug:

Author: acm
Date: Fri Apr 21 17:47:39 UTC 2017
New revision: 439102
URL: https://svnweb.freebsd.org/changeset/ports/439102

Log:
  - Fix rc script
  - Set default config file to %%PREFIX%%/etc/bareos/bareos-[dir|sd|fd].conf
    files. Set %%PREFIX%%/etc/bareos if you want to use new config style
  - Remove config file test on bareos-dir rc script. It fixed a problem on
    start/boot

  PR:		218126 217141
  Reported by:	Joakim Jalap <joakim.jalap at fastmail.com>
  		matthias at petermann-it.de
  		weberge42

Changes:
  head/sysutils/bareos-client/Makefile
  head/sysutils/bareos-client-static/Makefile
  head/sysutils/bareos-server/Makefile
  head/sysutils/bareos-server/files/bareos-dir.in
  head/sysutils/bareos-server/files/bareos-fd.in
  head/sysutils/bareos-server/files/bareos-sd.in