紅旗Linux案例精選:Amanda集中備份執行個體詳細講解

來源:互聯網
上載者:User

Amanda(進階馬里蘭自動網路磁碟歸檔 Advanced Maryland Automatic Network Disk Archiver
)網路備份軟體是我第一次接觸Linux就聽到過,只是從來都沒有使用過,有需要備份得時候,就是自己寫寫簡單的指令碼,使用cron來做定時任務,也能基本滿足需求。雖然曾經起心想用Amanda,但限於沒有適合的環境,只能作罷。

現在的情況有所不同了,有4,5台伺服器需要備份,設計到不同的平台,其備份特性應該達到或者至少朝企業級標準靠攏,因此,這幾天看了看Amanda的文檔,做了一些測試,目前在我的環境下配置成功,特記錄下來和大家分享。

這次打算分兩篇文檔介紹,本篇是介紹檔案備份,下一篇將介紹針對MySQL資料庫的備份方法。

這次配置的大致流程如下:

  1. 安裝和配置Amanda備份伺服器
  2. 安裝Amanda用戶端
  3. 設定管理員和用戶端參數
  4. 檢驗配置
  5. 校正備份
  6. 測試恢複

下面的列表給出這次測試環境的網路和機器配置

機器名

要備份的檔案

OS

是否壓縮

說明

cp1.domain.com

-

Ubuntu 8.10

Yes

Amanda服務端

cp2.domain.com

/web/websites

Asianux 3.0

Yes

用戶端,運行大量網站

cp3.domain.com

/opt/www

CentOS 5.3

Yes

IDC伺服器,大量客戶網站

一、安裝和配置Amanda服務

首先從官方網站現在對應OS的最新Amanda版本,我寫這篇文章的時候,針對Ubuntu 8.10的最新版本是2.6.1p1,可以從http://www.zmanda.com/download-amanda.php 找到適合裡的版本,包括服務端和用戶端。

以下操作cp1機器上執行,如果沒有特別說明,使用的帳號為root。

因為ubuntu倉庫裡內建的版本比較低,而且與官方版本在配置方面有些不同,所以建議先卸載內建的版本,然後安裝下載的版本。

Amanda服務的啟動依賴xinetd超級服務,編輯或者建立/etc/xinetd.d/amandaserver檔案,內容應該像下面這個樣子:

# default: on## description: Amanda services for Amanda server and client.# service amanda{        disable         = no#        flags           = IPv6        socket_type     = stream        protocol        = tcp        wait            = no        user            = amandabackup        group           = disk        groups          = yes        server          = /usr/libexec/amanda/amandad        server_args     = -auth=bsdtcp amdump amindexd amidxtaped}

重啟xinetd服務
root@cp1:~# /etc/init.d/xinetd reload
* Reloading internet superserver configuration xinetd [ OK ]
root@cp1:~#

  • 1
  • 2
  • 3
  • 4
  • 5
  • 下一頁
【內容導航】
第1頁:安裝和配置Amanda服務 第2頁:安裝用戶端
第3頁:配置備份參數 第4頁:測試
第5頁:恢複

相關文章

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.