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