Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
TetraWiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Basic Concepts of AMANDA
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Special pages
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
[[category:GSPC]] AMANDA SETUP: As other packages we has 3 methods of installing AMANDA: 1. '''SOURCE PACKAGE'''- COMPILING tar.gz with "amandabackup" user 2. '''RPM'''- using RPM packages, which will be needing other dependencies as well. 3. '''yum'''- easiest way to install, resolving dependencies. '''VERSION''' implemented at GSPC Project is 3.3.6, using yum utility. '''PROTOCOL''' by default used by AMANDA 2.5.6-1p2 is 'BSDUDP' but protocol configured at GSPC Project is BSDTCP because Tape Library communicates at TCP port. And by default port number is same -10080 and 10081. This is done by modifying /etc/xinetd.d/amanda and amanda.conf and amanda-client.conf. '''Using yum utility''' for installing default path of configuration file is /etc/amanda and that of state directory is /var/lib/amanda. Main configuration files of Amanda: '''A'''. '''amanda'''.'''conf'''- complete description of working of amanda with backup and tape. '''B'''. '''disklist'''- what and from where to backup with what algorithm. '''C'''. '''changer'''.'''conf'''- describing about changer (only if physical lib present) '''D.''' '''tapelist'''- describes the tapes, label over it and usabelity. '''E'''. '''amanda-client'''.'''conf'''- describing index server etc. '''F'''. '''(.amandahosts)''' - neccessary for recovering files and making amdump. Basicaly AMANDA works through backup set. Backup set is nothing but a directory containing above main configuration file. Now firstly we needs to define policy and configure AMANDA's working, this is done by editing amanda.conf. amanda.conf is base file of AMANDA, on which complete working and operations stands. it contains many perimeters, out of which important ones are discussed below: org "DailySet1" -> defines backup set name. mailto "amandabackup" -> defines mail of status to be sent to which user netusage 8000 Kbps -> bandwidth to be allocated to Amanda. dumpcycle 4 weeks -> very important perameter which defines when next full backup is to be taken. We can also define it in days. At gspc its 5 days which may change in future. runspercycle 20 -> dedines number of amdump could be run in dump period defined, at GSPC it is 10. tapecycle 25 tapes -> informs AMANDA to use 25 tapes. at GSPC is 2 which may change. etimeout 300 -> at gspc its 1030409300 as it should by runcycle * tape capacity. this describes estimation time period for file system. device_output_buffer_size 1280k -> REPLACE TO tapebufs. defines amount of buffer space to be used for writing after dumping. tpchanger "chg-manual" -> defines the tape changer(in GSPC chg-zd-mtx) tapedev "tape:/dev/nst0" -> tells the path of tape. changerfile "/etc/amanda/DailySet1/changer.conf" -> path of changer.conf file changerdev "/dev/changer" -> path describes about changer. runtapes 1 -> defines number of tapes to be used in single run of amdump. tapetype LTO-6 -> tells the type of tape used. infofile "/etc/amanda/DailySet1/curinfo"-> information of backed up file is stored here, useful while recovering data logdir "/etc/amanda/DailySet1" -> immediate status logs indexdir "/etc/amanda/DailySet1/index" -> index is built here for every successfull backup. and same is vital for recovery. <nowiki>###########################################################################</nowiki> define tapetype LTO-6 { comment "Created by amtapetype; compression enabled" length 2459255552 kbytes filemark 1211 kbytes speed 80723 kps blocksize 32 kbytes } <nowiki>###########################################################################</nowiki> CLass is giving description about the tape-type defined in pervious perameters. <nowiki>---------------------------------------------------------------------------</nowiki> <nowiki>###########################################################################</nowiki> define dumptype global { comment "Global definitions" auth "bsdtcp" } define dumptype comp-user-tar { user-tar compress client fast } <nowiki>##################################################################3#######</nowiki> This class is defining an algorithm to be used globally for all dumptypes. At GSPC dumptype used is comp-user-tar, which describes user's data is to be backuped up in compress state using tar utility. <nowiki>--------------------------------------------------------------------------</nowiki> <nowiki>##########################################################################</nowiki> holdingdisk hd2 { directory "/dumps2/amanda" use 1000 Mb } <nowiki>###########################################################################</nowiki> This class defines holding disk that to be used for storing data before it is flushed to tape. holding disk is nothing but a location but size is defined in amanda.conf only, by which AMANDA is stick to size limit for that particular data set. <nowiki>----------------------------------------------------------------------------</nowiki> Now, after configuring amanda.conf we has disklist which tells AMANDA frome where & what to backup with what dumptype. there are two ways of defining disklist- by class method and other is perameter. <nowiki>###########################################################################</nowiki> At GSPC, we are using below perameter method to describe disklist. gspc-cloud2 //10.100.10.3/gspc comp-user-tar-mod -1 <nowiki>###########################################################################</nowiki> this perameter tells at station gspc-cloud2 a directory names gspc is mounted with manually described dumptype and spindle used for this perameter. <nowiki>----------------------------------------------------------------------------</nowiki> Moving forward to changer.conf, at GSPC we has tape library so it is very usefule file to describe number of tapes for backup set and different perameters along with it. <nowiki>###########################################################################</nowiki> firstslot=14 lastslot=15 driveslot=0 havereader=1 <nowiki>#autoclean=1</nowiki> <nowiki>#cleanslot=25</nowiki> <nowiki>#autocleancount=99</nowiki> <nowiki>#cleancycle=120</nowiki> <nowiki>#max_drive_wait=120</nowiki> <nowiki>#unloadpause=20</nowiki> <nowiki>#poll_drive_ready=10</nowiki> <nowiki>#initial_poll_delay=10</nowiki> <nowiki>##########################################################################</nowiki> Considering above perameters we have to mainly consult with firstslot and lastslot which tells from where to where tapes are to be used for this backup set. <nowiki>--------------------------------------------------------------------------</nowiki> AMANDA uses its own convention while writing to tape. You can't write directly to tape while using AMANDA, for this we needs to label the tape first. 'amlabel' utility provides this facility. NOTE:- here is a difference between bar-cade label(physical label on a tape is needed for the changer to read and write on it in library) and AMANDA label(logical label used by AMANDA) is used to make AMANDA understand that particular backup-set contains a tape by particular label. Though we can label tapes ,not having bar-code, through AMANDA label but we will not be able to write over it until and unless bar-code is present over the tape. As Amlabel utility is used for labelling the tapes, thus labeling and pooling is done simultaneously. <nowiki>===============================================================================================================================================================</nowiki> Next is tapelist, which tells what all tapes are assigned to particular backup set. <nowiki>##########################################################################</nowiki> 0 mar-15 reuse BLOCKSIZE:32 0 mar-14 reuse BLOCKSIZE:32 <nowiki>##########################################################################</nowiki> this tells 2 tapes having labelled mar-15 and mar-14 are working on resuable mode with blocksize 32 having no backup written yet. <nowiki>----------------------------------------------------------------------------</nowiki> Coming to amanda-client.conf, this tells particular backup-set has index server and tape server with defined name some authentication is used. <nowiki>##########################################################################</nowiki> conf "march" index_server "gspc-cloud2" <nowiki># your amindexd server</nowiki> tape_server "gspc-cloud2" <nowiki># your amidxtaped server</nowiki> auth "bsdtcp" <nowiki>##########################################################################</nowiki> <nowiki>----------------------------------------------------------------------------</nowiki> In addition we has one more important file named amandahosts file present at /var/lib/amanda directory which describes the hosts which can be used for recovery as well whose dump can be taken. Syntax is as followed: localhost root amindexd amidxtaped localhost.localdomain root amindexd amidxtaped localhost amandabackup amdump gspc-cloud2 amandabackup amdump gspc-cloud2 root amindexd amidxtaped localhost.localdomain amandabackup amdump Window_FS amanda1 amdump Window_FS administrator amindexd amidxtaped Window_FS amandabackup amindexd amidxtaped Window_FS root amindexd amidxtaped <nowiki>###########################################################################</nowiki> <nowiki>------------------------------------------------------------------------------</nowiki> now starting with procedure of backup in AMANDA, firstly we have to be very clear that backup will be done by "amandabackup" user only. thus we needs switching to user 'amandabackup' then running various utilities. Before we proceed with backup we will firstly verify our status of backup-set via 'amcheck backupset' command. If it returns with 0problems then it means we are ready to backup for that backup-set. Now to start backup we use "amdump" utility so we shall initiate backup using "amdump backup-set" command. At same time on another terminal we can monitor its status through "amstatus backup-set" command. Here new concepts are arised that are "estimate" and 'dumping'. Estimate is is a process in which amanda first make estimates of directory to be backed up (including file system) and then start dumping whereas Dumping is another which is initiated after completion of etimating process. During this process AMANDA has calculated the size compressing the data using algorithm defined with perameters in disklist and amanda.conf. if tape would be available then AMANDA writes directly to it otherwise it will writes to holding disk, which is recommended for small-scale companies. "amadmin is another utility to administrate backup-set. using find option we can verify or check where data has been written after completion of amdump and with what level and status and other details too. command is 'amadmin backup-set find' "amrmtape" is the utility used for removing label as well as data over a tape. command is "amrmtape backup-set tape-name' <nowiki>---------------------------------------------------------------------------</nowiki> Imprtant NOTE: due to unavailabilty of physical tape library at home or small environment we has an optin of using virtual tapes but there is a small but crucial difference in configuring amanda using virtual tapes and physical tapes. That is when we use virtual tape amanda.conf itself acts as a changer file whereas for physical we needs changer.conf seperately for better administration. <nowiki>---------------------------------------------------------------------------</nowiki> Now on successful completion of backup and verification by amadmin we needs to recover the files which we will be using amrecover utility. here the point to be consider is amrecover should be run by root user instead of amandabackup via command - "amrecover backup-set". Pursuing further we needs to set device by following commands: listdevice -> list the available device(s). setdevice devicename -> sets the device to that particular name. then we will add particular file or all data by 'add' command. and then using 'extract' command we will recover the data. after we will rsync it to desired location. <nowiki>-----------------------------------------------------------------------------</nowiki> In case of any problem arises at recovery we firstly needs to check ".amandahosts" file, present at AMANDA's state directory(/var/lib/amanda). It must contains neccessary authentication type to users with particular host station name after that rest of files.
Summary:
Please note that all contributions to TetraWiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
TetraWiki:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)