zoukankan      html  css  js  c++  java
  • bacula安装部署篇(一)

    以bacula-7.4.4安装为例

    CentOS-7

    安装mariadb

    yum install -y mariadb-server mariadb-devel
    systemctl start mariadb
    systemctl enable mariadb
    

    源代码安装

    yum install -y gcc gcc-c++
    #需安装C++编译环境
    
    tar zxvf bacula-7.4.4.tar.gz
    cd bacula-7.4.4
    ./configure --prefix=/opt/bacula --with-mysql
    make && make install
    make install-autostart
    

    CentOS-6

    安装mysql

    yum install -y mysql mysql-server mysql-devel
    /etc/init.d/mysqld start
    
    #设置mysql开机自启动
    chkconfig mysqld on        #设置开机自启动
    chkconfig --list mysqld    #检查开机自启动
    

    源代码安装

    yum install -y gcc gcc-c++
    #需安装C++编译环境
    
    tar zxvf bacula-7.4.4.tar.gz
    cd bacula-7.4.4
    ./configure --prefix=/opt/bacula --with-mysql
    make && make install
    make install-autostart
    
    #执行命令后查看自启动
    ls /etc/rc.d/init.d/ |grep bacula
    bacula-dir
    bacula-fd
    bacula-sd
    

    在需要备份的服务器上安装客户端(linux)

    yum install -y gcc gcc-c++
    #需安装C++编译环境
    
    tar zxvf bacula-7.4.4.tar.gz
    cd bacula-7.4.4
    ./configure --prefix=/opt/bacula --enable-client-only
    make && make install
    make install-autostart
    

    初始化Bacula的数据库

    cd /opt/bacula/etc
    ./create_mysql_database 
    ./grant_mysql_privileges 
    ./make_mysql_tables
    

    登录Mysql数据库 查看bacula的库表是否已经建立

    [root@bacula1 etc]# mysql -uroot
    Welcome to the MariaDB monitor.  Commands end with ; or g.
    Your MariaDB connection id is 7
    Server version: 5.5.56-MariaDB MariaDB Server
    
    Copyright (c) 2000, 2017, Oracle, MariaDB Corporation Ab and others.
    
    Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
    
    MariaDB [(none)]> show databases;
    +--------------------+
    | Database           |
    +--------------------+
    | information_schema |
    | bacula             |
    | mysql              |
    | performance_schema |
    | test               |
    +--------------------+
    5 rows in set (0.00 sec)
    
    MariaDB [(none)]> quit
    Bye
    
  • 相关阅读:
    对list集合中的对象进行排序(转载)
    关键字的作用
    CocoaPods的 安装 /卸载/升级
    block基本使用和底层
    程序启动 - 类调用的方法
    成员变量修饰词的作用
    宏(define)与常量(const)
    iOS
    监听网络状态
    nil、Nil、NULL与NSNull的区别及应用
  • 原文地址:https://www.cnblogs.com/ogrecn/p/7693360.html
Copyright © 2011-2022 走看看