If you are upgrading from one Bacula version to another, you should first carefully read the ReleaseNotes of all major versions between your current version and the version to which you are upgrading. In many upgrades, especially for minor patch upgrades (e.g. between 3.0.0 and 3.0.1) there will be no database upgrade, and hence the process is rather simple.
With version 3.0.0 and later, you must ensure that on any one machine that all components of Bacula are running on exactly the same version. Prior to version 3.0.0, it was possible to run a lower level FD with a newer Director and SD. This is no longer the case.
As always, we attempt to support older File daemons. This avoids the need to do a simultaneous upgrade of many machines. For exactly what older versions of the FD are supported, please see the ReleaseNotes for the new version. In any case, you must always upgrade both the Director and the Storage daemon at the same time, and you must also upgrade any File daemon that is running on the same machine as a Director or a Storage daemon (see the prior paragraph).
If the Bacula catalog database has been upgraded (as it is almost every major release), you will either need to reinitialize your database starting from scratch (not normally a good idea), or save an ASCII copy of your database, then proceed to upgrade it. If you are upgrading two major versions (e.g. 1.36 to 2.0) then life will be more complicated because you must do two database upgrades. See below for more on this.
Upgrading the catalog is normally done after Bacula is build and installed by:
cd <installed-scripts-dir> (default /etc/bacula) ./update_bacula_tables
This update script can also be find in the Bacula source src/cats directory.
If you are upgrading from a very old version of Bacula, there may be several catalog database updates needed to go from your existing catalog format to the new one. The ./update_bacula_tables script will automatically do the updates for you one at a time.
If you are upgrading from one major version to another, you will need to replace all your components at the same time as generally the inter-daemon protocol will change. However, within any particular release (e.g. version 1.32.x) unless there is an oversight or bug, the daemon protocol will not change. If this is confusing, simply read the ReleaseNotes very carefully as they will note if all daemons must be upgraded at the same time.
Finally, please note that in general it is not necessary or desirable to do a make uninstall before doing an upgrade providing you are careful not to change the installation directories. In fact, if you do so, you will most likely delete all your conf files, which could be disastrous.
The normal procedure depends on whether you previously installed binary packages, in which case, you will use the update option to install the newer packages. If you installed from souce please follow the following steps:
./configure (your options) make make install
In general none of your existing .conf or .sql files will be overwritten, and you must do both the make and make install commands, a make install without the preceding make will not work.
We recommend the following base options for the ./configure that you run to configure how the make process will install Bacula.
#!/bin/sh # This is the recommended configure script for Bacula PREFIX=/opt/bacula CFLAGS="-g -O2 -Wall" \ ./configure \ --sbindir=${PREFIX}/bin \ --sysconfdir=${PREFIX}/etc \ --docdir=${PREFIX}/html \ --htmldir=${PREFIX}/html \ --with-working-dir=${PREFIX}/working \ --with-pid-dir=${PREFIX}/working \ --with-scriptdir=${PREFIX}/scripts \ --with-plugindir=${PREFIX}/plugins \ --libdir=${PREFIX}/lib \ --enable-smartalloc \ --enable-conio \ --enable-bat \ --with-postgresql \ --with-dump-email=email@example.com \ --with-job-email=email@example.com \ --with-smtp-host=mail.example.com \ --with-baseport=9101 exit 0
Note: you should adjust the email addresses to correspond to the address to which you would like Bacula to send you mail. Also, you must have the correct Qt5 libraries pre-loaded. If not, remove the line "-enable-bat".
major.minor.release
For example:
1.38.11
where each component (major, minor, patch) is a number. The major number is currently 1 and normally does not change very frequently. The minor number starts at 0 and increases each for each production release by 2 (i.e. it is always an even number for a production release), and the patch number is starts at zero each time the minor number changes. The patch number is increased each time a bug fix (or fixes) is released to production.
So, as of this date (05 May 2019), the current production Bacula release is version 11.0.3. If there are bug fixes, the next release will be 11.0.2 (i.e. the patch number has increased by one).
For all patch releases where the minor version number does not change, the database and all the daemons will be compatible. That means that you can safely run a 11.0.2 Director with a 11.0.0 Client. Of course, in this case, the Director may have bugs that are not fixed. Generally, within a minor release (some minor releases are not so minor), all patch numbers are officially released to production. This means that while the current Bacula version is 11.0.3, versions 11.0.0, 11.0.1, and 11.0.2 have been previously released.
When the minor number is odd, it indicates that the package is under development and thus may not be stable. For example, while the current production release of Bacula is currently 11.0.2, the current development version is 9.5.x. All patch versions of the development code are available in the SVN (source repository). However, not all patch versions of the development code (odd minor version) are officially released. When they are released, they are released as beta versions (see below for a definition of what beta means for Bacula releases).
In general when the minor number increases from one production release to the next (i.e. 9.2.5 to 11.0.0), the catalog database must be upgraded, the Director and Storage daemon must always be on the same minor release number, and often (not always), the Clients must also be on the same minor release. As often as possible, we attempt to make new releases that are downwards compatible with prior clients, but this is not always possible. You must check the release notes. In general, you will have fewer problems if you always run all the components on the same minor version number (i.e. all either 9.2.x or 11.0.x but not mixed).
As discussed above, we have combined a number of third party packages that Bacula might need into the depkgs release. You can, of course, get the latest packages from the original authors or from your operating system supplier. The locations of where we obtained the packages are in the README file in each package. However, be aware that the packages in the depkgs files have been tested by us for compatibility with Bacula.
Typically, a dependency package will be named depkgs-ddMMMyy.tar.gz where dd is the day we release it, MMM is the abbreviated month (e.g. Jan), and yy is the year. An actual example is: depkgs-18Dec.tar.gz. To install and build this package (if needed), you do the following:
Although the exact composition of the dependency packages may change from time to time, the current makeup is the following:
3rd Party Package | depkgs | depkgs-qt |
mtx | X | |
qt4 | X |
Note, some of these packages are quite large, so that building them can be a bit time consuming. The above instructions will build all the packages contained in the directory. However, when building Bacula, it will take only those pieces that it actually needs.
Alternatively, you can make just the packages that are needed. For example,
cd bacula/depkgs make qt4
will configure and build only the QT4 package.
You should build the packages that you will require in depkgs a prior to configuring and building Bacula, since Bacula will need them during the build process.
Note, the depkgs-qt package is required for building bat, because bat is currently built with Qt version 4.3.4. It can be built with other Qt versions, but that almost always creates problems or introduces instabilities.
You can build the depkgs-qt with the following:
cd bacula tar xfvz depkgs-qt-28Jul09.tar.gz cd depkgs-qt make qt4 source qt4-path
Doing the source qt4-path defines the following environment variables:
QTDIR QTLIB QTINC
Each one should point to a specific location in the depkgs-qt package that you loaded. It also puts the depkgs-qt/qt4/bin directory on your path before all other directories. This ensures that the bat build will use your Qt 4.3.4 library rather than any that might be on your system.
Before running your Bacula build, please make sure that qmake-qt4 is not on your path. If it is please rename it. If you don't do this, Bacula will attempt to build with any Qt5 package installed on your system rather than the one you just built. If you logoff and log back in, you must re-source the depkgs-qt/qt4-patch file before attempting to rebuild the bat part of Bacula.
For more information on the depkgs-qt package, please read the INSTALL file in the main directory of that package. If you are going to build Qt5 using depkgs-qt, you must source the qt5-paths file included in the package prior to building Bacula. Please read the INSTALL file for more details.
You might find it worthwhile to build mtx because the tapeinfo program that comes with it can often provide you with valuable information about your SCSI tape drive (e.g. compression, min/max block sizes, ...). Note, most distros provide mtx as part of their release.
The depkgs1 package is depreciated and previously contained readline, which should be available on all operating systems.
The depkgs-win32 package is deprecated and no longer used in Bacula version 1.39.x and later. It was previously used to build the native Win32 client program, but this program is now built on Linux systems using cross-compiling. All the tools and third party libraries are automatically downloaded by executing the appropriate scripts. See src/win32/README.mingw32 for more details.
Please see the Supported Operating Systems section of the QuickStart chapter of this manual.
The basic installation is rather simple.
Note, if you already have a running MySQL or PostgreSQL on your system, you can skip this phase provided that you have built the thread safe libraries. And you have already installed the additional rpms noted above.
make distclean
so that you are sure to start from scratch and not have a mixture of the two options. This is because ./configure caches much of the information. The make distclean is also critical if you move the source directory from one machine to another. If the make distclean fails, just ignore it and continue on.
If you skip this step (make) and proceed immediately to the make install you are making two serious errors: 1. your install will fail because Bacula requires a make before a make install. 2. you are depriving yourself of the chance to make sure there are no errors before beginning to write files to your system directories.
make uninstall make distclean ./configure (your-new-options) make make install
If all goes well, the ./configure will correctly determine which operating system you are running and configure the source code appropriately. Currently, FreeBSD, Linux (Red Hat), and Solaris are supported. The Bacula client (File daemon) is reported to work with MacOS X 10.3 is if readline support is not enabled (default) when building the client.
If you install Bacula on more than one system, and they are identical, you can simply transfer the source tree to that other system and do a "make install". However, if there are differences in the libraries or OS versions, or you wish to install on a different OS, you should start from the original compress tar file. If you do transfer the source tree, and you have previously done a ./configure command, you MUST do:
make distclean
prior to doing your new ./configure. This is because the GNU autoconf tools cache the configuration, and if you re-use a configuration for a Linux machine on a Solaris, you can be sure your build will fail. To avoid this, as mentioned above, either start from the tar file, or do a "make distclean".
In general, you will probably want to supply a more complicated configure statement to ensure that the modules you want are built and that everything is placed into the correct directories.
For example, on Fedora, Red Hat, or SuSE one could use the following:
CFLAGS="-g -Wall" \ ./configure \ --sbindir=/opt/bacula/bin \ --sysconfdir=/opt/bacula/etc \ --with-pid-dir=/var/run \ --with-subsys-dir=/var/run \ --with-mysql \ --with-working-dir=/opt/bacula/working \ --with-dump-email=$USER
The advantage of using the above configuration to start is that everything will be put into a single directory, which you can later delete once you have run the examples in the next chapter and learned how Bacula works. In addition, the above can be installed and run as non-root.
For the developer's convenience, I have added a defaultconfig script to the examples directory. This script contains the statements that you would normally use, and each developer/user may modify them to suit his needs. You should find additional useful examples in this directory as well.
The --
enable-conio or --
enable-readline options are useful because they provide a command line history, editing capability for the Console program and tab completion on various option. If you have included either option in the build, either the termcap or the ncurses package will be needed to link. On most systems, including Red Hat and SuSE, you should include the ncurses package. If Bacula's configure process finds the ncurses libraries, it will use those rather than the termcap library. On some systems, such as SuSE, the termcap library is not in the standard library directory. As a consequence, the option may be disabled or you may get an error message such as:
/usr/lib/gcc-lib/i586-suse-linux/3.3.1/.../ld: cannot find -ltermcap collect2: ld returned 1 exit status
while building the Bacula Console. In that case, you will need to set the LDFLAGS environment variable prior to building.
export LDFLAGS="-L/usr/lib/termcap"
The same library requirements apply if you wish to use the readline subroutines for command line editing, history and tab completion or if you are using a MySQL library that requires encryption. If you need encryption, you can either export the appropriate additional library options as shown above or, alternatively, you can include them directly on the ./configure line as in:
LDFLAGS="-lssl -lcyrpto" \ ./configure <your-options>
On some systems such as Mandriva, readline tends to gobble up prompts, which makes it totally useless. If this happens to you, use the disable option, or if you are using version 1.33 and above try using --
enable-conio to use a built-in readline replacement. You will still need either the termcap or the ncurses library, but it is unlikely that the conio package will gobble up prompts.
readline is no longer supported after version 1.34. The code within Bacula remains, so it should be usable, and if users submit patches for it, we will be happy to apply them. However, due to the fact that each version of readline seems to be incompatible with previous versions, and that there are significant differences between systems, we can no longer afford to support it.
If you wish to use MySQL as the Bacula catalog, please see the Installing and Configuring MySQL chapter of this manual. You will need to install MySQL prior to continuing with the configuration of Bacula. MySQL is a high quality database that is very efficient and is suitable for small and medium sized installation (up to 2,000,000 files per job).
If you wish to use PostgreSQL as the Bacula catalog, please see the Installing and Configuring PostgreSQL chapter of this manual. You will need to install PostgreSQL prior to continuing with the configuration of Bacula. PostgreSQL is very similar to MySQL, though it tends to be slightly more SQL92 compliant and has more advanced features such as DDL support in transactions. It requires a certain knowledge to install and maintain. PostgreSQL is suitable for any sized installation (some sites have much more than 1 billion objects in the Catalog). Bacula uses many optimized PostgreSQL functions, and can run more than 10 time faster on jobs having millions of files than MySQL (Specially in during restore, accurate mode, bvfs queries and when the database server is not on the same host than the Director).
There are a number of options and important considerations given below that you can skip for the moment if you have not had any problems building Bacula with a simplified configuration as shown above.
If the ./configure process is unable to find specific libraries (e.g. libintl, you should ensure that the appropriate package is installed on your system. Alternatively, if the package is installed in a non-standard location (as far as Bacula is concerned), then there is generally an option listed below (or listed with "./configure - -help" that will permit you to specify the directory that should be searched. In other cases, there are options that will permit you to disable to feature (e.g. - -disable-nls).
If you want to dive right into it, we recommend you skip to the next chapter, and run the example program. It will teach you a lot about Bacula and as an example can be installed into a single directory (for easy removal) and run as non-root. If you have any problems or when you want to do a real installation, come back to this chapter and read the details presented below.
The following command line options are available for configure to customize your installation.
Please note that Bacula attempts to make the configuration directory secure by doing an:
chmod 770 <sysconfdir>
So, if you make sysconfdir point to a global directory such as /usr/local/etc, the modes for that directory will be restricted, and this may affect other programs that are installed there. We strongly recommend that you set sysconfdir to /opt/bacula/etc so that the directory for all Bacula configuration files is unique to Bacula and used only by Bacula.
By default, Bacula will install the Unix man pages in /usr/share/man/man1 and /usr/share/man/man8. If you wish the man page to be installed in a different location, use this option to specify the path. Note, the main HTML and PDF Bacula documents are in a separate tar file that is not part of the source distribution.
Qt5 is available on OpenSUSE, CentOS , Fedora, and Debian. If it is not available on your system, you can download the depkgs-qt package from the Bacula Source Forge download area and build it. See the INSTALL file in that package for more details. In particular to use the Qt5 built by depkgs-qt you must source the file qt5-paths.
On most systems, MySQL and PostgreSQLare thread safe.
To verify that your PostgreSQL is thread safe, you can try this (change the path to point to your particular installed libpq.a; these commands were issued on FreeBSD 6.2):
$ nm /usr/local/lib/libpq.a | grep PQputCopyData 00001b08 T PQputCopyData $ nm /usr/local/lib/libpq.a | grep mutex U pthread_mutex_lock U pthread_mutex_unlock U pthread_mutex_init U pthread_mutex_lock U pthread_mutex_unlock
The above example shows a libpq that contains the required function PQputCopyData and is thread enabled (i.e. the pthread_mutex* entries). If you do not see PQputCopyData, your version of PostgreSQL is too old to allow batch insert. If you do not see the mutex entries, then thread support has not been enabled. Our tests indicate you usually need to change the configuration options and recompile/reinstall the PostgreSQL client software to get thread support.
Bacula always links to the thread safe MySQL libraries.
Running with Batch Insert turned on is recommended because it can significantly improve attribute insertion times. However, it does put a significantly larger part of the work on your SQL engine, so you may need to pay more attention to tuning it. In particular, Batch Insert can require large temporary table space, and consequently, the default location (often /tmp) may run out of space causing errors. For MySQL, the location is set in my.conf with "tmpdir". You may also want to increase the memory available to your SQL engine to further improve performance during Batch Inserts.
--
disable-static-tools.
--
enable-client-only option described below is useful for just building a client so that all the other parts of the program are not compiled. When linking a static binary, the linker needs the static versions of all the libraries that are used, so frequently users will experience linking errors when this option is used. The first thing to do is to make sure you have the static glibc library installed on your system. The second thing to do is the make sure you do not specify -openssl or other options on your ./configure statement as these options require additional libraries. You may be able to enable those options, but you will need to load additional static libraries.
When linking a static binary, the linker needs the static versions of all the libraries that are used, so frequently users will experience linking errors when this option is used. The first thing to do is to make sure you have the static glibc library installed on your system. The second thing to do is the make sure you do not specify -openssl or othyer options on your ./configure statement as these options require additional libraries. You may be able to enable those options, but you will need to load additional static libraries.
When linking a static binary, the linker needs the static versions of all the libraries that are used, so frequently users will experience linking errors when this option is used. The first thing to do is to make sure you have the static glibc library installed on your system. The second thing to do is the make sure you do not specify -openssl or other options on your ./configure statement as these options require additional libraries. You may be able to enable those options, but you will need to load additional static libraries.
When linking a static binary, the linker needs the static versions of all the libraries that are used, so frequently users will experience linking errors when this option is used. The first thing to do is to make sure you have the static glibc library installed on your system. The second thing to do is the make sure you do not specify -openssl or other options on your ./configure statement as these options require additional libraries. You may be able to enable those options, but you will need to load additional static libraries.
When linking a static binary, the linker needs the static versions of all the libraries that are used, so frequently users will experience linking errors when this option is used. The first thing to do is to make sure you have the static glibc library installed on your system. The second thing to do is the make sure you do not specify -openssl or other options on your ./configure statement as these options require additional libraries. You may be able to enable those options, but you will need to load additional static libraries.
--
disable-largefile.
See the note below under the -with-postgresql item.
Note, for Bacula to be configured properly, you must specify one of the two database options supported. That is: -with-postgresql, otherwise the ./configure will fail.
If you get errors linking, you need to load the development libraries, or you need to disable SSL by setting without-openssl.
For more information on configuring and testing TCP wrappers, please see the Configuring and Testing TCP Wrappers section in the Security Chapter.
On SuSE, the libwrappers libraries needed to link Bacula are contained in the tcpd-devel package. On Red Hat, the package is named tcp_wrappers.
This option is designed primarily for use in regression testing. Most users can safely ignore this option.
--
with-baseport option will automatically assign three ports beginning at the base port address specified. You may also change the port number in the resulting configuration files. However, you need to take care that the numbers correspond correctly in each of the three daemon configuration files. The default base port is 9101, which assigns ports 9101 through 9103. These ports (9101, 9102, and 9103) have been officially assigned to Bacula by IANA. This option is only used to modify the daemon configuration files. You may also accomplish the same thing by directly editing them later.
Note, many other options are presented when you do a ./configure --
help, but they are not implemented.
For most systems, we recommend starting with the following options:
./configure \ --enable-smartalloc \ --sbindir=/opt/bacula/bin \ --sysconfdir=/opt/bacula/etc \ --with-pid-dir=/opt/bacula/working \ --with-subsys-dir=/opt/bacula/working \ --with-working-dir=/opt/bacula/working
If you want to install Bacula in an installation directory rather than run it out of the build directory (as developers will do most of the time), you should also include the --
sbindir and --
sysconfdir options with appropriate paths. Neither are necessary if you do not use "make install" as is the case for most development work. The install process will create the sbindir and sysconfdir if they do not exist, but it will not automatically create the pid-dir, subsys-dir, or working-dir, so you must ensure that they exist before running Bacula for the first time.
or
CFLAGS="-g -Wall" ./configure \ --sbindir=/opt/bacula/bin \ --sysconfdir=/opt/bacula/etc \ --enable-smartalloc \ --with-mysql \ --with-working-dir=/opt/bacula/working --with-pid-dir=/opt/bacula/working \ --with-subsys-dir=/opt/bacula/working --enable-readline
or finally, a completely traditional Red Hat Linux install, which we do not recommend, because it make it harder to backup Bacula for disaster recovery purposes:
CFLAGS="-g -Wall" ./configure \ --sbindir=/usr/sbin \ --sysconfdir=/etc/bacula \ --with-scriptdir=/etc/bacula \ --enable-smartalloc \ --enable-bat \ --with-mysql \ --with-working-dir=/var/bacula \ --with-pid-dir=/var/run \ --enable-readline
Note, Bacula assumes that /var/bacula, /var/run, and /var/lock/subsys exist so it will not automatically create them during the install process.
To build Bacula from source, you will need the following installed on your system (they are not by default): libiconv, gcc 3.3.2, stdc++, libgcc (for stdc++ and gcc_s libraries), make 3.8 or later.
You will probably also need to: Add /usr/local/bin to PATH and Add /usr/ccs/bin to PATH for ar.
It is possible to build Bacula on Solaris with the Solaris compiler, but we recommend using GNU C++ if possible.
A typical configuration command might look like:
#!/bin/sh CFLAGS="-g" ./configure \ --sbindir=/opt/bacula/bin \ --sysconfdir=/opt/bacula/etc \ --with-mysql \ --enable-smartalloc \ --with-pid-dir=/opt/bacula/working \ --with-subsys-dir=/opt/bacula/working \ --with-working-dir=/opt/bacula/working
Note, you may need to install the following packages to build Bacula from source:
SUNWbinutils, SUNWarc, SUNWhea, SUNWGcc, SUNWGnutls SUNWGnutls-devel SUNWGmake SUNWgccruntime SUNWlibgcrypt SUNWzlib SUNWzlibs SUNWreadline SUNWbinutilsS SUNWGmakeS SUNWlibm export PATH=/usr/bin::/usr/ccs/bin:/etc:/usr/openwin/bin:/usr/local/bin:/usr/sfw/bin:/opt/sfw/bin:/usr/ucb:/usr/sbin
If you have installed special software not normally in the Solaris libraries, such as OpenSSL, or the packages shown above, then you may need to add /usr/sfw/lib to the library search path. Probably the simplest way to do so is to run:
setenv LDFLAGS "-L/usr/sfw/lib -R/usr/sfw/lib"
Prior to running the ./configure command.
Alternatively, you can set the LD_LIBARY_PATH and/or the LD_RUN_PATH environment variables appropriately.
It is also possible to use the crle program to set the library search path. However, this should be used with caution.
Please see: The FreeBSD Diaryhttp://www.freebsddiary.org/bacula.php for a detailed description on how to make Bacula work on your system. In addition, users of FreeBSD prior to 4.9-STABLE dated Mon Dec 29 15:18:01 2003 UTC who plan to use tape devices, please see the Tape Testing chapter of the Problems manual forimportant information on how to configure your tape drive for compatibility with Bacula.
If you are using Bacula with MySQL, you should take care to compile MySQL with FreeBSD native threads rather than LinuxThreads, since Bacula is normally built with FreeBSD native threads rather than LinuxTreads. Mixing the two will probably not work.
To install the binary Win32 version of the File daemon please see the Win32 Installation Chapter in this document.
The following script could be used if you want to put everything in a single directory (except for the working directory):
#!/bin/sh CFLAGS="-g -Wall" \ ./configure \ --sbindir=$HOME/bacula/bin \ --sysconfdir=$HOME/bacula/bin \ --mandir=$HOME/bacula/bin \ --enable-smartalloc \ --enable-bat \ --with-pid-dir=$HOME/bacula/bin/working \ --with-subsys-dir=$HOME/bacula/bin/working \ --with-mysql \ --with-working-dir=$HOME/bacula/bin/working \ --with-dump-email=$USER@your-site.com \ --with-job-email=$USER@your-site.com \ --with-smtp-host=mail.your-site.com exit 0
You may also want to put the following entries in your /etc/services file as it will make viewing the connections made by Bacula easier to recognize (i.e. netstat -a):
bacula-dir 9101/tcp bacula-fd 9102/tcp bacula-sd 9103/tcp
Before setting up your configuration files, you will want to install Bacula in its final location. Simply enter:
make install
If you have previously installed Bacula, the old binaries will be overwritten, but the old configuration files will remain unchanged, and the "new" configuration files will be appended with a .new. Generally if you have previously installed and run Bacula you will want to discard or ignore the configuration files with the appended .new.
If you run the Director and the Storage daemon on one machine and you wish to back up another machine, you must have a copy of the File daemon for that machine. If the machine and the Operating System are identical, you can simply copy the Bacula File daemon binary file bacula-fd as well as its configuration file bacula-fd.conf then modify the name and password in the conf file to be unique. Be sure to make corresponding additions to the Director's configuration file (bacula-dir.conf).
If the architecture or the OS level are different, you will need to build a File daemon on the Client machine. To do so, you can use the same ./configure command as you did for your main program, starting either from a fresh copy of the source tree, or using make distclean before the ./configure.
Since the File daemon does not access the Catalog database, you can remove the --
with-mysql ption, then add --
enable-client-only. This will compile only the necessary libraries and the client programs and thus avoids the necessity of installing one or another of those database programs to build the File daemon. With the above option, you simply enter make and just the client will be built.
If you wish the daemons to be automatically started and stopped when your system is booted (a good idea), one more step is necessary. First, the ./configure process must recognize your system - that is it must be a supported platform and not unknown, then you must install the platform dependent files by doing:
(become root) make install-autostart
Please note, that the auto-start feature is implemented only on systems that we officially support (currently, FreeBSD, Red Hat/Fedora Linux, and Solaris), and has only been fully tested on Fedora Linux.
The make install-autostart will cause the appropriate startup scripts to be installed with the necessary symbolic links. On Red Hat/Fedora Linux systems, these scripts reside in /etc/rc.d/init.d/bacula-dir /etc/rc.d/init.d/bacula-fd, and /etc/rc.d/init.d/bacula-sd. However the exact location depends on what operating system you are using.
If you only wish to install the File daemon, you may do so with:
make install-autostart-fd
To simply build a new executable in any directory, enter:
make
To clean out all the objects and binaries (including the files named 1, 2, or 3, which are development temporary files), enter:
make clean
To really clean out everything for distribution, enter:
make distclean
note, this cleans out the Makefiles and is normally done from the top level directory to prepare for distribution of the source. To recover from this state, you must redo the ./configure in the top level directory, since all the Makefiles will be deleted.
To add a new file in a subdirectory, edit the Makefile.in in that directory, then simply do a make. In most cases, the make will rebuild the Makefile from the new Makefile.in. In some case, you may need to issue the make a second time. In extreme cases, cd to the top level directory and enter: make Makefiles.
To add dependencies:
make depend
The make depend appends the header file dependencies for each of the object files to Makefile and Makefile.in. This command should be done in each directory where you change the dependencies. Normally, it only needs to be run when you add or delete source or header files. make depend is normally automatically invoked during the configuration process.
To install:
make install
This not normally done if you are developing Bacula, but is used if you are going to run it to backup your system.
After doing a make install the following files will be installed on your system (more or less). The exact files and location (directory) for each file depends on your ./configure command.
NOTE: it is quite probable that this list is out of date. But it is a starting point.
bacula bacula-dir bacula-dir.conf bacula-fd bacula-fd.conf bacula-sd bacula-sd.conf bextract bls bscan btape btraceback btraceback.gdb bconsole bconsole.conf create_mysql_database dbcheck delete_catalog_backup drop_bacula_tables drop_mysql_tables make_bacula_tables make_catalog_backup make_mysql_tables mtx-changer query.sql bsmtp startmysql stopmysql bwx-console bwx-console.conf 9 man pages
See the chapter Configuring Bacula in this manual for instructions on how to set Bacula configuration files.