Skip to content
This repository has been archived by the owner on Mar 19, 2021. It is now read-only.

Commit

Permalink
Merge pull request #5 from fbergkemper/bpipe
Browse files Browse the repository at this point in the history
bpipe
  • Loading branch information
joergsteffens committed Jan 6, 2014
2 parents b417ae9 + 14fe7ab commit d691669
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
23 changes: 23 additions & 0 deletions manuals/en/main/howto.tex
Expand Up @@ -756,3 +756,26 @@ \subsubsection{Backup of a MySQL Databases by using the bpipe plugin}
}
}
\end{bconfig}
If you do not want a direct restore of your data in your plugin directive, as shown in the examples above,
there is the possibility to restore the dump to the filesystem first, which offers you more control over the restore process, e.g.:
\begin{bconfig}{bpipe directive to backup a MySQL database and restore the dump to the filesystem first}
FileSet{
Name = "mysql-all"
Include {
Plugin = "bpipe:/MYSQL/dump.sql:mysqldump --host=<hostname> --user=<user> --password=<password> --opt --all-databases:/usr/lib/bareos/scripts/bpipe-restore.sh"
Options {
signature = MD5
compression = gzip
}
}
}
\end{bconfig}
A very simple corresponding shell script (bpipe-restore.sh) to the method above might look like the following one:
\begin{bconfig}{bpipe shell script for a restore to filesystem}
#!/bin/bash
cat - > /tmp/dump.sql
exit 0
\end{bconfig}
2 changes: 2 additions & 0 deletions manuals/en/main/plugins.tex
Expand Up @@ -68,3 +68,5 @@ \subsection{MSSQL Plugin}
See chapter \ilink{Backup Of MSSQL Databases}{MSSQL}.
Even keep in mind that currently the plugin command is being stored as part of the backup. The restore command in your directive
should be flexible enough if things might change in future, otherwise you could run into trouble.

0 comments on commit d691669

Please sign in to comment.