13b78d
======== Quick installation guide with the default PostgreSQL backend ========
13b78d
13b78d
Perform the following commands to install Bacula with its default configuration
13b78d
and all daemons and consoles in one server.
13b78d
13b78d
1) Install packages
13b78d
13b78d
# yum -y install postgresql-server \
13b78d
    bacula-director bacula-storage bacula-client \
13b78d
    bacula-console bacula-console-bat
13b78d
13b78d
2) Select the PostgreSQL database backend
13b78d
13b78d
# alternatives --set libbaccats.so /usr/lib64/libbaccats-postgresql.so
13b78d
13b78d
3) Create database
13b78d
13b78d
# postgresql-setup initdb
13b78d
# systemctl enable postgresql.service
13b78d
# systemctl start postgresql.service
13b78d
13b78d
# su - postgres
13b78d
$ cd /usr/libexec/bacula
13b78d
$ ./create_bacula_database
13b78d
$ ./make_bacula_tables
13b78d
$ ./grant_bacula_privileges
13b78d
13b78d
4) Change passwords in /etc/bacula/*.conf with something you like.
13b78d
13b78d
# sed -i -e 's/@@DIR_PASSWORD@@/dir-password/g' \
13b78d
        -e 's/@@FD_PASSWORD@@/fd-password/g' \
13b78d
        -e 's/@@SD_PASSWORD@@/sd-password/g' \
13b78d
        -e 's/@@MON_DIR_PASSWORD@@/mon-dir-password/g' \
13b78d
        -e 's/@@MON_FD_PASSWORD@@/mon-fd-password/g' \
13b78d
        -e 's/@@MON_SD_PASSWORD@@/mon-sd-password/g' \
13b78d
        /etc/bacula/*.conf
13b78d
13b78d
5) Enable daemons and check they are working
13b78d
13b78d
# systemctl enable bacula-dir.service
13b78d
# systemctl enable bacula-sd.service
13b78d
# systemctl enable bacula-fd.service
13b78d
13b78d
# systemctl start bacula-dir.service
13b78d
# echo status dir=bacula-dir | bconsole
13b78d
13b78d
# systemctl start bacula-sd.service
13b78d
# echo status storage=bacula-sd | bconsole
13b78d
13b78d
# systemctl start bacula-fd.service
13b78d
# echo status client=bacula-fd | bconsole
13b78d
13b78d
6) To grant console access to regular users add the read permission to the
13b78d
console configuration files. Remember that there is no authentication check; so
13b78d
a user that can launch the console can perform any command.
13b78d
13b78d
# chmod +r /etc/bacula/bconsole.conf /etc/bacula/bat.conf