Hello, list!

I have two jobs that back up a dump from a DB, one PostgreSQL DB and one 
OpenLDAP directory. In both cases, I try to backup using the 'dump to FIFO' 
method that is described in 
<http://wiki.bacula.org/doku.php?id=application_specific_backups:postgresql>. 
But instead of reading from the FIFO, Bareos copies the FIFO itself (having a 
size of 0 bytes). I have "ReadFIFO = yes" in the respective job definitions.

the director runs Bareos 16.2.4, the clients in question 15.2.2.

What do I need to do so that Bareos actually reads the FIFO and stores the 
output of the process writing to the FIFO instead of copying the FIFO as a FIFO?

Here is one of the job definitions:

---%<---
Job {
    Name = "OpenLDAP"
    JobDefs = "Yearly-Job-Defaults"
    Enabled = yes

    Client = "galathea-fd"
    FileSet = "OpenLDAP Database"

    RunScript {
        RunsWhen = Before
        Command = "/root/bin/ldap-backup-pre.sh"
    }

    RunScript {
        RunsWhen = After
        Command = "/root/bin/ldap-backup-post.sh"
    }

    Level = Full
}
--->%---

and here the pre-backup script I'm using:

---%<---
#!/bin/sh

set -e
set -o pipefail
set -x

DATE=$(date +"%Y-%m-%d")
LDAPDB_FIFO="/var/lib/ldap/ldapdb-$(hostname)-${DATE}.ldif"
orig_umask=$(umask)


cleanup()
{
        umask "$orig_umask"
        rm -f "$LDAPDB_FIFO"
}


trap "cleanup" ERR TERM KILL

mkfifo "$LDAPDB_FIFO"
slapcat -l "$LDAPDB_FIFO" > /dev/null 2>&1 &

umask "$orig_umask"
--->%---

Thanks alot in advance. Any hint is appreciated.

--- Eric

-- 
You received this message because you are subscribed to the Google Groups 
"bareos-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to