+2007-02-07 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amindexd.c: Use dbfd.
+
+2007-02-06 Jean-Louis Martineau <martineau@zmanda.com>
+ * Amanda 2.5.1p3 released.
+ * configure.in: AM_INIT_AUTOMAKE(amanda, 2.5.1p3).
+ * NEWS: Update for 2.5.1p3
+
+2007-02-06 Jean-Louis Martineau <martineau@zmanda.com>
+ * man/xml-source/amcheck.8.xml,
+ server-src/amlabel.c: Merge from zmanda.
+
+2007-02-06 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/clock.c (timesub): The result must always be positive.
+
+2007-02-05 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-zd-mtx.sh.in: Fix for sed and IMPORT/EXPORT.
+
+2007-02-05 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amcheck.c: Add parentheses.
+
+2007-02-02 Jean-Louis Martineau <martineau@zmanda.com>
+ * docs/*.txt: Update from xml-docs.
+
+2007-02-02 Jean-Louis Martineau <martineau@zmanda.com>
+ * man/Makefile.am: Use http://docbook.sourceforge.net
+ * man/xml-source/amadmin.8.xml, man/xml-source/amaespipe.8.xml,
+ man/xml-source/amanda.8.xml, man/xml-source/amanda-client.conf.5.xml,
+ man/xml-source/amanda.conf.5.xml, man/xml-source/amcheck.8.xml,
+ man/xml-source/amcrypt.8.xml, man/xml-source/amdump.8.xml,
+ man/xml-source/amfetchdump.8.xml, man/xml-source/amflush.8.xml,
+ man/xml-source/amgetconf.8.xml, man/xml-source/amlabel.8.xml,
+ man/xml-source/ammt.8.xml, man/xml-source/amrecover.8.xml,
+ man/xml-source/amreport.8.xml,
+ man/xml-source/amtape.8.xml: Fix for xmllint.
+ * man/xslt/man.xsl: Remove bogus code.
+
+2007-02-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-zd-mtx.sh.in: Support IMPORT/EXPORT slot.
+
+2007-02-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amdump.sh.in: Output a starttime line.
+ * server-src/amflush.c: Output a starttime line.
+ * server-src/amstatus.pl.in: parse the starttime line.
+
+2007-01-26 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amdump.sh.in: Exit with a status.
+
+2007-01-26 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/diskfile.c: Use hostnext pointer.
+
+2007-01-26 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/reporter.c: Exit with a status.
+
+2007-01-26 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amstatus.pl.in: Exit with a status.
+
+2007-01-26 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amstatus.pl.in: Detect failed dump to tape.
+
+2007-01-25 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/changer.c (changer_command): Send stderr to dbfd().
+
+2007-01-25 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/diskfile.c: Check hostname have same case.
+
+2007-01-25 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-zd-mtx.sh.in: Check if MT and MTX exists.
+
+2007-01-25 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-zd-mtx.sh.in: Set CHANGER environment variable.
+
+2007-01-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/clientconf.c: Don;t check for duplicate -o options.
+ * common-src/util.c: Check for duplicate -o options.
+ * recover-src/amrecover.c: Change precedence of option.
+
+2007-01-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/diskfile.c: Fix compiler warning.
+
+2007-01-23 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/security-util.c (tcpm_recv_token): Check size < 0.
+
+2007-01-23 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/diskfile.c: Check duplicate DLE with match_host and
+ match_disk.
+
+2007-01-18 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/selfcheck.c: Improve check if /etc/dumpdates in not there.
+
+2007-01-18 Jean-Louis Martineau <martineau@zmanda.com>
+ * restore-src/amfetchdump.c: Set arg_state to ARG_GET_HOST.
+
+2007-01-18 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amcheck.c: Check tape_access.
+ * server-src/taper.c: Improve message.
+
+2007-01-16 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/getconf.c: Fix segfault in parameter parsing.
+
+2007-01-11 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/conffile.c Set default length/filemark correctly.
+ * man/xml-source/amanda.conf.5.xml: Document they are in kbytes.
+
+2007-01-10 Jean-Louis Martineau <martineau@zmanda.com>
+ * amandad-src/amandad.c (do_sendpkt): Send packet if handle != NULL.
+
+2007-01-10 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/util.c, common-src/util.h, server-src/conffile.c,
+ server-src/diskfile.c: Keep different list for exclude file and list.
+
+2007-01-10 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/taper.c (read_file): Don't count first header twice.
+
+2007-01-05 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amstatus.pl.in: Fix split-dump accounting.
+
+2007-01-04 Jean-Louis Martineau <martineau@zmanda.com>
+ * restore-src/restore.c: Use prompt_in.
+
+2007-01-04 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-chio.pl.in, changer-src/chg-iomega.pl.in,
+ changer-src/chg-rth.pl.in, dumper-src/gnutar.pl.in,
+ server-src/amoverview.pl.in, server-src/amstatus.pl.in,
+ server-src/amtoc.pl.in: Clean ENV and set PATH.
+
+2006-12-27 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/driver.c: Don't repport error for many run in a day if
+ it's amflush.
+
+2006-12-27 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/util.c (quote_string): Escape '\' character.
+
+2006-12-22 Jean-Louis Martineau <martineau@zmanda.com>
+ * recover-src/display_commands.c: Send quoted text to amindexd.
+ * recover-src/extract_list.c: Send quoted text to amindexd.
+ * recover-src/set_commands.c: Send quoted text to amindexd.
+
+2006-12-22 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-disk.sh.in: LASTSLOT in a changerfile for chg-disk.
+
+2006-12-22 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/sendsize.c: Compilation fix.
+
+2006-12-18 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/packet.c (pkt_init_empty): New function.
+ * common-src/packet.h (pkt_init_empty): New prototype.
+ * amandad-src/amandad.c, common-src/protocol.c,
+ common-src/security-util.c: Use pkt_init_empty.
+
+2006-12-18 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/conffile.c: Print nothing if the list is emtpy.
+
+2006-12-14 Jean-Louis Martineau <martineau@zmanda.com>
+ * restore-src/restore.c: Fix filename for output file.
+
+2006-12-12 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/util.c: Fix printf format error.
+
+2006-12-12 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/amanda.h: Define __attribute__ for gcc >= 3.
+ * common-src/packet.c (pkt_init): Accept NULL for fmt.
+ * amandad-src/amandad.c, common-src/protocol.c,
+ common-src/security-util.c: Pass NULL to pkt_init.
+ * amandad-src/amandad.c, changer-src/chg-scsi.c,
+ changer-src/scsi-linux.c, client-src/sendbackup.c,
+ common-src/amanda.h, common-src/event.c,
+ common-src/packet.c, common-src/security-util.c,
+ common-src/stream.c, oldrecover-src/amrecover.c,
+ restore-src/restore.c, server-src/amcheck.c,
+ server-src/driver.c, server-src/driverio.c,
+ server-src/taper.c: Fix printf format error.
+
+2006-12-12 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amindexd.c: Use fgets to read index file because they
+ are not quoted.
+
+2006-12-12 Jean-Louis Martineau <martineau@zmanda.com>
+ * configure.in: Find patch for sort program.
+ * server-src/amindexd.c: Clean the indexd file between the uncompress
+ and sort process.
+
+2006-12-08 Jean-Louis Martineau <martineau@zmanda.com>
+ * man/xml-source/amadmin.8.xml, man/xml-source/amanda.8.xml,
+ man/xml-source/amanda.conf.5.xml, man/xml-source/amcheck.8.xml,
+ man/xml-source/amfetchdump.8.xml, man/xml-source/ammt.8.xml,
+ man/xml-source/amrecover.8.xml: Move </note> tag to beginning of line
+
+2006-12-08 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-rait.sh.in: Fix typo for -reset.
+
+2006-12-07 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/util.c (lookup_keyword): Use strcasecmp.
+ * common-src/util.c (get_conftoken): Don;t convert to uppercase.
+ * server-src/getconf.c: Don;t print extra '\n' for --list.
+
+2006-12-04 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amtape.h: Remove file.
+
+2006-11-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/sendbackup.c: Kill dump process on error.
+
+2006-11-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-chio.pl.in: Check tapedev is set.
+ * changer-src/chg-disk.sh.in: Check tapedev is set.
+ * changer-src/chg-iomega.pl.in: Check tapedev is set.
+ * changer-src/chg-manual.sh.in: Check tapedev is set.
+ * changer-src/chg-mtx.sh.in: Check tapedev is set.
+ * changer-src/chg-rth.pl.in: Check tapedev is set.
+ * server-src/amcheck.c: Tapedev is needed only if tpchanger is not set.
+ * server-src/amflush.c: Tapedev is needed only if tpchanger is not set.
+ * server-src/amindexd.c: Tapedev is needed only if tpchanger is not set
+ * server-src/taper.c: Tapedev is needed only if tpchanger is not set.
+
+2006-11-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/sendbackup.c: Ignore tar exit with status 1.
+
+2006-11-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amindexd.c (clean_backslash): New function use to unescape
+ '\' characters in index files.
+
+2006-11-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * restore-src/restore.c (search_tapes): Fix prompt_out setting.
+
+2006-11-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/util.c (copy_file): Fix compilation error.
+
+2006-11-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/sendbackup-dump.c, client-src/sendbackup-gnutar.c,
+ client-src/sendsize.c,
+ server-src/amindexd.c: Patch for gcc-3.2.3 to compile the new
+ vstralloc macro.
+
+2006-11-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/file.c (old_sanitise_filename): New function.
+ * common-src/amanda.h (old_sanitise_filename): Prototype.
+ * common-src/util.c (copy_file): New function.
+ * common-src/util.h (copy_file): Prototype.
+ * server-src/diskfile.c: Check that two DLE doesn't get the same
+ sanitized filename.
+ * server-src/amindex.c (getoldindexfname): New function.
+ * server-src/amindex.h (getoldindexfname): prototype.
+ * server-src/amindexd.c: Use the old sanitized filename if the new
+ file doesn't exist.
+ * server-src/amcheck.c: Call check_infofile.
+ * server-src/planner.c: Call check_infofile.
+ * server-src/server_util.c (check_infofile): New function, will copy
+ the old sanitizes info file if the new doesn't exist.
+ * server-src/server_util.h (check_infofile): Prototype.
+
+2006-11-23 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/security-util.c (tcpm_recv_token): amanda protocol
+ packet can be larger than NETWORK_BLOCK_BYTES
+
+2006-11-20 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/sendsize.c: Open the amandates file after the
+ <config>/amanda-client.conf file is loaded.
+
+2006-11-20 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/security-util.c, server-src/amcheck.c,
+ * server-src/driver.c, server-src/dumper.c,
+ * server-src/planner.c, tape-src/output-file.c: Lint cleanup.
+
+2006-11-20 Ian Turner <ian@zmanda.com>
+ * tape-src/output-file.c: Fix a compilation error related to
+ improper type casts. Thanks to Satya Ganga for noticing this
+ problem.
+
+2006-11-20 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/driver.c: Use temporary variable to scanf an OFF_T_FMT.
+ * server-src/planner.c: Use temporary variable to scanf an OFF_T_FMT.
+
+2006-11-13 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/selfcheck.c: Work for estimate calcsize and
+ program "DUMP".
+
+2006-11-13 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amcheck.c: Don't ouput an warning if holdingdisk 'use'
+ is set to 0.
+
+2006-11-09 Jean-Louis Martineau <martineau@zmanda.com>
+ * Amanda 2.5.1p2 released.
+ * configure.in: AM_INIT_AUTOMAKE(amanda, 2.5.1p2).
+ * NEWS: Update for 2.5.1p2
+
+2006-11-09 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/conffile.c (getconf_byname):
+ Parse "DEFINE:identifer:parameter" format.
+ * server-src/conffile.c (getconf_list): New function to list a DEFINE.
+ * server-src/conffile.c (lookup_holdingdisk): New function.
+ * server-src/conffile.h (getconf_list,
+ lookup_holdingdisk): New prototype.
+ * server-src/getconf.c: accept --list argument and
+ "DEFINE:identifer:parameter" format.
+ * man/xml-source/amgetconf.8.xml: Document.
+
+2006-11-09 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/chg-scsi.c: Don't remove '_' from "generic_changer".
+
+2006-11-08 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/amanda.h, common-src/security-util.c,
+ common-src/util.h, configure.in,
+ oldrecover-src/amrecover.c, oldrecover-src/extract_list.c,
+ recover-src/amrecover.c, recover-src/extract_list.c,
+ restore-src/amrestore.c, server-src/conffile.c,
+ server-src/dumper.c: Fix compiler error on Tru64.
+
+2006-11-08 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/driver.c: set off_t variable to 0 before sscanf.
+ * server-src/planner.c: set off_t variable to 0 before sscanf.
+
+2006-11-07 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amstatus.pl.in: Improve error message.
+
+2006-11-07 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/security-util.c: Fix coverity bug 170.
+ * server-src/diskfile.c: Fix coverity bug 147.
+
+2006-11-07 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/conffile.c (validate_chunksize): Check chunksize is >=
+ 2*DISK_BLOCK_KB
+
+2006-11-06 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/amanda.h: Define OFF_T_STRTOL.
+ * configure.in: Check for strtol and strtoll.
+
+2006-11-02 Ian Turner <ian@zmanda.com>
+ * common-src/amanda.h: Use atol if atoll is missing.
+
+2006-11-02 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/security-util.c: Better message on invalid size.
+
+2006-11-02 Jean-Louis Martineau <martineau@zmanda.com>
+ * configure.in: List bsdudp as a udp transport.
+
+2006-11-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/diskfile.c: Don't use 0 for NULL.
+
+2006-11-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/clientconf.c: Define AMANDATES_FILE
+ * client-src/amandates.h: Don't define AMANDATES_FILE
+
+2006-11-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/conffile.c: Rename DUMPTYPE_START_T to DUMPTYPE_STARTTIME.
+ * common-src/conffile.h: Rename DUMPTYPE_START_T to DUMPTYPE_STARTTIME.
+ * server-src/amadmin.c (disklist_one): Print correct starttime.
+ * server-src/diskfile.c: Set start_t to starttime.
+ * server-src/diskfile.h (disk_t): Add starttime.
+ * common-src/conffile.c (conf_print): Add a parameter if we want
+ CONFTYPE_STRING enclosed in ".
+ * server-src/planner.c: Use getconf_int to get etimeout value.
+ * common-src/conffile.c (CNF_CTIMEOUT, CNF_DTIMEOUT, CNF_ETIMEOUT):
+ They are of type CONFTYPE_INT
+ (CONFTYPE_TIME are for value parsed as "hhmm"")
+ * common-src/conffile.c (getconf_byname): Use conf_print().
+ * common-src/conffile.h: Add comment.
+ * server-src/amcheck.c, server-src/dumper.c, server-src/planner.c:
+ Use getconf_int to get timeout value.
+
+2006-11-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * changer-src/scsi-changer-driver.c: Add Tandberg SLR100,
+ more debugging.
+ * changer-src/sense.c: Add Tandberg SLR100 Tape Drive "SLR100".
+
+2006-11-01 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/amanda.h: Define dbrename if !DEBUG_CODE.
+ * restore-src/amidxtaped.c: Declare i if !DEBUG_CODE.
+
+2006-10-25 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amtape.c: Use parse_conf instead of parse_server_conf.
+ * server-src/diskfile.c: Correct hostname allocation.
+
+2006-10-25 Jean-Louis Martineau <martineau@zmanda.com>
+ Patch by Jay Fenlason
+ * common-src/rsh-security.c: Fix.
+
+2006-10-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/conffile.c (get_config_options): Build and argv of the
+ -o arguments.
+ * common-src/conffile.h (get_config_options): Prototype.
+ * server-src/driverio.c: exec dumper/chunker/driver with the argv from
+ get_config_options
+ * server-src/amtape.c: Accept -o argument.
+ * man/xml-source/amtape.8.xml: Document it.
+
+2006-10-24 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/taper.c: Fix allocation problem on tapedev.
+
+2006-10-20 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/taper.c (free_split_buffer): Correct free.
+
+2006-10-19 Jean-Louis Martineau <martineau@zmanda.com>
+ * man/xml-source/amanda.conf.5.xml: Fix formating.
+
+2006-10-19 Jean-Louis Martineau <martineau@zmanda.com>
+ * client-src/calcsize.c: Quote amname.
+
+2006-10-16 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/dgram.c (dgram_cat),
+ common-src/packet.c (pkt_init, pkt_cat): Works correctly with
+ vsnprintf returning -1.
+
+2006-10-11 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/planner.c: Improve message for dump larger than available
+ tape space if runtapes > 1 and splitsize == 0.
+
+2006-10-10 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/driver.c (wait_children): Don't crash if dumper->chunker
+ is NULL
+
+2006-10-04 Jean-Louis Martineau <martineau@zmanda.com>
+ * amandad-src/amandad.c: Call security_recvpkt() on A_SENDNACK
+ and dup P_REQ.
+ * common-src/security-util.c: Improve message.
+
+2006-10-03 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amcleanupdisk.c: Accept -o arguments.
+ * server-src/amcleanup.sh.in: Add missing 'shift' for non-linux system.
+ Accept -o arguments.
+
+2006-10-03 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amoverview.pl.in: Fix parsing of time field from amadmin.
+
+2006-10-03 Jean-Louis Martineau <martineau@zmanda.com>
+ * restore-src/amidxtaped.c, restore-src/restore.c,
+ server-src/amcheck.c, server-src/amflush.c,
+ server-src/amlabel.c, server-src/taper.c,
+ server-src/taperscan.c: Check for CNF_TAPEDEV == NULL.
+
+2006-10-03 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/conffile.c: Don't set CNF_TAPEDEV to DEFAULT_TAPE_DEVICE.
+ * configure.in: Don't set DEFAULT_TAPE_DEVICE.
+
+2006-09-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/bsdtcp-security.c: Add logging on error.
+
+2006-09-29 Jean-Louis Martineau <martineau@zmanda.com>
+ * server-src/amoverview.pl.in: Use shellwords instead of quotewords,
+ don't add date for disk not in the disklist.
+
+2006-09-28 Jean-Louis Martineau <martineau@zmanda.com>
+ * common-src/bsd-security.c: Fix %hd printf argument format.
+ * common-src/security-util.c: Fix %hd printf argument format.
+
2006-09-27 Jean-Louis Martineau <martineau@zmanda.com>
* Amanda 2.5.1p1 released.
* configure.in: AM_INIT_AUTOMAKE(amanda, 2.5.1p1).
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
+Changes in release 2.5.1p3
+ * Many bugs fixed
+ * amrecover improve handling of not ascii filename in index.
+ * Works with tar-1.16 and exit status of 1.
+ * Can define a LASTSLOT in a chg-disk config file.
+
+Changes in release 2.5.1p2
+
+ * Many bugs fixed
+ * amoverview is working
+ * dumptype starttime is working
+
+ * Amanda command changes
+ o amtape accept the -o arguments
+ o amgetconf --list to list all tapetype, dumptype, holdingdisk
+ or interface
+ o amgetconf can return a value of a specific tapetype, dumptype,
+ holdingdisk or interface
+
+
Changes in release 2.5.1p1
+
* Many bugs fixed:
o Timeout waiting for ACK
o "illegal density" with dump
* Some other small cleanup.
* Remove contrib/sst.
+
Changes in release 2.5.1
* Defects found by Coverity scan and Klocwork K7 analysis tools fixed.
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
*/
/*
- * $Id: amandad.c,v 1.18.2.1 2006/09/15 17:18:06 martinea Exp $
+ * $Id: amandad.c,v 1.18.2.5 2007/01/10 16:26:57 martinea Exp $
*
* handle client-host side of Amanda network communications, including
* security checks, execution of the proper service, and acking the
strcmp(as->arguments, arguments) == 0) {
dbprintf(("%s: %s %s: already running, acking req\n",
debug_prefix_time(NULL), service, arguments));
- pkt_init(&pkt_out, P_ACK, "");
+ pkt_init_empty(&pkt_out, P_ACK);
goto send_pkt_out_no_delete;
}
}
pkt_type2str(pkt->type));
do_sendpkt(as->security_handle, &nak);
amfree(nak.body);
+ security_recvpkt(as->security_handle, protocol_recv, as, -1);
#ifdef AMANDAD_DEBUG
dbprintf(("%s: state_machine: %p leaving (A_SENDNAK)\n",
debug_prefix_time(NULL), as));
(void)action; /* Quiet unused parameter warning */
(void)pkt; /* Quiet unused parameter warning */
- pkt_init(&ack, P_ACK, "");
+ pkt_init_empty(&ack, P_ACK);
if (do_sendpkt(as->security_handle, &ack) < 0) {
dbprintf(("%s: error sending ACK: %s\n",
debug_prefix_time(NULL), security_geterror(as->security_handle)));
dbprintf(("%s: received dup P_REQ packet, ACKing it\n",
debug_prefix_time(NULL)));
amfree(as->rep_pkt.body);
- pkt_init(&as->rep_pkt, P_ACK, "");
+ pkt_init_empty(&as->rep_pkt, P_ACK);
do_sendpkt(as->security_handle, &as->rep_pkt);
+ security_recvpkt(as->security_handle, protocol_recv, as, -1);
return (A_PENDING);
}
/* something unexpected. Nak it */
pkt_init(&as->rep_pkt, P_PREP, "%s", as->repbuf);
do_sendpkt(as->security_handle, &as->rep_pkt);
amfree(as->rep_pkt.body);
- pkt_init(&as->rep_pkt, P_REP, "");
+ pkt_init_empty(&as->rep_pkt, P_REP);
}
return (A_PENDING);
*/
repbuf = stralloc(as->repbuf);
amfree(as->rep_pkt.body);
- pkt_init(&as->rep_pkt, P_REP, "");
+ pkt_init_empty(&as->rep_pkt, P_REP);
tok = strtok(repbuf, " ");
if (tok == NULL)
goto error;
if (dh->netfd == NULL)
continue;
if (security_stream_accept(dh->netfd) < 0) {
- dbprintf(("%s: stream %d accept failed: %s\n",
+ dbprintf(("%s: stream %ld accept failed: %s\n",
debug_prefix_time(NULL),
dh - &as->data[0], security_geterror(as->security_handle)));
security_stream_close(dh->netfd);
{
dbprintf(("%s: sending %s pkt:\n<<<<<\n%s>>>>>\n",
debug_prefix_time(NULL), pkt_type2str(pkt->type), pkt->body));
- return security_sendpkt(handle, pkt);
+ if (handle)
+ return security_sendpkt(handle, pkt);
+ else
+ return 1;
}
#ifdef AMANDAD_DEBUG
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
use English;
use Getopt::Long;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
$| = 1;
if (-d "@AMANDA_DBGDIR@") {
chomp ($tapeDevice = `$sbindir/amgetconf$SUF tapedev 2>&1`);
die "tapedev not found in amanda.conf"
- if !$tapeDevice or $tapeDevice =~ m/no such parameter/;
+ if !$tapeDevice or $tapeDevice eq "" or
+ $tapeDevice =~ m/no such parameter/;
chomp ($changerDevice = `$sbindir/amgetconf$SUF changerdev 2>&1`);
chomp $changerDevice;
die "changerdev not found in amanda.conf"
- if !$changerDevice or $changerDevice =~ m/no such parameter/;
+ if !$changerDevice or $changerDevice eq "" or
+ $changerDevice =~ m/no such parameter/;
#
# Initialise a few global variables
# |- ...
# |- slotn
# where 'slot_root_dir' is the tapedev 'file:xxx' parameter and 'n'
-# is the tapecycle parameter.
-#
+# is the LASTSLOT value of your changerfile config file. If LASTSLOT is
+# not defined, the value of the tapecycle parameter is used.
+#
# To use this driver, just put the line 'tpchanger "chg-disk"' in your
# amanda.conf.
#
-# Example of use:
+# Example of use (amanda.conf):
# --- cut here ---
# tapedev "file:/BACKUP2/slots/"
# rawtapedev "file:/BACKUP2/slots/"
# changerdev "/dev/null"
+# changerfile "chg-disk"
# tpchanger "chg-disk"
# changerfile "/usr/local/amanda/etc/changer"
# tapetype HARD-DISK
# }
# --- cut here ---
#
-# The number of slot is equal to your tapecyle.
+# Example changerfile (chg-disk.conf):
+# --- cut here ---
+# LASTSLOT=12
+# --- cut here ---
+#
+# The number of slot is equal to your LASTSLOT or tapecycle.
# You must create the slots and data directory.
#
MYNAME=$0
TAPE=`amgetconf$SUF tapedev`
+if test X"$TAPE" == X""; then
+ echo "<none> tapedev not specified in amanda.conf." 1>&2
+ exit 2
+fi
SLOTDIR=`echo $TAPE | sed 's/^file://'`
isinteger() {
# need rwx access to directory of changer file
CHANGERFILE=`amgetconf$SUF changerfile`
+conf_match=`expr "$CHANGERFILE" : .\*\.conf\$`
+if [ $conf_match -ge 6 ]; then
+ CONFIGFILE=$CHANGERFILE
+ CHANGERFILE=`echo $CHANGERFILE | sed 's/.conf$//g'`
+else
+ CONFIGFILE=$CHANGERFILE.conf
+fi
+
CFDir=`dirname ${CHANGERFILE}`
[ -d ${CFDir} -a -r ${CFDir} -a -w ${CFDir} -a -x ${CFDir} ] ||
{ echo "$MYNAME: need 'rwx' access to '$CFDir'" 1>&2 ; exit 2 ; }
FIRSTSLOT=1
LASTSLOT=`amgetconf$SUF tapecycle`
+if test -r $CONFIGFILE; then
+ . $CONFIGFILE
+fi
CURSLOT=0
CLEANSLOT=$LASTSLOT
NSLOT=`expr $LASTSLOT - $FIRSTSLOT + 1`
use English;
use Getopt::Long;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
$| = 1;
if (-d "@AMANDA_DBGDIR@") {
chomp ($tapeDevice = `$sbindir/amgetconf$SUF tapedev 2>&1`);
die "tapedev not found in amanda.conf"
- if !$tapeDevice or $tapeDevice =~ m/no such parameter/;
+ if !$tapeDevice or $tapeDevice eq "" or
+ $tapeDevice =~ m/no such parameter/;
chomp ($changerDevice = `$sbindir/amgetconf$SUF changerdev 2>&1`);
chomp $changerDevice;
die "changerdev not found in amanda.conf"
- if !$changerDevice or $changerDevice =~ m/no such parameter/;
+ if !$changerDevice or $changerDevice eq "" or
+ $changerDevice =~ m/no such parameter/;
#
# Initialise a few global variables
ONLINEREGEX="ONLINE|READY|sense[_ ]key[(]0x0[)]|sense key error = 0|^er=0$|, mt_erreg: 0x0|^Current Driver State: at rest$"
REPORTTO=`amgetconf$SUF mailto`
tape=`amgetconf$SUF tapedev`
+
+if [ -z "$tape" ]; then
+ echo "<none> tapedev not specified in amanda.conf."
+ exit 2
+fi
+
ORG=`amgetconf$SUF ORG`
firstslot=1
myname=$0
tape=`amgetconf$SUF tapedev`
+if [ -z "$tape" ]; then
+ echo "<none> tapedev not specified in amanda.conf";
+ exit 2;
+fi
+
TAPE=`amgetconf$SUF changerdev`; export TAPE # for mtx command
+if [ -z "$TAPE" ]; then
+ echo "<none> changerdev not specified in amanda.conf";
+ exit 2;
+fi
+
if [ "$tape" = "/dev/null" -o "$TAPE" = "/dev/null" ]; then
- echo "Both tapedev and changerdev must be specified in config file";
+ echo "<none> Both tapedev and changerdev must be specified in config file";
exit 2;
fi
mysep="{"
case x$1 in
-x-slot|x-reseti|x-eject|x-search|x-label)
+x-slot|x-reset|x-eject|x-search|x-label)
#
# read slot number and device from each
use Getopt::Long;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
$pname = "rth-changer";
$prefix="@prefix@";
}
$tapeDevice=`$sbindir/amgetconf$SUF tapedev`;
+die "tapedev not found in amanda.conf"
+ if !$tapeDevice or $tapeDevice eq "" or
+ $tapeDevice =~ m/no such parameter/;
sub getCurrentTape {
-static char rcsid[] = "$Id: chg-scsi.c,v 1.52 2006/07/25 18:18:46 martinea Exp $";
+static char rcsid[] = "$Id: chg-scsi.c,v 1.52.2.2 2006/12/12 14:56:37 martinea Exp $";
/*
*
*
dbprintf (("\traw: %d\n",chg->emubarcode));
if (chg->debuglevel != NULL)
dbprintf(("debug level : %s\n", chg->debuglevel));
- dbprintf(("Tapes need sleep: %d seconds\n",chg->sleep));
+ dbprintf(("Tapes need sleep: %d seconds\n", (int)chg->sleep));
dbprintf(("Cleancycles : %d\n",chg->cleanmax));
dbprintf(("Changerdevice : %s\n",chg->device));
if (chg->labelfile != NULL)
fprintf(stderr,"drivenum %d is bad\n", drivenum);
drivenum = 0;
}
- p = chg->conf[drivenum].changerident;
- while (*p != '\0')
- {
- if (*p == '_')
+ if (strcmp(chg->conf[drivenum].changerident,"generic_changer") != 0) {
+ p = chg->conf[drivenum].changerident;
+ while (*p != '\0')
{
- *p=' ';
+ if (*p == '_')
+ {
+ *p=' ';
+ }
+ p++;
}
- p++;
- }
+ }
break;
case TAPEIDENT:
chg->conf[drivenum].tapeident = stralloc(value);
# Storage Element 7:Full :VolumeTag=SR0007
# Storage Element 8:Full :VolumeTag=SR0008
# Storage Element 9:Full :VolumeTag=SR0009
+# Storage Element 10 IMPORT/EXPORT:Full :VolumeTag=SR0009
#
# This says the first storage slot (element) is "1" and the last
# is "9". If you allocate the entire robot to Amanda, you do not need
s/.*Storage Element \([0-9][0-9]*\):Full/-2/p
q
}
+ /^.*Storage Element '$currentslot' IMPORT\/EXPORT:Empty/ {
+ s/.*Storage Element \([0-9][0-9]*\) IMPORT\/EXPORT:Empty/\1/p
+ q
+ }
+ /^.*Storage Element '$currentslot' IMPORT\/EXPORT:Full/ {
+ s/.*Storage Element \([0-9][0-9]*\) IMPORT\/EXPORT:Full/-2/p
+ q
+ }
}
' < $mtx_status 2>& 1`
shift # get rid of the "x"
s/.*Storage Element \([0-9][0-9]*\):Empty/\1/p
q
}
+ /^.*Storage Element \([0-9][0-9]*\) IMPORT\/EXPORT:Empty/ {
+ s/.*Storage Element \([0-9][0-9]*\) IMPORT\/EXPORT:Empty/\1/p
+ q
+ }
}
' < $mtx_status 2>& 1`
shift # get rid of the "x"
/^.*Storage Element \([0-9][0-9]*\):Full/ {
s/.*Storage Element \([0-9][0-9]*\):Full.*/\1/p
}
+/^.*Storage Element \([0-9][0-9]*\) IMPORT\/EXPORT:Full/ {
+ s/.*Storage Element \([0-9][0-9]*\) IMPORT\/EXPORT:Full.*/\1/p
+}
' < $mtx_status 2>&1 | grep -v "^${cleanslot}\$" | sort -n`
slot_list=`echo $slot_list` # remove the newlines
if [ $firstslot -lt 0 -o $lastslot -lt 0 ]; then
fi
export TAPE # for mtx command
+CHANGER=$TAPE
+export CHANGER # for mtx command
+
#### Set up the various config files.
conf_match=`expr "$changerfile" : .\*\.conf\$`
cleancount=`cat $cleanfile`
accesscount=`cat $accessfile`
+test -z "$MT" && Exit 2 "<none>" "No mt command defined"
+test ! -f "$MT" && Exit 2 "<none>" "mt command ($MT) doesn't exist"
+test -z "$MTX" && Exit 2 "<none>" "No mtx command defined"
+test ! -f "$MTX" && Exit 2 "<none>" "mtx command ($MTX) doesn't exist"
+
#### Dig out of the config file what is needed
varlist=
-static char rcsid[] = "$Id: scsi-changer-driver.c,v 1.52 2006/07/21 00:25:50 martinea Exp $";
+static char rcsid[] = "$Id: scsi-changer-driver.c,v 1.52.2.1 2006/11/01 13:55:55 martinea Exp $";
/*
* Interface to control a tape robot/library connected to the SCSI bus
*
int TapeStatus(void); /* Is the tape loaded ? */
int DLT4000Eject(char *Device, int type);
int GenericEject(char *Device, int type);
+int SCSI_LogSenseClean(char *Device); /* Does the tape need a clean */
int GenericClean(char *Device); /* Does the tape need a clean */
int GenericBarCode(int DeviceFD); /* Do we have Barcode reader support */
int NoBarCode(int DeviceFD);
NoBarCode,
GenericSearch,
GenericSenseHandler},
- {NULL, NULL, NULL,NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL}
+ {"SLR100",
+ "Tandberg SLR100",
+ GenericMove,
+ GenericElementStatus,
+ GenericResetStatus,
+ GenericFree,
+ GenericEject,
+ SCSI_LogSenseClean,
+ GenericRewind,
+ NoBarCode,
+ GenericSearch,
+ GenericSenseHandler},
+ {NULL, NULL, NULL,NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL}
};
extern OpenFiles_T *pDev;
int ret;
- DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### START eject_tape\n");
+ DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### START eject_tape %s\n",tapedev);
+ if (pDev[INDEX_TAPECTL].functions == NULL)
+ return(-1);
/*
* Try to read the label
{
if (pDev[INDEX_TAPECTL].SCSI == 1 && pDev[INDEX_TAPECTL].avail) {
+ DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### eject_tape rewind\n");
pDev[INDEX_TAPECTL].functions->function_rewind(INDEX_TAPECTL);
} else {
+ DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### eject_tape rewind2\n");
pDev[INDEX_TAPE].functions->function_rewind(INDEX_TAPE);
}
if (pDev[INDEX_TAPE].devopen == 1)
{
+ DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### eject_tape close\n");
SCSI_CloseDevice(INDEX_TAPE);
}
+ DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### tape_eject tape_rdlabel\n");
chgscsi_result = (char *)tape_rdlabel(pDev[INDEX_TAPE].dev, &chgscsi_datestamp, &chgscsi_label);
}
if (pDev[INDEX_TAPECTL].SCSI == 1 && pDev[INDEX_TAPECTL].avail == 1 && type == 1)
{
+ DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### tape_eject eject\n");
ret=pDev[INDEX_TAPECTL].functions->function_eject(tapedev, type);
DebugPrint(DEBUG_INFO,SECTION_TAPE,"##### STOP (SCSI)eject_tape [%d]\n", ret);
return(ret);
char * ident)
{
extern OpenFiles_T *pDev;
- char tmpstr[15];
+ char tmpstr[16];
ChangerCMD_T *p = (ChangerCMD_T *)&ChangerIO;
if (!ConfigName)
/* num returned by the inquiry command */
p = (ChangerCMD_T *)&ChangerIO;
snprintf(&tmpstr[0], SIZEOF(tmpstr), "%s_%s","generic",pDev[0].type);
+ DebugPrint(DEBUG_INFO, SECTION_SCSI,"##### OpenDevice trying GENERIC Device %s\n",tmpstr);
while(p->ident != NULL)
{
if (strcmp(tmpstr, p->ident) == 0)
} else { /* Something failed, lets see what */
DebugPrint(DEBUG_ERROR, SECTION_SCSI,"##### STOP OpenDevice failed\n");
}
+ pDev[ip].functions = NULL;
DebugPrint(DEBUG_INFO, SECTION_SCSI,"##### STOP OpenDevice (nothing found) !!\n");
return(0);
}
/* < 0 == fatal */
if (ret < 0) {
+ DebugPrint(DEBUG_INFO, SECTION_SCSI,"GenericEject SCSI_LoadUnload failed\n");
free(pRequestSense);
return(-1);
/*NOTREACHED*/
return(ret);
}
+int
+SCSI_LogSenseClean(
+ char * Device)
+{
+ extern OpenFiles_T *pDev;
+ CDB_T CDB;
+ RequestSense_T *pRequestSense;
+ int ret = 0;
+ u_char *buffer;
+ size_t size = 128;
+
+ (void)Device; /* Quiet unused parameter warning */
+ DebugPrint(DEBUG_INFO, SECTION_TAPE,"##### START SCSI_LogSenseClean\n");
+ if (pDev[INDEX_TAPECTL].SCSI == 0)
+ {
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"SCSILogSenseClean : can't send SCSI commands\n");
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"##### STOP SCSI_LogSenseClean\n");
+ return(0);
+ /*NOTREACHED*/
+ }
+
+ if (NULL == (buffer = alloc(size))){
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"SCSI_LogSenseClean : can't alloc buffer\n");
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"##### STOP SCSI_LogSenseClean\n");
+ return(0);
+ }
+ if (NULL == (pRequestSense = alloc(SIZEOF(RequestSense_T)))){
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"SCSI_LogSenseClean : can't alloc memory\n");
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"##### STOP SCSI_LogSenseClean\n");
+ return(0);
+ }
+
+ memset(buffer, 0, size);
+ CDB[0] = SC_COM_LOG_SENSE;
+ CDB[1] = 0;
+ CDB[2] = (u_char)(0x40 | 0x33);/* 0x40 for current values 0x33 Head Cleaning Page*/
+ CDB[3] = 0;
+ CDB[4] = 0;
+ CDB[5] = 0;
+ CDB[6] = 00;
+ MSB2(&CDB[7], size);
+ CDB[9] = 0;
+
+ if (SCSI_Run(INDEX_TAPECTL, Input, CDB, 10,
+ buffer,
+ size,
+ pRequestSense,
+ SIZEOF(RequestSense_T)) != 0)
+ {
+ DecodeSense(pRequestSense, "SCSI_LogSenseClean : ",debug_file);
+ free(pRequestSense);
+ free(buffer);
+ DebugPrint(DEBUG_ERROR, SECTION_TAPE,"##### STOP SCSI_LogSenseClean (0) Page could not be read.\n");
+ return(0);
+ /*NOTREACHED*/
+ }
+ if (1==(0x1 & buffer[8])){ /* Bit 0 of the 4th byte in the Clean Head Log Parameter, which are the bytes */
+ /* 4 to 8 on the Log Sense Page 0x33 */
+ ret = 1;
+ }else {
+ ret = 0;
+ }
+ DebugPrint(DEBUG_INFO, SECTION_TAPE,"##### STOP SCSI_LogSenseClean (%d)\n",ret);
+ free(pRequestSense);
+ free(buffer);
+ return(ret);
+}
+
int
GenericResetStatus(
int DeviceFD)
/*NOTREACHED*/
}
+ dbprintf(("##### STOP SCSI_LoadUnload\n"));
return(ret);
}
/*
* Some sense is set
*/
+ if (pRequestSense->ErrorCode != 0){
+ DebugPrint(DEBUG_INFO, SECTION_SCSI,"###### STOP SCSI_TestUnitReady ErrorCode set\n");
+ }
+ if (pRequestSense->SenseKey != 0) {
+ DebugPrint(DEBUG_INFO, SECTION_SCSI,"###### STOP SCSI_TestUnitReady Sense Key set\n");
+ }
DebugPrint(DEBUG_INFO, SECTION_SCSI,"###### STOP SCSI_TestUnitReady (0)\n");
return(SCSI_SENSE);
}
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: scsi-linux.c,v 1.30 2006/07/06 11:57:28 martinea Exp $
+ * $Id: scsi-linux.c,v 1.30.2.1 2006/12/12 14:56:38 martinea Exp $
*
* Interface to execute SCSI commands on Linux
*
void SCSI_OS_Version(void)
{
#ifndef lint
- static char rcsid[] = "$Id: scsi-linux.c,v 1.30 2006/07/06 11:57:28 martinea Exp $";
+ static char rcsid[] = "$Id: scsi-linux.c,v 1.30.2.1 2006/12/12 14:56:38 martinea Exp $";
DebugPrint(DEBUG_ERROR, SECTION_INFO, "scsi-os-layer: %s\n",rcsid);
#endif
}
(psg_header->result != 0))
{
dbprintf(("SCSI_ExecuteCommand error read \n"));
- dbprintf(("Status %d (%d) %2X\n", status, SCSI_OFF + DataBufferLength,psg_header->result ));
+ dbprintf(("Status %zd (%lu) %2X\n", status, SCSI_OFF + DataBufferLength,psg_header->result ));
SCSI_CloseDevice(DeviceFD);
amfree(buffer);
return(SCSI_ERROR);
{ "C1537A", "", TYPE_TAPE , UCHAR_MAX, 0x0, 0x0, SENSE_ABORT, "Nothing Found"},
/*
- * Tandberg Tape
+ * Tandberg TapeLibrary 1420
*/
{ "TDS 1420", "", TYPE_TAPE, SENSE_NULL, 0x0, 0x0, SENSE_NO, "No Sense"},
{ "TDS 1420", "", TYPE_TAPE, SENSE_NULL , UCHAR_MAX, UCHAR_MAX, SENSE_RETRY, "Default for SENSE_NULL"},
{ "TDS 1420", "", TYPE_TAPE, SENSE_UNIT_ATTENTION , UCHAR_MAX, UCHAR_MAX, SENSE_RETRY, "Default for SENSE_UNIT_ATTENTION"},
{ "TDS 1420", "", TYPE_TAPE, UCHAR_MAX, 0x0, 0x0, SENSE_ABORT, "Nothing Found"},
+
+/*
+ * Tandberg SLR100 Tape Drive
+ */
+
+ { "SLR100", "", TYPE_TAPE, SENSE_NULL, 0x0, 0x0, SENSE_NO, "No Sense"},
+ { "SLR100", "", TYPE_TAPE, SENSE_NULL ,0x00 ,0x01 , SENSE_ABORT ," FILEMARK_DETECTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NULL ,0x00 ,0x02 , SENSE_IGNORE ," END-OF-PARTITION/MEDIUM_DETECTED_ON_WRITE__LEW_PASSED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NULL ,0x00 ,0x03 , SENSE_ABORT ," SETMARK_DETECTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NULL ,0x00 ,0x04 , SENSE_ABORT ," BEGINNING-OF-PARTITION/MEDIUM_DETECTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NULL , UCHAR_MAX, UCHAR_MAX, SENSE_RETRY, "Default for SENSE_NULL"},
+
+ { "SLR100", "", TYPE_TAPE , SENSE_RECOVERED_ERROR, 0x0, 0x0, SENSE_IGNORE, "Recovered Error"},
+ { "SLR100", "", TYPE_TAPE , SENSE_RECOVERED_ERROR, 0x00, 0x17, SENSE_IGNORE, "Cleaning Requested"},
+ { "SLR100", "", TYPE_TAPE , SENSE_RECOVERED_ERROR, 0x03, 0x02, SENSE_IGNORE, "Excessive Write Errors"},
+ { "SLR100", "", TYPE_TAPE, SENSE_RECOVERED_ERROR ,0x0C ,0x05 , SENSE_ABORT ," DATA_EXPANSION_OCCURRED_DURING_COMPRESSION "},
+ { "SLR100", "", TYPE_TAPE , SENSE_RECOVERED_ERROR, 0x5B, 0x02, SENSE_IGNORE, "Log Counter at Maximum"},
+ { "SLR100", "", TYPE_TAPE, SENSE_RECOVERED_ERROR , UCHAR_MAX, UCHAR_MAX, SENSE_RETRY, "Default for SENSE_RECOVERED_ERROR"},
+
+ { "SLR100", "", TYPE_TAPE , SENSE_NOT_READY, 0x0, 0x0, SENSE_IGNORE, "Not Ready"},
+ { "SLR100", "", TYPE_TAPE, SENSE_NOT_READY ,0x04 ,0x00 , SENSE_ABORT ," LOGICAL_UNIT_NOT_READY_CAUSE_NOT_REPORTABLE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NOT_READY ,0x04 ,0x01 , SENSE_RETRY ," LOGICAL_UNIT_IS_IN_THE_PROCESS_OF_BECOMMING_READY "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NOT_READY ,0x04 ,0x02 , SENSE_ABORT ," LOGICAL-UNIT_NOT_READY_INITIALIZING_COMMAND_REQUIRED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NOT_READY ,0x30 ,0x03 , SENSE_ABORT ," CLEANING_CARTRIDGE_INSTALLED "},
+ { "SLR100", "", TYPE_TAPE ,SENSE_NOT_READY, 0x3A, 0x0, SENSE_TAPE_NOT_ONLINE, "No Tape online"},
+ { "SLR100", "", TYPE_TAPE, SENSE_NOT_READY ,0x53 ,0x02 , SENSE_ABORT ," MEDIUM_REMOVAL_PREVENTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_NOT_READY , UCHAR_MAX, UCHAR_MAX, SENSE_RETRY, "Default for SENSE_NOT_READY"},
+
+ { "SLR100", "", TYPE_TAPE ,SENSE_MEDIUM_ERROR, 0x0, 0x0, SENSE_ABORT, "Medium Error"},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x00 ,0x02 , SENSE_ABORT ," END-OF-PARTITION/MEDIUM_DETECTED_ON_READ__PHYSICAL_END_REACHED "},
+ { "SLR100", "", TYPE_TAPE ,SENSE_MEDIUM_ERROR, 0x03, 0x02, SENSE_IGNORE, "Excessive Write Errors(SERVO)"},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x09 ,0x00 , SENSE_ABORT ," TRACK_FOLLOWING_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x11 ,0x00 , SENSE_IGNORE ," UNRECOVERED_READ_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x11 ,0x01 , SENSE_IGNORE ," READ_RETRIES_EXHAUSTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x11 ,0x0D , SENSE_ABORT ," DECOMPRESSION_CRC_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x11 ,0x0E , SENSE_ABORT ," CANNOT_DECOMPRESS_USING_THE_DECLARED_ALGORITHM "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x15 ,0x01 , SENSE_ABORT ," MECHANICAL_POSITIONING_ERROR__ILLEGAL_HEAD_POSITION "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x30 ,0x01 , SENSE_ABORT ," CANNOT_READ_MEDIUM_-_UNKNOWN_FORMAT "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x30 ,0x02 , SENSE_ABORT ," CANNOT_READ_MEDIUM__INCOMPATIBLE_FORMAT "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x30 ,0x07 , SENSE_ABORT ," CLEANING_FAILURE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x50 ,0x01 , SENSE_IGNORE ," WRITE_APPEND_POSITION_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x51 ,0x00 , SENSE_ABORT ," ERASE_FAILURE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x52 ,0x00 , SENSE_ABORT ," CARTRIDGE_FAULT__BAD_CARTRIDGE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR ,0x52 ,0x00 , SENSE_IGNORE ," CARTRIDGE_FAULT__REFERENCE_BURST_SEEK_FAILURE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_MEDIUM_ERROR , UCHAR_MAX, UCHAR_MAX, SENSE_ABORT, "Default for SENSE_MEDIUM_ERROR"},
+
+ { "SLR100", "", TYPE_TAPE ,SENSE_HARDWARE_ERROR, 0x0, 0x0, SENSE_ABORT, "Hardware Error"},
+ { "SLR100", "", TYPE_TAPE, SENSE_HARDWARE_ERROR ,0x09 ,0x01 , SENSE_ABORT ," TRACKING_SERVO_FAILURE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_HARDWARE_ERROR ,0x40 ,0x80 , SENSE_ABORT ," DIAGNOSTIC_FAILURE__BUFFER_PARITY_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_HARDWARE_ERROR ,0x40 ,0x81 , SENSE_ABORT ," DIAGNOSTIC_FAILURE__WRITE_CHIP_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_HARDWARE_ERROR ,0x40 ,0xA0 , SENSE_ABORT ," DIAGNOSTIC_FAILURE__MULTIPLE_ERRORS "},
+ { "SLR100", "", TYPE_TAPE, SENSE_HARDWARE_ERROR ,0x44 ,0x00 , SENSE_ABORT ," INTERNAL_TARGET_FAILURE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_HARDWARE_ERROR , UCHAR_MAX, UCHAR_MAX, SENSE_ABORT, "Default for SENSE_HARDWARE_ERROR"},
+
+ { "SLR100", "", TYPE_TAPE ,SENSE_ILLEGAL_REQUEST, 0x0, 0x0, SENSE_ABORT, "Illegal Request"},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x1A ,0x00 , SENSE_ABORT ," PARAMETER_LIST_LENGTH_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x20 ,0x00 , SENSE_ABORT ," INVALID_COMMAND_OPERATION_CODE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x24 ,0x00 , SENSE_ABORT ," INVALID_FIELD_IN_CDB "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x25 ,0x00 , SENSE_ABORT ," LOGICAL_UNIT_NOT_SUPPORTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x26 ,0x00 , SENSE_ABORT ," INVALID_FIELD_IN_PARAMETER_LIST "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x2C ,0x00 , SENSE_ABORT ," COMMAND_SEQUENCE_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x30 ,0x00 , SENSE_ABORT ," INCOMPATIBLE_MEDIUM_INSTALLED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x30 ,0x06 , SENSE_ABORT ," CANNOT_FORMAT_MEDIUM__INCOMPATIBLE_MEDIUM "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x3D ,0x00 , SENSE_ABORT ," INVALID_BITS_IN_IDENTIFY_MESSAGE "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x43 ,0x00 , SENSE_ABORT ," MESSAGE_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST ,0x50 ,0x00 , SENSE_ABORT ," WRITE_APPEND_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ILLEGAL_REQUEST , UCHAR_MAX, UCHAR_MAX, SENSE_ABORT, "Default for SENSE_ILLEGAL_REQUEST"},
+
+ { "SLR100", "", TYPE_TAPE ,SENSE_UNIT_ATTENTION, 0x0, 0x0, SENSE_RETRY, "Unit Attention"},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x28 ,0x00 , SENSE_RETRY ," NOT_READY_TO_READY_TRANSITION__MEDIUM_MAY_HAVE_CHANGED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x29 ,0x00 , SENSE_RETRY ," POWER_ON_/_RESET_OCCURRED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x2A ,0x01 , SENSE_RETRY ," MODE_PARAMETERS_CHANGED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x2A ,0x02 , SENSE_RETRY ," LOG_PARAMETERS_CHANGED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x3F ,0x01 , SENSE_RETRY ," MICROCODE_HAS_BEEN_CHANGED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x5B ,0x01 , SENSE_RETRY ," THRESHOLD_CONDITION_MET "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION ,0x82 ,0x83 , SENSE_RETRY ," CLEANING_CARTRIDGE_EJECTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_UNIT_ATTENTION, UCHAR_MAX, UCHAR_MAX, SENSE_ABORT, "Default for SENSE_UNIT_ATTENTION"},
+
+ { "SLR100", "", TYPE_TAPE, SENSE_ABORTED_COMMAND ,0x47 ,0x00 , SENSE_RETRY ," SCSI_PARITY_ERROR "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ABORTED_COMMAND ,0x48 ,0x00 , SENSE_ABORT ," INITIATOR_DETECTED_ERROR_MESSAGE_RECEIVED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ABORTED_COMMAND ,0x4E ,0x00 , SENSE_ABORT ," OVERLAPPED_COMMANDS_ATTEMPTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_ABORTED_COMMAND ,0x53 ,0x00 , SENSE_ABORT ," MEDIA_LOAD_OR_EJECT_FAILED "},
+
+ { "SLR100", "", TYPE_TAPE, SENSE_CHG_ELEMENT_STATUS ,0x1D ,0x00 , SENSE_IGNORE ," MISCOMPARE_DURING_VERIFY_OPERATION "},
+
+ { "SLR100", "", TYPE_TAPE, SENSE_DATA_PROTECT ,0x27 ,0x05 , SENSE_ABORT ," PERMANENT_WRITE_PROTECTED_(CARTRIDGE_END_OF_LIFE) "},
+ { "SLR100", "", TYPE_TAPE, SENSE_DATA_PROTECT ,0x27 ,0x00 , SENSE_RETRY ," WRITE_PROTECTED "},
+
+ { "SLR100", "", TYPE_TAPE, SENSE_VOLUME_OVERFLOW ,0x00 ,0x02 , SENSE_IGNORE ," END-OF-PARTITION/MEDIUM_DETECTED_ON_WRITE__PHYSICAL_END_REACHED "},
+
+ { "SLR100", "", TYPE_TAPE, SENSE_BLANK_CHECK ,0x00 ,0x05 , SENSE_ABORT ," END-OF-DATA_DETECTED "},
+ { "SLR100", "", TYPE_TAPE, SENSE_BLANK_CHECK ,0x14 ,0x00 , SENSE_ABORT ," RECORDED_ENTITY_NOT_FOUND "},
+
+ { "SLR100", "", TYPE_TAPE , UCHAR_MAX, 0x0, 0x0, SENSE_ABORT, "Nothing Found"},
+
/*
* DLT 8000 Tape
*/
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amandates.h,v 1.5 2006/07/25 18:35:21 martinea Exp $
+ * $Id: amandates.h,v 1.5.2.1 2006/11/01 15:31:06 martinea Exp $
*
* interface for amandates file
*/
#define DUMP_LEVELS 10 /* XXX should be in amanda.h */
#define EPOCH ((time_t)0)
-#ifndef AMANDATES_FILE
-#define AMANDATES_FILE "/etc/amandates"
-#endif
-
typedef struct amandates_s {
struct amandates_s *next;
char *name; /* filesystem name */
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: calcsize.c,v 1.44 2006/07/25 18:27:56 martinea Exp $
+ * $Id: calcsize.c,v 1.44.2.1 2006/10/19 18:47:25 martinea Exp $
*
* traverse directory tree to get backup size estimates
*
return 0;
#else
int i;
- char *dirname=NULL, *amname=NULL, *filename=NULL, *qfilename = NULL;
+ char *dirname=NULL;
+ char *amname=NULL, *qamname = NULL;
+ char *filename=NULL, *qfilename = NULL;
unsigned long malloc_hist_1, malloc_size_1;
unsigned long malloc_hist_2, malloc_size_2;
if (argc > 0) {
amname = *argv;
+ qamname = quote_string(amname);
argc--, argv++;
} else {
error("missing <name>");
}
dbprintf(("calcsize: %s %d SIZE " OFF_T_FMT "\n",
- amname, dumplevel[i],
+ qamname, dumplevel[i],
(OFF_T_FMT_TYPE)final_size(i, dirname)));
fprintf(stderr, "%s %d SIZE " OFF_T_FMT "\n",
- amname, dumplevel[i],
+ qamname, dumplevel[i],
(OFF_T_FMT_TYPE)final_size(i, dirname));
fflush(stderr);
* University of Maryland at College Park
*/
/*
- * $Id: clientconf.c,v 1.17 2006/07/25 19:36:48 martinea Exp $
+ * $Id: clientconf.c,v 1.17.2.2 2007/01/24 18:33:29 martinea Exp $
*
* read configuration file
*/
#include "clientconf.h"
#include "clock.h"
+#ifndef AMANDATES_FILE
+#define AMANDATES_FILE "/etc/amandates"
+#endif
+
/* configuration parameters */
static char *cln_config_dir = NULL;
#else
conf_init_string(&client_conf[CLN_GNUTAR_LIST_DIR], NULL);
#endif
- conf_init_string(&client_conf[CLN_AMANDATES], "/etc/amandates");
+ conf_init_string(&client_conf[CLN_AMANDATES], AMANDATES_FILE);
/* defaults for internal variables */
conf_line_num = got_parserror = 0;
nb_option = 0;
for(command_option = client_options; command_option->name != NULL;
command_option++) {
- if(strcasecmp(command_option->name, kt->keyword) == 0) {
- return -1;
- }
nb_option++;
}
* University of Maryland at College Park
*/
/*
- * $Id: selfcheck.c,v 1.95 2006/08/29 11:21:00 martinea Exp $
+ * $Id: selfcheck.c,v 1.95.2.2 2007/01/19 01:03:34 martinea Exp $
*
* do self-check and send back any error messages
*/
static void check_disk(char *program, char *calcprog, char *disk, char *amdevice, int level, char *optstr);
static void check_overall(void);
static void check_access(char *filename, int mode);
+static int check_file_exist(char *filename);
static void check_file(char *filename, int mode);
static void check_dir(char *dirname, int mode);
static void check_suid(char *filename);
amode = F_OK;
amfree(device);
device = amname_to_dirname(amdevice);
- } else if (strcmp(program, "DUMP") == 0) {
+ } else if (strcmp(myprogram, "DUMP") == 0) {
if(amdevice[0] == '/' && amdevice[1] == '/') {
err = vstralloc("The DUMP program cannot handle samba shares,",
" use GNUTAR: ",
}
}
- if( need_compress_path )
+ if (need_compress_path )
check_file(COMPRESS_PATH, X_OK);
- if( need_dump || need_xfsdump )
- check_file("/etc/dumpdates",
+ if (need_dump || need_xfsdump ) {
+ if (check_file_exist("/etc/dumpdates")) {
+ check_file("/etc/dumpdates",
#ifdef USE_RUNDUMP
- F_OK
+ F_OK
#else
- R_OK|W_OK
+ R_OK|W_OK
#endif
- );
+ );
+ } else {
+#ifndef USE_RUNDUMP
+ if (access("/etc", R_OK|W_OK) == -1) {
+ printf("ERROR [dump will not be able to create the /etc/dumpdates file: %s]\n", strerror(errno));
+ }
+#endif
+ }
+ }
- if (need_vdump)
- check_file("/etc/vdumpdates", F_OK);
+ if (need_vdump) {
+ if (check_file_exist("/etc/vdumpdates")) {
+ check_file("/etc/vdumpdates", F_OK);
+ }
+ }
check_access("/dev/null", R_OK|W_OK);
check_space(AMANDA_TMPDIR, (off_t)64); /* for amandad i/o */
amfree(quoted);
}
+static int
+check_file_exist(
+ char *filename)
+{
+ struct stat stat_buf;
+
+ if (stat(filename, &stat_buf) != 0) {
+ if(errno == ENOENT) {
+ return 0;
+ }
+ }
+ return 1;
+}
+
static void
check_file(
char * filename,
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: sendbackup-dump.c,v 1.90.2.1 2006/09/23 19:19:47 martinea Exp $
+ * $Id: sendbackup-dump.c,v 1.90.2.2 2006/11/24 18:10:38 martinea Exp $
*
* send backup data using BSD dump
*/
#define RESTORE "restore"
#endif
+#ifdef HAVE_HONOR_NODUMP
+# define PARAM_HONOR_NODUMP "h"
+#else
+# define PARAM_HONOR_NODUMP ""
+#endif
dumpkeys = vstralloc(level_str,
options->no_record ? "" : "u",
"s",
-#ifdef HAVE_HONOR_NODUMP
- "h",
-#endif
+ PARAM_HONOR_NODUMP,
"f",
NULL);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: sendbackup-gnutar.c,v 1.98 2006/07/25 18:35:21 martinea Exp $
+ * $Id: sendbackup-gnutar.c,v 1.98.2.1 2006/11/24 18:10:38 martinea Exp $
*
* send backup data using GNU tar
*/
cur_dumptime = time(0);
cur_level = level;
cur_disk = stralloc(disk);
- indexcmd = vstralloc(
#ifdef GNUTAR
- GNUTAR,
+# define PROGRAM_GNUTAR GNUTAR
#else
- "tar",
+# define PROGRAM_GNUTAR "tar"
#endif
+ indexcmd = vstralloc(
+ PROGRAM_GNUTAR,
" -tf", " -",
" 2>/dev/null",
" | sed", " -e",
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: sendbackup.c,v 1.88 2006/07/25 18:27:56 martinea Exp $
+ * $Id: sendbackup.c,v 1.88.2.3 2006/12/12 14:56:38 martinea Exp $
*
* common code for the sendbackup-* programs.
*/
fflush(stdout);
if (freopen("/dev/null", "w", stdout) == NULL) {
dbprintf(("%s: error redirecting stdout to /dev/null: %s\n",
- debug_prefix_time(NULL), mesgfd, strerror(errno)));
+ debug_prefix_time(NULL), strerror(errno)));
exit(1);
}
amwait_t w)
{
char *thiserr = NULL;
- char *str;
+ char *str, *strX;
int ret, sig, rc;
char number[NUM_STR_SIZE];
+ char numberpid[NUM_STR_SIZE];
str = childstr(pid);
* but the failure is noted.
*/
if(ret != 0) {
- fprintf(stderr, "? %s returned %d\n", str, ret);
+ fprintf(stderr, "? index %s returned %d\n", str, ret);
rc = 0;
}
- }
-
-#ifndef HAVE_GZIP
- if(pid == comppid) {
+ indexpid = -1;
+ strX = "index ";
+ } else if(pid == comppid) {
/*
* compress returns 2 sometimes, but it is ok.
*/
+#ifndef HAVE_GZIP
if(ret == 2) {
rc = 0;
}
- }
#endif
-
-#ifdef DUMP_RETURNS_1
- if(pid == dumppid && tarpid == -1) {
+ comppid = -1;
+ strX = "compress ";
+ } else if(pid == dumppid && tarpid == -1) {
/*
* Ultrix dump returns 1 sometimes, but it is ok.
*/
+#ifdef DUMP_RETURNS_1
if(ret == 1) {
rc = 0;
}
- }
#endif
-
-#ifdef IGNORE_TAR_ERRORS
- if(pid == tarpid) {
+ dumppid = -1;
+ strX = "dump ";
+ } else if(pid == tarpid) {
+ if (ret == 1) {
+ rc = 0;
+ }
/*
* tar bitches about active filesystems, but we do not care.
*/
+#ifdef IGNORE_TAR_ERRORS
if(ret == 2) {
rc = 0;
}
- }
#endif
+ dumppid = tarpid = -1;
+ strX = "dump ";
+ } else {
+ strX = "unknown ";
+ }
if(rc == 0) {
return 0; /* normal exit */
}
+ snprintf(numberpid, SIZEOF(number), "%d", (int)pid);
if(ret == 0) {
snprintf(number, SIZEOF(number), "%d", sig);
- thiserr = vstralloc(str, " got signal ", number, NULL);
+ thiserr = vstralloc(strX, "(", numberpid, ") ", str, " got signal ", number, NULL);
} else {
snprintf(number, SIZEOF(number), "%d", ret);
- thiserr = vstralloc(str, " returned ", number, NULL);
+ thiserr = vstralloc(strX, "(", numberpid, ") ", str, " returned ", number, NULL);
}
if(errorstr) {
/*NOTREACHED*/
}
- while((wpid = wait(&retstat)) != -1) {
+ while((wpid = waitpid((pid_t)-1, &retstat, WNOHANG)) > 0) {
if(check_status(wpid, retstat)) goterror = 1;
}
+ if (dumppid != -1) {
+ sleep(5);
+ while((wpid = waitpid((pid_t)-1, &retstat, WNOHANG)) > 0) {
+ if(check_status(wpid, retstat)) goterror = 1;
+ }
+ }
+ if (dumppid != -1) {
+ dbprintf(("%s: Sending SIGHUP to dump process %d\n",
+ debug_prefix_time(NULL), (int)dumppid));
+ if(dumppid != -1) {
+ if(kill(dumppid, SIGHUP) == -1) {
+ dbprintf(("%s: Can't send SIGHUP to %d: %s\n",
+ debug_prefix_time(NULL), (int)dumppid,
+ strerror(errno)));
+ }
+ }
+ sleep(5);
+ while((wpid = waitpid((pid_t)-1, &retstat, WNOHANG)) > 0) {
+ if(check_status(wpid, retstat)) goterror = 1;
+ }
+ }
+ if (dumppid != -1) {
+ dbprintf(("%s: Sending SIGKILL to dump process %d\n",
+ debug_prefix_time(NULL), (int)dumppid));
+ if(dumppid != -1) {
+ if(kill(dumppid, SIGKILL) == -1) {
+ dbprintf(("%s: Can't send SIGKILL to %d: %s\n",
+ debug_prefix_time(NULL), (int)dumppid,
+ strerror(errno)));
+ }
+ }
+ sleep(5);
+ while((wpid = waitpid((pid_t)-1, &retstat, WNOHANG)) > 0) {
+ if(check_status(wpid, retstat)) goterror = 1;
+ }
+ }
+
if(errorstr) {
error("error [%s]", errorstr);
/*NOTREACHED*/
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: sendsize.c,v 1.171.2.1 2006/09/22 11:51:32 martinea Exp $
+ * $Id: sendsize.c,v 1.171.2.4 2006/12/22 14:42:42 martinea Exp $
*
* send estimated backup sizes using dump
*/
char *qamdevice = NULL;
char *conffile;
char *amandates_file;
+ int amandates_read = 0;
#if defined(USE_DBMALLOC)
unsigned long malloc_hist_1, malloc_size_1;
unsigned long malloc_hist_2, malloc_size_2;
/* handle all service requests */
- amandates_file = client_getconf_str(CLN_AMANDATES);
- if(!start_amandates(amandates_file, 0))
- error("error [opening %s: %s]", amandates_file, strerror(errno));
-
for(; (line = agets(stdin)) != NULL; free(line)) {
if (line[0] == '\0')
continue;
continue;
}
+ if (amandates_read == 0) {
+ amandates_file = client_getconf_str(CLN_AMANDATES);
+ if(!start_amandates(amandates_file, 0))
+ error("error [opening %s: %s]", amandates_file,
+ strerror(errno));
+ amandates_read = 1;
+ }
+
s = line;
ch = *s++;
char *qdisk = quote_string(disk);
char *qdevice;
char *config;
-#ifdef DUMP
+#if defined(DUMP) || defined(VDUMP) || defined(VXDUMP) || defined(XFSDUMP)
int is_rundump = 1;
#endif
dbprintf(("%s: running \"%s%s %s - %s\"\n",
debug_prefix_time(NULL), cmd, name, dumpkeys, qdevice));
# else /* } { */
+# ifdef HAVE_DUMP_ESTIMATE
+# define PARAM_DUMP_ESTIMATE HAVE_DUMP_ESTIMATE
+# else
+# define PARAM_DUMP_ESTIMATE ""
+# endif
+# ifdef HAVE_HONOR_NODUMP
+# define PARAM_HONOR_NODUMP "h"
+# else
+# define PARAM_HONOR_NODUMP ""
+# endif
dumpkeys = vstralloc(level_str,
-# ifdef HAVE_DUMP_ESTIMATE /* { */
- HAVE_DUMP_ESTIMATE,
-# endif /* } */
-# ifdef HAVE_HONOR_NODUMP /* { */
- "h",
-# endif /* } */
+ PARAM_DUMP_ESTIMATE,
+ PARAM_DUMP_ESTIMATE,
"s", "f", NULL);
# ifdef HAVE_DUMP_ESTIMATE
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amanda.h,v 1.131 2006/07/25 18:27:56 martinea Exp $
+ * $Id: amanda.h,v 1.131.2.5 2006/12/12 14:56:38 martinea Exp $
*
* the central header file included by all amanda sources
*/
* for printf-like functions). Only do this in gcc 2.7 or later ...
* it may work on earlier stuff, but why chance it.
*/
-#if !defined(__GNUC__) || __GNUC__ < 2 || __GNUC_MINOR__ < 7 || defined(S_SPLINT_S) || defined(LINT) || defined(__lint)
+#if !defined(__GNUC__) || __GNUC__ < 2 || (__GNUC__ == 2 && __GNUC_MINOR__ < 7) || defined(S_SPLINT_S) || defined(LINT) || defined(__lint)
#undef __attribute__
#define __attribute__(__x)
#endif
#else /* }{ */
# define dbopen(a)
# define dbreopen(a,b)
+# define dbrename(a,b)
# define dbclose()
# define dbprintf(p)
# define dbfd() (-1)
extern int mkpdir(char *file, mode_t mode, uid_t uid, gid_t gid);
extern int rmpdir(char *file, char *topdir);
extern char *sanitise_filename(char *inp);
+extern char *old_sanitise_filename(char *inp);
/* from old bsd-security.c */
extern int debug;
#endif
#if SIZEOF_OFF_T > SIZEOF_LONG
-# define OFF_T_FMT "%lld"
-# define OFF_T_RFMT "lld"
+# define OFF_T_FMT LL_FMT
+# define OFF_T_RFMT LL_RFMT
# define OFF_T_FMT_TYPE long long
-# define OFF_T_ATOI (off_t)atoll
-# define OFF_T_STRTOL (off_t)strtoll
+# ifdef HAVE_ATOLL
+# define OFF_T_ATOI (off_t)atoll
+# else
+# define OFF_T_ATOI (off_t)atol
+# endif
+# ifdef HAVE_STRTOLL
+# define OFF_T_STRTOL (off_t)strtoll
+# else
+# define OFF_T_STRTOL (off_t)strtol
+# endif
#else
# if SIZEOF_OFF_T == SIZEOF_LONG
# define OFF_T_FMT "%ld"
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: bsd-security.c,v 1.75 2006/07/19 17:41:14 martinea Exp $
+ * $Id: bsd-security.c,v 1.75.2.1 2006/09/28 18:46:08 martinea Exp $
*
* "BSD" security module
*/
STREAM_BUFSIZE, STREAM_BUFSIZE, &bs->port, 0);
if (bs->fd < 0) {
security_seterror(&bh->sech,
- "can't connect stream to %s port %hd: %s", bh->hostname,
+ "can't connect stream to %s port %d: %s", bh->hostname,
id, strerror(errno));
amfree(bs);
return (NULL);
*/
/*
- * $Id: bsdtcp-security.c,v 1.7.2.1 2006/09/12 14:30:47 martinea Exp $
+ * $Id: bsdtcp-security.c,v 1.7.2.2 2006/09/29 11:28:55 martinea Exp $
*
* bsdtcp-security.c - security and transport over bsdtcp or a bsdtcp-like command.
*
struct hostent *he;
len = sizeof(sin);
- if (getpeername(in, (struct sockaddr *)&sin, &len) < 0)
+ if (getpeername(in, (struct sockaddr *)&sin, &len) < 0) {
+ dbprintf(("%s: getpeername returned: %s\n", debug_prefix_time(NULL),
+ strerror(errno)));
return;
+ }
he = gethostbyaddr((void *)&sin.sin_addr, sizeof(sin.sin_addr), AF_INET);
- if (he == NULL)
+ if (he == NULL) {
+ dbprintf(("%s: he returned NULL: h_errno = %d\n",
+ debug_prefix_time(NULL), h_errno));
return;
+ }
rc = sec_tcp_conn_get(he->h_name, 0);
rc->recv_security_ok = &bsd_recv_security_ok;
* University of Maryland at College Park
*/
/*
- * $Id: clock.c,v 1.7 2006/07/27 18:12:10 martinea Exp $
+ * $Id: clock.c,v 1.7.2.1 2007/02/06 12:44:03 martinea Exp $
*
* timing functions
*/
end.tv_usec += 1000000;
}
diff.tv_usec = end.tv_usec - start.tv_usec;
- diff.tv_sec = end.tv_sec - start.tv_sec;
+
+ if (end.tv_sec > start.tv_sec)
+ diff.tv_sec = end.tv_sec - start.tv_sec;
+ else
+ diff.tv_sec = 0;
+
return diff;
}
* University of Maryland at College Park
*/
/*
- * $Id: dgram.c,v 1.32.2.3 2006/09/20 12:48:54 martinea Exp $
+ * $Id: dgram.c,v 1.32.2.4 2006/10/16 18:23:53 martinea Exp $
*
* library routines to marshall/send, recv/unmarshall UDP packets
*/
arglist_start(argp, fmt);
len = vsnprintf(dgram->cur, (size_t)bufsize, fmt, argp);
arglist_end(argp);
- if((ssize_t)len > bufsize) {
+ if(len < 0) {
+ return -1;
+ } else if((ssize_t)len > bufsize) {
dgram->len = sizeof(dgram->data);
dgram->cur = dgram->data + dgram->len;
return -1;
}
else {
- arglist_start(argp, fmt);
- dgram->len += vsnprintf(dgram->cur, (size_t)bufsize, fmt, argp);
- arglist_end(argp);
+ dgram->len += len;
dgram->cur = dgram->data + dgram->len;
}
return 0;
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: event.c,v 1.24 2006/06/16 10:55:05 martinea Exp $
+ * $Id: event.c,v 1.24.2.1 2006/12/12 14:56:38 martinea Exp $
*
* Event handler. Serializes different kinds of events to allow for
* a uniform interface, central state storage, and centralized
if ((type == EV_READFD) || (type == EV_WRITEFD)) {
/* make sure we aren't given a high fd that will overflow a fd_set */
if (data >= FD_SETSIZE) {
- error("event_register: Invalid file descriptor %d", data);
+ error("event_register: Invalid file descriptor %lu", data);
/*NOTREACHED*/
}
#if !defined(__lint) /* Global checking knows that these are never called */
} else if (type == EV_SIG) {
/* make sure signals are within range */
if (data >= NSIG) {
- error("event_register: Invalid signal %d", data);
+ error("event_register: Invalid signal %lu", data);
/*NOTREACHED*/
}
if (sigtable[data].handle != NULL) {
- error("event_register: signal %d already registered", data);
+ error("event_register: signal %lu already registered", data);
/*NOTREACHED*/
}
} else if (type >= EV_DEAD) {
* Author: AMANDA core development group.
*/
/*
- * $Id: file.c,v 1.40 2006/07/19 17:41:15 martinea Exp $
+ * $Id: file.c,v 1.40.2.1 2006/11/24 18:05:05 martinea Exp $
*
* file and directory bashing routines
*/
return buf;
}
+/* duplicate '_' */
+char *
+old_sanitise_filename(
+ char * inp)
+{
+ char *buf;
+ size_t buf_size;
+ char *s, *d;
+ int ch;
+
+ buf_size = 2*strlen(inp) + 1; /* worst case */
+ buf = alloc(buf_size);
+ d = buf;
+ s = inp;
+ while((ch = *s++) != '\0') {
+ if(ch == '_') {
+ *d++ = (char)ch;
+ }
+ if(ch == '/') {
+ ch = '_'; /* convert "bad" to "_" */
+ }
+ *d++ = (char)ch;
+ }
+ assert(d < buf + buf_size);
+ *d = '\0';
+
+ return buf;
+}
+
/*
*=====================================================================
* Get the next line of input from a stdio file.
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: packet.c,v 1.8.2.1 2006/09/22 11:02:12 martinea Exp $
+ * $Id: packet.c,v 1.8.2.4 2006/12/18 20:43:50 martinea Exp $
*
* Routines for modifying the amanda protocol packet type
*/
/*
* Initialize a packet
*/
+void pkt_init_empty(
+ pkt_t *pkt,
+ pktype_t type)
+{
+ assert(pkt != NULL);
+ assert(strcmp(pkt_type2str(type), "BOGUS") != 0);
+
+ pkt->type = type;
+ pkt->packet_size = 1000;
+ pkt->body = alloc(pkt->packet_size);
+ pkt->body[0] = '\0';
+ pkt->size = strlen(pkt->body);
+}
+
printf_arglist_function2(void pkt_init, pkt_t *, pkt, pktype_t, type,
const char *, fmt)
{
arglist_start(argp, fmt);
len = vsnprintf(pkt->body, pkt->packet_size, fmt, argp);
arglist_end(argp);
- if (len < (int)(pkt->packet_size - 1))
+ if (len > -1 && len < (int)(pkt->packet_size - 1))
break;
pkt->packet_size *= 2;
amfree(pkt->body);
arglist_start(argp, fmt);
lenX = vsnprintf(pkt->body + len, pkt->packet_size - len, fmt,argp);
arglist_end(argp);
- if (lenX < (int)(pkt->packet_size - len - 1))
+ if (lenX > -1 && lenX < (int)(pkt->packet_size - len - 1))
break;
pkt->packet_size *= 2;
pktbody = alloc(pkt->packet_size);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: packet.h,v 1.8 2006/05/25 01:47:12 johnfranks Exp $
+ * $Id: packet.h,v 1.8.2.1 2006/12/18 20:43:51 martinea Exp $
*
* interfaces for modifying amanda protocol packet type
*/
/*
* Initialize a packet
*/
+void pkt_init_empty(pkt_t *pkt, pktype_t type);
void pkt_init(pkt_t *, pktype_t, const char *, ...)
__attribute__ ((format (printf, 3, 4)));
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: protocol.c,v 1.45 2006/05/25 17:07:31 martinea Exp $
+ * $Id: protocol.c,v 1.45.2.2 2006/12/18 20:43:51 martinea Exp $
*
* implements amanda protocol
*/
return (PA_PENDING);
if(pkt->type == P_REP) {
- pkt_init(&ack, P_ACK, "");
+ pkt_init_empty(&ack, P_ACK);
if (security_sendpkt(p->security_handle, &ack) < 0) {
/* XXX should retry */
amfree(ack.body);
*/
/*
- * $Id: rsh-security.c,v 1.31 2006/08/21 20:17:10 martinea Exp $
+ * $Id: rsh-security.c,v 1.31.2.1 2006/10/25 19:13:11 martinea Exp $
*
* rsh-security.c - security and transport over rsh or a rsh-like command.
*
rh->hostname = NULL;
rh->rs = NULL;
rh->ev_timeout = NULL;
+ rh->rc = NULL;
+
if ((he = gethostbyname(hostname)) == NULL) {
security_seterror(&rh->sech,
*/
/*
- * $Id: security-util.c,v 1.25 2006/07/22 12:04:47 martinea Exp $
+ * $Id: security-util.c,v 1.25.2.10 2007/01/24 00:35:14 martinea Exp $
*
* sec-security.c - security and transport over sec or a sec-like command.
*
}
*size = (ssize_t)ntohl(netint[0]);
- if (*size > NETWORK_BLOCK_BYTES) {
- *errmsg = newvstralloc(*errmsg, "tcpm_recv_token: invalid size",
+ *handle = (int)ntohl(netint[1]);
+ /* amanda protocol packet can be above NETWORK_BLOCK_BYTES */
+ if (*size > 128*NETWORK_BLOCK_BYTES || *size < 0) {
+ if (isprint((*size ) & 0xFF) &&
+ isprint((*size >> 8 ) & 0xFF) &&
+ isprint((*size >> 16) & 0xFF) &&
+ isprint((*size >> 24) & 0xFF) &&
+ isprint((*handle ) & 0xFF) &&
+ isprint((*handle >> 8 ) & 0xFF) &&
+ isprint((*handle >> 16) & 0xFF) &&
+ isprint((*handle >> 24) & 0xFF)) {
+ char s[101];
+ int i;
+ s[0] = (*size >> 24) & 0xFF;
+ s[1] = (*size >> 16) & 0xFF;
+ s[2] = (*size >> 8) & 0xFF;
+ s[3] = (*size ) & 0xFF;
+ s[4] = (*handle >> 24) & 0xFF;
+ s[5] = (*handle >> 16) & 0xFF;
+ s[6] = (*handle >> 8 ) & 0xFF;
+ s[7] = (*handle ) & 0xFF;
+ i = 8; s[i] = ' ';
+ while(i<100 && isprint(s[i]) && s[i] != '\n') {
+ switch(net_read(fd, &s[i], 1, 0)) {
+ case -1: s[i] = '\0'; break;
+ case 0: s[i] = '\0'; break;
+ default: dbprintf(("read: %c\n", s[i])); i++; s[i]=' ';break;
+ }
+ }
+ s[i] = '\0';
+ *errmsg = newvstralloc(*errmsg, "tcpm_recv_token: invalid size: ",
+ s, NULL);
+ dbprintf(("%s: tcpm_recv_token: invalid size: %s\n",
+ debug_prefix_time(NULL), s));
+ } else {
+ *errmsg = newvstralloc(*errmsg, "tcpm_recv_token: invalid size",
NULL);
- dbprintf(("%s: tcpm_recv_token: invalid size %d\n",
- debug_prefix_time(NULL), *size));
+ dbprintf(("%s: tcpm_recv_token: invalid size %zd\n",
+ debug_prefix_time(NULL), *size));
+ }
*size = -1;
return -1;
}
amfree(*buf);
*buf = alloc((size_t)*size);
- *handle = (int)ntohl(netint[1]);
if(*size == 0) {
secprintf(("%s: tcpm_recv_token: read EOF from %d\n",
break;
}
- secprintf(("%s: tcpm_recv_token: read %ld bytes from %d\n",
+ secprintf(("%s: tcpm_recv_token: read %zd bytes from %d\n",
debug_prefix_time(NULL), *size, *handle));
return((*size));
}
if (id <= 0) {
security_seterror(&rh->sech,
- "%hd: invalid security stream id", id);
+ "%d: invalid security stream id", id);
return (NULL);
}
rh->rc = rs->rc;
}
- secprintf(("%s: sec: stream_client: connected to stream %hd\n",
+ secprintf(("%s: sec: stream_client: connected to stream %d\n",
debug_prefix_time(NULL), id));
return (rs);
return (NULL);
}
assert(strcmp(rh->hostname, rs->rc->hostname) == 0);
- //amfree(rh->hostname);
- //rh->hostname = stralloc(rs->rc->hostname);
/*
* so as not to conflict with the amanda server's handle numbers,
* we start at 500000 and work down
SIZEOF(rh->udp->peer.sin_addr)) != 0 ||
rh->peer.sin_port != rh->udp->peer.sin_port) {
amfree(rh->udp->handle);
- //rh->udp->handle = NULL;
return;
}
/*
* Save the hostname and port info
*/
- secprintf(("%s: udp_inithandle port %hd handle %s sequence %d\n",
- debug_prefix_time(NULL), ntohs(port),
+ secprintf(("%s: udp_inithandle port %u handle %s sequence %d\n",
+ debug_prefix_time(NULL), (unsigned int)ntohs(port),
handle, sequence));
assert(he != NULL);
if (strncasecmp(rh->hostname, he->h_name, strlen(rh->hostname)) != 0) {
secprintf(("%s: udp: cc\n", debug_prefix_time(NULL)));
security_seterror(&rh->sech,
- "%s: did not resolve to itself, it resolv to",
+ "%s: did not resolve to itself, it resolv to %s",
rh->hostname, he->h_name);
return (-1);
}
return;
}
secprintf((
- "%s: sec: stream_read_callback_sync: read %ld bytes from %s:%d\n",
+ "%s: sec: stream_read_callback_sync: read %zd bytes from %s:%d\n",
debug_prefix_time(NULL),
rs->rc->pktlen, rs->rc->hostname, rs->handle));
}
(*rs->fn)(rs->arg, NULL, rs->rc->pktlen);
return;
}
- secprintf(("%s: sec: stream_read_callback: read %ld bytes from %s:%d\n",
+ secprintf(("%s: sec: stream_read_callback: read %zd bytes from %s:%d\n",
debug_prefix_time(NULL),
rs->rc->pktlen, rs->rc->hostname, rs->handle));
(*rs->fn)(rs->arg, rs->rc->pkt, rs->rc->pktlen);
/* delete our 'accept' reference */
if (rc->accept_fn != NULL) {
if(rc->refcnt != 1) {
- dbprintf(("STRANGE, rc->refcnt should be 1"));
+ dbprintf(("STRANGE, rc->refcnt should be 1, it is %d\n",
+ rc->refcnt));
rc->refcnt=1;
}
rc->accept_fn = NULL;
if ((tok = strtok(NULL, " ")) == NULL)
goto parse_error;
amfree(pkt->body);
- pkt_init(pkt, pkt_str2type(tok), "");
+ pkt_init_empty(pkt, pkt_str2type(tok));
if (pkt->type == (pktype_t)-1)
goto parse_error;
if (ntohs(addr->sin_port) >= IPPORT_RESERVED) {
char number[NUM_STR_SIZE];
- snprintf(number, SIZEOF(number), "%hd", (short)ntohs(addr->sin_port));
+ snprintf(number, SIZEOF(number), "%u",
+ (unsigned int)ntohs(addr->sin_port));
*errstr = vstralloc("[",
"host ", remotehost, ": ",
"port ", number, " not secure",
* University of Maryland at College Park
*/
/*
- * $Id: stream.c,v 1.39 2006/08/24 01:57:15 paddy_s Exp $
+ * $Id: stream.c,v 1.39.2.1 2006/12/12 14:56:38 martinea Exp $
*
* functions for managing stream sockets
*/
size -= 1024;
}
if(size > 1024) {
- dbprintf(("%s: try_socksize: %s buffer size is %d\n",
+ dbprintf(("%s: try_socksize: %s buffer size is %zu\n",
debug_prefix(NULL),
(which == SO_SNDBUF) ? "send" : "receive",
size));
} else {
- dbprintf(("%s: try_socksize: could not allocate %s buffer of %d\n",
+ dbprintf(("%s: try_socksize: could not allocate %s buffer of %zu\n",
debug_prefix(NULL),
(which == SO_SNDBUF) ? "send" : "receive",
origsize));
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: util.c,v 1.42.2.4 2006/09/21 11:12:21 martinea Exp $
+ * $Id: util.c,v 1.42.2.13 2007/01/24 18:33:29 martinea Exp $
*/
#include "amanda.h"
if (connect(s, (struct sockaddr *)svaddr,
(socklen_t)sizeof(*svaddr)) == -1 && !nonblock) {
save_errno = errno;
- dbprintf(("%s: connect_portrange: connect from %s.%d failed\n",
+ dbprintf(("%s: connect_portrange: connect from %s.%d failed: %s\n",
debug_prefix_time(NULL),
inet_ntoa(addrp->sin_addr),
ntohs(addrp->sin_port),
*(s++) = 'f';
str++;
continue;
+ } else if (*str == '\\') {
+ *(s++) = '\\';
+ *(s++) = '\\';
+ str++;
+ continue;
}
if (*str == '"')
*(s++) = '\\';
/* switch to binary search if performance warrants */
for(kwp = keytable; kwp->keyword != NULL; kwp++) {
- if (strcmp(kwp->keyword, str) == 0) break;
+ if (strcasecmp(kwp->keyword, str) == 0) break;
}
return kwp->token;
}
buf = tkbuf;
token_overflow = 0;
do {
- if (islower(ch)) ch = toupper(ch);
if (buf < tkbuf+sizeof(tkbuf)-1) {
*buf++ = (char)ch;
} else {
break;
case CONFTYPE_EXINCLUDE:
- valdst->v.exinclude.type = valsrc->v.exinclude.type;
valdst->v.exinclude.optional = valsrc->v.exinclude.optional;
- valdst->v.exinclude.sl = duplicate_sl(valsrc->v.exinclude.sl);
+ valdst->v.exinclude.sl_list = duplicate_sl(valsrc->v.exinclude.sl_list);
+ valdst->v.exinclude.sl_file = duplicate_sl(valsrc->v.exinclude.sl_file);
break;
}
}
break;
case CONFTYPE_EXINCLUDE:
- free_sl(val->v.exinclude.sl);
+ free_sl(val->v.exinclude.sl_list);
+ free_sl(val->v.exinclude.sl_file);
break;
}
val->seen = 0;
char *
conf_print(
- val_t *val)
+ val_t *val,
+ int str_need_quote)
{
- struct tm *stm;
- int pos;
-
buffer_conf_print[0] = '\0';
switch(val->type) {
case CONFTYPE_INT:
break;
case CONFTYPE_STRING:
- buffer_conf_print[0] = '"';
- if(val->v.s) {
- strncpy(&buffer_conf_print[1], val->v.s,
- SIZEOF(buffer_conf_print) - 1);
- buffer_conf_print[SIZEOF(buffer_conf_print) - 2] = '\0';
- buffer_conf_print[strlen(buffer_conf_print)] = '"';
+ if(str_need_quote) {
+ buffer_conf_print[0] = '"';
+ if(val->v.s) {
+ strncpy(&buffer_conf_print[1], val->v.s,
+ SIZEOF(buffer_conf_print) - 1);
+ buffer_conf_print[SIZEOF(buffer_conf_print) - 2] = '\0';
+ buffer_conf_print[strlen(buffer_conf_print)] = '"';
+ } else {
+ buffer_conf_print[1] = '"';
+ buffer_conf_print[2] = '\0';
+ }
} else {
- buffer_conf_print[1] = '"';
- buffer_conf_print[2] = '\0';
+ if(val->v.s) {
+ strncpy(&buffer_conf_print[0], val->v.s,
+ SIZEOF(buffer_conf_print));
+ buffer_conf_print[SIZEOF(buffer_conf_print) - 1] = '\0';
+ } else {
+ buffer_conf_print[0] = '\0';
+ }
}
break;
case CONFTYPE_TIME:
- stm = localtime(&val->v.t);
- if (stm) {
- snprintf(buffer_conf_print, SIZEOF(buffer_conf_print),
- "%d%02d%02d", stm->tm_hour, stm->tm_min, stm->tm_sec);
- } else {
- strcpy(buffer_conf_print, "00000");
- }
+ snprintf(buffer_conf_print, SIZEOF(buffer_conf_print),
+ "%2d%02d", (int)val->v.t/100, (int)val->v.t % 100);
break;
case CONFTYPE_SL:
break;
case CONFTYPE_EXINCLUDE:
- buffer_conf_print[0] = '\0';
- if(val->v.exinclude.type == 0)
- strncpy(buffer_conf_print, "LIST ", SIZEOF(buffer_conf_print));
- else
- strncpy(buffer_conf_print, "FILE ", SIZEOF(buffer_conf_print));
- pos = 5;
- if(val->v.exinclude.optional == 1)
- strncpy(&buffer_conf_print[pos], "OPTIONAL ", SIZEOF(buffer_conf_print));
- pos += 9;
+ strcpy(buffer_conf_print, "ERROR: use print_conf_exinclude");
break;
case CONFTYPE_BOOL:
return buffer_conf_print;
}
+char *
+conf_print_exinclude(
+ val_t *val,
+ int str_need_quote,
+ int file)
+{
+ int pos;
+ sl_t *sl;
+ sle_t *excl;
+
+ (void)str_need_quote;
+ buffer_conf_print[0] = '\0';
+ if (val->type != CONFTYPE_EXINCLUDE) {
+ strcpy(buffer_conf_print, "ERROR: conf_print_exinclude called for type != CONFTYPE_EXINCLUDE");
+ return buffer_conf_print;
+ }
+
+ if (file == 0) {
+ sl = val->v.exinclude.sl_list;
+ strncpy(buffer_conf_print, "LIST ", SIZEOF(buffer_conf_print));
+ pos = 5;
+ } else {
+ sl = val->v.exinclude.sl_file;
+ strncpy(buffer_conf_print, "FILE ", SIZEOF(buffer_conf_print));
+ pos = 5;
+ }
+
+ if(val->v.exinclude.optional == 1) {
+ strncpy(&buffer_conf_print[pos], "OPTIONAL ", SIZEOF(buffer_conf_print)-pos);
+ pos += 9;
+ }
+
+ if( sl != NULL) {
+ for(excl = sl->first; excl != NULL; excl = excl->next) {
+ if (pos + 3 + strlen(excl->name) < SIZEOF(buffer_conf_print)) {
+ buffer_conf_print[pos++] = ' ';
+ buffer_conf_print[pos++] = '"';
+ strcpy(&buffer_conf_print[pos], excl->name);
+ pos += strlen(excl->name);
+ buffer_conf_print[pos++] = '"';
+ }
+ }
+ }
+
+ buffer_conf_print[SIZEOF(buffer_conf_print) - 1] = '\0';
+ return buffer_conf_print;
+}
+
void
conf_init_string(
val_t *val,
{
val->seen = 0;
val->type = CONFTYPE_EXINCLUDE;
- val->v.exinclude.type = 0;
val->v.exinclude.optional = 0;
- val->v.exinclude.sl = NULL;
+ val->v.exinclude.sl_list = NULL;
+ val->v.exinclude.sl_file = NULL;
}
void
keytab_t *kt;
char *myprefix;
command_option_t *command_option;
+ int duplicate;
if(!command_options) return;
/* NOTREACHED */
}
- for(command_option = command_options; command_option->name != NULL;
+ for(command_option = command_options; command_option->name != NULL;
command_option++) {
myprefix = stralloc2(prefix, kt->keyword);
if(strcasecmp(myprefix, command_option->name) == 0) {
+ duplicate = 0;
+ if (command_option->used == 0 &&
+ valarray[np->parm].seen == -2) {
+ duplicate = 1;
+ }
command_option->used = 1;
valarray[np->parm].seen = -2;
if(np->type == CONFTYPE_STRING &&
amfree(conf_line);
conf_line = conf_char = NULL;
- if(np->validate)
+ if (np->validate)
np->validate(np, &valarray[np->parm]);
+ if (duplicate == 1) {
+ fprintf(stderr,"Duplicate %s option, using %s\n",
+ command_option->name, command_option->value);
+ }
}
amfree(myprefix);
}
}
+int copy_file(
+ char *dst,
+ char *src,
+ char **errmsg)
+{
+ int infd, outfd;
+ int save_errno;
+ ssize_t nb;
+ char buf[32768];
+ char *quoted;
+
+ if ((infd = open(src, O_RDONLY)) == -1) {
+ save_errno = errno;
+ quoted = quote_string(src);
+ *errmsg = vstralloc("Can't open file ", quoted, " for reading: %s",
+ strerror(save_errno));
+ amfree(quoted);
+ return -1;
+ }
+
+ if ((outfd = open(dst, O_WRONLY|O_CREAT, 0600)) == -1) {
+ save_errno = errno;
+ quoted = quote_string(dst);
+ *errmsg = vstralloc("Can't open file ", quoted, " for writting: %s",
+ strerror(save_errno));
+ amfree(quoted);
+ close(infd);
+ return -1;
+ }
+
+ while((nb=read(infd, &buf, SIZEOF(buf))) > 0) {
+ if(fullwrite(outfd,&buf,(size_t)nb) < nb) {
+ save_errno = errno;
+ quoted = quote_string(dst);
+ *errmsg = vstralloc("Error writing to \"", quoted, "\":",
+ strerror(save_errno));
+ amfree(quoted);
+ close(infd);
+ close(outfd);
+ return -1;
+ }
+ }
+
+ if (nb < 0) {
+ save_errno = errno;
+ quoted = quote_string(src);
+ *errmsg = vstralloc("Error reading from \"", quoted, "\":",
+ strerror(save_errno));
+ amfree(quoted);
+ close(infd);
+ close(outfd);
+ return -1;
+ }
+
+ close(infd);
+ close(outfd);
+ return 0;
+}
#ifndef HAVE_LIBREADLINE
/*
* simple readline() replacements
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: util.h,v 1.17.2.1 2006/09/21 11:12:21 martinea Exp $
+ * $Id: util.h,v 1.17.2.5 2007/01/10 16:18:46 martinea Exp $
*/
#ifndef UTIL_H
#define UTIL_H
CONFTYPE_REAL,
CONFTYPE_STRING,
CONFTYPE_IDENT,
- CONFTYPE_TIME,
+ CONFTYPE_TIME, /* hhmm */
CONFTYPE_SIZE,
CONFTYPE_SL,
CONFTYPE_BOOL,
CONFTYPE_TAPERALGO,
CONFTYPE_PRIORITY,
CONFTYPE_RATE,
- CONFTYPE_EXINCLUDE,
+ CONFTYPE_EXINCLUDE
} conftype_t;
/* Compression types */
typedef enum {
ENCRYPT_NONE, /* No encryption */
ENCRYPT_CUST, /* Custom encryption on client */
- ENCRYPT_SERV_CUST, /* Custom encryption on server */
+ ENCRYPT_SERV_CUST /* Custom encryption on server */
} encrypt_t;
/* holdingdisk types */
} command_option_t;
typedef struct exinclude_s {
- int type; /* 0=list 1=file */
- sl_t *sl;
+ sl_t *sl_list;
+ sl_t *sl_file;
int optional;
} exinclude_t;
void read_time(t_conf_var *, val_t *);
void copy_val_t(val_t *, val_t *);
void free_val_t(val_t *);
-char *conf_print(val_t *);
+char *conf_print(val_t *, int);
+char *conf_print_exinclude(val_t *, int, int);
void conf_init_string(val_t *, char *);
void conf_init_ident(val_t *, char *);
void conf_init_int(val_t *, int);
char * strquotedstr(void);
ssize_t hexdump(const char *buffer, size_t bytes);
void dump_sockaddr(struct sockaddr_in * sa);
+int copy_file(char *dst, char *src, char **errmsg);
/*
* validate_email return 0 if the following characters are present
/* version.c - generated by genversion.c - DO NOT EDIT! */
const char * const version_info[] = {
- "build: VERSION=\"Amanda-2.5.1p1\"\n",
- " BUILT_DATE=\"Wed Sep 27 11:11:29 EDT 2006\"\n",
- " BUILT_MACH=\"Linux modemcable197.174-201-24.mc.videotron.ca 2.6.17-1.2187_FC5 #1 SMP Mon Sep 11 01:16:59 EDT 2006 x86_64 x86_64 x86_64 GNU/Linux\"\n",
+ "build: VERSION=\"Amanda-2.5.1p3\"\n",
+ " BUILT_DATE=\"Wed Feb 7 10:30:00 EST 2007\"\n",
+ " BUILT_MACH=\"Linux modemcable161.224-131-66.mc.videotron.ca 2.6.18-1.2257.fc5 #1 SMP Fri Dec 15 16:07:14 EST 2006 x86_64 x86_64 x86_64 GNU/Linux\"\n",
" CC=\"gcc\"\n",
" CONFIGURE_COMMAND=\"'./configure' '--prefix=/home/martinea/linux' '--with-configdir=/home/martinea/etc/amanda' '--with-gnutar-listdir=/var/gnutar-lists' '--with-bsd-security' '--with-ssh-security' '--with-rsh-security' '--with-krb4-security' '--without-krb5-security' '--with-user=martinea' '--with-group=martinea' '--mandir=/home/martinea/man'\"\n",
"paths: bindir=\"/home/martinea/linux/bin\"\n",
" COMPRESS_PATH=\"/usr/bin/gzip\"\n",
" UNCOMPRESS_PATH=\"/usr/bin/gzip\" LPRCMD=\"/usr/bin/lpr\"\n",
" MAILER=\"/usr/bin/Mail\" listed_incr_dir=\"/var/gnutar-lists\"\n",
- "defs: DEFAULT_SERVER=\"modemcable197.174-201-24.mc.videotron.ca\"\n",
+ "defs: DEFAULT_SERVER=\"modemcable161.224-131-66.mc.videotron.ca\"\n",
" DEFAULT_CONFIG=\"DailySet1\"\n",
- " DEFAULT_TAPE_SERVER=\"modemcable197.174-201-24.mc.videotron.ca\"\n",
+ " DEFAULT_TAPE_SERVER=\"modemcable161.224-131-66.mc.videotron.ca\"\n",
" HAVE_MMAP HAVE_SYSVSHM LOCKING=POSIX_FCNTL SETPGRP_VOID\n",
" DEBUG_CODE AMANDA_DEBUG_DAYS=4 BSD_SECURITY RSH_SECURITY\n",
" USE_AMANDAHOSTS CLIENT_LOGIN=\"martinea\" FORCE_USERID\n",
const int VERSION_MAJOR = 2;
const int VERSION_MINOR = 5;
const int VERSION_PATCH = 1;
-const char *const VERSION_COMMENT = "p1";
+const char *const VERSION_COMMENT = "p3";
const char *
versionsuffix(void)
{
#ifdef USE_VERSION_SUFFIXES
- return "-2.5.1p1";
+ return "-2.5.1p3";
#else
return "";
#endif
const char *
version(void)
{
- return "2.5.1p1";
+ return "2.5.1p3";
}
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
/* Define to 1 if you have the `strstr' function. */
#undef HAVE_STRSTR
+/* Define to 1 if you have the `strtol' function. */
+#undef HAVE_STRTOL
+
+/* Define to 1 if you have the `strtoll' function. */
+#undef HAVE_STRTOLL
+
+/* Define if strtoll is declared. */
+#undef HAVE_STRTOLL_DECL
+
+/* Define if strtol is declared. */
+#undef HAVE_STRTOL_DECL
+
/* Define if the database header declares struct datum. */
#undef HAVE_STRUCT_DATUM
/* Format for a long long printf. */
#undef LL_FMT
+/* Format for a long long printf. */
+#undef LL_RFMT
+
/* A comma-separated list of two integers, determining the minimum and maximum
reserved TCP port numbers sockets should be bound to. (mainly for
amrecover) */
/* The size of a `void*', as computed by sizeof. */
#undef SIZEOF_VOIDP
+/* Define to the exact path to the sort program. */
+#undef SORT_PATH
+
/* Define if SSH transport should be enabled. */
#undef SSH_SECURITY
# include <unistd.h>
#endif"
-ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os CONFIGURE_COMMAND INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar SNAPSHOT_STAMP VERSION_MAJOR VERSION_MINOR VERSION_PATCH VERSION_COMMENT VERSION_SUFFIX CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE GREP EGREP AMLINT AMLINTFLAGS DUMPER_DIR CONFIG_DIR USE_VERSION_SUFFIXES CLIENT_SCRIPTS_OPT DEFAULT_SERVER CLIENT_LOGIN SETUID_GROUP BINARY_OWNER DEFAULT_CONFIG DEFAULT_TAPE_SERVER DEFAULT_TAPE_DEVICE DEFAULT_RAW_TAPE_DEVICE DEFAULT_CHANGER_DEVICE GNUTAR_LISTED_INCREMENTAL_DIRX GNUTAR_LISTED_INCREMENTAL_DIR MAXTAPEBLOCKSIZE AMANDA_TMPDIR AMANDA_DBGDIR AMANDA_DEBUG_DAYS SERVICE_SUFFIX MT_FILE_FLAG CPP AR AWK_VAR_ASSIGNMENT_OPT YACC CAT COMPRESS DD GETCONF GNUPLOT GNUTAR SAMBA_CLIENT GZIP MAILER MT CHIO CHS MTX MCUTIL PRINT PCAT PERL DUMP RESTORE XFSDUMP XFSRESTORE VXDUMP VXRESTORE VDUMP VRESTORE AMPLOT_COMPRESS AMPLOT_CAT_GZIP AMPLOT_CAT_COMPRESS AMPLOT_CAT_PACK LL_FMT LN_S ECHO ac_ct_AR RANLIB ac_ct_RANLIB CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL LIBTOOL_DEPS LEX LEXLIB LEX_OUTPUT_ROOT READLINE_LIBS DB_EXT ALLOCA LIBOBJS ac_n ac_c WANT_CLIENT_TRUE WANT_CLIENT_FALSE WANT_SAMBA_TRUE WANT_SAMBA_FALSE WANT_RESTORE_TRUE WANT_RESTORE_FALSE WANT_SERVER_TRUE WANT_SERVER_FALSE WANT_RECOVER_TRUE WANT_RECOVER_FALSE WANT_TAPE_TRUE WANT_TAPE_FALSE WANT_AMPLOT_TRUE WANT_AMPLOT_FALSE WANT_CHG_SCSI_TRUE WANT_CHG_SCSI_FALSE WANT_CHIO_SCSI_TRUE WANT_CHIO_SCSI_FALSE WANT_RUNTIME_PSEUDO_RELOC_TRUE WANT_RUNTIME_PSEUDO_RELOC_FALSE WANT_SETUID_CLIENT_TRUE WANT_SETUID_CLIENT_FALSE WANT_SSH_SECURITY_TRUE WANT_SSH_SECURITY_FALSE LTLIBOBJS LTALLOCA DOC_BUILD_DATE BUILD_MAN_PAGES_TRUE BUILD_MAN_PAGES_FALSE XSLTPROC HAVE_XSLTPROC_TRUE HAVE_XSLTPROC_FALSE AM_CFLAGS'
+ac_subst_vars='SHELL PATH_SEPARATOR PACKAGE_NAME PACKAGE_TARNAME PACKAGE_VERSION PACKAGE_STRING PACKAGE_BUGREPORT exec_prefix prefix program_transform_name bindir sbindir libexecdir datadir sysconfdir sharedstatedir localstatedir libdir includedir oldincludedir infodir mandir build_alias host_alias target_alias DEFS ECHO_C ECHO_N ECHO_T LIBS build build_cpu build_vendor build_os host host_cpu host_vendor host_os target target_cpu target_vendor target_os CONFIGURE_COMMAND INSTALL_PROGRAM INSTALL_SCRIPT INSTALL_DATA CYGPATH_W PACKAGE VERSION ACLOCAL AUTOCONF AUTOMAKE AUTOHEADER MAKEINFO install_sh STRIP ac_ct_STRIP INSTALL_STRIP_PROGRAM mkdir_p AWK SET_MAKE am__leading_dot AMTAR am__tar am__untar SNAPSHOT_STAMP VERSION_MAJOR VERSION_MINOR VERSION_PATCH VERSION_COMMENT VERSION_SUFFIX CC CFLAGS LDFLAGS CPPFLAGS ac_ct_CC EXEEXT OBJEXT DEPDIR am__include am__quote AMDEP_TRUE AMDEP_FALSE AMDEPBACKSLASH CCDEPMODE am__fastdepCC_TRUE am__fastdepCC_FALSE GREP EGREP AMLINT AMLINTFLAGS DUMPER_DIR CONFIG_DIR USE_VERSION_SUFFIXES CLIENT_SCRIPTS_OPT DEFAULT_SERVER CLIENT_LOGIN SETUID_GROUP BINARY_OWNER DEFAULT_CONFIG DEFAULT_TAPE_SERVER DEFAULT_TAPE_DEVICE DEFAULT_RAW_TAPE_DEVICE DEFAULT_CHANGER_DEVICE GNUTAR_LISTED_INCREMENTAL_DIRX GNUTAR_LISTED_INCREMENTAL_DIR MAXTAPEBLOCKSIZE AMANDA_TMPDIR AMANDA_DBGDIR AMANDA_DEBUG_DAYS SERVICE_SUFFIX MT_FILE_FLAG CPP AR AWK_VAR_ASSIGNMENT_OPT YACC CAT COMPRESS DD GETCONF GNUPLOT GNUTAR SAMBA_CLIENT GZIP SORT MAILER MT CHIO CHS MTX MCUTIL PRINT PCAT PERL DUMP RESTORE XFSDUMP XFSRESTORE VXDUMP VXRESTORE VDUMP VRESTORE AMPLOT_COMPRESS AMPLOT_CAT_GZIP AMPLOT_CAT_COMPRESS AMPLOT_CAT_PACK LL_FMT LL_RFMT LN_S ECHO ac_ct_AR RANLIB ac_ct_RANLIB CXX CXXFLAGS ac_ct_CXX CXXDEPMODE am__fastdepCXX_TRUE am__fastdepCXX_FALSE CXXCPP F77 FFLAGS ac_ct_F77 LIBTOOL LIBTOOL_DEPS LEX LEXLIB LEX_OUTPUT_ROOT READLINE_LIBS DB_EXT ALLOCA LIBOBJS ac_n ac_c WANT_CLIENT_TRUE WANT_CLIENT_FALSE WANT_SAMBA_TRUE WANT_SAMBA_FALSE WANT_RESTORE_TRUE WANT_RESTORE_FALSE WANT_SERVER_TRUE WANT_SERVER_FALSE WANT_RECOVER_TRUE WANT_RECOVER_FALSE WANT_TAPE_TRUE WANT_TAPE_FALSE WANT_AMPLOT_TRUE WANT_AMPLOT_FALSE WANT_CHG_SCSI_TRUE WANT_CHG_SCSI_FALSE WANT_CHIO_SCSI_TRUE WANT_CHIO_SCSI_FALSE WANT_RUNTIME_PSEUDO_RELOC_TRUE WANT_RUNTIME_PSEUDO_RELOC_FALSE WANT_SETUID_CLIENT_TRUE WANT_SETUID_CLIENT_FALSE WANT_SSH_SECURITY_TRUE WANT_SSH_SECURITY_FALSE LTLIBOBJS LTALLOCA DOC_BUILD_DATE BUILD_MAN_PAGES_TRUE BUILD_MAN_PAGES_FALSE XSLTPROC HAVE_XSLTPROC_TRUE HAVE_XSLTPROC_FALSE AM_CFLAGS'
ac_subst_files=''
# Initialize some variables set by options.
--without-bsd-security do not use BSD rsh/rlogin style security
--without-amandahosts use .rhosts instead of .amandahosts
--with-dbmalloc=DIR Location of dbmalloc libs and headers
+ --with-ipv6 If IPv6 must be enabled (Default)
+ --without-ipv6 If IPv6 must be disable
--with-krb4-security=DIR Location of Kerberos software [/usr/kerberos /usr/cygnus /usr /opt/kerberos]
--with-rsh-security use rsh as a transport
--with-ssh-security use ssh as a transport
--with-bsdtcp-security use tcp as a transport
- --with-bsdudp-security use tcp as a transport
+ --with-bsdudp-security use udp as a transport
--with-server-principal=ARG server host principal ["amanda"]
--with-server-instance=ARG server host instance ["amanda"]
--with-server-keyfile=ARG server host key file ["/.amanda"]
# Define the identity of the package.
PACKAGE=amanda
- VERSION=2.5.1p1
+ VERSION=2.5.1p3
cat >>confdefs.h <<_ACEOF
;;
esac
-else
-
- if test -z "$DEFAULT_TAPE_DEVICE"; then
- echo "$as_me:$LINENO: checking for non-rewinding tape device" >&5
-echo $ECHO_N "checking for non-rewinding tape device... $ECHO_C" >&6
- tape_dev=
- nr_tape_dev=
- if test -d /dev/rmt; then
-
-
- for num in 9 8 7 6 5 4 3 2 1 0; do
- td=/dev/rmt/${num}b
- ntd=/dev/rmt/${num}bn
- if test -r $td -a -r $ntd; then
- tape_dev=$td
- nr_tape_dev=$ntd
- fi
- done
- else
- for num in 9 8 7 6 5 4 3 2 1 0; do
- td=/dev/rst${num}
- ntd=/dev/nrst${num}
- if test -r $td -a -r $ntd; then
- tape_dev=$td
- nr_tape_dev=$ntd
- fi
- done
- fi
- DEFAULT_TAPE_DEVICE=$nr_tape_dev
- echo "$as_me:$LINENO: result: $DEFAULT_TAPE_DEVICE" >&5
-echo "${ECHO_T}$DEFAULT_TAPE_DEVICE" >&6
- fi
-
fi;
esac
+# Check whether --with-ipv6 or --without-ipv6 was given.
+if test "${with_ipv6+set}" = set; then
+ withval="$with_ipv6"
+
+ case "$withval" in
+ y | ye | yes) amanda_ipv6=true;;
+ n | no) amanda_ipv6=false;;
+ *)
+ { { echo "$as_me:$LINENO: error: *** You must not supply an argument to --with-ipv6 option." >&5
+echo "$as_me: error: *** You must not supply an argument to --with-ipv6 option." >&2;}
+ { (exit 1); exit 1; }; }
+ ;;
+ esac
+
+
+fi;
+
+
: ${KRB4_SPOTS="/usr/kerberos /usr/cygnus /usr /opt/kerberos"}
NEED_SETUID_CLIENT=false
NEED_RUNTIME_PSEUDO_RELOC=true
+ BROKEN_IPV6=true
;;
*)
cat <<END
_ACEOF
+for ac_prog in sort
+do
+ # Extract the first word of "$ac_prog", so it can be a program name with args.
+set dummy $ac_prog; ac_word=$2
+echo "$as_me:$LINENO: checking for $ac_word" >&5
+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
+if test "${ac_cv_path_SORT+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ case $SORT in
+ [\\/]* | ?:[\\/]*)
+ ac_cv_path_SORT="$SORT" # Let the user override the test with a path.
+ ;;
+ *)
+ as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
+for as_dir in $LOCSYSPATH
+do
+ IFS=$as_save_IFS
+ test -z "$as_dir" && as_dir=.
+ for ac_exec_ext in '' $ac_executable_extensions; do
+ if $as_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
+ ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext"
+ echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
+ break 2
+ fi
+done
+done
+
+ ;;
+esac
+fi
+SORT=$ac_cv_path_SORT
+
+if test -n "$SORT"; then
+ echo "$as_me:$LINENO: result: $SORT" >&5
+echo "${ECHO_T}$SORT" >&6
+else
+ echo "$as_me:$LINENO: result: no" >&5
+echo "${ECHO_T}no" >&6
+fi
+
+ test -n "$SORT" && break
+done
+
+if test -z "$SORT"; then
+ if $NO_SERVER_MODE; then
+ SORT="NONE"
+ else
+ { { echo "$as_me:$LINENO: error: Set SORT to the path of the sort program." >&5
+echo "$as_me: error: Set SORT to the path of the sort program." >&2;}
+ { (exit 1); exit 1; }; }
+ fi
+fi
+
+cat >>confdefs.h <<_ACEOF
+#define SORT_PATH "$SORT"
+_ACEOF
+
+
for ac_prog in Mail mailx mail
do
# Extract the first word of "$ac_prog", so it can be a program name with args.
if test "$cross_compiling" = yes; then
echo "$as_me:$LINENO: result: assuming target platform uses ll" >&5
echo "${ECHO_T}assuming target platform uses ll" >&6
- LL_FMT="%lld"
+ LL_FMT="%lld"; LL_RFMT="lld"
else
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h. */
(exit $ac_status); }; }; then
echo "$as_me:$LINENO: result: ll" >&5
echo "${ECHO_T}ll" >&6
- LL_FMT="%lld"
+ LL_FMT="%lld"; LL_RFMT="lld"
else
echo "$as_me: program exited with status $ac_status" >&5
echo "$as_me: failed program was:" >&5
( exit $ac_status )
echo "$as_me:$LINENO: result: l" >&5
echo "${ECHO_T}l" >&6
- LL_FMT="%ld"
+ LL_FMT="%ld"; LL_RFMT="ld"
fi
rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
fi
_ACEOF
+cat >>confdefs.h <<_ACEOF
+#define LL_RFMT "$LL_RFMT"
+_ACEOF
+
+
+
GZIP=
;;
*-*-irix6*)
# Find out which ABI we are using.
- echo '#line 15015 "configure"' > conftest.$ac_ext
+ echo '#line 15068 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5
ac_status=$?
# Provide some information about the compiler.
-echo "$as_me:16121:" \
+echo "$as_me:16174:" \
"checking for Fortran 77 compiler version" >&5
ac_compiler=`set X $ac_compile; echo $2`
{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:17223: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:17276: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:17227: \$? = $ac_status" >&5
+ echo "$as_me:17280: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:17485: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:17538: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:17489: \$? = $ac_status" >&5
+ echo "$as_me:17542: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:17547: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:17600: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:17551: \$? = $ac_status" >&5
+ echo "$as_me:17604: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 19795 "configure"
+#line 19848 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 19893 "configure"
+#line 19946 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:22152: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:22205: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:22156: \$? = $ac_status" >&5
+ echo "$as_me:22209: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:22214: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:22267: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:22218: \$? = $ac_status" >&5
+ echo "$as_me:22271: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 23591 "configure"
+#line 23644 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 23689 "configure"
+#line 23742 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24574: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24627: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:24578: \$? = $ac_status" >&5
+ echo "$as_me:24631: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:24636: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:24689: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:24640: \$? = $ac_status" >&5
+ echo "$as_me:24693: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:26770: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:26823: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:26774: \$? = $ac_status" >&5
+ echo "$as_me:26827: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:27032: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:27085: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err)
ac_status=$?
cat conftest.err >&5
- echo "$as_me:27036: \$? = $ac_status" >&5
+ echo "$as_me:27089: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings other than the usual output.
-e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'`
- (eval echo "\"\$as_me:27094: $lt_compile\"" >&5)
+ (eval echo "\"\$as_me:27147: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err)
ac_status=$?
cat out/conftest.err >&5
- echo "$as_me:27098: \$? = $ac_status" >&5
+ echo "$as_me:27151: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext
then
# The compiler can only warn and ignore the option if not recognized
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 29342 "configure"
+#line 29395 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF
-#line 29440 "configure"
+#line 29493 "configure"
#include "confdefs.h"
#if HAVE_DLFCN_H
fi
+ice_have_strtol=no
+
+for ac_func in strtol
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+ For example, HP-UX 11i <limits.h> declares gettimeofday. */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
+#endif
+
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+ ice_have_strtol=yes
+fi
+done
+
+if test "${ice_have_strtol}" = yes; then
+echo "$as_me:$LINENO: checking for strtol declaration in stdlib.h" >&5
+echo $ECHO_N "checking for strtol declaration in stdlib.h... $ECHO_C" >&6
+if test "${ice_cv_have_strtol_decl+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+ice_cv_have_strtol_decl=no
+ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*'
+ice_re_word='(^|[^a-zA-Z0-9_])'
+for header in stdlib.h; do
+# Check for ordinary declaration
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$header>
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "${ice_re_word}strtol[ ]*\(" >/dev/null 2>&1; then
+ ice_cv_have_strtol_decl=yes
+fi
+rm -f conftest*
+
+if test "$ice_cv_have_strtol_decl" = yes; then
+ break
+fi
+# Check for "fixed" declaration like "getpid _PARAMS((int))"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$header>
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "${ice_re_word}strtol[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then
+ ice_cv_have_strtol_decl=yes
+fi
+rm -f conftest*
+
+if test "$ice_cv_have_strtol_decl" = yes; then
+ break
+fi
+done
+
+fi
+
+echo "$as_me:$LINENO: result: $ice_cv_have_strtol_decl" >&5
+echo "${ECHO_T}$ice_cv_have_strtol_decl" >&6
+if test "$ice_cv_have_strtol_decl" = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_STRTOL_DECL 1
+_ACEOF
+
+fi
+fi
+
+
+ice_have_strtoll=no
+
+for ac_func in strtoll
+do
+as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
+echo "$as_me:$LINENO: checking for $ac_func" >&5
+echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
+if eval "test \"\${$as_ac_var+set}\" = set"; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
+ For example, HP-UX 11i <limits.h> declares gettimeofday. */
+#define $ac_func innocuous_$ac_func
+
+/* System header to define __stub macros and hopefully few prototypes,
+ which can conflict with char $ac_func (); below.
+ Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
+ <limits.h> exists even on freestanding compilers. */
+
+#ifdef __STDC__
+# include <limits.h>
+#else
+# include <assert.h>
+#endif
+
+#undef $ac_func
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+{
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char $ac_func ();
+/* The GNU C library defines this for functions which it implements
+ to always fail with ENOSYS. Some functions are actually named
+ something starting with __ and the normal name is an alias. */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+char (*f) () = $ac_func;
+#endif
+#ifdef __cplusplus
+}
+#endif
+
+int
+main ()
+{
+return f != $ac_func;
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag"
+ || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ eval "$as_ac_var=yes"
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+eval "$as_ac_var=no"
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+fi
+echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
+echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
+if test `eval echo '${'$as_ac_var'}'` = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
+_ACEOF
+ ice_have_strtoll=yes
+fi
+done
+
+if test "${ice_have_strtoll}" = yes; then
+echo "$as_me:$LINENO: checking for strtoll declaration in stdlib.h" >&5
+echo $ECHO_N "checking for strtoll declaration in stdlib.h... $ECHO_C" >&6
+if test "${ice_cv_have_strtoll_decl+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+
+ice_cv_have_strtoll_decl=no
+ice_re_params='[a-zA-Z_][a-zA-Z0-9_]*'
+ice_re_word='(^|[^a-zA-Z0-9_])'
+for header in stdlib.h; do
+# Check for ordinary declaration
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$header>
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "${ice_re_word}strtoll[ ]*\(" >/dev/null 2>&1; then
+ ice_cv_have_strtoll_decl=yes
+fi
+rm -f conftest*
+
+if test "$ice_cv_have_strtoll_decl" = yes; then
+ break
+fi
+# Check for "fixed" declaration like "getpid _PARAMS((int))"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+#include <$header>
+
+_ACEOF
+if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
+ $EGREP "${ice_re_word}strtoll[ ]*$ice_re_params\(\(" >/dev/null 2>&1; then
+ ice_cv_have_strtoll_decl=yes
+fi
+rm -f conftest*
+
+if test "$ice_cv_have_strtoll_decl" = yes; then
+ break
+fi
+done
+
+fi
+
+echo "$as_me:$LINENO: result: $ice_cv_have_strtoll_decl" >&5
+echo "${ECHO_T}$ice_cv_have_strtoll_decl" >&6
+if test "$ice_cv_have_strtoll_decl" = yes; then
+
+cat >>confdefs.h <<_ACEOF
+#define HAVE_STRTOLL_DECL 1
+_ACEOF
+
+fi
+fi
+
+
for ac_func in basename
do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
s,@GNUTAR@,$GNUTAR,;t t
s,@SAMBA_CLIENT@,$SAMBA_CLIENT,;t t
s,@GZIP@,$GZIP,;t t
+s,@SORT@,$SORT,;t t
s,@MAILER@,$MAILER,;t t
s,@MT@,$MT,;t t
s,@CHIO@,$CHIO,;t t
s,@AMPLOT_CAT_COMPRESS@,$AMPLOT_CAT_COMPRESS,;t t
s,@AMPLOT_CAT_PACK@,$AMPLOT_CAT_PACK,;t t
s,@LL_FMT@,$LL_FMT,;t t
+s,@LL_RFMT@,$LL_RFMT,;t t
s,@LN_S@,$LN_S,;t t
s,@ECHO@,$ECHO,;t t
s,@ac_ct_AR@,$ac_ct_AR,;t t
[Saves the original ./configure command line arguments])
AC_SUBST(CONFIGURE_COMMAND)
-AM_INIT_AUTOMAKE(amanda, 2.5.1p1)
+AM_INIT_AUTOMAKE(amanda, 2.5.1p3)
AM_CONFIG_HEADER(config/config.h)
AC_PREREQ(2.57) dnl Minimum Autoconf version required.
*) DEFAULT_TAPE_DEVICE="$withval"
;;
esac
- ],
- [
- if test -z "$DEFAULT_TAPE_DEVICE"; then
- AC_MSG_CHECKING(for non-rewinding tape device)
- dnl Check for the /dev/rmt directory and use what's in there.
- dnl Otherwise look for tape devices in /dev. For the devices
- dnl in /dev/rmt, we want to use the Berkeley behavior of
- dnl reading the first record of the next tape file after 0
- dnl bytes are returned upon reading to the next tape mark,
- dnl instead of returning an error. Look for devices that have
- dnl a 'b' in their name.
- tape_dev=
- nr_tape_dev=
- if test -d /dev/rmt; then
-
- dnl See if we can find two devices, one being the norewind
- dnl version of the other. Devices in this directory are
- dnl normally a digit followed by some characters. We also
- dnl want the Berkely behavior, since Amanda needs it for
- dnl amrestore.
-
- for num in 9 8 7 6 5 4 3 2 1 0; do
- td=/dev/rmt/${num}b
- ntd=/dev/rmt/${num}bn
- if test -r $td -a -r $ntd; then
- tape_dev=$td
- nr_tape_dev=$ntd
- fi
- done
- else
- dnl Look for tape devices in /dev.
- for num in 9 8 7 6 5 4 3 2 1 0; do
- td=/dev/rst${num}
- ntd=/dev/nrst${num}
- if test -r $td -a -r $ntd; then
- tape_dev=$td
- nr_tape_dev=$ntd
- fi
- done
- fi
- DEFAULT_TAPE_DEVICE=$nr_tape_dev
- AC_MSG_RESULT($DEFAULT_TAPE_DEVICE)
- fi
]
)
[
if test -z "$DEFAULT_RAW_TAPE_DEVICE"; then
AC_MSG_CHECKING(for raw ftape device)
- dnl Look for tape devices in /dev.
+ dnl Look for tape devices in /dev.
raw_tape_dev=/dev/null
dnl Look for tape devices in /dev.
for num in 3 2 1 0 ; do
;;
esac
+AC_ARG_WITH(ipv6,
+ AS_HELP_STRING([--with-ipv6],
+ [If IPv6 must be enabled (Default)])
+AS_HELP_STRING([--without-ipv6],
+ [If IPv6 must be disable]),
+ [
+ case "$withval" in
+ y | ye | yes) amanda_ipv6=true;;
+ n | no) amanda_ipv6=false;;
+ *)
+ AC_MSG_ERROR([*** You must not supply an argument to --with-ipv6 option.])
+ ;;
+ esac
+ ]
+)
+
dnl Specify --with-krb4-security if Kerberos software is in somewhere
dnl other than the listed KRB4_SPOTS. We only compile kerberos support in
dnl if the right files are there.
esac
AC_ARG_WITH(bsdudp-security,
- [ --with-bsdudp-security use tcp as a transport],
+ [ --with-bsdudp-security use udp as a transport],
BSDUDP_SECURITY=$withval,
: ${BSDUDP_SECURITY=yes}
)
AC_DEFINE(DONT_SUID_ROOT,1,[Define on Cygwin. ])
NEED_SETUID_CLIENT=false
NEED_RUNTIME_PSEUDO_RELOC=true
+ BROKEN_IPV6=true
;;
*)
cat <<END
AC_DEFINE_UNQUOTED(UNCOMPRESS_PATH,"$UNCOMPRESS_PATH",[Define as the exact path to the gzip or compress command. ])
AC_DEFINE_UNQUOTED(UNCOMPRESS_OPT,"$UNCOMPRESS_OPT",[Define as any optional arguments to get UNCOMPRESS_PATH to uncompress. ])
+AC_PATH_PROGS(SORT,sort,,$LOCSYSPATH)
+if test -z "$SORT"; then
+ if $NO_SERVER_MODE; then
+ SORT="NONE"
+ else
+ AC_MSG_ERROR([Set SORT to the path of the sort program.])
+ fi
+fi
+AC_DEFINE_UNQUOTED(SORT_PATH,"$SORT",[Define to the exact path to the sort program. ])
+
AC_PATH_PROGS(MAILER,Mail mailx mail)
if test -z "$MAILER"; then
if $NO_SERVER_MODE; then
}
],
[AC_MSG_RESULT(ll)
- LL_FMT="%lld"],
+ LL_FMT="%lld"; LL_RFMT="lld"],
[AC_MSG_RESULT(l)
- LL_FMT="%ld"],
+ LL_FMT="%ld"; LL_RFMT="ld"],
[AC_MSG_RESULT(assuming target platform uses ll)
- LL_FMT="%lld"])
+ LL_FMT="%lld"; LL_RFMT="lld"])
AC_DEFINE_UNQUOTED(LL_FMT,"$LL_FMT",
[Format for a long long printf. ])
+AC_DEFINE_UNQUOTED(LL_RFMT,"$LL_RFMT",
+ [Format for a long long printf. ])
AC_SUBST(LL_FMT)
+AC_SUBST(LL_RFMT)
dnl Empty GZIP so that make dist works.
GZIP=
ICE_CHECK_DECL(atoi,stdlib.h)
ICE_CHECK_DECL(atol,stdlib.h)
ICE_CHECK_DECL(atoll,stdlib.h)
+ICE_CHECK_DECL(strtol,stdlib.h)
+ICE_CHECK_DECL(strtoll,stdlib.h)
AC_CHECK_FUNCS(basename)
ICE_CHECK_DECL(bind,sys/types.h sys/socket.h)
ICE_CHECK_DECL(bcopy,string.h strings.h stdlib.h)
36._The_Amanda_Manual_Pages.
- amadmin - administrative interface to control Amanda backups
+ amadmin \14 administrative interface to control Amanda backups
- amaespipe - wrapper program for aespipe
+ amaespipe \14 wrapper program for aespipe
- amanda - Advanced Maryland Automatic Network Disk Archiver
+ amanda \14 Advanced Maryland Automatic Network Disk Archiver
- amanda.conf - Main configuration file for Amanda, the Advanced Maryland
+ amanda.conf \14 Main configuration file for Amanda, the Advanced Maryland
Automatic Network Disk Archiver
- amanda-client.conf - Client configuration file for Amanda, the Advanced
+ amanda-client.conf \14 Client configuration file for Amanda, the Advanced
Maryland Automatic Network Disk Archiver
- amcheck - run Amanda self-checks
+ amcheck \14 run Amanda self-checks
- amcheckdb - check Amanda database for tape consistency
+ amcheckdb \14 check Amanda database for tape consistency
- amcleanup - run the Amanda cleanup process after a failure
+ amcleanup \14 run the Amanda cleanup process after a failure
- amcrypt - reference crypt program for Amanda symmetric data encryption
+ amcrypt \14 reference crypt program for Amanda symmetric data encryption
- amcrypt-ossl - crypt program for Amanda symmetric data encryption using
+ amcrypt-ossl \14 crypt program for Amanda symmetric data encryption using
OpenSSL
- amcrypt-ossl-asym - crypt program for Amanda asymmetric data encryption
+ amcrypt-ossl-asym \14 crypt program for Amanda asymmetric data encryption
using OpenSSL
- amdd - Amanda version of dd
+ amdd \14 Amanda version of dd
- amdump - back up all disks in an Amanda configuration
+ amdump \14 back up all disks in an Amanda configuration
- amfetchdump - extract backup images from multiple Amanda tapes.
+ amfetchdump \14 extract backup images from multiple Amanda tapes.
- amflush - flush Amanda backup files from holding disk to tape
+ amflush \14 flush Amanda backup files from holding disk to tape
- amgetconf - look up amanda.conf variables
+ amgetconf \14 look up amanda.conf variables
- amlabel - label an Amanda tape
+ amlabel \14 label an Amanda tape
- ammt - Amanda version of mt
+ ammt \14 Amanda version of mt
- amoverview - display file systems processed by Amanda over time
+ amoverview \14 display file systems processed by Amanda over time
- amplot - visualize the behavior of Amanda
+ amplot \14 visualize the behavior of Amanda
- amrecover - Amanda index database browser
+ amrecover \14 Amanda index database browser
- amreport - generate a formatted output of statistics for an Amanda run
+ amreport \14 generate a formatted output of statistics for an Amanda run
- amrestore - extract backup images from an Amanda tape
+ amrestore \14 extract backup images from an Amanda tape
- amrmtape - remove a tape from the Amanda database
+ amrmtape \14 remove a tape from the Amanda database
- amstatus - display the state of an Amanda run
+ amstatus \14 display the state of an Amanda run
- amtape - user interface to Amanda tape changer controls
+ amtape \14 user interface to Amanda tape changer controls
- amtapetype - generate a tapetype definition.
+ amtapetype \14 generate a tapetype definition.
- amtoc - generate TOC (Table Of Contents) for an Amanda run
+ amtoc \14 generate TOC (Table Of Contents) for an Amanda run
- amverify - check an Amanda tape for errors
+ amverify \14 check an Amanda tape for errors
- amverifyrun - check the tapes written by the last Amanda run
+ amverifyrun \14 check the tapes written by the last Amanda run
37._Web_Ressources
howto-auth.txt \
howto-cygwin.txt \
howto-filedriver.txt \
+ howto-gpg.txt \
howto-wrapper.txt \
howtos.txt \
index.txt \
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
howto-auth.txt \
howto-cygwin.txt \
howto-filedriver.txt \
+ howto-gpg.txt \
howto-wrapper.txt \
howtos.txt \
index.txt \
Synopsis
-amadmin config command [command options] [ -o | configoption ]*
+amadmin config command [command_options...] [-oconfigoption]...
DESCRIPTION
Display all backups currently on tape or in the holding disk. The tape
label or holding disk filename, file number, and status are displayed.
The --sort option changes the sort order using the following flags:
- hhost name kdisk name ddump date lbackup level p dump part btape label
+
+ h: host name
+ k: disk name
+ d: dump date
+ l: backup level
+ p: dump part
+ b: tape label
+
An uppercase letter reverses the sort order for that key. The default
sort order is hkdlpb.
$ amadmin daily find machine-c /var
date host disk lv tape or file file part status
- 2000\-11\-09 machine\-c /var 0 000110 9 -- OK
- 2000\-11\-08 machine\-c /var 2 000109 2 -- OK
- 2000\-11\-07 machine\-c /var 2 /amanda/20001107/machine-c._var.2 0 OK
- 2000\-11\-06 machine\-c /var 2 000107 2 -- OK
- 2000\-11\-05 machine\-c /var 2 000106 3 -- OK
- 2000\-11\-04 machine\-c /var 2 000105 2 -- OK
- 2000\-11\-03 machine\-c /var 2 000104 2 -- OK
- 2000\-11\-02 machine\-c /var 2 000103 2 -- OK
- 2000\-11\-01 machine\-c /var 1 000102 5 -- OK
- 2000\-10\-31 machine\-c /var 1 000101 3 -- OK
+ 2000-11-09 machine-c /var 0 000110 9 -- OK
+ 2000-11-08 machine-c /var 2 000109 2 -- OK
+ 2000-11-07 machine-c /var 2 /amanda/20001107/machine-c._var.2 0 OK
+ 2000-11-06 machine-c /var 2 000107 2 -- OK
+ 2000-11-05 machine-c /var 2 000106 3 -- OK
+ 2000-11-04 machine-c /var 2 000105 2 -- OK
+ 2000-11-03 machine-c /var 2 000104 2 -- OK
+ 2000-11-02 machine-c /var 2 000103 2 -- OK
+ 2000-11-01 machine-c /var 1 000102 5 -- OK
+ 2000-10-31 machine-c /var 1 000101 3 -- OK
Forget about the /workspace disk on machine-d. If you do not also remove the
disk from the disklist file, Amanda will treat it as a new disk during the next
tapedev tape:/dev/rmt/0mn
- .
null
This driver throws away anything written to it and returns EOF for any
? match exactly one character except the separator
* match zero or more characters except the separator
** match zero or more characters including the separator
+
Some examples:
-EXPRESSION WILL MATCH WILL NOT MATCH
-hosta hosta hostb
- hoSTA.dOMAIna.ORG
- foo.hosta.org
-host host hosta
-host? hosta host
- hostb
-ho*na hoina ho.aina.org
-ho**na hoina
- ho.aina.org
-^hosta hosta foo.hosta.org
-sda* /dev/sda1
- /dev/sda12
-/opt/ opt (disk) opt (host)
-.opt. opt (host) opt (disk)
-/ / any other disk
-/usr /usr
- /usr/opt
-/usr$ /usr /usr/opt
+EXPRESSION WILL MATCH WILL NOT MATCH
+hosta hosta hostb
+ hoSTA.dOMAIna.ORG
+ foo.hosta.org
+host host hosta
+host? hosta host
+ hostb
+ho*na hoina ho.aina.org
+ho**na hoina
+ ho.aina.org
+^hosta hosta foo.hosta.org
+sda* /dev/sda1
+ /dev/sda12
+/opt opt (disk) opt (host)
+.opt. opt (host) opt (disk)
+/ / any other disk
+/usr /usr
+ /usr/opt
+/usr$ /usr /usr/opt
+
DATESTAMP EXPRESSION
+ org string
+ Default: daily. A descriptive name for the configuration. This string
+ appears in the Subject line of mail reports. Each Amanda configuration
+ should have a different string to keep mail reports distinct.
+
+ mailto string
+ Default: operators. A space separated list of recipients for mail
+ reports.
+
+ dumpcycle int
+ Default: 10 days. The number of days in the backup cycle. Each disk will
+ get a full backup at least this often. Setting this to zero tries to do a
+ full backup each run.
+
+ Note
+
+ This parameter may also be set in a specific dumptype (see below). This
+ value sets the default for all dumptypes so must appear in amanda.conf
+ before any dumptypes are defined.
+
+ runspercycle int
+ Default: same as dumpcycle. The number of amdump runs in dumpcycle days.
+ A value of 0 means the same value as dumpcycle. A value of -1 means guess
+ the number of runs from the tapelist file, which is the number of tapes
+ used in the last dumpcycle days / runtapes.
+
+ tapecycle int
+ Default: 15 tapes. Typically tapes are used by Amanda in an ordered
+ rotation. The tapecycle parameter defines the size of that rotation. The
+ number of tapes in rotation must be larger than the number of tapes
+ required for a complete dump cycle (see the dumpcycle parameter).
+ This is calculated by multiplying the number of amdump runs per dump
+ cycle (runspercycle parameter) times the number of tapes used per run
+ (runtapes parameter). Typically two to four times this calculated number
+ of tapes are in rotation. While Amanda is always willing to use a new
+ tape in its rotation, it refuses to reuse a tape until at least
+ 'tapecycle -1' number of other tapes have been used.
+ It is considered good administrative practice to set the tapecycle
+ parameter slightly lower than the actual number of tapes in rotation.
+ This allows the administrator to more easily cope with damaged or
+ misplaced tapes or schedule adjustments that call for slight adjustments
+ in the rotation order.
+
+ usetimestamps bool
+ Default: No. By default, Amanda can only track at most one run per
+ calendar day. When this option is enabled, however, Amanda can track as
+ many runs as you care to make.
+ WARNING: This option is not backward-compatible. Do not enable it if you
+ intend to downgrade your server installation to Amanda community edition
+ 2.5.0
+
+ label_new_tapes string
+ Default: not set. When set, this directive will cause Amanda to
+ automatically write an Amanda tape label to any blank tape she
+ encounters. This option is DANGEROUS because when set, Amanda will ERASE
+ any non-Amanda tapes you may have, and may also ERASE any near-failing
+ tapes. Use with caution.
+ When using this directive, specify the template for new tape labels. The
+ template should contain some number of contiguous '%' characters, which
+ will be replaced with a generated number. Be sure to specify enough '%'
+ characters that you do not run out of tape labels. Example:
+ label_new_tapes "DailySet1-%%%"
+
+ dumpuser string
+ Default: amanda. The login name Amanda uses to run the backups. The
+ backup client hosts must allow access from the tape server host as this
+ user via .rhosts or .amandahosts, depending on how the Amanda software
+ was built.
+
+ printer string
+ Printer to use when doing tape labels. See the lbl-templ tapetype option.
+
+ tapedev string
+ Default: null:. The path name of the non-rewinding tape device. Non-
+ rewinding tape device names often have an 'n' in the name, e.g. /dev/rmt/
+ 0mn, however this is operating system specific and you should consult
+ that documentation for detailed naming information.
+ If a tape changer is configured (see the tpchanger option), this option
+ might not be used.
+ If the null output driver is selected (see the section OUTPUT DRIVERS in
+ the amanda(8) manpage for more information), programs such as amdump will
+ run normally but all images will be thrown away. This should only be used
+ for debugging and testing, and probably only with the record option set
+ to no.
+
+ rawtapedev string
+ Default: null:. The path name of the raw tape device. This is only used
+ if Amanda is compiled for Linux machines with floppy tapes and is needed
+ for QIC volume table operations.
+
+ tpchanger string
+ Default: none. The name of the tape changer. If a tape changer is not
+ configured, this option is not used and should be commented out of the
+ configuration file.
+ If a tape changer is configured, choose one of the changer scripts (e.g.
+ chg-scsi) and enter that here.
+
+ changerdev string
+ Default: /dev/null. A tape changer configuration parameter. Usage depends
+ on the particular changer defined with the tpchanger option.
+
+ changerfile string
+ Default: /usr/adm/amanda/log/changer-status. A tape changer configuration
+ parameter. Usage depends on the particular changer defined with the
+ tpchanger option.
+
+ runtapes int
+ Default: 1. The maximum number of tapes used in a single run. If a tape
+ changer is not configured, this option is not used and should be
+ commented out of the configuration file.
+ If a tape changer is configured, this may be set larger than one to let
+ Amanda write to more than one tape.
+ Note that this is an upper bound on the number of tapes, and Amanda may
+ use less.
+ Also note that as of this release, Amanda does not support true tape
+ overflow. When it reaches the end of one tape, the backup image Amanda
+ was processing starts over again on the next tape.
+
+ maxdumpsize int
+ Default: runtapes*tape_length. Maximum number of bytes the planner will
+ schedule for a run.
+
+ taperalgo [first|firstfit|largest|largestfit|smallest|last]
+ Default: first. The algorithm used to choose which dump image to send to
+ the taper.
+
+
+ first
+ First in, first out.
+
+ firstfit
+ The first dump image that will fit on the current tape.
+
+ largest
+ The largest dump image.
+
+ largestfit
+ The largest dump image that will fit on the current tape.
+
+ smallest
+ The smallest dump image.
+
+ last
+ Last in, first out.
+
+
+ labelstr string
+ Default: .*. The tape label constraint regular expression. All tape
+ labels generated (see amlabel(8)) and used by this configuration must
+ match the regular expression. If multiple configurations are run from the
+ same tape server host, it is helpful to set their labels to different
+ strings (for example, "DAILY[0-9][0-9]*" vs. "ARCHIVE[0-9][0-9]*") to
+ avoid overwriting each other's tapes.
+
+ tapetype string
+ Default: EXABYTE. The type of tape drive associated with tapedev or
+ tpchanger. This refers to one of the defined tapetypes in the config file
+ (see below), which specify various tape parameters, like the length,
+ filemark size, and speed of the tape media and device.
+ First character of a tapetype string must be an alphabetic character
+
+ ctimeout int
+ Default: 30 seconds. Maximum amount of time that amcheck will wait for
+ each client host.
+
+ dtimeout int
+ Default: 1800 seconds. Amount of idle time per disk on a given client
+ that a dumper running from within amdump will wait before it fails with a
+ data timeout error.
+
+ etimeout int
+ Default: 300 seconds. Amount of time per disk on a given client that the
+ planner step of amdump will wait to get the dump size estimates. For
+ instance, with the default of 300 seconds and four disks on client A,
+ planner will wait up to 20 minutes for that machine. A negative value
+ will be interpreted as a total amount of time to wait per client instead
+ of per disk.
+
+ netusage int
+ Default: 300 Kbps. The maximum network bandwidth allocated to Amanda, in
+ Kbytes per second. See also the interface section.
+
+ inparallel int
+ Default: 10. The maximum number of backups that Amanda will attempt to
+ run in parallel. Amanda will stay within the constraints of network
+ bandwidth and holding disk space available, so it doesn't hurt to set
+ this number a bit high. Some contention can occur with larger numbers of
+ backups, but this effect is relatively small on most systems.
+
+ displayunit "k|m|g|t"
+ Default: "k". The unit used to print many numbers, k=kilo, m=mega,
+ g=giga, t=tera.
+
+ dumporder string
+ Default: tttTTTTTTT. The priority order of each dumper:
+
+ s: smallest size
+ S: largest size
+ t: smallest time
+ T: largest time
+ b: smallest bandwidth
+ B: largest bandwidth
+
+
+ maxdumps int
+ Default: 1. The maximum number of backups from a single host that Amanda
+ will attempt to run in parallel. See also the inparallel option.
+ Note that this parameter may also be set in a specific dumptype (see
+ below). This value sets the default for all dumptypes so must appear in
+ amanda.conf before any dumptypes are defined.
+
+ bumpsize int
+ Default: 10 Mbytes. The minimum savings required to trigger an automatic
+ bump from one incremental level to the next, expressed as size. If Amanda
+ determines that the next higher backup level will be this much smaller
+ than the current level, it will do the next level. The value of this
+ parameter is used only if the parameter bumppercent is set to 0.
+ The global setting of this parameter can be overwritten inside of a
+ dumptype-definition.
+ See also the options bumppercent, bumpmult and bumpdays.
+
+ bumppercent int
+ Default: 0 percent. The minimum savings required to trigger an automatic
+ bump from one incremental level to the next, expressed as percentage of
+ the current size of the DLE (size of current level 0). If Amanda
+ determines that the next higher backup level will be this much smaller
+ than the current level, it will do the next level.
+ If this parameter is set to 0, the value of the parameter bumpsize is
+ used to trigger bumping.
+ The global setting of this parameter can be overwritten inside of a
+ dumptype-definition.
+ See also the options bumpsize, bumpmult and bumpdays.
+
+ bumpmult float
+ Default: 1.5. The bump size multiplier. Amanda multiplies bumpsize by
+ this factor for each level. This prevents active filesystems from bumping
+ too much by making it harder to bump to the next level. For example, with
+ the default bumpsize and bumpmult set to 2.0, the bump threshold will be
+ 10 Mbytes for level one, 20 Mbytes for level two, 40 Mbytes for level
+ three, and so on.
+ The global setting of this parameter can be overwritten inside of a
+ dumptype-definition.
+
+ bumpdays int
+ Default: 2 days. To insure redundancy in the dumps, Amanda keeps
+ filesystems at the same incremental level for at least bumpdays days,
+ even if the other bump threshold criteria are met.
+ The global setting of this parameter can be overwritten inside of a
+ dumptype-definition.
+
+ diskfile string
+ Default: disklist. The file name for the disklist file holding client
+ hosts, disks and other client dumping information.
+
+ infofile string
+ Default: /usr/adm/amanda/curinfo. The file or directory name for the
+ historical information database. If Amanda was configured to use DBM
+ databases, this is the base file name for them. If it was configured to
+ use text formated databases (the default), this is the base directory and
+ within here will be a directory per client, then a directory per disk,
+ then a text file of data.
+
+ logdir string
+ Default: /usr/adm/amanda. The directory for the amdump and log files.
+
+ indexdir string
+ Default /usr/adm/amanda/index. The directory where index files (backup
+ image catalogues) are stored. Index files are only generated for
+ filesystems whose dumptype has the index option enabled.
+
+ tapelist string
+ Default: tapelist. The file name for the active tapelist file. Amanda
+ maintains this file with information about the active set of tapes.
+
+ tapebufs int
+ Default: 20. The number of buffers used by the taper process run by
+ amdump and amflush to hold data as it is read from the network or disk
+ before it is written to tape. Each buffer is a little larger than 32
+ KBytes and is held in a shared memory region.
+
+ reserve number
+ Default: 100. The part of holding-disk space that should be reserved for
+ incremental backups if no tape is available, expressed as a percentage of
+ the available holding-disk space (0-100). By default, when there is no
+ tape to write to, degraded mode (incremental) backups will be performed
+ to the holding disk. If full backups should also be allowed in this case,
+ the amount of holding disk space reserved for incrementals should be
+ lowered.
+
+ autoflush bool
+ Default: off. Whether an amdump run will flush the dumps from holding
+ disk to tape.
+
+ amrecover_do_fsf bool
+ Default: on. Amrecover will call amrestore with the -f flag for faster
+ positioning of the tape.
+
+ amrecover_check_label bool
+ Default: on. Amrecover will call amrestore with the -l flag to check the
+ label.
+
+ amrecover_changer string
+ Default: ''. Amrecover will use the changer if you use 'settape <string>'
+ and that string is the same as the amrecover_changer setting.
+
+ columnspec string
+ Defines the width of columns amreport should use. String is a comma (',')
+ separated list of triples. Each triple consists of three parts which are
+ separated by a equal sign ('=') and a colon (':') (see the example).
+ These three parts specify:
+
+ 1. the name of the column, which may be:
+
+ Compress (compression ratio)
+ Disk (client disk name)
+ DumpRate (dump rate in KBytes/sec)
+ DumpTime (total dump time in hours:minutes)
+ HostName (client host name)
+ Level (dump level)
+ OrigKB (original image size in KBytes)
+ OutKB (output image size in KBytes)
+ TapeRate (tape writing rate in KBytes/sec)
+ TapeTime (total tape time in hours:minutes)
+
+
+ 2. the amount of space to display before the column (used to get
+ whitespace between columns).
+ 3. the width of the column itself. If set to a negative value, the
+ width will be calculated on demand to fit the largest entry in this
+ column.
+
+ Here is an example:
+
+ columnspec "Disk=1:18,HostName=0:10,OutKB=1:7"
+
+ The above will display the disk information in 18 characters and put one
+ space before it. The hostname column will be 10 characters wide with no
+ space to the left. The output KBytes column is seven characters wide with
+ one space before it.
+
includefile string
Default: none. The name of an Amanda configuration file to include within
the current file. Useful for sharing dumptypes, tapetypes and interface
chunk will not exceed the specified value. However, even though dump
images are split in the holding disk, they are concatenated as they are
written to tape, so each dump image still corresponds to a single
- continuous tape section. If 0 is specified, Amanda will create holding
- disk chunks as large as ((INT_MAX/1024)-64) Kbytes. Each holding disk
- chunk includes a 32 Kbyte header, so the minimum chunk size is 64 Kbytes
- (but that would be really silly). Operating systems that are limited to a
- maximum file size of 2 Gbytes actually cannot handle files that large.
- They must be at least one byte less than 2 Gbytes. Since Amanda works
- with 32 Kbyte blocks, and to handle the final read at the end of the
- chunk, the chunk size should be at least 64 Kbytes (2 * 32 Kbytes)
- smaller than the maximum file size, e.g. 2047 Mbytes.
+ continuous tape section.
+ If 0 is specified, Amanda will create holding disk chunks as large as (
+ (INT_MAX/1024)-64) Kbytes.
+ Each holding disk chunk includes a 32 Kbyte header, so the minimum chunk
+ size is 64 Kbytes (but that would be really silly).
+ Operating systems that are limited to a maximum file size of 2 Gbytes
+ actually cannot handle files that large. They must be at least one byte
+ less than 2 Gbytes. Since Amanda works with 32 Kbyte blocks, and to
+ handle the final read at the end of the chunk, the chunk size should be
+ at least 64 Kbytes (2 * 32 Kbytes) smaller than the maximum file size,
+ e.g. 2047 Mbytes.
DUMPTYPE SECTION
for reference)
So the compress options line may be one of:
- * compress none
- * compress [client] fast
- * compress [client] best
- * compress client custom
- Specify client_custom_compress "PROG"
- PROG must not contain white space and it must accept -d for uncompress.
- * compress server fast
- * compress server best
- * compress server custom
- Specify server_custom_compress "PROG"
- PROG must not contain white space and it must accept -d for uncompress.
+
+ compress none
+
+ compress client fast
+
+ compress client best
+
+ compress client custom
+ Specify client_custom_compress "PROG"
+ PROG must not contain white space and it must accept -d for
+ uncompress.
+
+ compress server fast
+
+ compress server best
+
+ compress server custom
+ Specify server_custom_compress "PROG"
+ PROG must not contain white space and it must accept -d for
+ uncompress.
Note that some tape devices do compression and this option has nothing to
do with whether that is used. If hardware compression is used (usually
host as it goes from the network into the holding disk or to tape.
So the encrypt options line may be one of:
- * encrypt none
- * encrypt client
- Specify client_encrypt "PROG"
- PROG must not contain white space.
- Specify client_decrypt_option "decryption-parameter" Default: "-d"
- decryption-parameter must not contain white space.
- (See dumptype server-encrypt-fast in example/amanda.conf for reference)
- * encrypt server
- Specify server_encrypt "PROG"
- PROG must not contain white space.
- Specify server_decrypt_option "decryption-parameter" Default: "-d"
- decryption-parameter must not contain white space.
- (See dumptype client-encrypt-nocomp in example/amanda.conf for
- reference)
+ encrypt none
+
+ encrypt client
+ Specify client_encrypt "PROG"
+ PROG must not contain white space.
+ Specify client_decrypt_option "decryption-parameter" Default: "-d"
+ decryption-parameter must not contain white space.
+ (See dumptype server-encrypt-fast in example/amanda.conf for
+ reference)
+
+ encrypt server
+ Specify server_encrypt "PROG"
+ PROG must not contain white space.
+ Specify server_decrypt_option "decryption-parameter" Default: "-d"
+ decryption-parameter must not contain white space.
+ (See dumptype client-encrypt-nocomp in example/amanda.conf for
+ reference)
+
+ Note that current logic assumes compression then encryption during backup
+ (thus decrypt then uncompress during restore). So specifying client-
+ encryption AND server-compression is not supported. amcrypt which is a
+ wrapper of aespipe is provided as a reference symmetric encryption
+ program.
estimate client|calcsize|server
Default: client. Determine the way Amanda does it's estimate.
- * client:
- Use the same program as the dumping program, this is the most accurate
- way to do estimates, but it can take a long time.
- * calcsize:
- Use a faster program to do estimates, but the result is less accurate.
- * server:
- Use only statistics from the previous run to give an estimate, it takes
- only a few seconds but the result is not accurate if your disk usage
- changes from day to day.
+
+ client
+ Use the same program as the dumping program, this is the most
+ accurate way to do estimates, but it can take a long time.
+
+ calcsize
+ Use a faster program to do estimates, but the result is less
+ accurate.
+
+ server
+ Use only statistics from the previous run to give an estimate, it
+ takes only a few seconds but the result is not accurate if your
+ disk usage changes from day to day.
exclude [ list|file ][[optional][ append ][ string ]+]
the actual file used would be /var/.amanda.excludes for a backup of /var,
/usr/local/.amanda.excludes for a backup of /usr/local, and so on.
- holdingdisk [ never|auto|required] ]
+ holdingdisk [ never|auto|required ]
Default: auto. Whether a holding disk should be used for these backups or
whether they should go directly to tape. If the holding disk is a portion
of another file system that Amanda is backing up, that file system should
Default: none. A comment string describing this set of tape information.
filemark int
- Default: 1000 bytes. How large a file mark (tape mark) is, measured in
- bytes. If the size is only known in some linear measurement (e.g.
- inches), convert it to bytes using the device density.
+ Default: 1 kbytes. How large a file mark (tape mark) is, measured in
+ kbytes. If the size is only known in some linear measurement (e.g.
+ inches), convert it to kbytes using the device density.
length int
Default: 2000 kbytes. How much data will fit on a tape.
exceptions).
blocksize int
- Default: 32. How much data will be written in each tape record expressed
- in KiloBytes. The tape record size (= blocksize) can not be reduced below
- the default 32 KBytes. The parameter blocksize can only be raised if
- Amanda was compiled with the configure option --with-maxtapeblocksize=N
- set with "N" greater than 32 during configure.
+ Default: 32 kbytes. How much data will be written in each tape record
+ expressed in KiloBytes. The tape record size (= blocksize) can not be
+ reduced below the default 32 KBytes. The parameter blocksize can only be
+ raised if Amanda was compiled with the configure option --with-
+ maxtapeblocksize=N set with "N" greater than 32 during configure.
file-pad boolean
Default: true. If true, every record, including the last one in the file,
Synopsis
-amcheck [-am] [-w] [-sclt] [ -M | address ]* config [ host | [disk]*]* [ -o |
-configoption ]*
+amcheck [-am] [-w] [-sclt] [-M address] config [ host [disk...] ...] [ -
+o configoption]...
DESCRIPTION
Synopsis
-amdump config [ host | [disk]*]* [ -o | configoption ]*
+amdump config [ host [disk...] ...] [ -o configoption]...
DESCRIPTION
Synopsis
amfetchdump [-pcClawns] [-d device] [-O directory] [-i logfile] [-b blocksize]
-config hostname [ disk [ date [ level [ hostname [...] ] ] ] ] [ -o |
-configoption ]*
+config hostname [ disk [ date [ level [ hostname [...] ] ] ] ] [ -
+o configoption]...
DESCRIPTION
Synopsis
-amflush [-b] [-f] [-s] [ -D | datestamp ]* config [ host | [disk]*]* [ -o |
-configoption ]*
+amflush [-b] [-f] [-s] [-D datestamp] config [ host [disk...] ...] [ -
+o configoption]...
DESCRIPTION
Synopsis
-amgetconf [config] parameter [ -o | configoption ]*
+amgetconf [config] [--list] parameter [ -o configoption]...
DESCRIPTION
+ --list
+ The parameter must be 'tapetype', 'dumptype, 'holdingdisk' or
+ 'interface'. It will output, one by line, the list of identifier for the
+ parameter.
+
+
+ --list tapetype
+ Output the list of tapetype, one by line.
+
+ --list dumptype
+ Output the list of dumptype, one by line.
+
+ --list holdingdisk
+ Output the list of holdingdisk, one by line.
+
+ --list interface
+ Output the list of interface, one by line.
+
+
+ parameter
+ It could be one of the below format:
+
+
+ runtapes
+
+ DUMPTYPE:no-compress:compress
+
+ TAPETYPE:HP-DAT:length
+
+ INTERFACE:local:use
+
+ HOLDINGDISK:hd1:use
+
+
-o configoption
See the "CONFIGURATION OVERWRITE" section in amanda(8).
Synopsis
-amlabel [-f ] config label [ slot | slot ] [ -o | configoption ]*
+amlabel [-f ] config label [slot slot] [ -o configoption]...
DESCRIPTION
Synopsis
-amrecover [[-C ] | config ] [ -s | index-server ] [ -t | tape-server ] [ -d |
-tape-device ] [ -o | clientconfigoption ]*
+amrecover [-C config] [-s index-server] [-t tape-server] [-d tape-device] [ -
+o configoption]...
DESCRIPTION
- setdisk diskname [mountpoint]
+ setdiskdiskname [mountpoint]
Specifies which disk to consider (default: the disk holding the working
directory where amrecover is started). It can only be set after the host
is set with sethost. Diskname is the device name specified in the
host. If mountpoint is not specified, all pathnames will be relative to
the (unknown) mount point instead of full pathnames.
- listhost [diskdevice]
+ listhost[diskdevice]
List all host
- listdisk [diskdevice]
+ listdisk[diskdevice]
List all diskname
- settape [[server]:][tapedev|default]
+ settape[[server]:][tapedev|default]
Specifies the host to use as the tape server, and which of its tape
devices to use. If the server is omitted, but the colon is not, the
server name reverts to the configure-time default. If the tape device is
- setmode mode
+ setmodemode
Set the extraction mode for Samba shares. If mode is smb, shares are sent
to the Samba server to be restored back onto the PC. If mode is tar, they
are extracted on the local machine the same way tar volumes are
otherwise they are relative to the current backup working directory. The
dir can be a shell style wildcards.
- cdx dir
+ cdxdir
Like the cd command but allow regular expression.
lpwd
Display the amrecover working directory. Files will be restored under
this directory, relative to the backed up filesystem.
- lcd path
+ lcdpath
Change the amrecover working directory to path.
ls
description of the setdate command for how the view of the directory is
built up. The backup date is shown for each file.
- add item1 item2 ...
+ additem1 item2 ...
Add the specified files or directories to the restore list. Each item may
have shell style wildcards.
- addx item1 item2 ...
+ addxitem1 item2 ...
Add the specified files or directories to the restore list. Each item may
be a regular expression.
- delete item1 item2 ...
+ deleteitem1 item2 ...
Delete the specified files or directories from the restore list. Each
item may have shell style wildcards.
- deletex item1 item2 ...
+ deletexitem1 item2 ...
Delete the specified files or directories from the restore list. Each
item may be a regular expression.
- list file
+ listfile
Display the contents of the restore list. If a file name is specified,
the restore list is written to that file. This can be used to manually
extract the files from the Amanda tapes with amrestore.
Synopsis
-amreport [config] [-i] [ -M | address ] [ -l | logfile ] [ -f | outputfile ]
-[ -p | postscriptfile ] [ -o | configoption ]*
+amreport [config] [-i] [-M address] [-l logfile] [-f outputfile] [-
+p postscriptfile] [ -o configoption]...
DESCRIPTION
Synopsis
-amtape config command [ command options ]
+amtape config command [command_options...] [-oconfigoption]...
DESCRIPTION
Eject any tape in the drive and put it away. Advance current to the next
tape, but do not load it.
+ -o configoption
+ See the "CONFIGURATION OVERWRITE" section in amanda(8).
+
This is useful with non-gravity stackers to unload the last tape used and set
up Amanda for the next run. If you just use eject, the current tape will be
mounted again in the next run, where it will be rejected as being still in use,
--- /dev/null
+
+Chapter 16. How to do Amanda-server-side gpg-encrypted backups.
+Prev Part III. HOWTOs Next
+
+-------------------------------------------------------------------------------
+
+Chapter 16. How to do Amanda-server-side gpg-encrypted backups.
+
+
+Stefan G. Weichinger
+
+Original text
+AMANDA Core Team
+<sgw@amanda.org>
+Table of Contents
+
+
+ Setup
+
+ Test
+
+ Plans
+
+
+Note
+
+Refer to http://www.amanda.org/docs/howto-gpg.html for the current version of
+this document.
+
+Note
+
+THIS IS *NOT* YET INTENDED FOR PRODUCTION SERVERS !!!
+Bruce Fletcher asked for a "simple" encryption method to be used with Amanda-
+server. gpg-amanda http://security.uchicago.edu/tools/gpg-amanda/ seems to
+create problems at restore-time, as it uses a wrapper for gzip.
+My solution uses a wrapper for GNU-tar instead, so there are several
+disadvantages avoided.
+
+Note
+
+This is based on a Amanda-vtape-setup with the Amanda-release 2.4.5. As this is
+still in the testing-stage, I have coded the home-dir of the Amanda-user into
+my scripts (/var/lib/amanda). This should be done with variables later, I agree
+...
+What you need:
+
+* aespipe http://loop-aes.sourceforge.net/aespipe/aespipe-v2.3b.tar.bz2 and the
+ bz2aespipe-wrapper that comes with it. It gets patched as described later.
+* the wrapper-script /usr/local/libexec/amgtar, as listed down below,
+* GNU-PG http://www.gnupg.org/(en)/download/index.html. This should be part of
+ most current operating systems already.
+* Amanda ;)
+
+
+Setup
+
+
+* Configure and compile aespipe:
+
+ tar -xjf aespipe-v2.3b.tar.bz2
+ cd aespipe-v2.3b
+ ./configure
+ make
+ make install
+
+* Generate and store the gpg-key for the Amanda-user:
+
+ # taken from the aespipe-README
+ head -c 2925 /dev/random | uuencode -m - | head -n 66 | tail -n 65 | \
+ gpg --symmetric -a > /var/lib/amanda/.gnupg/am_key.gpg
+
+ This will ask for a passphrase. Remember this passphrase as you will need it
+ in the next step.
+ Store the passphrase inside the home-directory of the Amanda-user and protect
+ it with proper permissions:
+
+ echo my_secret_passphrase > ~amanda/.am_passphrase
+ chown amanda:disk ~amanda/.am_passphrase
+ chmod 700 ~amanda/.am_passphrase
+
+ We need this file because we don't want to have to enter the passphrase
+ manually everytime we run amdump. We have to patch bz2aespipe to read the
+ passphrase from a file. I have called that file ~amanda/.am_passphrase.
+ It should NOT ;) look like this:
+
+ # cat ~amanda/.am_passphrase
+ my_secret_passphrase
+
+
+ Note
+
+ Store the key and the passphrase in some other place as well, without these
+ information you can't access any tapes that have been encrypted with it (this
+ is exactly why we are doing all this, isn't it? ;) ).
+* Create the wrapper for GNU-tar:
+ Example 16.1. /usr/local/libexec/amgtar
+
+ #!/bin/sh
+ #
+ # Original wrapper by Paul Bijnens
+ #
+ # crippled by Stefan G. Weichinger
+ # to enable gpg-encrypted dumps via aespipe
+
+ GTAR=/bin/tar
+ AM_AESPIPE=/usr/local/bin/amaespipe
+ AM_PASSPHRASE=/var/lib/amanda/.am_passphrase
+ LOG=/dev/null
+ LOG_ENABLED=1
+
+ if [ "$LOG_ENABLED" = "1" ]
+ then
+ LOG=/var/log/amanda/amgtar.debug
+ date >> $LOG
+ echo "$@" >> $LOG
+ fi
+
+ if [ "$3" = "/dev/null" ]
+ then
+ echo "Estimate only" >> $LOG
+ $GTAR "$@"
+ else
+ echo "Real backup" >> $LOG
+ $GTAR --use-compress-program="$AM_AESPIPE" "$@" 3< $AM_PASSPHRASE
+ fi
+
+ rc=$?
+ exit $rc
+
+
+* Copy the wrapper-script bz2aespipe, which comes with the aespipe-tarball, to
+ /usr/local/bin/amaespipe and edit it this way:
+ Example 16.2. /usr/local/bin/amaespipe
+
+ #! /bin/sh
+
+ # FILE FORMAT
+ # 10 bytes: constant string 'bz2aespipe'
+ # 10 bytes: itercountk digits
+ # 1 byte: '0' = AES128, '1' = AES192, '2' = AES256
+ # 1 byte: '0' = SHA256, '1' = SHA384, '2' = SHA512, '3' = RMD160
+ # 24 bytes: random seed string
+ # remaining bytes are bzip2 compressed and aespipe encrypted
+
+ # These definitions are only used when encrypting.
+ # Decryption will autodetect these definitions from archive.
+ ENCRYPTION=AES256
+ HASHFUNC=SHA256
+ ITERCOUNTK=100
+ WAITSECONDS=1
+ GPGKEY="/var/lib/amanda/.gnupg/am_key.gpg"
+ FDNUMBER=3
+
+ if test x$1 = x-d ; then
+ # decrypt
+ n=`head -c 10 - | tr -d -c 0-9a-zA-Z`
+ if test x${n} != xbz2aespipe ; then
+ echo "bz2aespipe: wrong magic - aborted" >/dev/tty
+ exit 1
+ fi
+ itercountk=`head -c 10 - | tr -d -c 0-9`
+ if test x${itercountk} = x ; then itercountk=0; fi
+ n=`head -c 1 - | tr -d -c 0-9`
+ encryption=AES128
+ if test x${n} = x1 ; then encryption=AES192; fi
+ if test x${n} = x2 ; then encryption=AES256; fi
+ n=`head -c 1 - | tr -d -c 0-9`
+ hashfunc=SHA256
+ if test x${n} = x1 ; then hashfunc=SHA384; fi
+ if test x${n} = x2 ; then hashfunc=SHA512; fi
+ if test x${n} = x3 ; then hashfunc=RMD160; fi
+ seedstr=`head -c 24 - | tr -d -c 0-9a-zA-Z+/`
+ #aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${encryption} -H ${hashfunc} -
+ S "${seedstr}" -C ${itercountk} -d | bzip2 -d -q
+ aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${encryption} -H ${hashfunc} -
+ S "${seedstr}" -C ${itercountk} -d
+ else
+ # encrypt
+ echo -n bz2aespipe
+ echo ${ITERCOUNTK} | awk '{printf "%10u", $1;}'
+ n=`echo ${ENCRYPTION} | tr -d -c 0-9`
+ aesstr=0
+ if test x${n} = x192 ; then aesstr=1; fi
+ if test x${n} = x256 ; then aesstr=2; fi
+ n=`echo ${HASHFUNC} | tr -d -c 0-9`
+ hashstr=0
+ if test x${n} = x384 ; then hashstr=1; fi
+ if test x${n} = x512 ; then hashstr=2; fi
+ if test x${n} = x160 ; then hashstr=3; fi
+ seedstr=`head -c 18 /dev/urandom | uuencode -m - | head -n 2 | tail -
+ n 1`
+ echo -n ${aesstr}${hashstr}${seedstr}
+ #bzip2 | aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${ENCRYPTION} -H $
+ {HASHFUNC} -S ${seedstr} -C ${ITERCOUNTK} -w ${WAITSECONDS}
+ aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${ENCRYPTION} -H ${HASHFUNC} -
+ S ${seedstr} -C ${ITERCOUNTK} -w ${WAITSECONDS}
+ fi
+ exit 0
+
+
+ or apply this small patch
+ Example 16.3. bz2aespipe.patch
+
+ @@ -15,3 +15,5 @@
+ ITERCOUNTK=100
+ -WAITSECONDS=10
+ +WAITSECONDS=1
+ +GPGKEY="/var/lib/amanda/.gnupg/am_key.gpg"
+ +FDNUMBER=3
+
+ @@ -36,3 +38,4 @@
+ seedstr=`head -c 24 - | tr -d -c 0-9a-zA-Z+/`
+ - aespipe -e ${encryption} -H ${hashfunc} -S "${seedstr}" -C $
+ {itercountk} -d | bzip2 -d -q
+ + #aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${encryption} -H ${hashfunc} -
+ S "${seedstr}" -C ${itercountk} -d | bzip2 -d -q
+ + aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${encryption} -H ${hashfunc} -
+ S "${seedstr}" -C ${itercountk} -d
+ else
+ @@ -52,3 +55,4 @@
+ echo -n ${aesstr}${hashstr}${seedstr}
+ - bzip2 | aespipe -e ${ENCRYPTION} -H ${HASHFUNC} -S ${seedstr} -C $
+ {ITERCOUNTK} -T -w ${WAITSECONDS}
+ + #bzip2 | aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${ENCRYPTION} -H $
+ {HASHFUNC} -S ${seedstr} -C ${ITERCOUNTK} -w ${WAITSECONDS}
+ + aespipe -K ${GPGKEY} -p ${FDNUMBER} -e ${ENCRYPTION} -H ${HASHFUNC} -
+ S ${seedstr} -C ${ITERCOUNTK} -w ${WAITSECONDS}
+ fi
+
+
+ Things I have changed:
+
+ o Decreased WAITSECONDS: No need to wait for 10 seconds to read the
+ passphrase.
+ o Removed bzip2 from the pipes: Amanda triggers GNU-zip-compression by
+ itself, no need to do this twice (slows down things, blows up size).
+ o Added options -K and -p: This enables aespipe to use the generated gpg-key
+ and tells it the number of the file-descriptor to read the passphrase from.
+
+
+ Note
+
+ You may set various parameters inside bz2aespipe. You may also call
+ bz2aespipe with various command-line-parameters to choose the encryption-
+ algorithm, hash-function etc. . For a start I have chosen to call bz2aespipe
+ without command-line-options.
+* Reconfigure and recompile Amanda (yes, I'm sorry ...):
+ As described in How_to_use_a_wrapper you have to run configure again with the
+ option --with-gnutar=/usr/local/libexec/amgtar, after that recompile and
+ reinstall Amanda. These steps are described in the mentioned document.
+
+
+Test
+
+Still to come ...
+
+Plans
+
+There are several wishes:
+
+* Ability to switch encryption inside a dumptype. This HOWTO describes a method
+ that enables/disables encryption for the whole installation. You might remove
+ the amgtar-wrapper and simply link to plain GNU-tar again to disable
+ encryption, but be aware that you also disable decryption with this step. You
+ will hit problems when you then try to restore encrypted tapes.
+* Ability to switch encryption-parameters inside a dumptype. Choice of
+ algorithm, hash-functions etc. I don't know if it makes sense to put it into
+ a dumptype or if it would be enough to configure it once inside amaespipe (I
+ assume the latter).
+* All this leads to the need to code this into Amanda itself: new dumptype-
+ options and corresponding calls to GNU-tar etc. inside client-src/sendbackup-
+ gnutar.c.
+
+This is it so far. Release early, release often. Feel free to contact me with
+your thoughts on this paper.
+-------------------------------------------------------------------------------
+
+Prev Up Next
+Chapter 15. How to use a wrapper Home Chapter 17. How to use different auth
+ with Amanda
+
/usr/local/bin/gtar "$@"
fi
+
Here is an example script in perl:
Example 15.2.
exit $rc;
+
-------------------------------------------------------------------------------
Prev Up Next
Stefan G. Weichinger
+AMANDA Core Team
+<sgw@amanda.org>
+
+Edited by
+
Amanda Core Team
+AMANDA Core Team
-------------------------------------------------------------------------------
Table of Contents
36._The_Amanda_Manual_Pages.
- amadmin - administrative interface to control Amanda backups
+ amadmin \14 administrative interface to control Amanda backups
- amaespipe - wrapper program for aespipe
+ amaespipe \14 wrapper program for aespipe
- amanda - Advanced Maryland Automatic Network Disk Archiver
+ amanda \14 Advanced Maryland Automatic Network Disk Archiver
- amanda.conf - Main configuration file for Amanda, the Advanced
+ amanda.conf \14 Main configuration file for Amanda, the Advanced
Maryland Automatic Network Disk Archiver
- amanda-client.conf - Client configuration file for Amanda, the
+ amanda-client.conf \14 Client configuration file for Amanda, the
Advanced Maryland Automatic Network Disk Archiver
- amcheck - run Amanda self-checks
+ amcheck \14 run Amanda self-checks
- amcheckdb - check Amanda database for tape consistency
+ amcheckdb \14 check Amanda database for tape consistency
- amcleanup - run the Amanda cleanup process after a failure
+ amcleanup \14 run the Amanda cleanup process after a failure
- amcrypt - reference crypt program for Amanda symmetric data
+ amcrypt \14 reference crypt program for Amanda symmetric data
encryption
- amcrypt-ossl - crypt program for Amanda symmetric data encryption
+ amcrypt-ossl \14 crypt program for Amanda symmetric data encryption
using OpenSSL
- amcrypt-ossl-asym - crypt program for Amanda asymmetric data
+ amcrypt-ossl-asym \14 crypt program for Amanda asymmetric data
encryption using OpenSSL
- amdd - Amanda version of dd
+ amdd \14 Amanda version of dd
- amdump - back up all disks in an Amanda configuration
+ amdump \14 back up all disks in an Amanda configuration
- amfetchdump - extract backup images from multiple Amanda tapes.
+ amfetchdump \14 extract backup images from multiple Amanda tapes.
- amflush - flush Amanda backup files from holding disk to tape
+ amflush \14 flush Amanda backup files from holding disk to tape
- amgetconf - look up amanda.conf variables
+ amgetconf \14 look up amanda.conf variables
- amlabel - label an Amanda tape
+ amlabel \14 label an Amanda tape
- ammt - Amanda version of mt
+ ammt \14 Amanda version of mt
- amoverview - display file systems processed by Amanda over time
+ amoverview \14 display file systems processed by Amanda over time
- amplot - visualize the behavior of Amanda
+ amplot \14 visualize the behavior of Amanda
- amrecover - Amanda index database browser
+ amrecover \14 Amanda index database browser
- amreport - generate a formatted output of statistics for an
+ amreport \14 generate a formatted output of statistics for an
Amanda run
- amrestore - extract backup images from an Amanda tape
+ amrestore \14 extract backup images from an Amanda tape
- amrmtape - remove a tape from the Amanda database
+ amrmtape \14 remove a tape from the Amanda database
- amstatus - display the state of an Amanda run
+ amstatus \14 display the state of an Amanda run
- amtape - user interface to Amanda tape changer controls
+ amtape \14 user interface to Amanda tape changer controls
- amtapetype - generate a tapetype definition.
+ amtapetype \14 generate a tapetype definition.
- amtoc - generate TOC (Table Of Contents) for an Amanda run
+ amtoc \14 generate TOC (Table Of Contents) for an Amanda run
- amverify - check an Amanda tape for errors
+ amverify \14 check an Amanda tape for errors
- amverifyrun - check the tapes written by the last Amanda run
+ amverifyrun \14 check the tapes written by the last Amanda run
37._Web_Ressources
|___________________|dumps_aren't.___________________________________________|
+
Installation Notes
0 16 * * 1-5 /usr/local/sbin/amcheck -m confname
45 0 * * 2-6 /usr/local/sbin/amdump confname
+
This is for SunOS 4.x, which has a per-user crontab; most other systems also
require a userid on each cron line. See your cron(8) for details. With these
cron lines, Amanda will check that the correct tape is in the drive every
amandaidx 10082/tcp
amidxtape 10083/tcp
+
You may choose a different port number if you like, but it must match that in
the services file on the client hosts too.
If you are running NIS (aka YP), you have to enter the Amanda service into
amandaidx stream tcp nowait $USER $AMINDEXD_PATH amindexd
amidxtape stream tcp nowait $USER $AMIDXTAPED_PATH amidxtaped
+
where $AMINDEXD_PATH and $AMIDXTAPED_PATH are the complete paths to where
the amindexd and amidxtaped executables (usually libexec_dir/amindexd and
libexec_dir/amidxtaped), and USER is the Amanda user.
groups = yes
server = $AMINDEXD_PATH/amindexd }
+
Example 2.5. /etc/xinetd.d/amidxtape
service amidxtape
groups = yes
server = $AMIDXTAPED_PATH/amidxtaped }
+
o If your tape server uses Dan Bernstein's daemontools http://cr.yp.to/
daemontools.html) instead of (x)inetd, you have to create amandaidx and
amidxtape services by hand.
/usr/local/bin/tcpserver -DHRl0 0 10082 \
/usr/local/libexec/amindexd >/dev/null 2>/dev/null
+
Example 2.7. /etc/amanda/supervise/amidxtape/run
#!/bin/sh
/usr/local/bin/tcpserver -DHRl0 0 10083 \
/usr/local/libexec/amidxtaped >/dev/null 2>/dev/null
+
# Link service directories into your svscan directory:
cd /service
amandaidx 10082/tcp
amidxtape 10083/tcp
+
You may choose a different port number if you like, but it must match that in
the services file on the tape server host too.
If you are running NIS (aka YP), you have to enter the Amanda service into
amanda dgram udp wait USER AMANDAD_PATH amandad
+
You may use the `patch-system' script, from client-src, in order to modify
this file. Run it with a `-h' argument for usage.
o If your Amanda client uses xinetd, you have to add the following file to
server = $AMANDAD_PATH/amandad
}
+
o If your Amanda client uses Dan Bernstein's daemontools (http://cr.yp.to/
daemontools.html) instead of (x)inetd, you have to create the amanda
service by hand. You will need also an UDP super-server (netcat in this
-e /usr/local/libexec/amandad >/dev/null 2>/dev/null
+
Note
The netcat-binary used in this run-file might also be called /usr/bin/nc
Table of Contents
- amadmin - administrative interface to control Amanda backups
+ amadmin \14 administrative interface to control Amanda backups
- amaespipe - wrapper program for aespipe
+ amaespipe \14 wrapper program for aespipe
- amanda - Advanced Maryland Automatic Network Disk Archiver
+ amanda \14 Advanced Maryland Automatic Network Disk Archiver
- amanda.conf - Main configuration file for Amanda, the Advanced Maryland
+ amanda.conf \14 Main configuration file for Amanda, the Advanced Maryland
Automatic Network Disk Archiver
- amanda-client.conf - Client configuration file for Amanda, the Advanced
+ amanda-client.conf \14 Client configuration file for Amanda, the Advanced
Maryland Automatic Network Disk Archiver
- amcheck - run Amanda self-checks
+ amcheck \14 run Amanda self-checks
- amcheckdb - check Amanda database for tape consistency
+ amcheckdb \14 check Amanda database for tape consistency
- amcleanup - run the Amanda cleanup process after a failure
+ amcleanup \14 run the Amanda cleanup process after a failure
- amcrypt - reference crypt program for Amanda symmetric data encryption
+ amcrypt \14 reference crypt program for Amanda symmetric data encryption
- amcrypt-ossl - crypt program for Amanda symmetric data encryption using
+ amcrypt-ossl \14 crypt program for Amanda symmetric data encryption using
OpenSSL
- amcrypt-ossl-asym - crypt program for Amanda asymmetric data encryption using
+ amcrypt-ossl-asym \14 crypt program for Amanda asymmetric data encryption using
OpenSSL
- amdd - Amanda version of dd
+ amdd \14 Amanda version of dd
- amdump - back up all disks in an Amanda configuration
+ amdump \14 back up all disks in an Amanda configuration
- amfetchdump - extract backup images from multiple Amanda tapes.
+ amfetchdump \14 extract backup images from multiple Amanda tapes.
- amflush - flush Amanda backup files from holding disk to tape
+ amflush \14 flush Amanda backup files from holding disk to tape
- amgetconf - look up amanda.conf variables
+ amgetconf \14 look up amanda.conf variables
- amlabel - label an Amanda tape
+ amlabel \14 label an Amanda tape
- ammt - Amanda version of mt
+ ammt \14 Amanda version of mt
- amoverview - display file systems processed by Amanda over time
+ amoverview \14 display file systems processed by Amanda over time
- amplot - visualize the behavior of Amanda
+ amplot \14 visualize the behavior of Amanda
- amrecover - Amanda index database browser
+ amrecover \14 Amanda index database browser
- amreport - generate a formatted output of statistics for an Amanda run
+ amreport \14 generate a formatted output of statistics for an Amanda run
- amrestore - extract backup images from an Amanda tape
+ amrestore \14 extract backup images from an Amanda tape
- amrmtape - remove a tape from the Amanda database
+ amrmtape \14 remove a tape from the Amanda database
- amstatus - display the state of an Amanda run
+ amstatus \14 display the state of an Amanda run
- amtape - user interface to Amanda tape changer controls
+ amtape \14 user interface to Amanda tape changer controls
- amtapetype - generate a tapetype definition.
+ amtapetype \14 generate a tapetype definition.
- amtoc - generate TOC (Table Of Contents) for an Amanda run
+ amtoc \14 generate TOC (Table Of Contents) for an Amanda run
- amverify - check an Amanda tape for errors
+ amverify \14 check an Amanda tape for errors
- amverifyrun - check the tapes written by the last Amanda run
+ amverifyrun \14 check the tapes written by the last Amanda run
Note
+
Run it on both the tape server and client and make sure the port numbers match:
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
& eval 'exec @PERL@ -S $0 $argv:q'
if 0;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
$debug=1;
push(@INC, "@DUMPER_DIR@");
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
$(XSLTPROC) --path $(srcdir)/xslt/ --xinclude --stringparam latex.imagebasedir "$*/" --stringparam noreference 1 --output $@ $(srcdir)/xslt/expand-sambadoc.xsl $<
%: xml-source/%.proc.xml $(srcdir)/xslt/man.xsl
- $(XSLTPROC) --path $(srcdir)/xslt/ --output $@ man.xsl $<
+ $(XSLTPROC) --path $(srcdir)/xslt/ --output $@ http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
else # !HAVE_XSLTPROC
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
@BUILD_MAN_PAGES_TRUE@@HAVE_XSLTPROC_TRUE@ $(XSLTPROC) --path $(srcdir)/xslt/ --xinclude --stringparam latex.imagebasedir "$*/" --stringparam noreference 1 --output $@ $(srcdir)/xslt/expand-sambadoc.xsl $<
@BUILD_MAN_PAGES_TRUE@@HAVE_XSLTPROC_TRUE@%: xml-source/%.proc.xml $(srcdir)/xslt/man.xsl
-@BUILD_MAN_PAGES_TRUE@@HAVE_XSLTPROC_TRUE@ $(XSLTPROC) --path $(srcdir)/xslt/ --output $@ man.xsl $<
+@BUILD_MAN_PAGES_TRUE@@HAVE_XSLTPROC_TRUE@ $(XSLTPROC) --path $(srcdir)/xslt/ --output $@ http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl $<
@BUILD_MAN_PAGES_TRUE@@HAVE_XSLTPROC_FALSE@xml-source/%.proc.xml: $(SRCMANPAGEDIR)/%.xml $(srcdir)/xslt/expand-sambadoc.xsl
@BUILD_MAN_PAGES_TRUE@@HAVE_XSLTPROC_FALSE@ @echo WARNING: $@ can not be generated: xsltproc is not available.
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMADMIN" 8 "" "" ""
+.\" Title: amadmin
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMADMIN" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amadmin - administrative interface to control Amanda backups
+amadmin \- administrative interface to control Amanda backups
.SH "SYNOPSIS"
.HP 8
-\fBamadmin\fR \fIconfig\fR \fIcommand\fR [\fIcommand\fR\fIoptions\fR] [-o \fIconfigoption\fR]*
-
+\fBamadmin\fR \fIconfig\fR \fIcommand\fR [\fIcommand_options\fR...] [\fB\-o\ \fR\fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmadmin\fR
performs various administrative tasks on the
-\fBconfig\fR\fBAmanda\fR
+\fIconfig\fR
+\fIAmanda\fR
configuration.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "COMMANDS"
.PP
Commands that take a
-\fBhostname\fR
+\fIhostname\fR
[
-\fBdisks\fR
+\fIdisks\fR
] parameter pair operate on all disks in the
-\fBdisklist\fR
+\fIdisklist\fR
for that
-\fBhostname\fR
+\fIhostname\fR
if no disks are specified. Where
-\fBhostname\fR
+\fIhostname\fR
is also marked as being optional, the command operates on all hosts and disks in the
-\fBdisklist\fR. Both
-\fBhostname\fR
+\fIdisklist\fR. Both
+\fIhostname\fR
and
-\fBdisks\fR
+\fIdisks\fR
are special expressions, see the "HOST & DISK EXPRESSION" section of
\fBamanda\fR(8)
for a description.
-.TP
+.PP
\fBversion\fR
+.RS 4
Show the current version and some compile time and runtime parameters. The
-\fBconfig\fR
+\fIconfig\fR
parameter must be present but is ignored.
-.TP
-\fBforce-bump\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]+
+.RE
+.PP
+\fBforce\-bump\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
+.RS 4
Force the
-\fBdisks\fR
+\fIdisks\fR
on
-\fBhostname\fR
+\fIhostname\fR
to bump to a new incremental level during the next
-\fBAmanda\fR
+\fIAmanda\fR
run.
-.TP
-\fBforce-no-bump\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]+
+.RE
+.PP
+\fBforce\-no\-bump\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
+.RS 4
Force the
-\fBdisks\fR
+\fIdisks\fR
on
-\fBhostname\fR
+\fIhostname\fR
to not bump to a new incremental level during the next
-\fBAmanda\fR
+\fIAmanda\fR
run.
-.TP
-\fBunforce-bump\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]+
+.RE
+.PP
+\fBunforce\-bump\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
+.RS 4
Undo a previous
-\fBforce-bump\fR
+\fBforce\-bump\fR
or
-\fBforce-no-bump\fR
+\fBforce\-no\-bump\fR
command.
-.TP
-\fBforce\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]+
+.RE
+.PP
+\fBforce\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
+.RS 4
Force the
-\fBdisks\fR
+\fIdisks\fR
on
-\fBhostname\fR
+\fIhostname\fR
to do a full (level 0) backup during the next
-\fBAmanda\fR
+\fIAmanda\fR
run.
-.TP
-\fBunforce\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]+
+.RE
+.PP
+\fBunforce\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
+.RS 4
Undo a previous
\fBforce\fR
command.
-.TP
-\fBreuse\fR \fBtapelabel\fR [ ... ]
+.RE
+.PP
+\fBreuse\fR \fItapelabel\fR [ ... ]
+.RS 4
The tapes listed will be available for reuse at their point in the tape cycle.
-.TP
-\fBno-reuse\fR \fBtapelabel\fR [ ... ]
+.RE
+.PP
+\fBno\-reuse\fR \fItapelabel\fR [ ... ]
+.RS 4
The tapes listed will not be reused when their turn comes up again in the tape cycle. Note that if this causes the number of reusable tapes to drop below the
-\fBamanda.conf\fR\fBtapecycle\fR
+\fBamanda.conf\fR
+\fItapecycle\fR
value,
-\fBAmanda\fR
+\fIAmanda\fR
will request new tapes until the count is satisfied again.
-.TP
-\fBdue\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]*
+.RE
+.PP
+\fBdue\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
+.RS 4
Show when the next full dump is due.
-.TP
-\fBfind\fR [ \fB--sort\fR \fIhkdlpb\fR ]\fB\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]*
+.RE
+.PP
+\fBfind\fR [ \fB\-\-sort\fR \fIhkdlpb\fR ] [ \fIhostname\fR [ \fIdisks\fR ]* ]*
+.RS 4
Display all backups currently on tape or in the holding disk. The tape label or holding disk filename, file number, and status are displayed.
.sp
The
-\fB--sort\fR
+\fB\-\-sort\fR
option changes the sort order using the following flags:
.sp
-\fBh\fR
-host name
-\fBk\fR
-disk name
-\fBd\fR
-dump date
-\fBl\fR
-backup level
-\fBp\fR
-dump part
-\fBb\fR
-tape label
+.RS 4
+.nf
+\fIh\fR: host name
+\fIk\fR: disk name
+\fId\fR: dump date
+\fIl\fR: backup level
+\fIp\fR: dump part
+\fIb\fR: tape label
+.fi
+.RE
.sp
An uppercase letter reverses the sort order for that key. The default sort order is
\fBhkdlpb\fR.
-.TP
-\fBdelete\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]+
+.RE
+.PP
+\fBdelete\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]+
+.RS 4
Delete the specified
-\fBdisks\fR
+\fIdisks\fR
on
-\fBhostname\fR
+\fIhostname\fR
from the
-\fBAmanda\fR
+\fIAmanda\fR
database.
.sp
.it 1 an-trap
.br
\fBNote\fR
If you do not also remove the disk from the
-\fBdisklist\fR
-file, \fBAmanda\fR will treat it as a new disk during the next run..TP
+\fIdisklist\fR
+file,
+\fIAmanda\fR
+will treat it as a new disk during the next run.
+.RE
+.PP
\fBtape\fR
+.RS 4
Display the tape(s)
-\fBAmanda\fR
+\fIAmanda\fR
expects to write to during the next run. See also
\fBamcheck\fR(8).
-.TP
+.RE
+.PP
\fBbumpsize\fR
+.RS 4
Display the current bump threshold parameters, calculated for all backup levels.
-.TP
-\fBbalance\fR [ \fB--days\fR \fI<num>\fR ]\fB\fR \fB\fR \fB\fR
+.RE
+.PP
+\fBbalance\fR [ \fB\-\-days\fR \fI<num>\fR ]
+.RS 4
Display the distribution of full backups throughout the dump schedule.
-.TP
-\fBexport\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]*
+.RE
+.PP
+\fBexport\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
+.RS 4
Convert records from the
-\fBAmanda\fR
+\fIAmanda\fR
database to a text format that may be transmitted to another
-\fBAmanda\fR
+\fIAmanda\fR
machine and
\fBimport\fRed.
-.TP
+.RE
+.PP
\fBimport\fR
+.RS 4
Convert
\fBexport\fRed records read from standard input to a form
-\fBAmanda\fR
+\fIAmanda\fR
uses and insert them into the database on this machine.
-.TP
-\fBdisklist\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]*
+.RE
+.PP
+\fBdisklist\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
+.RS 4
Display the
-\fBdisklist\fR
+\fIdisklist\fR
information for each of the
-\fBdisks\fR
+\fIdisks\fR
on
-\fBhostname\fR
+\fIhostname\fR
(or all hosts). Mostly used for debugging.
-.TP
-\fBinfo\fR [ \fBhostname\fR [ \fBdisks\fR ]* ]*
+.RE
+.PP
+\fBinfo\fR [ \fIhostname\fR [ \fIdisks\fR ]* ]*
+.RS 4
Display the database record for each of the
-\fBdisks\fR
+\fIdisks\fR
on
-\fBhostname\fR
+\fIhostname\fR
(or all hosts). Mostly used for debugging.
-.TP
-\fB-o\fR \fIconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "EXAMPLES"
.PP
Request three specific file systems on
-\fBmachine-a\fR
+\fImachine\-a\fR
get a full level 0 backup during the next
-\fBAmanda\fR
+\fIAmanda\fR
run.
+.sp
+.RS 4
.nf
-
-$ amadmin daily force machine-a / /var /usr
-amadmin: machine-a:/ is set to a forced level 0 tonight.
-amadmin: machine-a:/var is set to a forced level 0 tonight.
-amadmin: machine-a:/usr is set to a forced level 0 tonight.
+$ amadmin daily force machine\-a / /var /usr
+amadmin: machine\-a:/ is set to a forced level 0 tonight.
+amadmin: machine\-a:/var is set to a forced level 0 tonight.
+amadmin: machine\-a:/usr is set to a forced level 0 tonight.
.fi
+.RE
.PP
Request all file systems on
-\fBmachine-b\fR
+\fImachine\-b\fR
get a full level 0 backup during the next
-\fBAmanda\fR
+\fIAmanda\fR
run.
+.sp
+.RS 4
.nf
-
-$ amadmin daily force machine-b
-amadmin: machine-b:/ is set to a forced level 0 tonight.
-amadmin: machine-b:/var is set to a forced level 0 tonight.
-amadmin: machine-b:/usr is set to a forced level 0 tonight.
-amadmin: machine-b:/home is set to a forced level 0 tonight.
+$ amadmin daily force machine\-b
+amadmin: machine\-b:/ is set to a forced level 0 tonight.
+amadmin: machine\-b:/var is set to a forced level 0 tonight.
+amadmin: machine\-b:/usr is set to a forced level 0 tonight.
+amadmin: machine\-b:/home is set to a forced level 0 tonight.
.fi
+.RE
.PP
Undo the previous
\fBforce\fR
request for
\fI/home\fR
on
-\fBmachine-b\fR. The other file systems will still get a full level 0 backup.
+\fImachine\-b\fR. The other file systems will still get a full level 0 backup.
+.sp
+.RS 4
.nf
-
-$ amadmin daily unforce machine-b /home
-amadmin: force command for machine-b:/home cleared.
+$ amadmin daily unforce machine\-b /home
+amadmin: force command for machine\-b:/home cleared.
.fi
+.RE
.PP
Locate backup images of
\fI/var\fR
from
-\fBmachine-c\fR. The
-\fBtape or file\fR
+\fImachine\-c\fR. The
+\fItape or file\fR
column displays either a tape label or a filename depending on whether the image is on tape or is still in the holding disk. If the image is on tape, the
-\fBfile\fR
+\fIfile\fR
column tells you which file on the tape has the image (file number zero is a tape label). This column shows zero and is not meaningful if the image is still in the holding disk. The
-\fBstatus\fR
+\fIstatus\fR
column tells you whether the backup was successful or had some type of error.
+.sp
+.RS 4
.nf
-
-$ amadmin daily find machine-c /var
+$ amadmin daily find machine\-c /var
date host disk lv tape or file file part status
-2000\-11\-09 machine\-c /var 0 000110 9 -- OK
-2000\-11\-08 machine\-c /var 2 000109 2 -- OK
-2000\-11\-07 machine\-c /var 2 /amanda/20001107/machine-c._var.2 0 OK
-2000\-11\-06 machine\-c /var 2 000107 2 -- OK
-2000\-11\-05 machine\-c /var 2 000106 3 -- OK
-2000\-11\-04 machine\-c /var 2 000105 2 -- OK
-2000\-11\-03 machine\-c /var 2 000104 2 -- OK
-2000\-11\-02 machine\-c /var 2 000103 2 -- OK
-2000\-11\-01 machine\-c /var 1 000102 5 -- OK
-2000\-10\-31 machine\-c /var 1 000101 3 -- OK
+2000\-11\-09 machine\-c /var 0 000110 9 \-\- OK
+2000\-11\-08 machine\-c /var 2 000109 2 \-\- OK
+2000\-11\-07 machine\-c /var 2 /amanda/20001107/machine\-c._var.2 0 OK
+2000\-11\-06 machine\-c /var 2 000107 2 \-\- OK
+2000\-11\-05 machine\-c /var 2 000106 3 \-\- OK
+2000\-11\-04 machine\-c /var 2 000105 2 \-\- OK
+2000\-11\-03 machine\-c /var 2 000104 2 \-\- OK
+2000\-11\-02 machine\-c /var 2 000103 2 \-\- OK
+2000\-11\-01 machine\-c /var 1 000102 5 \-\- OK
+2000\-10\-31 machine\-c /var 1 000101 3 \-\- OK
.fi
+.RE
.PP
Forget about the
\fI/workspace\fR
disk on
-\fBmachine-d\fR. If you do not also remove the disk from the
-\fBdisklist\fR
+\fImachine\-d\fR. If you do not also remove the disk from the
+\fIdisklist\fR
file,
-\fBAmanda\fR
+\fIAmanda\fR
will treat it as a new disk during the next run.
+.sp
+.RS 4
.nf
-
-$ amadmin daily delete machine-d /workspace
-amadmin: machine-d:/workspace deleted from database.
+$ amadmin daily delete machine\-d /workspace
+amadmin: machine\-d:/workspace deleted from database.
amadmin: NOTE: you'll have to remove these from the disklist yourself.
.fi
+.RE
.PP
Find the next tape
-\fBAmanda\fR
+\fIAmanda\fR
will use (in this case,
123456).
+.sp
+.RS 4
.nf
-
$ amadmin daily tape
-The next \fBAmanda\fR run should go onto tape 123456 or a new tape.
+The next \fIAmanda\fR run should go onto tape 123456 or a new tape.
.fi
+.RE
.PP
Show how well full backups are balanced across the dump cycle. The
-\fBdue-date\fR
+\fIdue\-date\fR
column is the day the backups are due for a full backup.
-\fB#fs\fR
+\fI#fs\fR
shows the number of filesystems doing full backups that night, and
-\fBorig KB\fR
+\fIorig KB\fR
and
-\fBout KB\fR
+\fIout KB\fR
show the estimated total size of the backups before and after any compression, respectively.
.PP
The
-\fBbalance\fR
+\fIbalance\fR
column shows how far off that night's backups are from the average size (shown at the bottom of the balance column).
-\fBAmanda\fR
-tries to keep the backups within +/- 5%, but since the amount of data on each filesystem is always changing, and
-\fBAmanda\fR
+\fIAmanda\fR
+tries to keep the backups within +/\- 5%, but since the amount of data on each filesystem is always changing, and
+\fIAmanda\fR
will never delay backups just to rebalance the schedule, it is common for the schedule to fluctuate by larger percentages. In particular, in the case of a tape or backup failure, a bump will occur the following night, which will not be smoothed out until the next pass through the schedule.
.PP
The last line also shows an estimate of how many
-\fBAmanda\fR
+\fIAmanda\fR
runs will be made between full backups for a file system. In the example, a file system will probably have a full backup done every eight times
-\fBAmanda\fR
+\fIAmanda\fR
is run (e.g. every eight days).
+.sp
+.RS 4
.nf
-
$ amadmin daily balance
- due-date #fs orig KB out KB balance
--------------------------------------------
+ due\-date #fs orig KB out KB balance
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
11/10 Mon 21 930389 768753 +5.1%
11/11 Tue 29 1236272 733211 +0.2%
11/12 Wed 31 1552381 735796 +0.6%
-11/13 Thu 23 1368447 684552 -6.4%
+11/13 Thu 23 1368447 684552 \-6.4%
11/14 Fri 32 1065603 758155 +3.6%
11/15 Sat 14 1300535 738430 +0.9%
11/16 Sun 31 1362696 740365 +1.2%
11/17 Mon 30 1427936 773397 +5.7%
-11/18 Tue 11 1059191 721786 -1.3%
-11/19 Wed 19 1108737 661867 -9.5%
--------------------------------------------
+11/18 Tue 11 1059191 721786 \-1.3%
+11/19 Wed 19 1108737 661867 \-9.5%
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
TOTAL 241 12412187 7316312 731631 (estimated 8 runs per dumpcycle)
.fi
+.RE
.SH "FILES"
.PP
-/usr/local/etc/amanda/\fBconfig\fR/amanda.conf
+/usr/local/etc/amanda/\fIconfig\fR/amanda.conf
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamdump\fR(8),
\fBamrestore\fR(8),
\fBamfetchdump\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMAESPIPE" 8 "" "" ""
+.\" Title: amaespipe
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMAESPIPE" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amaespipe - wrapper program for aespipe
+amaespipe \- wrapper program for aespipe
.SH "SYNOPSIS"
.HP 10
\fBamaespipe\fR
.SH "DESCRIPTION"
.PP
+
\fBamaespipe\fR
requires
\fBaespipe\fR,
and
\fBgpg\fR
to work. Aespipe is available from
-: http://loop-aes.sourceforge.net
+\fI\%http://loop\-aes.sourceforge.net\fR
.PP
+
\fBamaespipe\fR
will search for the aespipe program in the following directories: /usr/bin:/usr/local/bin:/sbin:/usr/sbin.
-\fBamaespipe\fR is called by \fBamcrypt\fR for \fBAmanda\fR data encryption.
.PP
+
+\fBamaespipe\fR
+is called by
+\fBamcrypt\fR
+for
+\fIAmanda\fR
+data encryption.
+.PP
+
\fBamaespipe\fR
is based on aespipe's bzaespipe program. It calls aespipe to encrypt data using AES256 as the encryption and SHA256 as the hash function. GPG key should be stored in $AMANDA_HOME/.gnupg/am_key.gpg.
\fBamaespipe\fR
\fBaespipe\fR(1),
\fBamcrypt\fR(8),
\fBgpg\fR(1)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMANDA-CLIENT.CONF" 5 "" "" ""
+.\" Title: amanda-client.conf
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMANDA\-CLIENT.CONF" "5" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amanda-client.conf - Client configuration file for Amanda, the Advanced Maryland Automatic Network Disk Archiver
+amanda\-client.conf \- Client configuration file for Amanda, the Advanced Maryland Automatic Network Disk Archiver
.SH "DESCRIPTION"
.PP
-\fIamanda-client.conf\fR
+\fIamanda\-client.conf\fR
is the client configuration file for
-\fBAmanda\fR. This manpage lists the relevant sections and parameters of this file for quick reference.
+\fIAmanda\fR. This manpage lists the relevant sections and parameters of this file for quick reference.
.PP
The files
-\fB<CONFIG_DIR>/amanda-client.conf\fR
+\fB<CONFIG_DIR>/amanda\-client.conf\fR
and
-\fB<CONFIG_DIR>/<config>/amanda-client.conf\fR
+\fB<CONFIG_DIR>/<config>/amanda\-client.conf\fR
are loaded.
.SH "PARAMETERS"
.PP
There are a number of configuration parameters that control the behavior of the
-\fBAmanda\fR
+\fIAmanda\fR
programs. All have default values, so you need not specify the parameter in
-\fBamanda-client.conf\fR
+\fBamanda\-client.conf\fR
if the default is suitable.
.PP
Lines starting with # are ignored, as are blank lines. Comments may be placed on a line with a directive by starting the comment with a #. The remainder of the line is ignored.
.PP
Integer arguments may have one of the following (case insensitive) suffixes, some of which have a multiplier effect:
.SS "POSSIBLE SUFFIXES"
-.TP
+.PP
\fBb byte bytes\fR
+.RS 4
Some number of bytes.
-.TP
+.RE
+.PP
\fBbps\fR
+.RS 4
Some number of bytes per second.
-.TP
+.RE
+.PP
\fBk kb kbyte kbytes kilobyte kilobytes\fR
+.RS 4
Some number of kilobytes (bytes*1024).
-.TP
+.RE
+.PP
\fBkps kbps\fR
+.RS 4
Some number of kilobytes per second (bytes*1024).
-.TP
+.RE
+.PP
\fBm mb meg mbyte mbytes megabyte megabytes\fR
+.RS 4
Some number of megabytes (bytes*1024*1024).
-.TP
+.RE
+.PP
\fBmps mbps\fR
+.RS 4
Some number of megabytes per second (bytes*1024*1024).
-.TP
+.RE
+.PP
\fBg gb gbyte gbytes gigabyte gigabytes\fR
+.RS 4
Some number of gigabytes (bytes*1024*1024*1024).
-.TP
+.RE
+.PP
\fBtape tapes\fR
+.RS 4
Some number of tapes.
-.TP
+.RE
+.PP
\fBday days\fR
+.RS 4
Some number of days.
-.TP
+.RE
+.PP
\fBweek weeks\fR
+.RS 4
Some number of weeks (days*7).
.sp
.it 1 an-trap
\fBNote\fR
The value
\fBinf\fR
-may be used in most places where an integer is expected
-to mean an infinite amount.
-
+may be used in most places where an integer is expected to mean an infinite amount.
+.sp
Boolean arguments may have any of the values
\fBy\fR,
\fByes\fR,
to indicate a false state. If no argument is given,
\fBtrue\fR
is assumed.
+.RE
.SS "PARAMETERS"
-.TP
-\fBconf\fR \fB string\fR
+.PP
+\fBconf\fR \fI string\fR
+.RS 4
Default:
-\fBSet by configure\fR. The conf use by amrecover.
-.TP
-\fBindex_server\fR \fB string\fR
+\fISet by configure\fR. The conf use by amrecover.
+.RE
+.PP
+\fBindex_server\fR \fI string\fR
+.RS 4
Default:
-\fBSet by configure\fR. The amindexd server amrecover will connect to.
-.TP
-\fBtape_server\fR \fB string\fR
+\fISet by configure\fR. The amindexd server amrecover will connect to.
+.RE
+.PP
+\fBtape_server\fR \fI string\fR
+.RS 4
Default:
-\fBSet by configure\fR. The amidxtaped server amrecover will connect to.
-.TP
-\fBtapedev\fR \fB string\fR
+\fISet by configure\fR. The amidxtaped server amrecover will connect to.
+.RE
+.PP
+\fBtapedev\fR \fI string\fR
+.RS 4
Default:
-\fBSet by configure\fR. The tapedev amrecover will use.
-.TP
-\fBauth\fR \fB string\fR
+\fISet by configure\fR. The tapedev amrecover will use.
+.RE
+.PP
+\fBauth\fR \fI string\fR
+.RS 4
Default:
-\fBbsd\fR. Type of authorization to perform between tape server and backup client hosts.
+\fIbsd\fR. Type of authorization to perform between tape server and backup client hosts.
.sp
\fBbsd\fR, bsd authorization with udp initial connection and one tcp connection by data stream.
.sp
\fBbsdudp\fR, like bsd, but will use only one tcp connection for all data stream.
.sp
\fBkrb4\fR
-to use Kerberos-IV authorization.
+to use Kerberos\-IV authorization.
.sp
\fBkrb5\fR
-to use Kerberos-V authorization.
+to use Kerberos\-V authorization.
.sp
\fBrsh\fR
to use rsh authorization.
.sp
\fBssh\fR
to use OpenSSH authorization.
-.TP
-\fBssh_keys\fR \fB string\fR
+.RE
+.PP
+\fBssh_keys\fR \fI string\fR
+.RS 4
Default:
-\fBNo default\fR. The key file the ssh auth will use, it must be the private key. If this parameter is not specified, then the deafult ssh key will be used.
-.TP
-\fBgnutar_list_dir\fR \fB string\fR
+\fINo default\fR. The key file the ssh auth will use, it must be the private key. If this parameter is not specified, then the deafult ssh key will be used.
+.RE
+.PP
+\fBgnutar_list_dir\fR \fI string\fR
+.RS 4
Default from configure
-\fB--with-gnutar-listdir=DIR\fR. The directory where gnutar keep its state file.
-.TP
-\fBamandates\fR \fB string\fR
+\fI\-\-with\-gnutar\-listdir=DIR\fR. The directory where gnutar keep its state file.
+.RE
+.PP
+\fBamandates\fR \fI string\fR
+.RS 4
Default:
-\fB/etc/amandates\fR. The file where amanda keep the last date of each dumplevel.
+\fI/etc/amandates\fR. The file where amanda keep the last date of each dumplevel.
+.RE
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion, major update, splitting
+\fIAmanda\fR\-documentation: XML\-conversion, major update, splitting
.SH "SEE ALSO"
.PP
+
\fBamanda\fR(8),
\fBamanda.conf\fR(5),
\fBamcrypt\fR(8),
\fBaespipe\fR(1),
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMANDA" 8 "" "" ""
+.\" Title: amanda
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMANDA" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amanda - Advanced Maryland Automatic Network Disk Archiver
+amanda \- Advanced Maryland Automatic Network Disk Archiver
.SH "SYNOPSIS"
.HP 8
\fBamadmin\fR \fIconfig\fR \fIcommand\fR [\fIoptions\fR]
.br
.HP 8
-\fBamflush\fR [-f] \fIconfig\fR
+\fBamflush\fR [\-f] \fIconfig\fR
.br
.HP 10
.br
.HP 8
-\fBamlabel\fR \fIconfig\fR \fIlabel\fR [\fIslot\fRÂ \fIslot\fR]
+\fBamlabel\fR \fIconfig\fR \fIlabel\fR [\fIslot\fR\ \fIslot\fR]
.br
.HP 5
.br
.HP 7
-\fBamplot\fR [\fIoptions\fR] \fIamdump-files\fR
+\fBamplot\fR [\fIoptions\fR] \fIamdump\-files\fR
.br
.HP 10
.br
.HP 10
-\fBamrestore\fR [\fIoptions\fR] \fItapedevice\fR [\fIhostname\fRÂ [\fIdiskname\fR]]
+\fBamrestore\fR [\fIoptions\fR] \fItapedevice\fR [\fIhostname\fR\ [\fIdiskname\fR]]
.br
.HP 12
-\fBamfetchdump\fR [\fIoptions\fR] \fIconfig\fR [\fIhostname\fRÂ [\fIdiskname\fRÂ [\fIdate\fRÂ [level]]]]
+\fBamfetchdump\fR [\fIoptions\fR] \fIconfig\fR [\fIhostname\fR\ [\fIdiskname\fR\ [\fIdate\fR\ [level]]]]
.HP 9
\fBamrmtape\fR [\fIoptions\fR] \fIconfig\fR \fIlabel\fR
.br
\fBamverifyrun\fR \fIconfig\fR
.SH "DESCRIPTION"
.PP
-\fBAmanda\fR
+\fIAmanda\fR
is the "Advanced Maryland Automatic Network Disk Archiver". This manual page gives an overview of the
-\fBAmanda\fR
+\fIAmanda\fR
commands and configuration files for quick reference.
.PP
Here are all the
-\fBAmanda\fR
+\fIAmanda\fR
commands. Each one has its own manual page. See them for all the gory details.
-.TP
+.PP
\fBamdump\fR
+.RS 4
Take care of automatic
-\fBAmanda\fR
+\fIAmanda\fR
backups. This is normally executed by
\fBcron\fR
on a computer called the
-\fBtape server host\fR
+\fItape server host\fR
and requests backups of file systems located on
-\fBbackup\fR\fBclients\fR.
+\fIbackup\fR
+\fIclients\fR.
\fBAmdump\fR
backs up all disks in the
-\fBdisklist\fR
+\fIdisklist\fR
file (discussed below) to tape or, if there is a problem, to a special
-\fBholding\fR\fBdisk\fR. After all backups are done,
+\fIholding\fR
+\fIdisk\fR. After all backups are done,
\fBamdump\fR
sends mail reporting failures and successes.
-.TP
+.RE
+.PP
\fBamflush\fR
+.RS 4
Flush backups from the holding disk to tape.
\fBAmflush\fR
is used after
has reported it could not write backups to tape for some reason. When this happens, backups stay in the holding disk. Run
\fBamflush\fR
after the tape problem is corrected to write backups from the holding disk to tape.
-.TP
+.RE
+.PP
\fBamcleanup\fR
+.RS 4
Clean up after an interrupted
\fBamdump\fR. This command is only needed if
\fBamdump\fR
was unable to complete for some reason, usually because the tape server host crashed while
\fBamdump\fR
was running.
-.TP
+.RE
+.PP
\fBamrecover\fR
+.RS 4
Provides an interactive interface to browse the
-\fBAmanda\fR
+\fIAmanda\fR
index files (backup image catalogues) and select which tapes to recover files from. It can also run
\fBamrestore\fR
and a restore program (e.g.
\fBtar\fR) to actually recover the files.
-.TP
+.RE
+.PP
\fBamrestore\fR
+.RS 4
Read an
-\fBAmanda\fR
+\fIAmanda\fR
tape, searching for requested backups.
\fBAmrestore\fR
is suitable for everything from interactive restores of single files to a full restore of all partitions on a failed disk.
-.TP
+.RE
+.PP
\fBamfetchdump\fR
+.RS 4
Performs
-\fBAmanda\fR
+\fIAmanda\fR
tape restoration, similar to
-\fBamrestore\fR. Additional capabilities include "hands-off" searching of multiple tapes, automatic retrieval of specific dump files based on dump logs, and assembly of tape-spanning split dump files.
-.TP
+\fBamrestore\fR. Additional capabilities include "hands\-off" searching of multiple tapes, automatic retrieval of specific dump files based on dump logs, and assembly of tape\-spanning split dump files.
+.RE
+.PP
\fBamlabel\fR
+.RS 4
Write an
-\fBAmanda\fR
+\fIAmanda\fR
format label onto a tape. All
-\fBAmanda\fR
+\fIAmanda\fR
tapes must be labeled with
\fBamlabel\fR.
\fBAmdump\fR
and
\fBamflush\fR
will not write to an unlabeled tape (see TAPE MANAGEMENT below).
-.TP
+.RE
+.PP
\fBamcheck\fR
+.RS 4
Verify the correct tape is mounted and all file systems on all backup client systems are ready to be backed up. Often run by
\fBcron\fR
before
\fBamdump\fR
to generate a mail warning that backups might fail unless corrective action is taken.
-.TP
+.RE
+.PP
\fBamadmin\fR
+.RS 4
Take care of administrative tasks like finding out which tapes are needed to restore a filesystem, forcing hosts to do full backups of selected disks and looking at schedule balance information.
-.TP
+.RE
+.PP
\fBamtape\fR
+.RS 4
Take care of tape changer control operations like loading particular tapes, ejecting tapes and scanning the tape storage slots.
-.TP
+.RE
+.PP
\fBamverify\fR
+.RS 4
Check
-\fBAmanda\fR
+\fIAmanda\fR
backup tapes for errors.
-.TP
+.RE
+.PP
\fBamrmtape\fR
+.RS 4
Delete a tape from the
-\fBAmanda\fR
+\fIAmanda\fR
databases.
-.TP
+.RE
+.PP
\fBamstatus\fR
+.RS 4
Report the status of a running or completed
\fBamdump\fR.
-.TP
+.RE
+.PP
\fBamoverview\fR
+.RS 4
Display a chart of hosts and file systems backed up every run.
-.TP
+.RE
+.PP
\fBamplot\fR
+.RS 4
Generate utilization plots of
-\fBAmanda\fR
+\fIAmanda\fR
runs for performance tuning.
-.TP
+.RE
+.PP
\fBamreport\fR
+.RS 4
Generate an
-\fBAmanda\fR
-summary E-mail report.
-.TP
+\fIAmanda\fR
+summary E\-mail report.
+.RE
+.PP
\fBamtoc\fR
+.RS 4
Generate table of content files for
-\fBAmanda\fR
+\fIAmanda\fR
tapes.
-.TP
+.RE
+.PP
\fBamcheckdb\fR
+.RS 4
Verify every tape
-\fBAmanda\fR
+\fIAmanda\fR
knows about is consistent in the database.
-.TP
+.RE
+.PP
\fBamgetconf\fR
+.RS 4
Look up parameters in the
-\fBAmanda\fR
+\fIAmanda\fR
configuration file.
-.TP
+.RE
+.PP
\fBamtapetype\fR
+.RS 4
Generate a tapetype definition.
-.TP
+.RE
+.PP
\fBamaespipe\fR
+.RS 4
Wrapper program from aespipe (data encryption utility)
-.TP
+.RE
+.PP
\fBamcrypt\fR
+.RS 4
Reference encryption program for Amanda symmetric data encryption
+.RE
.SH "CONFIGURATION"
.PP
-There are three user-editable files that control the behavior of
-\fBAmanda\fR.
+There are three user\-editable files that control the behavior of
+\fIAmanda\fR.
.PP
The first is
\fBamanda.conf\fR, the main configuration file. It contains parameters to customize
-\fBAmanda\fR
+\fIAmanda\fR
for the site. Refer to the
\fBamanda.conf\fR(5), manpage for details on
-\fBAmanda\fR
+\fIAmanda\fR
configuration parameters.
.PP
Second is the
-\fBdisklist\fR
+\fIdisklist\fR
file, which lists hosts and disk partitions to back up.
.PP
Third is the
-\fBtapelist\fR
+\fItapelist\fR
file, which lists tapes that are currently active. These files are described in more detail in the following sections.
.PP
All files are stored in individual configuration directories under
\fI/usr/local/etc/amanda/\fR. A site will often have more than one configuration. For example, it might have a
-\fBnormal\fR
+\fInormal\fR
configuration for everyday backups and an
-\fBarchive\fR
+\fIarchive\fR
configuration for infrequent full archival backups. The configuration files would be stored under directories
\fI/usr/local/etc/amanda/normal/\fR
and
\fI/usr/local/etc/amanda/archive/\fR, respectively. Part of the job of an
-\fBAmanda\fR
+\fIAmanda\fR
administrator is to create, populate and maintain these directories.
.PP
All log and database files generated by
-\fBAmanda\fR
+\fIAmanda\fR
go in corresponding directories somewhere. The exact location is controlled by entries in
\fBamanda.conf\fR. A typical location would be under
\fI/var/adm/amanda\fR. For the above example, the files might go in
\fI/var/adm/amanda/archive/\fR.
.PP
As log files are no longer needed (no longer contain relevant information),
-\fBAmanda\fR
+\fIAmanda\fR
cycles them out in various ways, depending on the type of file.
.PP
Detailed information about
\fBamdump\fR
runs are stored in files named
-\fBamdump.\fR\fBNN\fR
+\fBamdump.\fR\fINN\fR
where
-\fBNN\fR
+\fINN\fR
is a sequence number, with 1 being the most recent file.
\fBAmdump\fR
rotates these files each run, keeping roughly the last
The file used by
\fBamreport\fR
to generate the mail summary is named
-\fBlog.\fR\fBYYYYMMDD.NN\fR
+\fBlog.\fR\fIYYYYMMDD.NN\fR
where
-\fBYYYYMMDD\fR
+\fIYYYYMMDD\fR
is the datestamp of the start of the
\fBamdump\fR
run and
-\fBNN\fR
+\fINN\fR
is a sequence number started at 0. At the end of each
\fBamdump\fR
run, log files for runs whose tapes have been reused are renamed into a subdirectory of the main log directory (see the
\fBlogdir\fR
parameter below) named
\fBoldlog\fR. It is up to the
-\fBAmanda\fR
+\fIAmanda\fR
administrator to remove them from this directory when desired.
.PP
Index (backup image catalogue) files older than the full dump matching the oldest backup image for a given client and disk are removed by
.SH "DISKLIST FILE"
.PP
The
-\fBdisklist\fR
+\fIdisklist\fR
file determines which disks will be backed up by
-\fBAmanda\fR. The file usually contains one line per disk:
+\fIAmanda\fR. The file usually contains one line per disk:
+.sp
+.RS 4
.nf
-
-\fBhostname diskname\fR [\fBdiskdevice\fR] \fBdumptype\fR [\fBspindle\fR [\fBinterface\fR] ]
+\fIhostname diskname\fR [\fIdiskdevice\fR] \fIdumptype\fR [\fIspindle\fR [\fIinterface\fR] ]
.fi
+.RE
.PP
All pairs [
-\fBhostname diskname\fR
+\fIhostname diskname\fR
] must be unique.
.PP
Lines starting with # are ignored, as are blank lines. The fields have the following meanings:
-.TP
-\fBhostname\fR
+.PP
+\fIhostname\fR
+.RS 4
The name of the host to be backed up. If
\fBdiskdevice\fR
refers to a PC share, this is the host
-\fBAmanda\fR
+\fIAmanda\fR
will run the Samba
\fBsmbclient\fR
program on to back up the share.
-.TP
-\fBdiskname\fR
+.RE
+.PP
+\fIdiskname\fR
+.RS 4
The name of the disk (a label). In most case, you set your
\fBdiskname\fR
to the
for each entry. It's the
\fBdiskname\fR
that you use on the commandline for any
-\fBAmanda\fR
+\fIAmanda\fR
command. Look at the example/disklist file for example.
-.TP
-\fBdiskdevice\fR
+.RE
+.PP
+\fIdiskdevice\fR
+.RS 4
Default: same as diskname. The name of the disk device to be backed up. It may be a full device name, a device name without the
\fI/dev/\fR
prefix, e.g.
-\fBsd0a\fR, or a mount point such as
+\fIsd0a\fR, or a mount point such as
\fI/usr\fR.
.sp
It may also refer to a PC share by starting the name with two (forward) slashes, e.g.
-\fI//some-pc/home\fR. In this case, the
+\fI//some\-pc/home\fR. In this case, the
\fBprogram\fR
option in the associated
\fBdumptype\fR
in the
\fBdumptype\fR
that triggers the use of Samba.
-.TP
-\fBdumptype\fR
+.RE
+.PP
+\fIdumptype\fR
+.RS 4
Refers to a
\fBdumptype\fR
defined in the
\fBamanda.conf\fR
file.
-\fBDumptype\fRs specify backup related parameters, such as whether to compress the backups, whether to record backup results in
+\fIDumptype\fRs specify backup related parameters, such as whether to compress the backups, whether to record backup results in
\fI/etc/dumpdates\fR, the disk's relative priority, etc.
-.TP
-\fBspindle\fR
+.RE
+.PP
+\fIspindle\fR
+.RS 4
Default:
-\fB-1\fR. A number used to balance backup load on a host.
-\fBAmanda\fR
-will not run multiple backups at the same time on the same spindle, unless the spindle number is -1, which means there is no spindle restriction.
-.TP
-\fBinterface\fR
+\fB\-1\fR. A number used to balance backup load on a host.
+\fIAmanda\fR
+will not run multiple backups at the same time on the same spindle, unless the spindle number is \-1, which means there is no spindle restriction.
+.RE
+.PP
+\fIinterface\fR
+.RS 4
Default:
-\fBlocal\fR. The name of a network interface definition in the
+\fIlocal\fR. The name of a network interface definition in the
\fBamanda.conf\fR
file, used to balance network load.
+.RE
.PP
Instead of naming a
-\fBdumptype\fR, it is possible to define one in-line, enclosing
+\fBdumptype\fR, it is possible to define one in\-line, enclosing
\fBdumptype\fR
options within curly braces, one per line, just like a
\fBdumptype\fR
definition in
-\fBamanda.conf\fR. Since pre-existing
+\fBamanda.conf\fR. Since pre\-existing
\fBdumptype\fRs are valid option names, this syntax may be used to customize
\fBdumptype\fRs for particular disks.
.PP
For instance, if a
\fBdumptype\fR
named
-\fBnormal\fR
+\fInormal\fR
is used for most disks, but use of the holding disk needs to be disabled for the file system that holds it, this would work instead of defining a new dumptype:
+.sp
+.RS 4
.nf
-
-\fBhostname diskname\fR [ \fBdiskdevice\fR ] {
+\fIhostname diskname\fR [ \fIdiskdevice\fR ] {
normal
holdingdisk never
-} [ \fBspindle\fR [ \fBinterface\fR ] ]
+} [ \fIspindle\fR [ \fIinterface\fR ] ]
.fi
+.RE
.SH "TAPE MANAGEMENT"
.PP
The
-\fBtapelist\fR
+\fItapelist\fR
file contains the list of tapes in active use. This file is maintained entirely by
-\fBAmanda\fR
+\fIAmanda\fR
and should not be created or edited during normal operation. It contains lines of the form:
.PP
-
-.sp
+.RS 4
.nf
YYYYMMDD label flags
.fi
-
+.RE
.PP
Where
-\fBYYYYMMDD\fR
+\fIYYYYMMDD\fR
is the date the tape was written,
-\fBlabel\fR
+\fIlabel\fR
is a label for the tape as written by
\fBamlabel\fR
and
-\fBflags\fR
+\fIflags\fR
tell
-\fBAmanda\fR
+\fIAmanda\fR
whether the tape may be reused, etc (see the
\fBreuse\fR
options of
.PP
The normal value for the
\fBtapedev\fR
-parameter, or for what a tape changer returns, is a full path name to a non-rewinding tape device, such as
+parameter, or for what a tape changer returns, is a full path name to a non\-rewinding tape device, such as
\fI/dev/nst0\fR
or
\fI/dev/rmt/0mn\fR
or
\fI/dev/nst0.1\fR
or whatever conventions the operating system uses.
-\fBAmanda\fR
-provides additional application level drivers that support non-traditional tape-simulations or features. To access a specific output driver, set
+\fIAmanda\fR
+provides additional application level drivers that support non\-traditional tape\-simulations or features. To access a specific output driver, set
\fBtapedev\fR
(or configure your changer to return) a string of the form
-\fBdriver\fR:\fBdriver-info\fR
+\fIdriver\fR:\fIdriver\-info\fR
where
-\fBdriver\fR
+\fIdriver\fR
is one of the supported drivers and
-\fBdriver-info\fR
+\fIdriver\-info\fR
is optional additional information needed by the driver.
.PP
The supported drivers are:
-.TP
-\fBtape\fR
+.PP
+\fItape\fR
+.RS 4
This is the default driver. The
-\fBdriver-info\fR
+\fIdriver\-info\fR
is the tape device name. Entering
-
.sp
+.RS 4
.nf
tapedev /dev/rmt/0mn
.fi
+.RE
+.sp
is really a short hand for
-
.sp
+.RS 4
.nf
tapedev tape:/dev/rmt/0mn
.fi
-.
-.TP
-\fBnull\fR
+.RE
+.RE
+.PP
+\fInull\fR
+.RS 4
This driver throws away anything written to it and returns EOF for any reads except a special case is made for reading a label, in which case a "fake" value is returned that
-\fBAmanda\fR
+\fIAmanda\fR
checks for and allows through regardless of what you have set in
\fBlabelstr\fR. The
-\fBdriver-info\fR
+\fIdriver\-info\fR
field is not used and may be left blank:
.sp
-
.sp
+.RS 4
.nf
tapedev null:
.fi
-
+.RE
.sp
The
-\fBlength\fR
+\fIlength\fR
value from the associated
\fBtapetype\fR
is used to limit the amount of data written. When the limit is reached, the driver will simulate end of tape.
.nr an-break-flag 1
.br
\fBNote\fR
-This driver should only be used for debugging and testing,
-and probably only with the
+This driver should only be used for debugging and testing, and probably only with the
\fBrecord\fR
option set to
-\fBno\fR..TP
-\fBrait\fR
-\fBR\fRedundant
-\fBA\fRrray of
-\fBI\fRnexpensive (?)
-\fBT\fRapes. Reads and writes tapes mounted on multiple drives by spreading the data across N-1 drives and using the last drive for a checksum. See docs/RAIT for more information.
+\fIno\fR.
+.RE
+.PP
+\fIrait\fR
+.RS 4
+\fIR\fRedundant
+\fIA\fRrray of
+\fII\fRnexpensive (?)
+\fIT\fRapes. Reads and writes tapes mounted on multiple drives by spreading the data across N\-1 drives and using the last drive for a checksum. See docs/RAIT for more information.
.sp
The
-\fBdriver-info\fR
+\fIdriver\-info\fR
field describes the devices to use. Curly braces indicate multiple replacements in the string. For instance:
.sp
-
.sp
+.RS 4
.nf
tapedev rait:/dev/rmt/tps0d{4,5,6}n
.fi
-
+.RE
.sp
would use the following devices:
.sp
-\fI/dev/rmt/tps0d4n\fR\fI/dev/rmt/tps0d5n\fR\fI/dev/rmt/tps0d6n\fR
-.TP
-\fBfile\fR
+\fI/dev/rmt/tps0d4n\fR
+\fI/dev/rmt/tps0d5n\fR
+\fI/dev/rmt/tps0d6n\fR
+.RE
+.PP
+\fIfile\fR
+.RS 4
This driver emulates a tape device with a set of files in a directory. The
-\fBdriver-info\fR
+\fIdriver\-info\fR
field must be the name of an existing directory. The driver will test for a subdirectory of that named
-\fBdata\fR
+\fIdata\fR
and return
\fBoffline\fR
until it is present. When present, the driver uses two files in the
-\fBdata\fR
+\fIdata\fR
subdirectory for each tape file. One contains the actual data. The other contains record length information.
.sp
The driver uses a file named
-\fBstatus\fR
+\fIstatus\fR
in the
\fBfile\fR
device directory to hold driver status information, such as tape position. If not present, the driver will create it as though the device is rewound.
.sp
The
-\fBlength\fR
+\fIlength\fR
value from the associated
\fBtapetype\fR
is used to limit the amount of data written. When the limit is reached, the driver will simulate end of tape.
.sp
-One way to use this driver with a real device such as a CD-writer is to create a directory for the
+One way to use this driver with a real device such as a CD\-writer is to create a directory for the
\fBfile\fR
device and one or more other directories for the actual data. Create a symlink named
-\fBdata\fR
+\fIdata\fR
in the
\fBfile\fR
directory to one of the data directories. Set the
length to whatever the medium will hold.
.sp
When
-\fBAmanda\fR
+\fIAmanda\fR
fills the
\fBfile\fR
device, remove the symlink and (optionally) create a new symlink to another data area. Use a CD writer software package to burn the image from the first data area.
.sp
To read the CD, mount it and create the
-\fBdata\fR
+\fIdata\fR
symlink in the
\fBfile\fR
device directory.
+.RE
.SH "AUTHORIZATION"
.PP
-\fBAmanda\fR
+\fIAmanda\fR
processes on the tape server host run as the
\fBdumpuser\fR
user listed in
\fBamanda.conf\fR. When they connect to a backup client, they do so with an
-\fBAmanda\fR-specific protocol. They do not, for instance, use
+\fIAmanda\fR\-specific protocol. They do not, for instance, use
\fBrsh\fR
or
\fBssh\fR
On the client side, the
\fBamandad\fR
daemon validates the connection using one of several methods, depending on how it was compiled and on options it is passed:
-.TP
-.rhosts
+.PP
+\&.rhosts
+.RS 4
Even though
-\fBAmanda\fR
+\fIAmanda\fR
does not use
\fBrsh\fR, it can use
-.rhosts-style authentication and a
-.rhosts
+\fB.rhosts\fR\-style authentication and a
+\fB.rhosts\fR
file.
-.TP
-.amandahosts
+.RE
+.PP
+\&.amandahosts
+.RS 4
This is essentially the same as
-.rhosts
+\fB.rhosts\fR
authentication except a different file, with almost the same format, is used. This is the default mechanism built into
-\fBAmanda\fR.
+\fIAmanda\fR.
.sp
The format of the
\fI.amandahosts\fR
file is:
.sp
-\fBhostname\fR
+\fIhostname\fR
[
-\fBusername\fR
+\fIusername\fR
[
-\fBservice\fR
+\fIservice\fR
]*]
.sp
If
-\fBusername\fR
+\fIusername\fR
is ommitted, it defaults to the user running
\fBamandad\fR, i.e. the user listed in the
\fBinetd\fR
configuration file.
.sp
The
-\fBservice\fR
+\fIservice\fR
is a list of the service the client is authorized to execute:
\fBamdump\fR,
\fBnoop\fR,
\fBamidxtaped\fR.
\fBamdump\fR
is a shortcut for "noop selfcheck sendsize sendbackup"
-.TP
+.RE
+.PP
Kerberos
-\fBAmanda\fR
+.RS 4
+\fIAmanda\fR
may use the Kerberos authentication system. Further information is in the
-\fBdocs/KERBEROS\fRfile that comes with an
-\fBAmanda\fR
+\fBdocs/KERBEROS\fR
+file that comes with an
+\fIAmanda\fR
distribution.
.sp
For Samba access,
-\fBAmanda\fR
+\fIAmanda\fR
needs a file on the Samba server (which may or may not also be the tape server) named
\fI/etc/amandapass\fR
with share names, (clear text) passwords and (optional) domain names, in that order, one per line, whitespace separated. By default, the user used to connect to the PC is the same for all PC's and is compiled into
-\fBAmanda\fR. It may be changed on a host by host basis by listing it first in the password field followed by a percent sign and then the password. For instance:
+\fIAmanda\fR. It may be changed on a host by host basis by listing it first in the password field followed by a percent sign and then the password. For instance:
+.sp
+.RS 4
.nf
-
- //some-pc/home normalpw
- //another-pc/disk otheruser%otherpw
+ //some\-pc/home normalpw
+ //another\-pc/disk otheruser%otherpw
.fi
-
-
-With clear text passwords, this file should obviously be tightly protected.
-It only needs to be readable by the \fBAmanda\fR-user on the Samba server.
-
+.RE
+With clear text passwords, this file should obviously be tightly protected. It only needs to be readable by the
+\fIAmanda\fR\-user on the Samba server.
+.sp
You can find further information in the
-\fBdocs/SAMBA\fRfile that comes with an
-\fBAmanda\fR
+\fBdocs/SAMBA\fR
+file that comes with an
+\fIAmanda\fR
distribution.
+.RE
.SH "HOST & DISK EXPRESSION"
.PP
All host and disk arguments to programs are special expressions. The command applies to all disks that match your arguments. This section describes the matcher.
.PP
The matcher matches by word, each word is a glob expression, words are separated by the separator '.' for host and '/' for disk. You can anchor the expression at left with a '^'. You can anchor the expression at right with a '$'. The matcher is case insensitive for host but is case sensitive for disk. A match succeeds if all words in your expression match contiguous words in the host or disk.
+.TS
+tab(:);
+l l
+l l
+l l
+l l
+l l
+l l
+l l.
+T{
+\&.
+T}:T{
+word separator for a host
+T}
+T{
+/
+T}:T{
+word separator for a disk
+T}
+T{
+^
+T}:T{
+anchor at left
+T}
+T{
+$
+T}:T{
+anchor at right
+T}
+T{
+?
+T}:T{
+match exactly one character except the separator
+T}
+T{
+*
+T}:T{
+match zero or more characters except the separator
+T}
+T{
+**
+T}:T{
+match zero or more characters including the separator
+T}
+.TE
.sp
-.nf
-
-. word separator for a host
-/ word separator for a disk
-^ anchor at left
-$ anchor at right
-? match exactly one character except the separator
-* match zero or more characters except the separator
-** match zero or more characters including the separator
-
-.fi
.PP
Some examples:
+.TS
+tab(:);
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l
+l l l.
+T{
+EXPRESSION
+T}:T{
+WILL MATCH
+T}:T{
+WILL NOT MATCH
+T}
+T{
+\
+T}:T{
+ho.aina.org
+T}:T{
+\
+T}
+T{
+^hosta
+T}:T{
+hosta
+T}:T{
+foo.hosta.org
+T}
+T{
+sda*
+T}:T{
+/dev/sda1
+T}:T{
+\
+T}
+T{
+\
+T}:T{
+/dev/sda12
+T}:T{
+\
+T}
+T{
+/opt
+T}:T{
+opt (disk)
+T}:T{
+opt (host)
+T}
+T{
+\&.opt.
+T}:T{
+opt (host)
+T}:T{
+opt (disk)
+T}
+T{
+/
+T}:T{
+/
+T}:T{
+any other disk
+T}
+T{
+/usr
+T}:T{
+/usr
+T}:T{
+\
+T}
+T{
+\
+T}:T{
+/usr/opt
+T}:T{
+\
+T}
+T{
+/usr$
+T}:T{
+/usr
+T}:T{
+/usr/opt
+T}
+T{
+hosta
+T}:T{
+hosta
+T}:T{
+hostb
+T}
+T{
+\
+T}:T{
+hoSTA.dOMAIna.ORG
+T}:T{
+\
+T}
+T{
+\
+T}:T{
+foo.hosta.org
+T}:T{
+\
+T}
+T{
+host
+T}:T{
+host
+T}:T{
+hosta
+T}
+T{
+host?
+T}:T{
+hosta
+T}:T{
+host
+T}
+T{
+\
+T}:T{
+hostb
+T}:T{
+\
+T}
+T{
+ho*na
+T}:T{
+hoina
+T}:T{
+ho.aina.org
+T}
+T{
+ho**na
+T}:T{
+hoina
+T}:T{
+\
+T}
+.TE
.sp
-.nf
-
-EXPRESSION WILL MATCH WILL NOT MATCH
-hosta hosta hostb
- hoSTA.dOMAIna.ORG
- foo.hosta.org
-host host hosta
-host? hosta host
- hostb
-ho*na hoina ho.aina.org
-ho**na hoina
- ho.aina.org
-^hosta hosta foo.hosta.org
-sda* /dev/sda1
- /dev/sda12
-/opt/ opt (disk) opt (host)
-.opt. opt (host) opt (disk)
-/ / any other disk
-/usr /usr
- /usr/opt
-/usr$ /usr /usr/opt
-
-.fi
.SH "DATESTAMP EXPRESSION"
.PP
A
-\fBdatestamp\fR
+\fIdatestamp\fR
expression is a range expression where we only match the prefix. Leading ^ is removed. Trailing $ forces an exact match.
-20001212-14match all dates beginning with 20001212, 20001213 or 2000121420001212-4same as previous20001212-24match all dates between 20001212 and 200012242000121match all dates that start with 2000121 (20001210-20001219)2match all dates that start with 2 (20000101-29991231)2000-10match all dates between 20000101-20101231200010$match only 200010.PP
-
+.TS
+allbox tab(:);
+l l
+l l
+l l
+l l
+l l
+l l
+l l.
+T{
+20001212\-14
+T}:T{
+match all dates beginning with 20001212, 20001213 or 20001214
+T}
+T{
+20001212\-4
+T}:T{
+same as previous
+T}
+T{
+20001212\-24
+T}:T{
+match all dates between 20001212 and 20001224
+T}
+T{
+2000121
+T}:T{
+match all dates that start with 2000121 (20001210\-20001219)
+T}
+T{
+2
+T}:T{
+match all dates that start with 2 (20000101\-29991231)
+T}
+T{
+2000\-10
+T}:T{
+match all dates between 20000101\-20101231
+T}
+T{
+200010$
+T}:T{
+match only 200010
+T}
+.TE
+.sp
+.PP
.SH "CONFIGURATION OVERWRITE"
.PP
-Most command allow to overwrite any configuration parameter on the command line with the -o option.
+Most command allow to overwrite any configuration parameter on the command line with the \-o option.
.PP
--o NAME=value
+\-o NAME=value
.PP
-eg. -o runtapes=2
+eg. \-o runtapes=2
.PP
-eg. -o DUMPTYPE:no-compress:compress="server fast"
+eg. \-o DUMPTYPE:no\-compress:compress="server fast"
.PP
-eg. -o TAPETYPE:HP-DAT:length=2000m
+eg. \-o TAPETYPE:HP\-DAT:length=2000m
.PP
-eg. -o INTERFACE:local:use="2000 kbps"
+eg. \-o INTERFACE:local:use="2000 kbps"
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion, major update
+\fIAmanda\fR\-documentation: XML\-conversion, major update
.SH "SEE ALSO"
.PP
+
\fBamadmin\fR(8),
\fBamanda.conf\fR(5),
-\fBamanda-client.conf\fR(5),
+\fBamanda\-client.conf\fR(5),
\fBamcheck\fR(8),
\fBamcheckdb\fR(8),
\fBamcleanup\fR(8),
\fBamdd\fR(8),
\fBamdump\fR(8),
-\fBamfetchdump\fR(8)\fBamflush\fR(8),
+\fBamfetchdump\fR(8)
+\fBamflush\fR(8),
\fBamgetconf\fR(8),
\fBamlabel\fR(8),
\fBammt\fR(8),
\fBamtoc\fR(8),
\fBamverify\fR(8),
\fBamverifyrun\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMANDA.CONF" 5 "" "" ""
+.\" Title: amanda.conf
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMANDA.CONF" "5" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amanda.conf - Main configuration file for Amanda, the Advanced Maryland Automatic Network Disk Archiver
+amanda.conf \- Main configuration file for Amanda, the Advanced Maryland Automatic Network Disk Archiver
.SH "DESCRIPTION"
.PP
\fIamanda.conf\fR
is the main configuration file for
-\fBAmanda\fR. This manpage lists the relevant sections and parameters of this file for quick reference.
+\fIAmanda\fR. This manpage lists the relevant sections and parameters of this file for quick reference.
.PP
The file
\fB<CONFIG_DIR>/<config>/amanda.conf\fR
.SH "PARAMETERS"
.PP
There are a number of configuration parameters that control the behavior of the
-\fBAmanda\fR
+\fIAmanda\fR
programs. All have default values, so you need not specify the parameter in
\fBamanda.conf\fR
if the default is suitable.
.PP
Integer arguments may have one of the following (case insensitive) suffixes, some of which have a multiplier effect:
.SS "POSSIBLE SUFFIXES"
-.TP
+.PP
\fBb byte bytes\fR
+.RS 4
Some number of bytes.
-.TP
+.RE
+.PP
\fBbps\fR
+.RS 4
Some number of bytes per second.
-.TP
+.RE
+.PP
\fBk kb kbyte kbytes kilobyte kilobytes\fR
+.RS 4
Some number of kilobytes (bytes*1024).
-.TP
+.RE
+.PP
\fBkps kbps\fR
+.RS 4
Some number of kilobytes per second (bytes*1024).
-.TP
+.RE
+.PP
\fBm mb meg mbyte mbytes megabyte megabytes\fR
+.RS 4
Some number of megabytes (bytes*1024*1024).
-.TP
+.RE
+.PP
\fBmps mbps\fR
+.RS 4
Some number of megabytes per second (bytes*1024*1024).
-.TP
+.RE
+.PP
\fBg gb gbyte gbytes gigabyte gigabytes\fR
+.RS 4
Some number of gigabytes (bytes*1024*1024*1024).
-.TP
+.RE
+.PP
\fBtape tapes\fR
+.RS 4
Some number of tapes.
-.TP
+.RE
+.PP
\fBday days\fR
+.RS 4
Some number of days.
-.TP
+.RE
+.PP
\fBweek weeks\fR
+.RS 4
Some number of weeks (days*7).
.sp
.it 1 an-trap
\fBNote\fR
The value
\fBinf\fR
-may be used in most places where an integer is expected
-to mean an infinite amount.
-
+may be used in most places where an integer is expected to mean an infinite amount.
+.sp
Boolean arguments may have any of the values
\fBy\fR,
\fByes\fR,
to indicate a false state. If no argument is given,
\fBtrue\fR
is assumed.
+.RE
.SS "PARAMETERS"
-.TP
-\fBorg\fR \fB string\fR
+.PP
+\fBorg\fR \fI string\fR
+.RS 4
Default:
-\fBdaily\fR. A descriptive name for the configuration. This string appears in the Subject line of mail reports. Each
-\fBAmanda\fR
+\fIdaily\fR. A descriptive name for the configuration. This string appears in the Subject line of mail reports. Each
+\fIAmanda\fR
configuration should have a different string to keep mail reports distinct.
-.TP
-\fBmailto\fR \fB string\fR
+.RE
+.PP
+\fBmailto\fR \fI string\fR
+.RS 4
Default:
-\fBoperators\fR. A space separated list of recipients for mail reports.
-.TP
-\fBdumpcycle\fR \fB int\fR
+\fIoperators\fR. A space separated list of recipients for mail reports.
+.RE
+.PP
+\fBdumpcycle\fR \fI int\fR
+.RS 4
Default:
-\fB10 days\fR. The number of days in the backup cycle. Each disk will get a full backup at least this often. Setting this to zero tries to do a full backup each run.
+\fI10 days\fR. The number of days in the backup cycle. Each disk will get a full backup at least this often. Setting this to zero tries to do a full backup each run.
.sp
.it 1 an-trap
.nr an-no-space-flag 1
\fBNote\fR
This parameter may also be set in a specific
\fBdumptype\fR
-(see below).
-This value sets the default for all
-\fBdumptype\fRs
-so must appear in
+(see below). This value sets the default for all
+\fBdumptype\fRs so must appear in
\fBamanda.conf\fR
before any
-\fBdumptype\fRs
-are defined..TP
-\fBrunspercycle\fR \fB int\fR
+\fBdumptype\fRs are defined.
+.RE
+.PP
+\fBrunspercycle\fR \fI int\fR
+.RS 4
Default:
-\fBsame as dumpcycle\fR. The number of amdump runs in
+\fIsame as dumpcycle\fR. The number of amdump runs in
\fBdumpcycle\fR
days. A value of 0 means the same value as
-\fBdumpcycle\fR. A value of -1 means guess the number of runs from the
-\fBtapelist\fR
+\fBdumpcycle\fR. A value of \-1 means guess the number of runs from the
+\fItapelist\fR
file, which is the number of tapes used in the last
\fBdumpcycle\fR
days /
\fBruntapes\fR.
-.TP
-\fBtapecycle\fR \fB int\fR
+.RE
+.PP
+\fBtapecycle\fR \fI int\fR
+.RS 4
Default:
-\fB15 tapes\fR. Typically tapes are used by
-\fBAmanda\fR
+\fI15 tapes\fR. Typically tapes are used by
+\fIAmanda\fR
in an ordered rotation. The
\fBtapecycle\fR
parameter defines the size of that rotation. The number of tapes in rotation must be larger than the number of tapes required for a complete dump cycle (see the
runs per dump cycle (\fBrunspercycle\fR
parameter) times the number of tapes used per run (\fBruntapes\fR
parameter). Typically two to four times this calculated number of tapes are in rotation. While
-\fBAmanda\fR
+\fIAmanda\fR
is always willing to use a new tape in its rotation, it refuses to reuse a tape until at least '\fBtapecycle\fR
--1' number of other tapes have been used.
+\-1' number of other tapes have been used.
.sp
It is considered good administrative practice to set the
\fBtapecycle\fR
parameter slightly lower than the actual number of tapes in rotation. This allows the administrator to more easily cope with damaged or misplaced tapes or schedule adjustments that call for slight adjustments in the rotation order.
-.TP
-\fBusetimestamps\fR \fB bool\fR
+.RE
+.PP
+\fBusetimestamps\fR \fI bool\fR
+.RS 4
Default:
\fBNo\fR. By default, Amanda can only track at most one run per calendar day. When this option is enabled, however, Amanda can track as many runs as you care to make.
.sp
-\fBWARNING\fR: This option is not backward-compatible. Do not enable it if you intend to downgrade your server installation to Amanda community edition 2.5.0
-.TP
-\fBlabel_new_tapes\fR \fB string\fR
+
+\fBWARNING\fR: This option is not backward\-compatible. Do not enable it if you intend to downgrade your server installation to Amanda community edition 2.5.0
+.RE
+.PP
+\fBlabel_new_tapes\fR \fI string\fR
+.RS 4
Default: not set. When set, this directive will cause
-\fBAmanda\fR
+\fIAmanda\fR
to automatically write an
-\fBAmanda\fR
+\fIAmanda\fR
tape label to any blank tape she encounters. This option is DANGEROUS because when set,
-\fBAmanda\fR
-will ERASE any non-\fBAmanda\fR
-tapes you may have, and may also ERASE any near-failing tapes. Use with caution.
+\fIAmanda\fR
+will ERASE any non\-\fIAmanda\fR
+tapes you may have, and may also ERASE any near\-failing tapes. Use with caution.
.sp
When using this directive, specify the template for new tape labels. The template should contain some number of contiguous '%' characters, which will be replaced with a generated number. Be sure to specify enough '%' characters that you do not run out of tape labels. Example:
-label_new_tapes "DailySet1-%%%"
-.TP
-\fBdumpuser\fR \fB string\fR
+\fBlabel_new_tapes "DailySet1\-%%%"\fR
+.RE
+.PP
+\fBdumpuser\fR \fI string\fR
+.RS 4
Default:
-\fBamanda\fR. The login name
-\fBAmanda\fR
+\fIamanda\fR. The login name
+\fIAmanda\fR
uses to run the backups. The backup client hosts must allow access from the tape server host as this user via
-.rhosts
+\fB.rhosts\fR
or
-.amandahosts, depending on how the
-\fBAmanda\fR
+\fB.amandahosts\fR, depending on how the
+\fIAmanda\fR
software was built.
-.TP
+.RE
+.PP
\fBprinter\fR string
+.RS 4
Printer to use when doing tape labels. See the
-\fBlbl-templ\fR\fBtapetype\fR
+\fBlbl\-templ\fR
+\fBtapetype\fR
option.
-.TP
+.RE
+.PP
\fBtapedev\fR string
+.RS 4
Default:
-\fInull:\fR. The path name of the non-rewinding tape device. Non-rewinding tape device names often have an 'n' in the name, e.g.
+\fInull:\fR. The path name of the non\-rewinding tape device. Non\-rewinding tape device names often have an 'n' in the name, e.g.
\fI/dev/rmt/0mn\fR, however this is operating system specific and you should consult that documentation for detailed naming information.
.sp
If a tape changer is configured (see the
will run normally but all images will be thrown away. This should only be used for debugging and testing, and probably only with the
\fBrecord\fR
option set to
-\fBno\fR.
-.TP
+\fIno\fR.
+.RE
+.PP
\fBrawtapedev\fR string
+.RS 4
Default:
\fInull:\fR. The path name of the raw tape device. This is only used if
-\fBAmanda\fR
+\fIAmanda\fR
is compiled for Linux machines with floppy tapes and is needed for QIC volume table operations.
-.TP
+.RE
+.PP
\fBtpchanger\fR string
+.RS 4
Default:
-\fBnone\fR. The name of the tape changer. If a tape changer is not configured, this option is not used and should be commented out of the configuration file.
+\fInone\fR. The name of the tape changer. If a tape changer is not configured, this option is not used and should be commented out of the configuration file.
.sp
If a tape changer is configured, choose one of the changer scripts (e.g.
-\fBchg-scsi\fR) and enter that here.
-.TP
+\fBchg\-scsi\fR) and enter that here.
+.RE
+.PP
\fBchangerdev\fR string
+.RS 4
Default:
\fI/dev/null\fR. A tape changer configuration parameter. Usage depends on the particular changer defined with the
\fBtpchanger\fR
option.
-.TP
+.RE
+.PP
\fBchangerfile\fR string
+.RS 4
Default:
-\fI/usr/adm/amanda/log/changer-status\fR. A tape changer configuration parameter. Usage depends on the particular changer defined with the
+\fI/usr/adm/amanda/log/changer\-status\fR. A tape changer configuration parameter. Usage depends on the particular changer defined with the
\fBtpchanger\fR
option.
-.TP
+.RE
+.PP
\fBruntapes\fR int
+.RS 4
Default:
1. The maximum number of tapes used in a single run. If a tape changer is not configured, this option is not used and should be commented out of the configuration file.
.sp
If a tape changer is configured, this may be set larger than one to let
-\fBAmanda\fR
+\fIAmanda\fR
write to more than one tape.
.sp
Note that this is an upper bound on the number of tapes, and
-\fBAmanda\fR
+\fIAmanda\fR
may use less.
.sp
Also note that as of this release,
-\fBAmanda\fR
+\fIAmanda\fR
does not support true tape overflow. When it reaches the end of one tape, the backup image
-\fBAmanda\fR
+\fIAmanda\fR
was processing starts over again on the next tape.
-.TP
+.RE
+.PP
\fBmaxdumpsize\fR int
+.RS 4
Default:
-\fBruntapes\fR*\fBtape_length\fR. Maximum number of bytes the planner will schedule for a run.
-.TP
+\fIruntapes\fR*\fItape_length\fR. Maximum number of bytes the planner will schedule for a run.
+.RE
+.PP
\fBtaperalgo\fR [first|firstfit|largest|largestfit|smallest|last]
+.RS 4
Default:
-\fBfirst\fR. The algorithm used to choose which dump image to send to the taper.
-.RS
-.TP
+\fIfirst\fR. The algorithm used to choose which dump image to send to the taper.
+.RS 4
+.PP
\fBfirst\fR
+.RS 4
First in, first out.
-.TP
+.RE
+.PP
\fBfirstfit\fR
+.RS 4
The first dump image that will fit on the current tape.
-.TP
+.RE
+.PP
\fBlargest\fR
+.RS 4
The largest dump image.
-.TP
+.RE
+.PP
\fBlargestfit\fR
+.RS 4
The largest dump image that will fit on the current tape.
-.TP
+.RE
+.PP
\fBsmallest\fR
+.RS 4
The smallest dump image.
-.TP
+.RE
+.PP
\fBlast\fR
+.RS 4
Last in, first out.
.RE
-.TP
-\fBlabelstr\fR \fB string\fR
+.RE
+.RE
+.PP
+\fBlabelstr\fR \fI string\fR
+.RS 4
Default:
-\fB.*\fR. The tape label constraint regular expression. All tape labels generated (see
-\fBamlabel\fR(8)) and used by this configuration must match the regular expression. If multiple configurations are run from the same tape server host, it is helpful to set their labels to different strings (for example, "DAILY[0-9][0-9]*" vs. "ARCHIVE[0-9][0-9]*") to avoid overwriting each other's tapes.
-.TP
-\fBtapetype\fR \fB string\fR
+\fI.*\fR. The tape label constraint regular expression. All tape labels generated (see
+\fBamlabel\fR(8)) and used by this configuration must match the regular expression. If multiple configurations are run from the same tape server host, it is helpful to set their labels to different strings (for example, "DAILY[0\-9][0\-9]*" vs. "ARCHIVE[0\-9][0\-9]*") to avoid overwriting each other's tapes.
+.RE
+.PP
+\fBtapetype\fR \fI string\fR
+.RS 4
Default:
-\fBEXABYTE\fR. The type of tape drive associated with
+\fIEXABYTE\fR. The type of tape drive associated with
\fBtapedev\fR
or
\fBtpchanger\fR. This refers to one of the defined
First character of a
\fBtapetype\fR
string must be an alphabetic character
-.TP
+.RE
+.PP
\fBctimeout\fR int
+.RS 4
Default:
-\fB30 seconds\fR. Maximum amount of time that
+\fI30 seconds\fR. Maximum amount of time that
\fBamcheck\fR
will wait for each client host.
-.TP
+.RE
+.PP
\fBdtimeout\fR int
+.RS 4
Default:
-\fB1800 seconds\fR. Amount of idle time per disk on a given client that a
+\fI1800 seconds\fR. Amount of idle time per disk on a given client that a
\fBdumper\fR
running from within
\fBamdump\fR
will wait before it fails with a data timeout error.
-.TP
+.RE
+.PP
\fBetimeout\fR int
+.RS 4
Default:
-\fB300 seconds\fR. Amount of time per disk on a given client that the
+\fI300 seconds\fR. Amount of time per disk on a given client that the
\fBplanner\fR
step of
\fBamdump\fR
will wait to get the dump size estimates. For instance, with the default of 300 seconds and four disks on client A,
\fBplanner\fR
will wait up to 20 minutes for that machine. A negative value will be interpreted as a total amount of time to wait per client instead of per disk.
-.TP
+.RE
+.PP
\fBnetusage\fR int
+.RS 4
Default:
-\fB300 Kbps\fR. The maximum network bandwidth allocated to
-\fBAmanda\fR, in Kbytes per second. See also the
+\fI300 Kbps\fR. The maximum network bandwidth allocated to
+\fIAmanda\fR, in Kbytes per second. See also the
\fBinterface\fR
section.
-.TP
+.RE
+.PP
\fBinparallel\fR int
+.RS 4
Default:
10. The maximum number of backups that
-\fBAmanda\fR
+\fIAmanda\fR
will attempt to run in parallel.
-\fBAmanda\fR
+\fIAmanda\fR
will stay within the constraints of network bandwidth and holding disk space available, so it doesn't hurt to set this number a bit high. Some contention can occur with larger numbers of backups, but this effect is relatively small on most systems.
-.TP
+.RE
+.PP
\fBdisplayunit\fR "k|m|g|t"
+.RS 4
Default:
"k". The unit used to print many numbers, k=kilo, m=mega, g=giga, t=tera.
-.TP
+.RE
+.PP
\fBdumporder\fR string
+.RS 4
Default:
-\fBtttTTTTTTT\fR. The priority order of each dumper:
-.RS
-.TP 3
-•
+\fItttTTTTTTT\fR. The priority order of each dumper:
+.sp
+.RS 4
+.nf
s: smallest size
-.TP
-•
S: largest size
-.TP
-•
t: smallest time
-.TP
-•
T: largest time
-.TP
-•
b: smallest bandwidth
-.TP
-•
B: largest bandwidth
+.fi
+.RE
.RE
-.TP
+.PP
\fBmaxdumps\fR int
+.RS 4
Default:
1. The maximum number of backups from a single host that
-\fBAmanda\fR
+\fIAmanda\fR
will attempt to run in parallel. See also the
\fBinparallel\fR
option.
\fBamanda.conf\fR
before any
\fBdumptype\fRs are defined.
-.TP
+.RE
+.PP
\fBbumpsize\fR int
+.RS 4
Default:
-\fB10 Mbytes\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as size. If
-\fBAmanda\fR
+\fI10 Mbytes\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as size. If
+\fIAmanda\fR
determines that the next higher backup level will be this much smaller than the current level, it will do the next level. The value of this parameter is used only if the parameter
-\fBbumppercent\fR
+\fIbumppercent\fR
is set to 0.
.sp
-The global setting of this parameter can be overwritten inside of a dumptype-definition.
+The global setting of this parameter can be overwritten inside of a dumptype\-definition.
.sp
See also the options
\fBbumppercent\fR,
\fBbumpmult\fR
and
\fBbumpdays\fR.
-.TP
+.RE
+.PP
\fBbumppercent\fR int
+.RS 4
Default:
-\fB0 percent\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as percentage of the current size of the DLE (size of current level 0). If
-\fBAmanda\fR
+\fI0 percent\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as percentage of the current size of the DLE (size of current level 0). If
+\fIAmanda\fR
determines that the next higher backup level will be this much smaller than the current level, it will do the next level.
.sp
If this parameter is set to 0, the value of the parameter
-\fBbumpsize\fR
+\fIbumpsize\fR
is used to trigger bumping.
.sp
-The global setting of this parameter can be overwritten inside of a dumptype-definition.
+The global setting of this parameter can be overwritten inside of a dumptype\-definition.
.sp
See also the options
\fBbumpsize\fR,
\fBbumpmult\fR
and
\fBbumpdays\fR.
-.TP
-\fBbumpmult\fR \fB float\fR
+.RE
+.PP
+\fBbumpmult\fR \fI float\fR
+.RS 4
Default:
1.5. The bump size multiplier.
-\fBAmanda\fR
+\fIAmanda\fR
multiplies
\fBbumpsize\fR
by this factor for each level. This prevents active filesystems from bumping too much by making it harder to bump to the next level. For example, with the default
\fBbumpmult\fR
set to 2.0, the bump threshold will be 10 Mbytes for level one, 20 Mbytes for level two, 40 Mbytes for level three, and so on.
.sp
-The global setting of this parameter can be overwritten inside of a dumptype-definition.
-.TP
-\fBbumpdays\fR \fB int\fR
+The global setting of this parameter can be overwritten inside of a dumptype\-definition.
+.RE
+.PP
+\fBbumpdays\fR \fI int\fR
+.RS 4
Default:
-\fB2 days\fR. To insure redundancy in the dumps,
-\fBAmanda\fR
+\fI2 days\fR. To insure redundancy in the dumps,
+\fIAmanda\fR
keeps filesystems at the same incremental level for at least
\fBbumpdays\fR
days, even if the other bump threshold criteria are met.
.sp
-The global setting of this parameter can be overwritten inside of a dumptype-definition.
-.TP
-\fBdiskfile\fR \fB string\fR
+The global setting of this parameter can be overwritten inside of a dumptype\-definition.
+.RE
+.PP
+\fBdiskfile\fR \fI string\fR
+.RS 4
Default:
-\fBdisklist\fR. The file name for the
-\fBdisklist\fR
+\fIdisklist\fR. The file name for the
+\fIdisklist\fR
file holding client hosts, disks and other client dumping information.
-.TP
-\fBinfofile\fR \fB string\fR
+.RE
+.PP
+\fBinfofile\fR \fI string\fR
+.RS 4
Default:
\fI/usr/adm/amanda/curinfo\fR. The file or directory name for the historical information database. If
-\fBAmanda\fR
+\fIAmanda\fR
was configured to use DBM databases, this is the base file name for them. If it was configured to use text formated databases (the default), this is the base directory and within here will be a directory per client, then a directory per disk, then a text file of data.
-.TP
-\fBlogdir\fR \fB string\fR
+.RE
+.PP
+\fBlogdir\fR \fI string\fR
+.RS 4
Default:
\fI/usr/adm/amanda\fR. The directory for the
\fBamdump\fR
and
\fBlog\fR
files.
-.TP
-\fBindexdir\fR \fB string\fR
+.RE
+.PP
+\fBindexdir\fR \fI string\fR
+.RS 4
Default
\fI/usr/adm/amanda/index\fR. The directory where index files (backup image catalogues) are stored. Index files are only generated for filesystems whose
\fBdumptype\fR
has the
\fBindex\fR
option enabled.
-.TP
-\fBtapelist\fR \fB string\fR
+.RE
+.PP
+\fBtapelist\fR \fI string\fR
+.RS 4
Default:
-\fBtapelist\fR. The file name for the active
-\fBtapelist\fR
+\fItapelist\fR. The file name for the active
+\fItapelist\fR
file.
-\fBAmanda\fR
+\fIAmanda\fR
maintains this file with information about the active set of tapes.
-.TP
-\fBtapebufs\fR \fB int\fR
+.RE
+.PP
+\fBtapebufs\fR \fI int\fR
+.RS 4
Default:
20. The number of buffers used by the
\fBtaper\fR
and
\fBamflush\fR
to hold data as it is read from the network or disk before it is written to tape. Each buffer is a little larger than 32 KBytes and is held in a shared memory region.
-.TP
-\fBreserve\fR \fB number\fR
+.RE
+.PP
+\fBreserve\fR \fI number\fR
+.RS 4
Default:
-100. The part of holding-disk space that should be reserved for incremental backups if no tape is available, expressed as a percentage of the available holding-disk space (0-100). By default, when there is no tape to write to, degraded mode (incremental) backups will be performed to the holding disk. If full backups should also be allowed in this case, the amount of holding disk space reserved for incrementals should be lowered.
-.TP
-\fBautoflush\fR \fB bool\fR
+100. The part of holding\-disk space that should be reserved for incremental backups if no tape is available, expressed as a percentage of the available holding\-disk space (0\-100). By default, when there is no tape to write to, degraded mode (incremental) backups will be performed to the holding disk. If full backups should also be allowed in this case, the amount of holding disk space reserved for incrementals should be lowered.
+.RE
+.PP
+\fBautoflush\fR \fI bool\fR
+.RS 4
Default:
-\fBoff\fR. Whether an amdump run will flush the dumps from holding disk to tape.
-.TP
-\fBamrecover_do_fsf\fR \fB bool\fR
+\fIoff\fR. Whether an amdump run will flush the dumps from holding disk to tape.
+.RE
+.PP
+\fBamrecover_do_fsf\fR \fI bool\fR
+.RS 4
Default:
-\fBon\fR. Amrecover will call amrestore with the -f flag for faster positioning of the tape.
-.TP
-\fBamrecover_check_label\fR \fB bool\fR
+\fIon\fR. Amrecover will call amrestore with the \-f flag for faster positioning of the tape.
+.RE
+.PP
+\fBamrecover_check_label\fR \fI bool\fR
+.RS 4
Default:
-\fBon\fR. Amrecover will call amrestore with the -l flag to check the label.
-.TP
-\fBamrecover_changer\fR \fB string\fR
+\fIon\fR. Amrecover will call amrestore with the \-l flag to check the label.
+.RE
+.PP
+\fBamrecover_changer\fR \fI string\fR
+.RS 4
Default: ''. Amrecover will use the changer if you use 'settape <string>' and that string is the same as the amrecover_changer setting.
-.TP
-\fBcolumnspec\fR \fB string\fR
+.RE
+.PP
+\fBcolumnspec\fR \fI string\fR
+.RS 4
Defines the width of columns
\fBamreport\fR
should use.
-\fBString\fR
+\fIString\fR
is a comma (',') separated list of triples. Each triple consists of three parts which are separated by a equal sign ('=') and a colon (':') (see the example). These three parts specify:
-.RS
-.TP 3
-•
-the name of the column, which may be:
-.RS
-.TP 3
-•
-Compress (compression ratio)
-.TP
-•
-Disk (client disk name)
-.TP
-•
-DumpRate (dump rate in KBytes/sec)
-.TP
-•
-DumpTime (total dump time in hours:minutes)
-.TP
-•
-HostName (client host name)
-.TP
-•
-Level (dump level)
-.TP
-•
-OrigKB (original image size in KBytes)
-.TP
-•
-OutKB (output image size in KBytes)
-.TP
-•
-TapeRate (tape writing rate in KBytes/sec)
-.TP
-•
-TapeTime (total tape time in hours:minutes)
-.RE
-.TP
-•
-the amount of space to display before the column (used to get whitespace between columns).
-.TP
-•
-the width of the column itself. If set to a negative value, the width will be calculated on demand to fit the largest entry in this column.
-.RE
-.IP
+.RS 4
+\h'-04' 1.\h'+02'the name of the column, which may be:
+.sp
+.RS 4
+.nf
+ Compress (compression ratio)
+ Disk (client disk name)
+ DumpRate (dump rate in KBytes/sec)
+ DumpTime (total dump time in hours:minutes)
+ HostName (client host name)
+ Level (dump level)
+ OrigKB (original image size in KBytes)
+ OutKB (output image size in KBytes)
+ TapeRate (tape writing rate in KBytes/sec)
+ TapeTime (total tape time in hours:minutes)
+
+.fi
+.RE
+.RE
+.RS 4
+\h'-04' 2.\h'+02'the amount of space to display before the column (used to get whitespace between columns).
+.sp
+.RE
+.RS 4
+\h'-04' 3.\h'+02'the width of the column itself. If set to a negative value, the width will be calculated on demand to fit the largest entry in this column.
+.RE
+.IP "" 4
Here is an example:
+.sp
+.RS 4
.nf
-
columnspec "Disk=1:18,HostName=0:10,OutKB=1:7"
-
.fi
-
-The above will display the disk information in 18 characters
-and put one space before it. The hostname column will be 10 characters wide with
-no space to the left. The output KBytes column is seven characters wide
-with one space before it.
- .TP
-\fBincludefile\fR \fB string\fR
-Default:
-\fBnone\fR. The name of an
-\fBAmanda\fR
+.RE
+.sp
+The above will display the disk information in 18 characters and put one space before it. The hostname column will be 10 characters wide with no space to the left. The output KBytes column is seven characters wide with one space before it.
+.RE
+.PP
+\fBincludefile\fR \fI string\fR
+.RS 4
+Default:
+\fInone\fR. The name of an
+\fIAmanda\fR
configuration file to include within the current file. Useful for sharing dumptypes, tapetypes and interface definitions among several configurations.
+.RE
.SH "HOLDINGDISK SECTION"
.PP
The
\fBamanda.conf\fR
file may define one or more holding disks used as buffers to hold backup images before they are written to tape. The syntax is:
+.sp
+.RS 4
.nf
-
-holdingdisk \fBname\fR {
- \fBholdingdisk-option\fR \fBholdingdisk-value\fR
+holdingdisk \fIname\fR {
+ \fIholdingdisk\-option\fR \fIholdingdisk\-value\fR
...
}
.fi
+.RE
.PP
-\fBName\fR
+\fIName\fR
is a logical name for this holding disk.
.PP
The options and values are:
-.TP
-\fBcomment\fR \fB string\fR
+.PP
+\fBcomment\fR \fI string\fR
+.RS 4
Default:
-\fBnone\fR. A comment string describing this holding disk.
-.TP
-\fBdirectory\fR \fB disk\fR
+\fInone\fR. A comment string describing this holding disk.
+.RE
+.PP
+\fBdirectory\fR \fI disk\fR
+.RS 4
Default:
\fI/dumps/amanda\fR. The path to this holding area.
-.TP
-\fBuse\fR \fB int\fR
-
+.RE
+.PP
+\fBuse\fR \fI int\fR
+.RS 4
Default:
-\fB0 Gb\fR.
-Amount of space that can be used in this holding disk area.
-If the value is zero, all available space on the file system is used.
-If the value is negative, \fBAmanda\fR will use all available space minus that value.
- .TP
-\fBchunksize\fR \fB int\fR
-
+\fI0 Gb\fR. Amount of space that can be used in this holding disk area. If the value is zero, all available space on the file system is used. If the value is negative,
+\fIAmanda\fR
+will use all available space minus that value.
+.RE
+.PP
+\fBchunksize\fR \fI int\fR
+.RS 4
Default:
-\fB1 Gb\fR.
-Holding disk chunk size. Dumps larger than the specified size will be stored in multiple
-holding disk files. The size of each chunk will not exceed the specified value.
-However, even though dump images are split in the holding disk, they are concatenated as
-they are written to tape, so each dump image still corresponds to a single continuous
-tape section.
-
-If 0 is specified, \fBAmanda\fR will create holding disk chunks as large as
-((INT_MAX/1024)-64) Kbytes.
-
-Each holding disk chunk includes a 32 Kbyte header, so the minimum
-chunk size is 64 Kbytes (but that would be really silly).
-
-Operating systems that are limited to a maximum file size of 2 Gbytes
-actually cannot handle files that large.
-They must be at least one byte less than 2 Gbytes.
-Since \fBAmanda\fR works with 32 Kbyte blocks, and
-to handle the final read at the end of the chunk, the chunk size
-should be at least 64 Kbytes (2 * 32 Kbytes) smaller than the maximum
-file size, e.g. 2047 Mbytes.
- .SH "DUMPTYPE SECTION"
+\fI1 Gb\fR. Holding disk chunk size. Dumps larger than the specified size will be stored in multiple holding disk files. The size of each chunk will not exceed the specified value. However, even though dump images are split in the holding disk, they are concatenated as they are written to tape, so each dump image still corresponds to a single continuous tape section.
+.sp
+If 0 is specified,
+\fIAmanda\fR
+will create holding disk chunks as large as ((INT_MAX/1024)\-64) Kbytes.
+.sp
+Each holding disk chunk includes a 32 Kbyte header, so the minimum chunk size is 64 Kbytes (but that would be really silly).
+.sp
+Operating systems that are limited to a maximum file size of 2 Gbytes actually cannot handle files that large. They must be at least one byte less than 2 Gbytes. Since
+\fIAmanda\fR
+works with 32 Kbyte blocks, and to handle the final read at the end of the chunk, the chunk size should be at least 64 Kbytes (2 * 32 Kbytes) smaller than the maximum file size, e.g. 2047 Mbytes.
+.RE
+.SH "DUMPTYPE SECTION"
.PP
The
\fIamanda.conf\fR
A set of backup options are entered in a
\fBdumptype\fR
section, which looks like this:
+.sp
+.RS 4
.nf
-
-define dumptype \fBname\fR {
- \fBdumptype-option\fR \fBdumptype-value\fR
+define dumptype \fIname\fR {
+ \fIdumptype\-option\fR \fIdumptype\-value\fR
...
}
.fi
+.RE
.PP
-\fBName\fR
+\fIName\fR
is the name of this set of backup options. It is referenced from the
\fIdisklist\fR
file.
\fBdumptype\fRs are defined.
.PP
The dumptype options and values are:
-.TP
-\fBauth\fR \fB string\fR
+.PP
+\fBauth\fR \fI string\fR
+.RS 4
Default:
-\fBbsd\fR. Type of authorization to perform between tape server and backup client hosts.
+\fIbsd\fR. Type of authorization to perform between tape server and backup client hosts.
.sp
\fBbsd\fR, bsd authorization with udp initial connection and one tcp connection by data stream.
.sp
\fBbsdudp\fR, like bsd, but will use only one tcp connection for all data stream.
.sp
\fBkrb4\fR
-to use Kerberos-IV authorization.
+to use Kerberos\-IV authorization.
.sp
\fBkrb5\fR
-to use Kerberos-V authorization.
+to use Kerberos\-V authorization.
.sp
\fBrsh\fR
to use rsh authorization.
.sp
\fBssh\fR
to use OpenSSH authorization.
-.TP
-\fBamandad_path\fR \fB string\fR
+.RE
+.PP
+\fBamandad_path\fR \fI string\fR
+.RS 4
Default:
-\fB$libexec/amandad\fR. Specify the amandad path of the client, only use with rsh/ssh authentification.
-.TP
-\fBclient_username\fR \fB string\fR
+\fI$libexec/amandad\fR. Specify the amandad path of the client, only use with rsh/ssh authentification.
+.RE
+.PP
+\fBclient_username\fR \fI string\fR
+.RS 4
Default:
-\fBCLIENT_LOGIN\fR. Specify the username to connect on the client, only use with rsh/ssh authentification.
-.TP
+\fICLIENT_LOGIN\fR. Specify the username to connect on the client, only use with rsh/ssh authentification.
+.RE
+.PP
\fBbumpsize\fR int
+.RS 4
Default:
-\fB10 Mbytes\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as size. If
-\fBAmanda\fR
+\fI10 Mbytes\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as size. If
+\fIAmanda\fR
determines that the next higher backup level will be this much smaller than the current level, it will do the next level. The value of this parameter is used only if the parameter
-\fBbumppercent\fR
+\fIbumppercent\fR
is set to 0.
.sp
See also the options
\fBbumpmult\fR
and
\fBbumpdays\fR.
-.TP
+.RE
+.PP
\fBbumppercent\fR int
+.RS 4
Default:
-\fB0 percent\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as percentage of the current size of the DLE (size of current level 0). If
-\fBAmanda\fR
+\fI0 percent\fR. The minimum savings required to trigger an automatic bump from one incremental level to the next, expressed as percentage of the current size of the DLE (size of current level 0). If
+\fIAmanda\fR
determines that the next higher backup level will be this much smaller than the current level, it will do the next level.
.sp
If this parameter is set to 0, the value of the parameter
-\fBbumpsize\fR
+\fIbumpsize\fR
is used to trigger bumping.
.sp
See also the options
\fBbumpmult\fR
and
\fBbumpdays\fR.
-.TP
-\fBbumpmult\fR \fB float\fR
+.RE
+.PP
+\fBbumpmult\fR \fI float\fR
+.RS 4
Default:
1.5. The bump size multiplier.
-\fBAmanda\fR
+\fIAmanda\fR
multiplies
\fBbumpsize\fR
by this factor for each level. This prevents active filesystems from bumping too much by making it harder to bump to the next level. For example, with the default
and
\fBbumpmult\fR
set to 2.0, the bump threshold will be 10 Mbytes for level one, 20 Mbytes for level two, 40 Mbytes for level three, and so on.
-.TP
-\fBbumpdays\fR \fB int\fR
+.RE
+.PP
+\fBbumpdays\fR \fI int\fR
+.RS 4
Default:
-\fB2 days\fR. To insure redundancy in the dumps,
-\fBAmanda\fR
+\fI2 days\fR. To insure redundancy in the dumps,
+\fIAmanda\fR
keeps filesystems at the same incremental level for at least
\fBbumpdays\fR
days, even if the other bump threshold criteria are met.
-.TP
-\fBcomment\fR \fB string\fR
+.RE
+.PP
+\fBcomment\fR \fI string\fR
+.RS 4
Default:
-\fBnone\fR. A comment string describing this set of backup options.
-.TP
-\fBcomprate\fR \fBfloat\fR [, \fBfloat\fR ]
+\fInone\fR. A comment string describing this set of backup options.
+.RE
+.PP
+\fBcomprate\fR \fIfloat\fR [, \fIfloat\fR ]
+.RS 4
Default:
0.50,
0.50. The expected full and incremental compression factor for dumps. It is only used if
-\fBAmanda\fR
+\fIAmanda\fR
does not have any history information on compression rates for a filesystem, so should not usually need to be set. However, it may be useful for the first time a very large filesystem that compresses very little is backed up.
-.TP
-\fBcompress [client|server]\fR \fB string\fR
+.RE
+.PP
+\fBcompress [client|server]\fR \fI string\fR
+.RS 4
Default:
-\fBclient fast\fR. If
-\fBAmanda\fR
+\fIclient fast\fR. If
+\fIAmanda\fR
does compression of the backup images, it can do so either on the backup client host before it crosses the network or on the tape server host as it goes from the network into the holding disk or to tape. Which place to do compression (if at all) depends on how well the dump image usually compresses, the speed and load on the client or server, network capacity, holding disk capacity, availability of tape hardware compression, etc.
.sp
For either type of compression,
-\fBAmanda\fR
+\fIAmanda\fR
also allows the selection of three styles of compression.
\fBBest\fR
is the best compression available, often at the expense of CPU overhead.
is often not as good a compression as
\fBbest\fR, but usually less CPU overhead. Or to specify
\fBCustom\fR
-to use your own compression method. (See dumptype custom-compress in example/amanda.conf for reference)
+to use your own compression method. (See dumptype custom\-compress in example/amanda.conf for reference)
.sp
So the
\fBcompress\fR
options line may be one of:
-.RS
-.TP 3
-•
+.RS 4
+.PP
compress none
-.TP
-•
-compress [client] fast
-.TP
-•
-compress [client] best
-.TP
-•
+.RS 4
+.RE
+.PP
+compress client fast
+.RS 4
+.RE
+.PP
+compress client best
+.RS 4
+.RE
+.PP
compress client custom
+.RS 4
+Specify
+\fIclient_custom_compress\fR
+"PROG"
.sp
-Specify client_custom_compress "PROG"
-.sp
-PROG must not contain white space and it must accept -d for uncompress.
-.TP
-•
+PROG must not contain white space and it must accept \-d for uncompress.
+.RE
+.PP
compress server fast
-.TP
-•
+.RS 4
+.RE
+.PP
compress server best
-.TP
-•
+.RS 4
+.RE
+.PP
compress server custom
+.RS 4
+Specify
+\fIserver_custom_compress\fR
+"PROG"
.sp
-Specify server_custom_compress "PROG"
-.sp
-PROG must not contain white space and it must accept -d for uncompress.
+PROG must not contain white space and it must accept \-d for uncompress.
+.RE
.RE
-.IP
+.IP "" 4
Note that some tape devices do compression and this option has nothing to do with whether that is used. If hardware compression is used (usually via a particular tape device name or
\fBmt\fR
option),
-\fBAmanda\fR
+\fIAmanda\fR
(software) compression should be disabled.
-.TP
-\fBdumpcycle\fR \fB int\fR
+.RE
+.PP
+\fBdumpcycle\fR \fI int\fR
+.RS 4
Default:
-\fB10 days\fR. The number of days in the backup cycle. Each disk using this set of options will get a full backup at least this of ten. Setting this to zero tries to do a full backup each run.
-.TP
+\fI10 days\fR. The number of days in the backup cycle. Each disk using this set of options will get a full backup at least this of ten. Setting this to zero tries to do a full backup each run.
+.RE
+.PP
\fBencrypt [none|client|server]\fR
+.RS 4
Default:
-\fBnone\fR. To encrypt backup images, it can do so either on the backup client host before it crosses the network or on the tape server host as it goes from the network into the holding disk or to tape.
+\fInone\fR. To encrypt backup images, it can do so either on the backup client host before it crosses the network or on the tape server host as it goes from the network into the holding disk or to tape.
.sp
So the
\fBencrypt\fR
options line may be one of:
-.RS
-.TP 3
-•
+.RS 4
+.PP
encrypt none
-.TP
-•
+.RS 4
+.RE
+.PP
encrypt client
-.sp
+.RS 4
Specify client_encrypt "PROG"
.sp
PROG must not contain white space.
.sp
-Specify client_decrypt_option "decryption-parameter" Default: "-d"
+Specify client_decrypt_option "decryption\-parameter" Default: "\-d"
.sp
-decryption-parameter must not contain white space.
+decryption\-parameter must not contain white space.
.sp
-(See dumptype server-encrypt-fast in example/amanda.conf for reference)
-.TP
-•
+(See dumptype server\-encrypt\-fast in example/amanda.conf for reference)
+.RE
+.PP
encrypt server
-.sp
+.RS 4
Specify server_encrypt "PROG"
.sp
PROG must not contain white space.
.sp
-Specify server_decrypt_option "decryption-parameter" Default: "-d"
+Specify server_decrypt_option "decryption\-parameter" Default: "\-d"
.sp
-decryption-parameter must not contain white space.
+decryption\-parameter must not contain white space.
.sp
-(See dumptype client-encrypt-nocomp in example/amanda.conf for reference)
+(See dumptype client\-encrypt\-nocomp in example/amanda.conf for reference)
.RE
-.PP
-Note that current logic assumes compression then encryption during backup(thus decrypt then uncompress during restore). So specifying client-encryption AND server-compression is not supported.
-\fBamcrypt\fR
+.RE
+.IP "" 4
+Note that current logic assumes compression then encryption during backup(thus decrypt then uncompress during restore). So specifying client\-encryption AND server\-compression is not supported.
+\fIamcrypt\fR
which is a wrapper of
-\fBaespipe\fR
+\fIaespipe\fR
is provided as a reference symmetric encryption program.
-.TP
-\fBestimate\fR \fBclient|calcsize|server\fR
+.RE
+.PP
+\fBestimate\fR \fIclient|calcsize|server\fR
+.RS 4
Default:
-\fBclient\fR. Determine the way
-\fBAmanda\fR
+\fIclient\fR. Determine the way
+\fIAmanda\fR
does it's estimate.
-.RS
-.TP 3
-•
-client:
-.sp
+.RS 4
+.PP
+client
+.RS 4
Use the same program as the dumping program, this is the most accurate way to do estimates, but it can take a long time.
-.TP
-•
-calcsize:
-.sp
+.RE
+.PP
+calcsize
+.RS 4
Use a faster program to do estimates, but the result is less accurate.
-.TP
-•
-server:
-.sp
+.RE
+.PP
+server
+.RS 4
Use only statistics from the previous run to give an estimate, it takes only a few seconds but the result is not accurate if your disk usage changes from day to day.
.RE
-.TP
-\fBexclude\fR [ \fBlist|file\fR ][[optional][ \fBappend\fR ][ \fB string\fR ]+]
+.RE
+.RE
+.PP
+\fBexclude\fR [ list|file ][[optional][ append ][ \fIstring\fR ]+]
+.RS 4
Default:
-\fBfile\fR. There are two exclude lists,
+\fIfile\fR. There are two exclude lists,
\fBexclude file\fR
and
\fBexclude list.\fR
With
\fBexclude file\fR
, the
-\fBstring\fR
+\fIstring\fR
is a
-\fBGNU-tar\fR
+\fBGNU\-tar\fR
exclude expression. With
\fBexclude list\fR
, the
-\fBstring\fR
+\fIstring\fR
is a file name on the client containing
-\fBGNU-tar\fR
+\fBGNU\-tar\fR
exclude expressions. The path to the specified exclude list file, if present (see description of 'optional' below), must be readable by the
-\fBAmanda\fR
+\fIAmanda\fR
user.
.sp
All exclude expressions are concatenated in one file and passed to
-\fBGNU-tar\fR
+\fBGNU\-tar\fR
as an
-\fB--exclude-from\fR
+\fB\-\-exclude\-from\fR
argument.
.sp
Exclude expressions must always be specified as relative to the head directory of the DLE.
With the
\fBappend\fR
keyword, the
-\fBstring\fR
+\fIstring\fR
is appended to the current list, without it, the
-\fBstring\fR
+\fIstring\fR
overwrites the list.
.sp
If
.sp
For
\fBexclude list\fR, if the file name is relative, the disk name being backed up is prepended. So if this is entered:
+.sp
+.RS 4
.nf
-
exclude list ".amanda.excludes"
.fi
+.RE
the actual file used would be
\fI/var/.amanda.excludes\fR
for a backup of
\fI/usr/local/.amanda.excludes\fR
for a backup of
\fI/usr/local\fR, and so on.
-.TP
-\fBholdingdisk\fR [ \fBnever|auto|required]\fR ]
+.RE
+.PP
+\fBholdingdisk\fR [ never|auto|required ]
+.RS 4
Default:
-\fBauto\fR. Whether a holding disk should be used for these backups or whether they should go directly to tape. If the holding disk is a portion of another file system that
-\fBAmanda\fR
+\fIauto\fR. Whether a holding disk should be used for these backups or whether they should go directly to tape. If the holding disk is a portion of another file system that
+\fIAmanda\fR
is backing up, that file system should refer to a dumptype with
\fBholdingdisk\fR
set to
-\fBnever\fR
+\fInever\fR
to avoid backing up the holding disk into itself.
-.RS
-.TP
+.RS 4
+.PP
\fBnever\fR|no|false|off
+.RS 4
Never use a holdingdisk, the dump will always go directly to tape. There will be no dump if you have a tape error.
-.TP
+.RE
+.PP
\fBauto\fR|yes|true|on
+.RS 4
Use the holding disk, unless there is a problem with the holding disk, the dump won't fit there or the medium doesn't require spooling (e.g., VFS device)
-.TP
+.RE
+.PP
\fBrequired\fR
+.RS 4
Always dump to holdingdisk, never directly to tape. There will be no dump if it doesn't fit on holdingdisk
.RE
-.TP
-\fBignore\fR \fB boolean\fR
+.RE
+.RE
+.PP
+\fBignore\fR \fI boolean\fR
+.RS 4
Default:
-\fBno\fR. Whether disks associated with this backup type should be backed up or not. This option is useful when the
-\fBdisklist\fR
+\fIno\fR. Whether disks associated with this backup type should be backed up or not. This option is useful when the
+\fIdisklist\fR
file is shared among several configurations, some of which should not back up all the listed file systems.
-.TP
-\fBinclude\fR [ \fBlist|file\fR ][[optional][ \fBappend\fR ][ \fB string\fR ]+]
+.RE
+.PP
+\fBinclude\fR [ list|file ][[optional][ append ][ \fIstring\fR ]+]
+.RS 4
Default:
-\fBfile\fR
+\fIfile\fR
".". There are two include lists,
\fBinclude file\fR
and
With
\fBinclude file\fR
, the
-\fBstring\fR
+\fIstring\fR
is a glob expression. With
\fBinclude list\fR
, the
-\fBstring\fR
+\fIstring\fR
is a file name on the client containing glob expressions.
.sp
All include expressions are expanded by
-\fBAmanda\fR, concatenated in one file and passed to
-\fBGNU-tar\fR
+\fIAmanda\fR, concatenated in one file and passed to
+\fBGNU\-tar\fR
as a
-\fB--files-from\fR
+\fB\-\-files\-from\fR
argument. They must start with "./" and contain no other "/".
.sp
Include expressions must always be specified as relative to the head directory of the DLE.
.nr an-break-flag 1
.br
\fBNote\fR
-For globbing to work at all, even the limited single level,
-the top level directory of the DLE must be readable by the \fBAmanda\fR user.With the
+For globbing to work at all, even the limited single level, the top level directory of the DLE must be readable by the
+\fIAmanda\fR
+user.
+
+With the
\fBappend\fR
keyword, the
-\fBstring\fR
+\fIstring\fR
is appended to the current list, without it, the
-\fBstring\fR
+\fIstring\fR
overwrites the list.
.sp
If
.sp
For
\fBinclude list\fR, If the file name is relative, the disk name being backed up is prepended.
-.TP
-\fBindex\fR \fB boolean\fR
+.RE
+.PP
+\fBindex\fR \fI boolean\fR
+.RS 4
Default:
-\fBno\fR. Whether an index (catalogue) of the backup should be generated and saved in
+\fIno\fR. Whether an index (catalogue) of the backup should be generated and saved in
\fBindexdir\fR. These catalogues are used by the
\fBamrecover\fR
utility.
-.TP
-\fBkencrypt\fR \fB boolean\fR
+.RE
+.PP
+\fBkencrypt\fR \fI boolean\fR
+.RS 4
Default:
-\fBno\fR. Whether the backup image should be encrypted by Kerberos as it is sent across the network from the backup client host to the tape server host.
-.TP
-\fBmaxdumps\fR \fB int\fR
+\fIno\fR. Whether the backup image should be encrypted by Kerberos as it is sent across the network from the backup client host to the tape server host.
+.RE
+.PP
+\fBmaxdumps\fR \fI int\fR
+.RS 4
Default:
1. The maximum number of backups from a single host that
-\fBAmanda\fR
+\fIAmanda\fR
will attempt to run in parallel. See also the main section parameter
\fBinparallel\fR.
-.TP
-\fBmaxpromoteday\fR \fB int\fR
+.RE
+.PP
+\fBmaxpromoteday\fR \fI int\fR
+.RS 4
Default:
10000. The maximum number of day for a promotion, set it 0 if you don't want promotion, set it to 1 or 2 if your disks get overpromoted.
-.TP
-\fBpriority\fR \fB string\fR
+.RE
+.PP
+\fBpriority\fR \fI string\fR
+.RS 4
Default:
-\fBmedium\fR. When there is no tape to write to,
-\fBAmanda\fR
+\fImedium\fR. When there is no tape to write to,
+\fIAmanda\fR
will do incremental backups in priority order to the holding disk. The priority may be high (2), medium (1), low (0) or a number of your choice.
-.TP
-\fBprogram\fR \fB string\fR
+.RE
+.PP
+\fBprogram\fR \fI string\fR
+.RS 4
Default:
-\fBDUMP\fR. The type of backup to perform. Valid values are
+\fIDUMP\fR. The type of backup to perform. Valid values are
\fBDUMP\fR
for the native operating system backup program, and
\fBGNUTAR\fR
to use
-\fBGNU-tar\fR
+\fBGNU\-tar\fR
or to do PC backups using Samba.
-.TP
-\fBrecord\fR \fB boolean\fR
+.RE
+.PP
+\fBrecord\fR \fI boolean\fR
+.RS 4
Default:
-\fByes\fR. Whether to ask the backup program to update its database (e.g.
+\fIyes\fR. Whether to ask the backup program to update its database (e.g.
\fI/etc/dumpdates\fR
for DUMP or
-\fI/usr/local/var/amanda/gnutar-lists\fR
+\fI/usr/local/var/amanda/gnutar\-lists\fR
for GNUTAR) of time stamps. This is normally enabled for daily backups and turned off for periodic archival runs.
-.TP
-\fBskip-full\fR \fB boolean\fR
+.RE
+.PP
+\fBskip\-full\fR \fI boolean\fR
+.RS 4
Default:
-\fBno\fR. If
-\fBtrue\fR
+\fIno\fR. If
+\fItrue\fR
and
\fBplanner\fR
-has scheduled a full backup, these disks will be skipped, and full backups should be run off-line on these days. It was reported that
-\fBAmanda\fR
+has scheduled a full backup, these disks will be skipped, and full backups should be run off\-line on these days. It was reported that
+\fIAmanda\fR
only schedules level 1 incrementals in this configuration; this is probably a bug.
-.TP
-\fBskip-incr\fR \fB boolean\fR
+.RE
+.PP
+\fBskip\-incr\fR \fI boolean\fR
+.RS 4
Default:
-\fBno\fR. If
-\fBtrue\fR
+\fIno\fR. If
+\fItrue\fR
and
\fBplanner\fR
has scheduled an incremental backup, these disks will be skipped.
-.TP
-\fBstarttime\fR \fB int\fR
+.RE
+.PP
+\fBstarttime\fR \fI int\fR
+.RS 4
Default:
-\fBnone\fR. Backups will not start until after this time of day. The value should be hh*100+mm, e.g. 6:30PM (18:30) would be entered as
+\fInone\fR. Backups will not start until after this time of day. The value should be hh*100+mm, e.g. 6:30PM (18:30) would be entered as
1830.
-.TP
-\fBstrategy\fR \fB string\fR
+.RE
+.PP
+\fBstrategy\fR \fI string\fR
+.RS 4
Default:
-\fBstandard\fR. Strategy to use when planning what level of backup to run next. Values are:
-.RS
-.TP
+\fIstandard\fR. Strategy to use when planning what level of backup to run next. Values are:
+.RS 4
+.PP
\fBstandard\fR
+.RS 4
The standard
-\fBAmanda\fR
+\fIAmanda\fR
schedule.
-.TP
+.RE
+.PP
\fBnofull\fR
+.RS 4
Never do full backups, only level 1 incrementals.
-.TP
+.RE
+.PP
\fBnoinc\fR
+.RS 4
Never do incremental backups, only full dumps.
-.TP
+.RE
+.PP
\fBskip\fR
+.RS 4
Never do backups (useful when sharing the
-\fBdisklist\fR
+\fIdisklist\fR
file).
-.TP
+.RE
+.PP
\fBincronly\fR
+.RS 4
Only do incremental dumps.
\fBamadmin force\fR
should be used to tell
-\fBAmanda\fR
-that a full dump has been performed off-line, so that it resets to level 1. It is similar to skip-full, but with incronly full dumps may be scheduled manually. Unfortunately, it appears that
-\fBAmanda\fR
+\fIAmanda\fR
+that a full dump has been performed off\-line, so that it resets to level 1. It is similar to skip\-full, but with incronly full dumps may be scheduled manually. Unfortunately, it appears that
+\fIAmanda\fR
will perform full backups with this configuration, which is probably a bug.
.RE
-.TP
-\fBtape_splitsize\fR \fB int\fR
+.RE
+.RE
+.PP
+\fBtape_splitsize\fR \fI int\fR
+.RS 4
Default:
-\fBnone\fR. Split dump file on tape into pieces of a specified size. This allows dumps to be spread across multiple tapes, and can potentially make more efficient use of tape space. Note that if this value is too large (more than half the size of the average dump being split), substantial tape space can be wasted. If too small, large dumps will be split into innumerable tiny dumpfiles, adding to restoration complexity. A good rule of thumb, usually, is 1/10 of the size of your tape.
-.TP
-\fBsplit_diskbuffer\fR \fB string\fR
+\fInone\fR. Split dump file on tape into pieces of a specified size. This allows dumps to be spread across multiple tapes, and can potentially make more efficient use of tape space. Note that if this value is too large (more than half the size of the average dump being split), substantial tape space can be wasted. If too small, large dumps will be split into innumerable tiny dumpfiles, adding to restoration complexity. A good rule of thumb, usually, is 1/10 of the size of your tape.
+.RE
+.PP
+\fBsplit_diskbuffer\fR \fI string\fR
+.RS 4
Default:
-\fBnone\fR. When dumping a split dump in PORT-WRITE mode (usually meaning "no holding disk"), buffer the split chunks to a file in the directory specified by this option.
-.TP
-\fBfallback_splitsize\fR \fB int\fR
+\fInone\fR. When dumping a split dump in PORT\-WRITE mode (usually meaning "no holding disk"), buffer the split chunks to a file in the directory specified by this option.
+.RE
+.PP
+\fBfallback_splitsize\fR \fI int\fR
+.RS 4
Default:
-\fB10M\fR. When dumping a split dump in PORT-WRITE mode, if no split_diskbuffer is specified (or if we somehow fail to use our split_diskbuffer), we must buffer split chunks in memory. This specifies the maximum size split chunks can be in this scenario, and thus the maximum amount of memory consumed for in-memory splitting. The size of this buffer can be changed from its (very conservative) default to a value reflecting the amount of memory that each taper process on the dump server may reasonably consume.
+\fI10M\fR. When dumping a split dump in PORT\-WRITE mode, if no split_diskbuffer is specified (or if we somehow fail to use our split_diskbuffer), we must buffer split chunks in memory. This specifies the maximum size split chunks can be in this scenario, and thus the maximum amount of memory consumed for in\-memory splitting. The size of this buffer can be changed from its (very conservative) default to a value reflecting the amount of memory that each taper process on the dump server may reasonably consume.
+.RE
.PP
The following
\fBdumptype\fR
entries are predefined by
-\fBAmanda\fR:
+\fIAmanda\fR:
+.sp
+.RS 4
.nf
-
-define dumptype no-compress {
+define dumptype no\-compress {
compress none
}
-define dumptype compress-fast {
+define dumptype compress\-fast {
compress client fast
}
-define dumptype compress-best {
+define dumptype compress\-best {
compress client best
}
define dumptype srvcompress {
compress server fast
}
-define dumptype bsd-auth {
+define dumptype bsd\-auth {
auth bsd
}
-define dumptype krb4-auth {
+define dumptype krb4\-auth {
auth krb4
}
-define dumptype no-record {
+define dumptype no\-record {
record no
}
-define dumptype no-hold {
+define dumptype no\-hold {
holdingdisk no
}
-define dumptype no-full {
- skip-full yes
+define dumptype no\-full {
+ skip\-full yes
}
.fi
+.RE
.PP
In addition to options in a
\fBdumptype\fR
\fBdumptype\fRs. For instance, two sections might be the same except for the
\fBrecord\fR
option:
+.sp
+.RS 4
.nf
-
define dumptype normal {
comment "Normal backup, no compression, do indexing"
- no-compress
+ no\-compress
index yes
maxdumps 2
}
record no
}
.fi
+.RE
.PP
-\fBAmanda\fR
+\fIAmanda\fR
provides a
\fBdumptype\fR
named
-\fBglobal\fR
+\fIglobal\fR
in the sample
\fBamanda.conf\fR
file that all
file may define multiple types of tape media and devices. The information is entered in a
\fBtapetype\fR
section, which looks like this in the config file:
+.sp
+.RS 4
.nf
-
-define tapetype \fBname\fR {
- \fBtapetype-option\fR \fBtapetype-value\fR
+define tapetype \fIname\fR {
+ \fItapetype\-option\fR \fItapetype\-value\fR
...
}
.fi
+.RE
.PP
-\fBName\fR
+\fIName\fR
is the name of this type of tape medium/device. It is referenced from the
\fBtapetype\fR
option in the main part of the config file.
.PP
The tapetype options and values are:
-.TP
-\fBcomment\fR \fB string\fR
+.PP
+\fBcomment\fR \fI string\fR
+.RS 4
Default:
-\fBnone\fR. A comment string describing this set of tape information.
-.TP
-\fBfilemark\fR \fB int\fR
+\fInone\fR. A comment string describing this set of tape information.
+.RE
+.PP
+\fBfilemark\fR \fI int\fR
+.RS 4
Default:
-\fB1000 bytes\fR. How large a file mark (tape mark) is, measured in bytes. If the size is only known in some linear measurement (e.g. inches), convert it to bytes using the device density.
-.TP
-\fBlength\fR \fB int\fR
+\fI1 kbytes\fR. How large a file mark (tape mark) is, measured in kbytes. If the size is only known in some linear measurement (e.g. inches), convert it to kbytes using the device density.
+.RE
+.PP
+\fBlength\fR \fI int\fR
+.RS 4
Default:
-\fB2000 kbytes\fR. How much data will fit on a tape.
+\fI2000 kbytes\fR. How much data will fit on a tape.
.sp
Note that this value is only used by
-\fBAmanda\fR
+\fIAmanda\fR
to schedule which backups will be run. Once the backups start,
-\fBAmanda\fR
+\fIAmanda\fR
will continue to write to a tape until it gets an error, regardless of what value is entered for
\fBlength\fR
(but see the section OUTPUT DRIVERS in the
\fBamanda\fR(8)
manpage for exceptions).
-.TP
-\fBblocksize\fR \fB int\fR
+.RE
+.PP
+\fBblocksize\fR \fI int\fR
+.RS 4
Default:
-\fB32\fR. How much data will be written in each tape record expressed in KiloBytes. The tape record size (= blocksize) can not be reduced below the default 32 KBytes. The parameter blocksize can only be raised if
-\fBAmanda\fR
-was compiled with the configure option --with-maxtapeblocksize=N set with "N" greater than 32 during
+\fI32 kbytes\fR. How much data will be written in each tape record expressed in KiloBytes. The tape record size (= blocksize) can not be reduced below the default 32 KBytes. The parameter blocksize can only be raised if
+\fIAmanda\fR
+was compiled with the configure option \-\-with\-maxtapeblocksize=N set with "N" greater than 32 during
\fBconfigure\fR.
-.TP
-\fBfile-pad\fR \fB boolean\fR
+.RE
+.PP
+\fBfile\-pad\fR \fI boolean\fR
+.RS 4
Default:
-\fBtrue\fR. If true, every record, including the last one in the file, will have the same length. This matches the way
-\fBAmanda\fR
+\fItrue\fR. If true, every record, including the last one in the file, will have the same length. This matches the way
+\fIAmanda\fR
wrote tapes prior to the availability of this parameter. It may also be useful on devices that only support a fixed blocksize.
.sp
Note that the last record on the tape probably includes trailing null byte padding, which will be passed back to
or the restore program. Most programs just ignore this (although possibly with a warning).
.sp
If this parameter is false, the last record in a file may be shorter than the block size. The file will contain the same amount of data the dump program generated, without trailing null byte padding. When read, the same amount of data that was written will be returned.
-.TP
-\fBspeed\fR \fB int\fR
+.RE
+.PP
+\fBspeed\fR \fI int\fR
+.RS 4
Default:
-\fB200 bps\fR. How fast the drive will accept data, in bytes per second. This parameter is NOT currently used by
-\fBAmanda\fR.
-.TP
-\fBlbl-templ\fR \fB string\fR
+\fI200 bps\fR. How fast the drive will accept data, in bytes per second. This parameter is NOT currently used by
+\fIAmanda\fR.
+.RE
+.PP
+\fBlbl\-templ\fR \fI string\fR
+.RS 4
A PostScript template file used by
\fBamreport\fR
to generate labels. Several sample files are provided with the
-\fBAmanda\fR
+\fIAmanda\fR
sources in the
-\fBexample\fR
+\fIexample\fR
directory. See the
\fBamreport\fR(8)
man page for more information.
+.RE
.PP
In addition to options, another
\fBtapetype\fR
name may be entered, which makes this
\fBtapetype\fR
inherit options from another
-\fBtapetype\fR. For instance, the only difference between a DLT4000 tape drive using Compact-III tapes and one using Compact-IV tapes is the length of the tape. So they could be entered as:
+\fBtapetype\fR. For instance, the only difference between a DLT4000 tape drive using Compact\-III tapes and one using Compact\-IV tapes is the length of the tape. So they could be entered as:
+.sp
+.RS 4
.nf
-
-define tapetype DLT4000-III {
- comment "DLT4000 tape drives with Compact-III tapes"
+define tapetype DLT4000\-III {
+ comment "DLT4000 tape drives with Compact\-III tapes"
length 12500 mbytes # 10 Gig tapes with some compression
filemark 2000 kbytes
speed 1536 kps
}
-define tapetype DLT4000-IV {
- DLT4000-III
- comment "DLT4000 tape drives with Compact-IV tapes"
+define tapetype DLT4000\-IV {
+ DLT4000\-III
+ comment "DLT4000 tape drives with Compact\-IV tapes"
length 25000 mbytes # 20 Gig tapes with some compression
}
.fi
+.RE
+.sp
.SH "INTERFACE SECTION"
.PP
The
file may define multiple types of network interfaces. The information is entered in an
\fBinterface\fR
section, which looks like this:
+.sp
+.RS 4
.nf
-
-define interface \fBname\fR {
- \fBinterface-option\fR \fBinterface-value\fR
+define interface \fIname\fR {
+ \fIinterface\-option\fR \fIinterface\-value\fR
...
}
.fi
+.RE
.PP
-\fBname\fR
+\fIname\fR
is the name of this type of network interface. It is referenced from the
-\fBdisklist\fR
+\fIdisklist\fR
file.
.PP
Note that these sections define network interface characteristics, not the actual interface that will be used. Nor do they impose limits on the bandwidth that will actually be taken up by
-\fBAmanda\fR.
-\fBAmanda\fR
+\fIAmanda\fR.
+\fIAmanda\fR
computes the estimated bandwidth each file system backup will take based on the estimated size and time, then compares that plus any other running backups with the limit as another of the criteria when deciding whether to start the backup. Once a backup starts,
-\fBAmanda\fR
+\fIAmanda\fR
will use as much of the network as it can leaving throttling up to the operating system and network hardware.
.PP
The interface options and values are:
-.TP
-\fBcomment\fR \fB string\fR
+.PP
+\fBcomment\fR \fI string\fR
+.RS 4
Default:
-\fBnone\fR. A comment string describing this set of network information.
-.TP
-\fBuse\fR \fB int\fR
+\fInone\fR. A comment string describing this set of network information.
+.RE
+.PP
+\fBuse\fR \fI int\fR
+.RS 4
Default:
-\fB300 Kbps\fR. The speed of the interface in Kbytes per second.
+\fI300 Kbps\fR. The speed of the interface in Kbytes per second.
+.RE
.PP
In addition to options, another
\fBinterface\fR
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion, major update, splitting
+\fIAmanda\fR\-documentation: XML\-conversion, major update, splitting
.SH "SEE ALSO"
.PP
+
\fBamanda\fR(8),
-\fBamanda-client.conf\fR(5),
+\fBamanda\-client.conf\fR(5),
\fBamcrypt\fR(8),
\fBaespipe\fR(1),
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMCHECK" 8 "" "" ""
+.\" Title: amcheck
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMCHECK" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amcheck - run Amanda self-checks
+amcheck \- run Amanda self\-checks
.SH "SYNOPSIS"
.HP 8
-\fBamcheck\fR [-am] [-w] [-sclt] [-M \fIaddress\fR]*
- \fIconfig\fR [\fIhost\fR [\fIdisk\fR]*]*
- [-o \fIconfigoption\fR]*
-
+\fBamcheck\fR [\-am] [\-w] [\-sclt] [\-M\ \fIaddress\fR] \fIconfig\fR [\fIhost\fR\ [\fIdisk\fR...]...] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmcheck\fR
-runs a number of self-checks on both the
-\fBAmanda\fR
+runs a number of self\-checks on both the
+\fIAmanda\fR
tape server host and the
-\fBAmanda\fR
+\fIAmanda\fR
client hosts.
.PP
On the tape server host,
run to verify the correct tape for the next run is mounted.
.PP
\fBAmcheck\fR
-can also do a self-check on all client hosts to make sure each host is running and that permissions on filesystems to be backed up are correct.
+can also do a self\-check on all client hosts to make sure each host is running and that permissions on filesystems to be backed up are correct.
.PP
You can specify many host/disk expressions, only disks that match an expression will be checked. All disks are checked if no expressions are given.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-s\fR
+.PP
+\fB\-s\fR
+.RS 4
Run the tape server local and tape checks (same as
-\fB-lt\fR).
-.TP
-\fB-c\fR
-Run the client host checks.Multiple specific clients can be checked by specifying the client name.
-.TP
-\fB-l\fR
+\fB\-lt\fR).
+.RE
+.PP
+\fB\-c\fR
+.RS 4
+Run the client host checks. Multiple specific clients can be checked by specifying the client name.
+.RE
+.PP
+\fB\-l\fR
+.RS 4
Run the local tests (e.g. permissions) on the server host.
-.TP
-\fB-t\fR
+.RE
+.PP
+\fB\-t\fR
+.RS 4
Run the tape tests on the server host.
-.TP
-\fB-w\fR
-Enables a DESTRUCTIVE check for write-protection on the tape (which would otherwise cause the subsequent
+.RE
+.PP
+\fB\-w\fR
+.RS 4
+Enables a DESTRUCTIVE check for write\-protection on the tape (which would otherwise cause the subsequent
\fBamdump\fR
-to fail). If the tape is writable, this check causes all data after the tape label to be erased. If the label_new_tapes option is enabled, this check may ERASE any non-Amanda tape in the drive or changer. The check enable the tape tests on the server host and is only made if the tape is otherwise correct.
-.TP
-\fB-m\fR
+to fail). If the tape is writable, this check causes all data after the tape label to be erased. If the label_new_tapes option is enabled, this check may ERASE any non\-Amanda tape in the drive or changer. The check enable the tape tests on the server host and is only made if the tape is otherwise correct.
+.RE
+.PP
+\fB\-m\fR
+.RS 4
Nothing is printed, but mail is sent if any errors are detected. The mail goes to the
\fBmailto\fR
address specified in the
-\fBamanda.conf\fR
+\fIamanda.conf\fR
file or the
-\fBaddress\fR
+\fIaddress\fR
value if
-\fB-M\fR
+\fB\-M\fR
is set.
-.TP
-\fB-a\fR
+.RE
+.PP
+\fB\-a\fR
+.RS 4
Like
-\fB-m\fR
+\fB\-m\fR
but the mail is always sent.
-.TP
-\fB-M\fR \fIaddress\fR
+.RE
+.PP
+\fB\-M\fR \fIaddress\fR
+.RS 4
Mail the report to
-\fBaddress\fR
+\fIaddress\fR
instead of the
\fBmailto\fR
value from
-\fBamanda.conf\fR. Implies
-\fB-m\fR.
-.TP
+\fIamanda.conf\fR. Implies
+\fB\-m\fR.
+.RE
+.PP
\fIhost\fR [\fIdisk\fR]*
+.RS 4
Specify the host and disk on which the command will work.
-.TP
-\fB-o\fR \fIconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.PP
The default is
-\fB-cs\fR.
+\fB\-cs\fR.
.SH "EXAMPLES"
.PP
In this example, both the tape server and client tests are run. The results are displayed on standard output.
+.sp
+.RS 4
.nf
-
% amcheck daily
-\fBAmanda\fR Tape Server Host Check
------------------------------
+\fIAmanda\fR Tape Server Host Check
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
/amanda2/amanda/work: 911475 KB disk space available, that's plenty.
-NOTE: skipping tape-writable test.
+NOTE: skipping tape\-writable test.
Tape VOL10 label ok.
Server check took 34.966 seconds.
-\fBAmanda\fR Backup Client Hosts Check
---------------------------------
+\fIAmanda\fR Backup Client Hosts Check
+\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-
WARNING: northstar: selfcheck request timed out. Host down?
WARNING: drinkme: selfcheck request timed out. Host down?
WARNING: scruffy: selfcheck request timed out. Host down?
Client check: 136 hosts checked in 51.945 seconds, 3 problems found.
-(brought to you by \fBAmanda\fR 2.5.0)
+(brought to you by \fIAmanda\fR 2.5.0)
.fi
+.RE
.PP
In this example, if the line
-\fBmailto csd-amanda\fR
+\fBmailto csd\-amanda\fR
is in
-\fBamanda.conf\fR, mail will be sent to
-\fBcsd-amanda\fR
+\fIamanda.conf\fR, mail will be sent to
+\fBcsd\-amanda\fR
if the server check returns an error.
+.sp
+.RS 4
.nf
-
-% amcheck -s -m daily
+% amcheck \-s \-m daily
.fi
+.RE
.SH "MESSAGES"
-.TP
-fatal slot \fBslot\fR: \fBerror message\fR
+.PP
+fatal slot \fIslot\fR: \fIerror message\fR
+.RS 4
(error) The tape changer detected some kind of fatal error while trying to load slot
-\fBslot\fR.
-.TP
-slot \fBslot\fR: \fBerror message\fR
-(warning) The tape changer detected some kind of non-fatal error (e.g. an empty slot was detected) while trying to load slot
-\fBslot\fR, or an error was detected trying to read the tape label.
-.TP
-slot \fBslot\fR: date \fBYYYYMMDD\fR label \fBlabel\fR (\fBresult\fR)
+\fIslot\fR.
+.RE
+.PP
+slot \fIslot\fR: \fIerror message\fR
+.RS 4
+(warning) The tape changer detected some kind of non\-fatal error (e.g. an empty slot was detected) while trying to load slot
+\fIslot\fR, or an error was detected trying to read the tape label.
+.RE
+.PP
+slot \fIslot\fR: date \fIYYYYMMDD\fR label \fIlabel\fR (\fIresult\fR)
+.RS 4
(info) Tape
-\fBlabel\fR
+\fIlabel\fR
in slot
-\fBslot\fR
+\fIslot\fR
was loaded and found to have been last written on
-\fBYYYYMMDD\fR. If the tape is new, the date field will be an
-\fBX\fR. The
-\fBresult\fR
+\fIYYYYMMDD\fR. If the tape is new, the date field will be an
+\fIX\fR. The
+\fIresult\fR
may be one of:
-.RS
-.TP
+.RS 4
+.PP
exact label match
+.RS 4
This is the expected tape.
-.TP
+.RE
+.PP
no match
+.RS 4
This label does not match the
\fBlabelstr\fR
pattern in
-\fBamanda.conf\fR. Tape scanning will continue.
-.TP
+\fIamanda.conf\fR. Tape scanning will continue.
+.RE
+.PP
active tape
+.RS 4
This tape is still active and cannot be overwritten. Tape scanning will continue.
-.TP
+.RE
+.PP
first labelstr match
+.RS 4
This tape is the first one that matches the
\fBlabelstr\fR
pattern in
-\fBamanda.conf\fR. Tape scanning will continue if necessary.
-.TP
+\fIamanda.conf\fR. Tape scanning will continue if necessary.
+.RE
+.PP
labelstr match
+.RS 4
This tape is the next one that matches the
\fBlabelstr\fR
pattern in
-\fBamanda.conf\fR. Tape scanning will continue.
+\fIamanda.conf\fR. Tape scanning will continue.
+.RE
.RE
-.IP
-.TP
-ERROR: cannot look up dump user \fBuser\fR
+.IP "" 4
+.RE
+.PP
+ERROR: cannot look up dump user \fIuser\fR
+.RS 4
(error) Dump user
-\fBuser\fR
+\fIuser\fR
from
-\fBamanda.conf\fR
+\fIamanda.conf\fR
could not be found in the system password information.
-.TP
-ERROR: cannot look up my own uid (\fBuid\fR)
+.RE
+.PP
+ERROR: cannot look up my own uid (\fIuid\fR)
+.RS 4
(error) User id
-\fBuid\fR
+\fIuid\fR
running
\fBamcheck\fR
could not be found in the system password information.
-.TP
-ERROR: running as user \fBrunuser\fR instead of \fBdumpuser\fR
+.RE
+.PP
+ERROR: running as user \fIrunuser\fR instead of \fIdumpuser\fR
+.RS 4
(error)
\fBAmcheck\fR
should be run as the dump user
-\fBdumpuser\fR
+\fIdumpuser\fR
from
-\fBamanda.conf\fR
+\fIamanda.conf\fR
instead of
-\fBrunuser\fR.
-.TP
-ERROR: program dir \fBdirectory\fR: not accessible
+\fIrunuser\fR.
+.RE
+.PP
+ERROR: program dir \fIdirectory\fR: not accessible
+.RS 4
(error) The directory
-\fBAmanda\fR
+\fIAmanda\fR
expects to find its auxiliary programs in,
-\fBdirectory\fR, is not accessible.
-.TP
-ERROR: program \fBprogram\fR: does not exist
+\fIdirectory\fR, is not accessible.
+.RE
+.PP
+ERROR: program \fIprogram\fR: does not exist
+.RS 4
(error) Program
-\fBprogram\fR
+\fIprogram\fR
needed on the tape server could not be found.
-.TP
-ERROR: program \fBprogram\fR: not a file
+.RE
+.PP
+ERROR: program \fIprogram\fR: not a file
+.RS 4
(error) Program
-\fBprogram\fR
+\fIprogram\fR
needed on the tape server exists but is not a file.
-.TP
-ERROR: program \fBprogram\fR: not executable
+.RE
+.PP
+ERROR: program \fIprogram\fR: not executable
+.RS 4
(error) Program
-\fBprogram\fR
+\fIprogram\fR
needed on the tape server exists but is not executable.
-.TP
-WARNING: program \fBprogram\fR: not setuid-root
+.RE
+.PP
+WARNING: program \fIprogram\fR: not setuid\-root
+.RS 4
(warning) Program
-\fBprogram\fR
+\fIprogram\fR
needed on the tape server exists but should be owned by user "root" and setuid.
-.TP
-ERROR: \fBXXX\fR dir \fBdirectory\fR: not writable
+.RE
+.PP
+ERROR: \fIXXX\fR dir \fIdirectory\fR: not writable
+.RS 4
(error) Directory
-\fBdirectory\fR
+\fIdirectory\fR
is either not writable, i.e. the dump user will not be able to create or remove files, or cannot be accessed, perhaps because a parent directory does not allow search permission. The
-\fBXXX\fR
+\fIXXX\fR
may be:
-.RS
-.TP
+.RS 4
+.PP
log
+.RS 4
for the
-\fBAmanda\fR
+\fIAmanda\fR
log directory (see
\fBlogdir\fR
in
\fBamanda.conf\fR)
-.TP
+.RE
+.PP
oldlog
+.RS 4
for the directory that holds the old log files (see
\fBlogdir\fR
in
\fBamanda.conf\fR)
-.TP
+.RE
+.PP
info
+.RS 4
for an
-\fBAmanda\fR
+\fIAmanda\fR
database information directory (see
\fBcurinfo\fR
in
\fBamanda.conf\fR) or
-.TP
+.RE
+.PP
index
+.RS 4
for an
-\fBAmanda\fR
+\fIAmanda\fR
index directory (see
\fBindexdir\fR
in
\fBamanda.conf\fR)
-.TP
+.RE
+.PP
tapelist
+.RS 4
for the
-\fBAmanda\fR
+\fIAmanda\fR
tapelist directory (see
\fBtapelist\fR
in
\fBamanda.conf\fR)
.RE
-.IP
-.TP
-NOTE: \fBXXX\fR dir \fBdirectory\fR: does not exist
+.RE
+.IP "" 4
+.RE
+.PP
+NOTE: \fIXXX\fR dir \fIdirectory\fR: does not exist
+.RS 4
(info) A database (info) or index directory does not exist or cannot be accessed. This might just mean this is a new client or disk, but if that is not the case, this should be treated as an error.
-.TP
+.RE
+.PP
NOTE: it will be created on the next run
+.RS 4
(info) This indicates the info directory listed in the previous message will be created on the next run.
-.TP
-ERROR: \fBXXX\fR dir \fBname\fR: not a directory
+.RE
+.PP
+ERROR: \fIXXX\fR dir \fIname\fR: not a directory
+.RS 4
(error)
\fBAmcheck\fR
expected
-\fBname\fR
+\fIname\fR
to be a directory, but it is something else (e.g. file).
-.TP
+.RE
+.PP
WARNING: info file \fIfile\fR: does not exist
+.RS 4
(warning) File
-\fBfile\fR
+\fIfile\fR
does not exist in the text format database. Since the parent directories do exist, the file should already have been created.
-.TP
+.RE
+.PP
ERROR: info file \fIname\fR: not a file
+.RS 4
(error)
\fBAmcheck\fR
expected
-\fBname\fR
+\fIname\fR
to be a file, but it is something else (e.g. file).
-.TP
+.RE
+.PP
ERROR: info file \fIfile\fR: not readable
+.RS 4
(error) The text format database file
-\fBfile\fR
+\fIfile\fR
is not readable.
-.TP
+.RE
+.PP
ERROR: log file \fIfile\fR: not writable
+.RS 4
(error) Log file
-\fBfile\fR
+\fIfile\fR
(file
\fBlog\fR
in
\fBlogdir\fR
from
\fBamanda.conf\fR) is either not writable, or cannot be accessed, perhaps because a parent directory does not allow search permission.
-.TP
-ERROR: tape list \fBtapelist\fR: not writable
+.RE
+.PP
+ERROR: tape list \fItapelist\fR: not writable
+.RS 4
(error)
-\fBAmanda\fR
+\fIAmanda\fR
tape list file
-\fBtapelist\fR
+\fItapelist\fR
(see
\fBtapelist\fR
in
\fBamanda.conf\fR) is not writable or was not found.
-.TP
-ERROR: tape list \fBtapelist\fR: parse error
+.RE
+.PP
+ERROR: tape list \fItapelist\fR: parse error
+.RS 4
(error)
-\fBAmanda\fR
+\fIAmanda\fR
tape list file
-\fBtapelist\fR
+\fItapelist\fR
(see
\fBtapelist\fR
in
\fBamanda.conf\fR) could not be read or parsed.
-.TP
+.RE
+.PP
WARNING: tapedev is /dev/null, dumps will be thrown away
+.RS 4
(warning) The
\fBtapedev\fR
parameter in
is set to
\fI/dev/null\fR
and
-\fBAmanda\fR
+\fIAmanda\fR
uses that when debugging to throw all the dump images away.
-.TP
+.RE
+.PP
WARNING: hold file \fIfile\fR exists
+.RS 4
(info) Hold file
-\fBfile\fR
+\fIfile\fR
exists and will cause
\fBamdump\fR
to pause at the beginning until it is removed.
-.TP
-ERROR: holding disk \fBdisk\fR: statfs: \fBerror message\fR
+.RE
+.PP
+ERROR: holding disk \fIdisk\fR: statfs: \fIerror message\fR
+.RS 4
(error) An error was returned from the
-\fBstatfs\fR
+\fIstatfs\fR
system call on holding disk
-\fBdisk\fR
+\fIdisk\fR
(maybe because it does not exist).
-.TP
-ERROR: holding disk \fBdisk\fR: not writable
+.RE
+.PP
+ERROR: holding disk \fIdisk\fR: not writable
+.RS 4
(error) Holding disk
-\fBdisk\fR, is not writable, probably because the caller does not have write permission or a parent directory does not allow search permission.
-.TP
-WARNING: holding disk \fBdisk\fR: available space unknown \fBN\fR KB requested.
+\fIdisk\fR, is not writable, probably because the caller does not have write permission or a parent directory does not allow search permission.
+.RE
+.PP
+WARNING: holding disk \fIdisk\fR: available space unknown \fIN\fR KB requested.
+.RS 4
(warning)
\fBAmcheck\fR
could not determine the amount of available space on holding disk
-\fBdisk\fR
+\fIdisk\fR
to see if there were at least
-\fBN\fR
+\fIN\fR
KBytes available.
-.TP
-WARNING: holding disk \fBdisk\fR: only \fBF\fR KB free (\fBR\fR KB requested).
+.RE
+.PP
+WARNING: holding disk \fIdisk\fR: only \fIF\fR KB free (\fIR\fR KB requested).
+.RS 4
(warning)
-\fBamanda.conf\fR
+\fIamanda.conf\fR
requested
-\fBR\fR
+\fIR\fR
KBytes of free space on holding disk
-\fBdisk\fR, but only
-\fBF\fR
+\fIdisk\fR, but only
+\fIF\fR
KBytes were available. 10 MBytes is subtracted for each backup process (see the
-\fBinparallel\fR\fBamanda.conf\fR
+\fBinparallel\fR
+\fIamanda.conf\fR
option) to allow for unexpected overruns.
.sp
.it 1 an-trap
.nr an-break-flag 1
.br
\fBNote\fR
-Even though this message is listed as a warning, it causes \fBamcheck\fR to exit with a non-zero status..TP
-Holding disk \fBdisk\fR: \fBN\fR KB disk space available, that's plenty.
+Even though this message is listed as a warning, it causes
+\fBamcheck\fR
+to exit with a non\-zero status.
+.RE
+.PP
+Holding disk \fIdisk\fR: \fIN\fR KB disk space available, that's plenty.
+.RS 4
(info) There was sufficient free space on holding disk
-\fBdisk\fR.
-.TP
-WARNING: holding disk \fBdisk\fR: only \fBF\fR KB free, using nothing
+\fIdisk\fR.
+.RE
+.PP
+WARNING: holding disk \fIdisk\fR: only \fIF\fR KB free, using nothing
+.RS 4
(warning) Holding disk
-\fBdisk\fR
+\fIdisk\fR
has
-\fBF\fR
+\fIF\fR
KBytes of free space, but that is not enough for what is requested in
-\fBamanda.conf\fR.
-.TP
-Holding disk \fBdisk\fR: \fBF\fR KB disk space available, using \fBU\fR KB
+\fIamanda.conf\fR.
+.RE
+.PP
+Holding disk \fIdisk\fR: \fIF\fR KB disk space available, using \fIU\fR KB
+.RS 4
(info) Holding disk
-\fBdisk\fR
+\fIdisk\fR
has
-\fBF\fR
+\fIF\fR
KBytes of free space and
-\fBAmanda\fR
+\fIAmanda\fR
will be using up to
-\fBU\fR
+\fIU\fR
Kbytes.
-.TP
+.RE
+.PP
WARNING: if a tape changer is not available, runtapes must be set to 1.
+.RS 4
(warning) The
-\fBruntapes\fR\fBamanda.conf\fR
+\fBruntapes\fR
+\fIamanda.conf\fR
option must be set to 1 if the
-\fBtpchanger\fR\fBamanda.conf\fR
+\fBtpchanger\fR
+\fIamanda.conf\fR
option is not set.
-.TP
-ERROR: \fBerror message\fR.
+.RE
+.PP
+ERROR: \fIerror message\fR.
+.RS 4
(error) An error was detected while initializing the tape changer.
-.TP
-ERROR: \fBtape device\fR: \fBerror message\fR.
+.RE
+.PP
+ERROR: \fItape device\fR: \fIerror message\fR.
+.RS 4
(error) An error was detected while processing the tape label.
-.TP
-ERROR: cannot overwrite active tape \fBlabel\fR.
+.RE
+.PP
+ERROR: cannot overwrite active tape \fIlabel\fR.
+.RS 4
(error) Tape
-\fBlabel\fR
+\fIlabel\fR
is still active and cannot be used.
-.TP
-ERROR: label \fBlabel\fR doesn't match labelstr \fBpattern\fR .
+.RE
+.PP
+ERROR: label \fIlabel\fR doesn't match labelstr \fIpattern\fR .
+.RS 4
(error) The label on tape
-\fBlabel\fR
+\fIlabel\fR
does not match the
-\fBlabelstr\fR\fBamanda.conf\fR
+\fBlabelstr\fR
+\fIamanda.conf\fR
option.
-.TP
+.RE
+.PP
(expecting a new tape)
+.RS 4
(info) The tape is not OK and a new tape was expected.
-.TP
-(expecting tape \fBlabel\fR or a new tape)
+.RE
+.PP
+(expecting tape \fIlabel\fR or a new tape)
+.RS 4
(info) The tape is not OK and either tape
-\fBlabel\fR
+\fIlabel\fR
or a new tape was expected.
-.TP
-ERROR: tape \fBlabel\fR label ok, but is not writable.
+.RE
+.PP
+ERROR: tape \fIlabel\fR label ok, but is not writable.
+.RS 4
(error) Tape
-\fBlabel\fR
+\fIlabel\fR
is OK, but the write enable test failed.
-.TP
-Tape \fBlabel\fR is writable.
+.RE
+.PP
+Tape \fIlabel\fR is writable.
+.RS 4
(info) Tape
-\fBlabel\fR
+\fIlabel\fR
is OK and the write enable test succeeded.
-.TP
-NOTE: skipping tape-writable test.
+.RE
+.PP
+NOTE: skipping tape\-writable test.
+.RS 4
(info) The tape write test (see the
-\fB-w\fR
+\fB\-w\fR
option) was not enabled.
-.TP
+.RE
+.PP
WARNING: skipping tape test because amdump or amflush seem to be running, WARNING: if they are not, you must run amcleanup
+.RS 4
(warning) It looked to
\fBamcheck\fR
like either
\fBamcleanup\fR
to clear up a previous failure. Otherwise, you need to wait until they complete before running
\fBamcheck\fR.
-.TP
+.RE
+.PP
NOTE: skipping tape checks
+.RS 4
(info) The tape tests are being skipped because you used the
-\fB-t\fR
+\fB\-t\fR
command line option.
-.TP
-WARNING: \fBcompress\fR is not executable, server-compression and indexing will not work
+.RE
+.PP
+WARNING: \fIcompress\fR is not executable, server\-compression and indexing will not work
+.RS 4
(warning) Compression program
-\fBcompress\fR
+\fIcompress\fR
is not executable, so compression on the tape server host and creating index files will not work.
-.TP
-Tape \fBlabel\fR label ok.
+.RE
+.PP
+Tape \fIlabel\fR label ok.
+.RS 4
(info) Tape
-\fBlabel\fR
+\fIlabel\fR
is OK for the next run.
-.TP
-Server check took \fBS\fR seconds.
+.RE
+.PP
+Server check took \fIS\fR seconds.
+.RS 4
(info) Reports how long the tape server host checks took.
-.TP
-ERROR: \fBhost\fR: could not resolve hostname
+.RE
+.PP
+ERROR: \fIhost\fR: could not resolve hostname
+.RS 4
(error) Could not look up client hostname
-\fBhost\fR.
-.TP
-Client check: \fBH\fR hosts checked in \fBS\fR seconds, \fBN\fR problems found.
+\fIhost\fR.
+.RE
+.PP
+Client check: \fIH\fR hosts checked in \fIS\fR seconds, \fIN\fR problems found.
+.RS 4
(info) Reports the number of client hosts checked, how long it took and the number of errors detected.
-.TP
-WARNING: \fBhost\fR: selfcheck request timed out. Host down?
+.RE
+.PP
+WARNING: \fIhost\fR: selfcheck request timed out. Host down?
+.RS 4
(warning) There was no response from
-\fBhost\fR
+\fIhost\fR
when trying to do the client checks. The host might really be down or it might not be configured properly.
-.TP
-ERROR: \fBhost\fR NAK: \fBmessage\fR
+.RE
+.PP
+ERROR: \fIhost\fR NAK: \fImessage\fR
+.RS 4
(error)
-\fBHost\fR
+\fIHost\fR
reported a negative acknowledgment error of
-\fBmessage\fR
+\fImessage\fR
to the status check request.
-.TP
-ERROR: \fBhost\fR NAK: [NAK parse failed]
+.RE
+.PP
+ERROR: \fIhost\fR NAK: [NAK parse failed]
+.RS 4
(error)
\fBAmcheck\fR
could not parse the negative acknowledgment error from
-\fBhost\fR. There might be an
-\fBAmanda\fR
+\fIhost\fR. There might be an
+\fIAmanda\fR
version mismatch between the host running
\fBamcheck\fR
and
-\fBhost\fR.
-.TP
-ERROR: \fBhost\fR [mutual-authentication failed]
+\fIhost\fR.
+.RE
+.PP
+ERROR: \fIhost\fR [mutual\-authentication failed]
+.RS 4
(error) Kerberos authentication failed while contacting
-\fBhost\fR.
-.TP
-ERROR: \fBhost\fR: \fBmessage\fR
+\fIhost\fR.
+.RE
+.PP
+ERROR: \fIhost\fR: \fImessage\fR
+.RS 4
(error) Error
-\fBmessage\fR
+\fImessage\fR
was reported by the status check on
-\fBhost\fR.
+\fIhost\fR.
+.RE
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamdump\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMCHECKDB" 8 "" "" ""
+.\" Title: amcheckdb
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMCHECKDB" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amcheckdb - check Amanda database for tape consistency
+amcheckdb \- check Amanda database for tape consistency
.SH "SYNOPSIS"
.HP 10
\fBamcheckdb\fR \fIconfig\fR
.PP
\fBAmcheckdb\fR
verifies that every tape mentioned in the
-\fBAmanda\fR
+\fIAmanda\fR
database is still valid in the
-\fBtapelist\fR
+\fItapelist\fR
file.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "EXAMPLE"
.PP
This shows a normal response:
+.sp
+.RS 4
.nf
-
# amcheckdb daily
Ready.
.fi
+.RE
.PP
This shows tape
-\fBDMP014\fR
+\fIDMP014\fR
is still listed in the database but is no longer listed in the
-\fBtapelist\fR
+\fItapelist\fR
file:
+.sp
+.RS 4
.nf
-
# amcheckdb daily
Tape DMP014 missing in /usr/local/etc/amanda//daily/tapelist
Ready.
.fi
+.RE
.SH "AUTHOR"
.PP
-Adrian T. Filipi-Martin <atf3r@cs.virginia.edu>: Original text
+Adrian T. Filipi\-Martin <atf3r@cs.virginia.edu>: Original text
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamadmin\fR(8),
\fBamrmtape\fR(8),
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMCLEANUP" 8 "" "" ""
+.\" Title: amcleanup
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMCLEANUP" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amcleanup - run the Amanda cleanup process after a failure
+amcleanup \- run the Amanda cleanup process after a failure
.SH "SYNOPSIS"
.HP 10
\fBamcleanup\fR \fIconfig\fR
.PP
\fBAmcleanup\fR
generates the
-\fB\fBAmanda\fR Mail Report\fR
+\fI\fIAmanda\fR\fR\fI Mail Report\fR
and updates the
-\fBAmanda\fR
+\fIAmanda\fR
databases after a system failure on a tape server host. This cleanup process is normally done automatically as part of the
\fBamdump\fR
program, but if
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-k\fR
+.PP
+\fB\-k\fR
+.RS 4
Kill all Amanda processes.
+.RE
.SH "EXAMPLES"
.PP
This example runs the
-\fBAmanda\fR
+\fIAmanda\fR
cleanup process by hand after a failure.
+.sp
+.RS 4
.nf
-
% amcleanup daily
.fi
+.RE
.PP
Putting the following line in a system boot script (e.g.
\fI/etc/rc.local\fR) runs the
-\fBAmanda\fR
+\fIAmanda\fR
cleanup process as part of the reboot, eliminating the need to run it by hand.
+.sp
+.RS 4
.nf
-
/usr/local/sbin/amcleanup daily
.fi
+.RE
.PP
If nothing needs to be done,
\fBamcleanup\fR
exits normally with the message:
+.sp
+.RS 4
.nf
-
amcleanup: no unprocessed logfile to clean up.
.fi
+.RE
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamdump\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMCRYPT-OSSL-ASYM" 8 "" "" ""
+.\" Title: amcrypt-ossl-asym
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMCRYPT\-OSSL\-ASYM" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amcrypt-ossl-asym - crypt program for Amanda asymmetric data encryption using OpenSSL
+amcrypt\-ossl\-asym \- crypt program for Amanda asymmetric data encryption using OpenSSL
.SH "SYNOPSIS"
.HP 18
-\fBamcrypt-ossl-asym\fR [-d]
+\fBamcrypt\-ossl\-asym\fR [\-d]
.SH "DESCRIPTION"
.PP
-\fBamcrypt-ossl-asym\fR
+
+\fBamcrypt\-ossl\-asym\fR
uses
\fBOpenSSL\fR
to encrypt and decrypt data. OpenSSL is available from
-www.openssl.org. OpenSSL offers a wide variety of cipher choices (
-\fBamcrypt-ossl-asym\fR
-defaults to 256-bit AES) and can use hardware cryptographic accelerators on several platforms.
+\fIwww.openssl.org\fR\&[1]. OpenSSL offers a wide variety of cipher choices (
+\fBamcrypt\-ossl\-asym\fR
+defaults to 256\-bit AES) and can use hardware cryptographic accelerators on several platforms.
.PP
-\fBamcrypt-ossl-asym\fR
+
+\fBamcrypt\-ossl\-asym\fR
will search for the OpenSSL program in the following directories: /bin:/usr/bin:/usr/local/bin:/usr/ssl/bin:/usr/local/ssl/bin.
.SH "GENERATING PUBLIC AND PRIVATE KEYS"
.PP
RSA keys can be generated with the standard OpenSSL commands, e.g.:
+.sp
+.RS 4
.nf
-
$ cd /var/lib/amanda
-$ openssl genrsa -aes128 -out backup-privkey.pem 1024
+$ openssl genrsa \-aes128 \-out backup\-privkey.pem 1024
Generating RSA private key, 1024 bit long modulus
[...]
-Enter pass phrase for backup-privkey.pem: \fBENTER YOUR PASS PHRASE\fR
-Verifying - Enter pass phrase for backup-key.pem: \fBENTER YOUR PASS PHRASE\fR
+Enter pass phrase for backup\-privkey.pem: \fIENTER YOUR PASS PHRASE\fR
+Verifying \- Enter pass phrase for backup\-key.pem: \fIENTER YOUR PASS PHRASE\fR
-$ openssl rsa -in backup-privkey.pem -pubout -out backup-pubkey.pem
-Enter pass phrase for backup-privkey.pem: \fBENTER YOUR PASS PHRASE\fR
+$ openssl rsa \-in backup\-privkey.pem \-pubout \-out backup\-pubkey.pem
+Enter pass phrase for backup\-privkey.pem: \fIENTER YOUR PASS PHRASE\fR
Writing RSA key
.fi
+.RE
.PP
To generate a private key without a passphrase, omit the
-\fB-aes128\fR
+\fB\-aes128\fR
option. See
\fBopenssl_genrsa\fR(1)
for more key generation options.
Note that it is always possible to generate the public key from the private key.
.SH "KEY AND PASSPHRASE MANAGEMENT"
.PP
-\fBamcrypt-ossl-asym\fR
+
+\fBamcrypt\-ossl\-asym\fR
uses the
-\fBpublic key\fR
+\fIpublic key\fR
to encrypt data. The security of the data does not depend on the confidentiality of the public key. The
-\fBprivate key\fR
+\fIprivate key\fR
is used to decrypt data, and must be protected. Encrypted backup data cannot be recovered without the private key. The private key may optionally be encrypted with a passphrase.
.PP
While the public key must be online at all times to perorm backups, the private key and optional passphrase are only needed to restore data. It is recommended that the latter be stored offline all other times. For example, you could keep the private key on removable media, and copy it into place for a restore; or you could keep the private key online, encrypted with a passphrase that is present only for a restore.
.PP
OpenSSL's key derivation routines use a salt to guard against dictionary attacks on the pass phrase; still it is important to pick a pass phrase that is hard to guess. The Diceware method (see
-www.diceware.com) can be used to create passphrases that are difficult to guess and easy to remember.
+\fIwww.diceware.com\fR\&[2]) can be used to create passphrases that are difficult to guess and easy to remember.
.SH "FILES"
-.TP
-/var/lib/amanda/backup-privkey.pem
+.PP
+/var/lib/amanda/backup\-privkey.pem
+.RS 4
File containing the RSA private key. It should not be readable by any user other than the
-\fBAmanda\fR
+\fIAmanda\fR
user.
-.TP
-/var/lib/amanda/backup-pubkey.pem
+.RE
+.PP
+/var/lib/amanda/backup\-pubkey.pem
+.RS 4
File containing the RSA public key.
-.TP
+.RE
+.PP
/var/lib/amanda/.am_passphrase
+.RS 4
File containing the passphrase. It should not be readable by any user other than the
-\fBAmanda\fR
+\fIAmanda\fR
user.
+.RE
.SH "SEE ALSO"
.PP
+
\fBamanda\fR(8),
\fBamanda.conf\fR(5),
\fBopenssl\fR(1),
-\fBamcrypt-ossl\fR(8)
-
+\fBamcrypt\-ossl\fR(8)
+.SH "REFERENCES"
+.IP " 1." 4
+www.openssl.org
+.RS 4
+\%http://www.openssl.org/
+.RE
+.IP " 2." 4
+www.diceware.com
+.RS 4
+\%http://www.diceware.com/
+.RE
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMCRYPT-OSSL" 8 "" "" ""
+.\" Title: amcrypt-ossl
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMCRYPT\-OSSL" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amcrypt-ossl - crypt program for Amanda symmetric data encryption using OpenSSL
+amcrypt\-ossl \- crypt program for Amanda symmetric data encryption using OpenSSL
.SH "SYNOPSIS"
.HP 13
-\fBamcrypt-ossl\fR [-d]
+\fBamcrypt\-ossl\fR [\-d]
.SH "DESCRIPTION"
.PP
-\fBamcrypt-ossl\fR
+
+\fBamcrypt\-ossl\fR
uses
\fBOpenSSL\fR
to encrypt and decrypt data. OpenSSL is available from
-www.openssl.org. OpenSSL offers a wide variety of cipher choices (
-\fBamcrypt-ossl\fR
-defaults to 256-bit AES) and can use hardware cryptographic accelerators on several platforms.
+\fIwww.openssl.org\fR\&[1]. OpenSSL offers a wide variety of cipher choices (
+\fBamcrypt\-ossl\fR
+defaults to 256\-bit AES) and can use hardware cryptographic accelerators on several platforms.
.PP
-\fBamcrypt-ossl\fR
+
+\fBamcrypt\-ossl\fR
will search for the OpenSSL program in the following directories: /bin:/usr/bin:/usr/local/bin:/usr/ssl/bin:/usr/local/ssl/bin.
.SH "PASSPHRASE MANAGEMENT"
.PP
-\fBamcrypt-ossl\fR
+
+\fBamcrypt\-ossl\fR
uses the same pass phrase to encrypt and decrypt data. It is very important to store and protect the pass phrase properly. Encrypted backup data can
\fBonly\fR
be recovered with the correct passphrase.
.PP
OpenSSL's key derivation routines use a salt to guard against dictionary attacks on the pass phrase; still it is important to pick a pass phrase that is hard to guess. The Diceware method (see
-www.diceware.com) can be used to create passphrases that are difficult to guess and easy to remember.
+\fIwww.diceware.com\fR\&[2]) can be used to create passphrases that are difficult to guess and easy to remember.
.SH "FILES"
-.TP
+.PP
/var/lib/amanda/.am_passphrase
+.RS 4
File containing the pass phrase. It should not be readable by any user other than the
-\fBAmanda\fR
+\fIAmanda\fR
user.
+.RE
.SH "SEE ALSO"
.PP
+
\fBamanda\fR(8),
\fBamanda.conf\fR(5),
\fBopenssl\fR(1),
-\fBamcrypt-ossl-asym\fR(8)
-
+\fBamcrypt\-ossl\-asym\fR(8)
+.SH "REFERENCES"
+.IP " 1." 4
+www.openssl.org
+.RS 4
+\%http://www.openssl.org/
+.RE
+.IP " 2." 4
+www.diceware.com
+.RS 4
+\%http://www.diceware.com/
+.RE
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMCRYPT" 8 "" "" ""
+.\" Title: amcrypt
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMCRYPT" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amcrypt - reference crypt program for Amanda symmetric data encryption
+amcrypt \- reference crypt program for Amanda symmetric data encryption
.SH "SYNOPSIS"
.HP 8
\fBamcrypt\fR
.SH "DESCRIPTION"
.PP
+
\fBamcrypt\fR
requires
\fBaespipe\fR,
and
\fBgpg\fR
to work. Aespipe is available from
-: http://loop-aes.sourceforge.net
+\fI\%http://loop\-aes.sourceforge.net\fR
.PP
+
\fBamcrypt\fR
will search for the aespipe program in the following directories: /usr/bin:/usr/local/bin:/sbin:/usr/sbin.
-\fBamcrypt\fR calls \fBamaespipe\fR and pass the
-\fBpassphrase\fR through file descriptor 3.
-The passphrase should be stored in ~amanda/.am_passphrase.
-.SH "HOW TO CREATE ENCRYPTION KEYS FOR AMCRYPT"
+.PP
-1. Create 65 random encryption keys and encrypt those keys using gpg. Reading
-from /dev/random may take indefinitely long if kernel's random entropy pool
-is empty. If that happens, do some other work on some other console (use
-keyboard, mouse and disks).
+\fBamcrypt\fR
+calls
+\fBamaespipe\fR
+and pass the
+\fBpassphrase\fR
+through file descriptor 3. The passphrase should be stored in ~amanda/.am_passphrase.
+.SH "HOW TO CREATE ENCRYPTION KEYS FOR AMCRYPT"
+.PP
+1. Create 65 random encryption keys and encrypt those keys using gpg. Reading from /dev/random may take indefinitely long if kernel's random entropy pool is empty. If that happens, do some other work on some other console (use keyboard, mouse and disks).
.PP
-head -c 2925 /dev/random | uuencode -m - | head -n 66 | tail -n 65 \ | gpg --symmetric -a > ~amanda/.gnupg/am_key.gpg
+head \-c 2925 /dev/random | uuencode \-m \- | head \-n 66 | tail \-n 65 \e | gpg \-\-symmetric \-a > ~amanda/.gnupg/am_key.gpg
.PP
This will ask for a passphrase. Remember this passphrase as you will need it in the next step.
.PP
-2. Store the passphrase inside the home-directory of the AMANDA-user and protect it with proper permissions:
+2. Store the passphrase inside the home\-directory of the AMANDA\-user and protect it with proper permissions:
+.sp
+.RS 4
.nf
-
echo my_secret_passphrase > ~amanda/.am_passphrase
chown amanda:disk ~amanda/.am_passphrase
chmod 700 ~amanda/.am_passphrase
.fi
+.RE
.SH "KEY AND PASSPHRASE"
.PP
+
\fBamcrypt\fR
uses the same key to encrypt and decrypt data.
-
-It is very important to store and protect the key and the passphrase
-properly. Encrypted backup data can \fBonly\fR be recovered with the correct key and
-passphrase.
+.PP
+It is very important to store and protect the key and the passphrase properly. Encrypted backup data can
+\fBonly\fR
+be recovered with the correct key and passphrase.
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBaespipe\fR(1),
\fBamaespipe\fR(8),
\fBgpg\fR(1)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMDD" 8 "" "" ""
+.\" Title: amdd
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMDD" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amdd - Amanda version of dd
+amdd \- Amanda version of dd
.SH "SYNOPSIS"
.HP 5
-\fBamdd\fR [-d] [\fIif=input\fR] [\fIof=output\fR] [\fIbs=blocksize\fR] [\fIskip=count\fR] [\fIcount=count\fR]
+\fBamdd\fR [\-d] [\fIif=input\fR] [\fIof=output\fR] [\fIbs=blocksize\fR] [\fIskip=count\fR] [\fIcount=count\fR]
.SH "DESCRIPTION"
.PP
\fBAmdd\fR
provides just enough of the standard UNIX
\fBdd\fR
command for the needs of
-\fBAmanda\fR. This is handy when doing a full restore and the standard
+\fIAmanda\fR. This is handy when doing a full restore and the standard
\fBdd\fR
program has not yet been found.
.PP
\fBAmdd\fR
also provides access to the
-\fBAmanda\fR
+\fIAmanda\fR
output drivers that support various tape simulations. This may be used for debugging or to convert from one format to another.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR. See the
+\fIAmanda\fR. See the
\fBOUTPUT DRIVERS\fR
section of
-\fBamanda(8)\fR
+\fIamanda(8)\fR
for more information on the
-\fBAmanda\fR
+\fIAmanda\fR
output drivers.
.SH "OPTIONS"
-.TP
-\fB-d\fR
+.PP
+\fB\-d\fR
+.RS 4
Turn on debugging output.
-.TP
-\fB-l\fR\fIlength\fR
+.RE
+.PP
+\fB\-l\fR\fIlength\fR
+.RS 4
Set the output length. If the output driver limits the output size, this controls when end of tape will be simulated.
.sp
-\fBLength\fR
+\fILength\fR
may have a multiplier suffix:
.sp
+.RS 4
.nf
-
-k -> 1024 (Kilobytes)
-b -> 512 (Blocks)
-M -> 1024*1024 (Megabytes)
-
+k \-> 1024 (Kilobytes)
+b \-> 512 (Blocks)
+M \-> 1024*1024 (Megabytes)
.fi
+.RE
The default is no multiplier (bytes).
-.TP
-\fBif=\fR\fBinput\fR
+.RE
+.PP
+\fBif=\fR\fIinput\fR
+.RS 4
Input to
\fBdd\fR. Default is stdin.
-.TP
-\fBof=\fR\fBoutput\fR
+.RE
+.PP
+\fBof=\fR\fIoutput\fR
+.RS 4
Where to send the output of
\fBdd\fR. Default is stdout.
-.TP
-\fBbs=\fR\fBblocksize\fR
+.RE
+.PP
+\fBbs=\fR\fIblocksize\fR
+.RS 4
Size of each record. Input records smaller than this will
-\fBnot\fR
+\fInot\fR
be padded. Output records will be the same size as the corresponding input record. Default is 512 bytes.
.sp
-\fBBlocksize\fR
+\fIBlocksize\fR
may have a multiplier suffix:
.sp
+.RS 4
.nf
-
-k -> 1024 (Kilobytes)
-b -> 512 (Blocks)
-M -> 1024*1024 (Megabytes)
-
+k \-> 1024 (Kilobytes)
+b \-> 512 (Blocks)
+M \-> 1024*1024 (Megabytes)
.fi
+.RE
The default is no multiplier (bytes).
-.TP
-\fBcount=\fR\fBcount\fR
+.RE
+.PP
+\fBcount=\fR\fIcount\fR
+.RS 4
Number of records to copy. Default is all records until end of file.
-.TP
-\fBskip=\fR\fBcount\fR
+.RE
+.PP
+\fBskip=\fR\fIcount\fR
+.RS 4
Number of records to skip before copying input to output. Default is zero.
+.RE
.SH "AUTHOR"
.PP
Marc Mengel
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMDUMP" 8 "" "" ""
+.\" Title: amdump
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMDUMP" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amdump - back up all disks in an Amanda configuration
+amdump \- back up all disks in an Amanda configuration
.SH "SYNOPSIS"
.HP 7
-\fBamdump\fR \fIconfig\fR [\fIhost\fR [\fIdisk\fR]*]*
- [-o \fIconfigoption\fR]*
-
+\fBamdump\fR \fIconfig\fR [\fIhost\fR\ [\fIdisk\fR...]...] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmdump\fR
switches to the appropriate
-\fBAmanda\fR
-configuration directory, e.g. /usr/local/etc/amanda/\fBconfig\fR, then attempts to back up every disk specified by the
-\fBamanda.conf\fR
+\fIAmanda\fR
+configuration directory, e.g. /usr/local/etc/amanda/\fIconfig\fR, then attempts to back up every disk specified by the
+\fIamanda.conf\fR
file.
\fBAmdump\fR
is normally run by
.PP
You can specify many host/disk expressions, only disks that match an expression will be dumped. All disks are dumped if no expressions are given.
.PP
-If the file /usr/local/etc/amanda/\fBconfig\fR/hold exists,
+If the file /usr/local/etc/amanda/\fIconfig\fR/hold exists,
\fBamdump\fR
will wait until it is removed before starting the backups. This allows scheduled backups to be delayed when circumstances warrant, for example, if the tape device is being used for some other purpose. While waiting,
\fBamdump\fR
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
+.PP
\fIhost\fR [\fIdisk\fR]*
+.RS 4
Specify the host and disk on which the command will work.
-.TP
-\fB-o\fR \fIconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "EXAMPLE"
.PP
Here is a typical crontab entry. It runs
\fBamdump\fR
every weeknight at 1 a.m. as user
\fBbin\fR:
+.sp
+.RS 4
.nf
-
-0 1 * * 1-5 bin /usr/local/sbin/amdump daily
+0 1 * * 1\-5 bin /usr/local/sbin/amdump daily
.fi
+.RE
.PP
Please see the
\fBcrontab\fR(5)
\fBcrontab\fR(1)
manual page for the correct crontab format for your system.
.SH "MESSAGES"
-.TP
+.PP
amdump: waiting for hold file to be removed
+.RS 4
The "hold" file exists and
\fBamdump\fR
is waiting for it to be removed before starting backups.
-.TP
+.RE
+.PP
amdump: amdump or amflush is already running, or you must run amcleanup
+.RS 4
Amdump detected another
\fBamdump\fR
or
\fBamcleanup\fR(8)
and then rerun
\fBamdump\fR.
+.RE
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamrestore\fR(8),
\fBamflush\fR(8),
\fBcron\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMFETCHDUMP" 8 "" "" ""
+.\" Title: amfetchdump
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMFETCHDUMP" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amfetchdump - extract backup images from multiple Amanda tapes.
+amfetchdump \- extract backup images from multiple Amanda tapes.
.SH "SYNOPSIS"
.HP 12
-\fBamfetchdump\fR [-pcClawns] [-d \fIdevice\fR] [-O \fIdirectory\fR] [-i \fIlogfile\fR] [-b \fIblocksize\fR] \fIconfig\fR \fIhostname\fR [\fIdisk\fR [ \fIdate\fR [ \fIlevel\fR [ \fIhostname\fR [...] ] ] ]] [-o \fIconfigoption\fR]*
-
+\fBamfetchdump\fR [\-pcClawns] [\-d\ \fIdevice\fR] [\-O\ \fIdirectory\fR] [\-i\ \fIlogfile\fR] [\-b\ \fIblocksize\fR] \fIconfig\fR \fIhostname\fR [\fIdisk\fR\ [\ \fIdate\fR\ [\ \fIlevel\fR\ [\ \fIhostname\fR\ [...]\ ]\ ]\ ]] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmfetchdump\fR
-pulls one or more matching dumps from tape or from the holding disk, handling the reassembly of multi-tape split dump files as well as any tape autochanger operations.
+pulls one or more matching dumps from tape or from the holding disk, handling the reassembly of multi\-tape split dump files as well as any tape autochanger operations.
.PP
It will automatically use the logs created by
\fBamdump\fR(8)
\fBfind\fR
feature of
\fBamadmin\fR(8)
-lists available dumps. If these logs are unavailable, it can search tape-by-tape to find what it needs, and can generate new logs to serve as an emergency tape inventory.
+lists available dumps. If these logs are unavailable, it can search tape\-by\-tape to find what it needs, and can generate new logs to serve as an emergency tape inventory.
.PP
The
-\fBhostname\fR,
-\fBdiskname\fR,
-\fBdatestamp\fR, and
-\fBlevel\fR
-dump pattern-matching works as in
+\fIhostname\fR,
+\fIdiskname\fR,
+\fIdatestamp\fR, and
+\fIlevel\fR
+dump pattern\-matching works as in
\fBamrestore\fR(8), with the added requirement that at minimum a
-\fBhostname\fR
+\fIhostname\fR
must be specified when not in inventory mode.
.PP
Unless
-\fB-p\fR
+\fB\-p\fR
is used, backup images are extracted to files in the current directory named:
.PP
-\fBhostname.diskname.datestamp.dumplevel\fR
+\fIhostname.diskname.datestamp.dumplevel\fR
.SH "OPTIONS"
-.TP
-\fB-p\fR
+.PP
+\fB\-p\fR
+.RS 4
Pipe exactly one complete dump file to
-\fBstdout\fR, instead of writing the file to disk. This will restore only the first matching dumpfile (where "first" is determined by the dump log search facility).
-.TP
-\fB-d\fR \fIdevice\fR
+\fIstdout\fR, instead of writing the file to disk. This will restore only the first matching dumpfile (where "first" is determined by the dump log search facility).
+.RE
+.PP
+\fB\-d\fR \fIdevice\fR
+.RS 4
Restore from this tape device instead of the default.
-.TP
-\fB-O\fR \fIdirectory\fR
+.RE
+.PP
+\fB\-O\fR \fIdirectory\fR
+.RS 4
Output restored files to this directory, instead of to the current working directory.
-.TP
-\fB-c\fR
+.RE
+.PP
+\fB\-c\fR
+.RS 4
Compress output, fastest method available.
-.TP
-\fB-C\fR
+.RE
+.PP
+\fB\-C\fR
+.RS 4
Compress output, smallest file size method available.
-.TP
-\fB-l\fR
+.RE
+.PP
+\fB\-l\fR
+.RS 4
Leave dumps in the compressed/uncompressed state in which they were found on tape. By default,
\fBamfetchdump\fR
will automatically uncompress when restoring.
-.TP
-\fB-a\fR
+.RE
+.PP
+\fB\-a\fR
+.RS 4
Assume that all tapes are already available, via tape changer or otherwise, instead of prompting the operator to ensure that all tapes are loaded.
-.TP
-\fB-i\fR \fIfilename\fR
+.RE
+.PP
+\fB\-i\fR \fIfilename\fR
+.RS 4
Generate an inventory of all dumps "seen" on the tapes we search, for later use as a log.
-.TP
-\fB-w\fR
+.RE
+.PP
+\fB\-w\fR
+.RS 4
Wait to put split dumps together until all chunks have been restored. Normally,
\fBamfetchdump\fR
will attempt to read pieces of a split file from tape in order, so that it can assemble them simply by appending each file to the first. This option disables the appending behavior, and instead restores each piece as an individual file and reassembles them only after all have been restored.
.nr an-break-flag 1
.br
\fBNote\fR
-This requires at least double the size of your dump in free
-disk space, in order to build the final assembled dumpfile.This behavior is implicitly invoked in circumstances where knowing the location of all dumps on tape in advance is not possible, such as when you are restoring without log files.
-.TP
-\fB-n\fR
+This requires at least double the size of your dump in free disk space, in order to build the final assembled dumpfile.
+
+This behavior is implicitly invoked in circumstances where knowing the location of all dumps on tape in advance is not possible, such as when you are restoring without log files.
+.RE
+.PP
+\fB\-n\fR
+.RS 4
Do not reassemble split dump files at all, just restore each piece as an individual file.
-.TP
-\fB-s\fR
-Do not fast-forward straight to needed files on tape. This will slow down most restores substantially. Only use this option if your tape drive does not properly support the fast-forward operation.
-.TP
-\fB-b\fR \fIblocksize\fR
+.RE
+.PP
+\fB\-s\fR
+.RS 4
+Do not fast\-forward straight to needed files on tape. This will slow down most restores substantially. Only use this option if your tape drive does not properly support the fast\-forward operation.
+.RE
+.PP
+\fB\-b\fR \fIblocksize\fR
+.RS 4
Force a particular block size when reading from tapes. This value will usually be autodetected, and should not normally need to be set.
-.TP
-\fB-o\fR \fIconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "EXAMPLES"
.PP
All the examples here assume your configuration is called
.PP
Here's a simple case, restoring all known dumps of the host vanya to the current working directory.
.sp
+.RS 4
.nf
-
$ amfetchdump SetA vanya
-
.fi
+.RE
.sp
.PP
A more likely scenario involves restoring a particular dump from a particular date. We'll pipe this one to
-\fBGNU-tar\fR
+\fBGNU\-tar\fR
as well, to automatically extract the dump.
.sp
+.RS 4
.nf
-
-$ amfetchdump -p SetA vanya /home 20051020 | gtar -xvpf -
-
+$ amfetchdump \-p SetA vanya /home 20051020 | gtar \-xvpf \-
.fi
+.RE
.sp
.PP
In a situation where all of our dump logs have been wiped out, we could also use amfetchdump to inventory our tapes and recreate an imitation of those logs, which we'll send to
-\fBstdout\fR
+\fIstdout\fR
for casual perusal.
+
.sp
+.RS 4
.nf
-
-$ amfetchdump -i - SetA
-
+$ amfetchdump \-i \- SetA
.fi
+.RE
.sp
.PP
Note that you can specify a restore while in inventory mode, and
\fBamfetchdump\fR
will continue searching for more dumps from this host even after successfully restoring a dump, inventorying all the while. If your backup searcher has been trashed, this is a handy way to recover what you have.
+
.sp
+.RS 4
.nf
-
-$ amfetchdump -i /var/amanda/log SetA backupserver
-
+$ amfetchdump \-i /var/amanda/log SetA backupserver
.fi
+.RE
.sp
.SH "CAVEATS"
-\fBAmfetchdump\fR is dependent on accessing your server's config,
-tape changer, and (normally) dump logs. As such, it's not necessarily
-the most useful tool when those have all been wiped out and you
-desperately need to pull things from your tape. Pains have been taken
-to make it as capable as possible, but for seriously minimialist
-restores, look to
+.PP
+\fBAmfetchdump\fR
+is dependent on accessing your server's config, tape changer, and (normally) dump logs. As such, it's not necessarily the most useful tool when those have all been wiped out and you desperately need to pull things from your tape. Pains have been taken to make it as capable as possible, but for seriously minimialist restores, look to
\fBamrestore\fR(8)
or
\fBdd\fR(8)
<building@nap.edu>, National Academies Press
.PP
Ian Turner,
-<ian@zmanda.com>: XML-conversion
+<ian@zmanda.com>: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamadmin\fR(8),
\fBamrestore\fR(8),
-\fBtar\fR(1)\fBrestore\fR(8)
-
+\fBtar\fR(1)
+\fBrestore\fR(8)
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMFLUSH" 8 "" "" ""
+.\" Title: amflush
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMFLUSH" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amflush - flush Amanda backup files from holding disk to tape
+amflush \- flush Amanda backup files from holding disk to tape
.SH "SYNOPSIS"
.HP 8
-\fBamflush\fR [-b] [-f] [-s] [-D \fIdatestamp\fR]*
- \fIconfig\fR [\fIhost\fR [\fIdisk\fR]*]*
- [-o \fIconfigoption\fR]*
-
+\fBamflush\fR [\-b] [\-f] [\-s] [\-D\ \fIdatestamp\fR] \fIconfig\fR [\fIhost\fR\ [\fIdisk\fR...]...] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmflush\fR
writes
-\fBAmanda\fR
+\fIAmanda\fR
backups from the holding disks to tape, and updates the
-\fBAmanda\fR
+\fIAmanda\fR
info database and tapelist accordingly. Backups may stay in a holding disk when something is wrong with the tape at the time
\fBamdump\fR
is run. When this happens, the problem must be corrected and
\fBamflush\fR
run by hand.
.SH "OPTIONS"
-.TP
-\fB-b\fR
+.PP
+\fB\-b\fR
+.RS 4
Run
\fBamflush\fR
in batch mode. All datestamps are selected unless specified. The flush is started without confirmation.
-.TP
-\fB-f\fR
+.RE
+.PP
+\fB\-f\fR
+.RS 4
Run
\fBamflush\fR
in foreground.
\fBAmflush\fR
normally detaches itself from the tty and runs as a background process. With the
-\fB-f\fR
+\fB\-f\fR
option,
\fBamflush\fR
stays in the foreground. This is useful if
\fBamflush\fR
is run as part of another script that, for example, advances the tape after the flush is completed.
-.TP
-\fB-s\fR
+.RE
+.PP
+\fB\-s\fR
+.RS 4
Write log to stdout/stderr instead of the amflush log file. Requires the
-\fB-f\fR
+\fB\-f\fR
option.
-.TP
-\fB-D datestamp\fR
+.RE
+.PP
+\fB\-D datestamp\fR
+.RS 4
specify a datestamp expression you want to flush, see the "DATESTAMP EXPRESSION" section of
\fBamanda\fR(8)
for a description.
-\fB-D 20001225-7\fR
+\fB\-D 20001225\-7\fR
will flush all dumps from 25 december 2000 to 27 december 2000.
-.TP
+.RE
+.PP
\fIhost\fR [\fIdisk\fR]*
+.RS 4
Specify the host and disk on which the command will work.
-.TP
-\fB-o\fR \fIconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.PP
You can specify many host/disk expressions, only disks that match an expression will be flushed. All disks are flushed if no expressions are given. see the "HOST & DISK EXPRESSION" section of
\fBamanda\fR(8)
.PP
\fBAmflush\fR
will look in the holding disks specified by the
-\fBamanda.conf\fR
-file in /usr/local/etc/amanda/\fBconfig\fR
-for any non-empty
-\fBAmanda\fR
+\fIamanda.conf\fR
+file in /usr/local/etc/amanda/\fIconfig\fR
+for any non\-empty
+\fIAmanda\fR
work directories. It then prompts you to select a directory or to process all of the directories. The work directories in the holding disks are named by the date at the time
\fBamdump\fR
was run, e.g.
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "EXAMPLE"
.PP
\fBAmflush\fR
will search for holding areas associated with the
-\fBdaily\fR
+\fIdaily\fR
configuration. After you select which holding area to flush,
\fBamflush\fR
writes the data to tape, updates the databases and sends a mail report similar to
\fBamdump\fR(8).
+.sp
+.RS 4
.nf
-
% amflush daily
-Scanning /amanda-hold...
- 20001113: found \fBAmanda\fR directory.
- 20001114: found \fBAmanda\fR directory.
+Scanning /amanda\-hold...
+ 20001113: found \fIAmanda\fR directory.
+ 20001114: found \fIAmanda\fR directory.
-Multiple \fBAmanda\fR directories, please pick one by letter:
+Multiple \fIAmanda\fR directories, please pick one by letter:
A. 20001113
B. 20001114
Select directories to flush [A..B]: [ALL] all
Running in background, you can log off now.
You'll get mail when amflush is finished.
.fi
+.RE
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamdump\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMGETCONF" 8 "" "" ""
+.\" Title: amgetconf
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMGETCONF" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amgetconf - look up amanda.conf variables
+amgetconf \- look up amanda.conf variables
.SH "SYNOPSIS"
.HP 10
-\fBamgetconf\fR [\fIconfig\fR] \fIparameter\fR [-o \fIconfigoption\fR]*
-
+\fBamgetconf\fR [\fIconfig\fR] [\fI\-\-list\fR] \fIparameter\fR [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmgetconf\fR
looks up parameters in
-\fBamanda.conf\fR, the
-\fBAmanda\fR
+\fIamanda.conf\fR, the
+\fIAmanda\fR
configuration file, or from the build and runtime environment, and returns their corresponding value.
.PP
If
-\fBconfig\fR
+\fIconfig\fR
is not specified,
\fBamgetconf\fR
assumes it is being run from the configuration directory and that
-\fBamanda.conf\fR
+\fIamanda.conf\fR
is present.
.PP
If
-\fBparameter\fR
+\fIparameter\fR
begins with
-\fBbuild.\fR, the (case insensitive) string following the period is a build environment variable. Variables without a value (e.g.
-\fBXFSDUMP\fR
+\fIbuild.\fR, the (case insensitive) string following the period is a build environment variable. Variables without a value (e.g.
+\fIXFSDUMP\fR
on a system that does not support that type of file system) will not report an error and will return an empty string as the value. Flag variables (e.g.
-\fBUSE_AMANDAHOSTS\fR) will return
+\fIUSE_AMANDAHOSTS\fR) will return
1
if the flag is set or an empty string if it is not.
.PP
If
-\fBparameter\fR
+\fIparameter\fR
begins with
-\fBdbopen.\fR, the string following the period is a program name and an
-\fBAmanda\fR
+\fIdbopen.\fR, the string following the period is a program name and an
+\fIAmanda\fR
debug file will be created for the caller. The name of the file is returned.
.PP
If
-\fBparameter\fR
+\fIparameter\fR
begins with
-\fBdbclose.\fR, the string following the period is a program name previously used with
-\fBdbopen.\fR, followed by a colon (:) and the previously opened file name.
+\fIdbclose.\fR, the string following the period is a program name previously used with
+\fIdbopen.\fR, followed by a colon (:) and the previously opened file name.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-o\fR \fIconfigoption\fR
+.PP
+\fB\-\-list\fR
+.RS 4
+The parameter must be 'tapetype', 'dumptype, 'holdingdisk' or 'interface'. It will output, one by line, the list of identifier for the parameter.
+.RS 4
+.PP
+\-\-list tapetype
+.RS 4
+Output the list of tapetype, one by line.
+.RE
+.PP
+\-\-list dumptype
+.RS 4
+Output the list of dumptype, one by line.
+.RE
+.PP
+\-\-list holdingdisk
+.RS 4
+Output the list of holdingdisk, one by line.
+.RE
+.PP
+\-\-list interface
+.RS 4
+Output the list of interface, one by line.
+.RE
+.RE
+.RE
+.PP
+\fBparameter\fR
+.RS 4
+It could be one of the below format:
+.RS 4
+.PP
+runtapes
+.RS 4
+.RE
+.PP
+DUMPTYPE:no\-compress:compress
+.RS 4
+.RE
+.PP
+TAPETYPE:HP\-DAT:length
+.RS 4
+.RE
+.PP
+INTERFACE:local:use
+.RS 4
+.RE
+.PP
+HOLDINGDISK:hd1:use
+.RS 4
+.RE
+.RE
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "EXAMPLE"
.PP
Find out the path to the log file directory:
.sp
+.RS 4
.nf
-
% amgetconf daily logdir
/usr/local/etc/amanda//daily
-
.fi
+.RE
.sp
.PP
Find out the current tape type:
.sp
+.RS 4
.nf
-
% amgetconf daily tapetype
-DLT4000-IV
-
+DLT4000\-IV
.fi
+.RE
.sp
.PP
Find out the default configuration directory:
.sp
+.RS 4
.nf
-
% amgetconf daily build.CONFIG_DIR
/usr/local/etc/amanda/
-
.fi
+.RE
.sp
.PP
Create, use and close a debug file in a script:
.sp
+.RS 4
.nf
-
% set debug_file = `amgetconf daily dbopen.myscript`
% echo debug information >> $debug_file
% amgetconf daily dbclose.myscript:$debug_file
-
.fi
+.RE
.sp
.SH "MESSAGES"
-.TP
-amgetconf: no such parameter \fBparam\fR
+.PP
+amgetconf: no such parameter \fIparam\fR
+.RS 4
Parameter
-\fBparam\fR
+\fIparam\fR
is not a known keyword (e.g. not a valid
-\fBamanda.conf\fR
+\fIamanda.conf\fR
keyword).
+.RE
.SH "SEE ALSO"
.PP
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMLABEL" 8 "" "" ""
+.\" Title: amlabel
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMLABEL" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amlabel - label an Amanda tape
+amlabel \- label an Amanda tape
.SH "SYNOPSIS"
.HP 8
-\fBamlabel\fR [-f] \fIconfig\fR \fIlabel\fR [slot \fIslot\fR] [-o \fIconfigoption\fR]*
-
+\fBamlabel\fR [\-f] \fIconfig\fR \fIlabel\fR [slot\ \fIslot\fR] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
All
-\fBAmanda\fR
-tapes must be pre-labeled before they are used.
-\fBAmanda\fR
+\fIAmanda\fR
+tapes must be pre\-labeled before they are used.
+\fIAmanda\fR
verifies the label in
\fBamdump\fR
and
.PP
\fBAmlabel\fR
writes an
-\fBAmanda\fR
+\fIAmanda\fR
label on the tape in the device specified by the
-\fBamanda.conf\fR
-file in /usr/local/etc/amanda/\fBconfig\fR.
-\fBLabel\fR
+\fIamanda.conf\fR
+file in /usr/local/etc/amanda/\fIconfig\fR.
+\fILabel\fR
may be any string that does not contain whitespace and that matches the
-\fBamanda.conf\fR\fBlabelstr\fR
+\fIamanda.conf\fR
+\fBlabelstr\fR
regular expression option. It is up to the system administrator to define a naming convention.
.PP
\fBAmlabel\fR
appends the new tape to the
-\fBtapelist\fR
+\fItapelist\fR
file so it will be used by
-\fBAmanda\fR
+\fIAmanda\fR
before it reuses any other tapes. When you
\fBamlabel\fR
multiple tapes, they will be used in the order you
.PP
\fBAmlabel\fR
will not write the label if the tape contains an active
-\fBAmanda\fR
+\fIAmanda\fR
tape or if the label specified is on an active tape. The
-\fB-f\fR
+\fB\-f\fR
(force) flag bypasses these verifications.
.PP
An optional
-\fBslot\fR
+\fIslot\fR
may be specified after the tape label. If a tape changer is in use,
\fBamlabel\fR
will label the tape in the specified slot instead of the currently loaded tape.
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-o\fR \fIconfigoption\fR
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "EXAMPLE"
.PP
Write an
-\fBAmanda\fR
+\fIAmanda\fR
label with the string "DMP000" on the tape loaded in the device named in the
\fBtapedev\fR
option in /usr/local/etc/amanda/daily/amanda.conf:
+.sp
+.RS 4
.nf
-
% amlabel daily DMP000
.fi
+.RE
.PP
Label the tape in slot 3 of the currently configured tape changer with the string "DMP003":
+.sp
+.RS 4
.nf
-
% amlabel daily DMP003 slot 3
.fi
+.RE
.SH "MESSAGES"
-.TP
-label \fBlabel\fR doesn't match labelstr \fBstr\fR
+.PP
+label \fIlabel\fR doesn't match labelstr \fIstr\fR
+.RS 4
Label
-\fBlabel\fR
+\fIlabel\fR
on the command line does not match the
-\fBlabelstr\fR
+\fIlabelstr\fR
regular expression
-\fBstr\fR
+\fIstr\fR
from
-\fBamanda.conf\fR.
-.TP
-label \fBlabel\fR already on a tape
+\fIamanda.conf\fR.
+.RE
+.PP
+label \fIlabel\fR already on a tape
+.RS 4
Label
-\fBlabel\fR
+\fIlabel\fR
is already listed as an active
-\fBAmanda\fR
+\fIAmanda\fR
tape.
-.TP
-no tpchanger specified in \fBpath\fR , so slot command invalid
+.RE
+.PP
+no tpchanger specified in \fIpath\fR , so slot command invalid
+.RS 4
The command line has the
\fBslot\fR
parameter but the
-\fBamanda.conf\fR
+\fIamanda.conf\fR
file in
-\fBpath\fR
+\fIpath\fR
does not have a tape changer configured.
-.TP
-reading label \fBlabel\fR, tape is in another amanda configuration
+.RE
+.PP
+reading label \fIlabel\fR, tape is in another amanda configuration
+.RS 4
This tape appears to be a valid
-\fBAmanda\fR
+\fIAmanda\fR
tape, but label does not match
\fBlabelstr\fR
for this configuration so it is probably part of a different
-\fBAmanda\fR
+\fIAmanda\fR
configuration.
-.TP
-reading label \fBlabel\fR, tape is active
+.RE
+.PP
+reading label \fIlabel\fR, tape is active
+.RS 4
Tape
-\fBlabel\fR
+\fIlabel\fR
appears to already be part of this
-\fBAmanda\fR
+\fIAmanda\fR
configuration and active, i.e. has valid data on it.
-.TP
-no label found, are you sure \fBtape\fR is non-rewinding?
+.RE
+.PP
+no label found, are you sure \fItape\fR is non\-rewinding?
+.RS 4
While checking that the label was written correctly,
\fBamlabel\fR
-got an error that might be caused by mis-configuring
-\fBAmanda\fR
-with a rewinding tape device name instead of a non-rewinding device name for
-\fBtape.\fR
+got an error that might be caused by mis\-configuring
+\fIAmanda\fR
+with a rewinding tape device name instead of a non\-rewinding device name for
+\fItape.\fR
+.RE
.SH "AUTHOR"
.PP
James da Silva,
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
-\fBamanda\fR(8)\fBamdump\fR(8)\fBamflush\fR(8)
-
+\fBamanda\fR(8)
+\fBamdump\fR(8)
+\fBamflush\fR(8)
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMMT" 8 "" "" ""
+.\" Title: ammt
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMMT" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-ammt - Amanda version of mt
+ammt \- Amanda version of mt
.SH "SYNOPSIS"
.HP 5
-\fBammt\fR [-d] [-f -t \fIdevice\fR] \fIcommand\fR [\fIcount\fR]
+\fBammt\fR [\-d] [\-f | \-t | \fIdevice\fR] \fIcommand\fR [\fIcount\fR]
.SH "DESCRIPTION"
.PP
\fBAmmt\fR
provides just enough of the standard UNIX
\fBmt\fR
command for the needs of
-\fBAmanda\fR. This is handy when doing a full restore and the standard
+\fIAmanda\fR. This is handy when doing a full restore and the standard
\fBmt\fR
program has not yet been found.
.PP
\fBAmmt\fR
also provides access to the
-\fBAmanda\fR
+\fIAmanda\fR
output drivers that support various tape simulations.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR. See the
+\fIAmanda\fR. See the
\fBOUTPUT DRIVERS\fR
section of
-\fBamanda(8)\fR
+\fIamanda(8)\fR
for more information on the
-\fBAmanda\fR
+\fIAmanda\fR
output drivers.
.SH "OPTIONS"
-.TP
-\fB-d\fR
+.PP
+\fB\-d\fR
+.RS 4
Turn on debugging output.
-.TP
-\fB-f\fR\fI device\fR
+.RE
+.PP
+\fB\-f\fR\fI device\fR
+.RS 4
Access tape device
-\fBdevice\fR. If not specified, the
+\fIdevice\fR. If not specified, the
\fBTAPE\fR
environment variable is used.
-.TP
-\fB-t\fR\fI device\fR
+.RE
+.PP
+\fB\-t\fR\fI device\fR
+.RS 4
Same as
-\fB-f\fR.
-.TP
-\fBcommand\fR\fB count\fR
+\fB\-f\fR.
+.RE
+.PP
+\fBcommand\fR\fI count\fR
+.RS 4
Which command to issue, and an optional count of operations.
+.RE
.SH "COMMANDS"
.PP
Each command may be abbreviated to whatever length makes it unique.
-.TP
-\fBeof|weof\fR\fB count\fR
+.PP
+\fBeof|weof\fR\fI count\fR
+.RS 4
Write
-\fBcount\fR
+\fIcount\fR
(default: 1) end of file marks (tapemarks).
-.TP
-\fBfsf\fR\fB count\fR
+.RE
+.PP
+\fBfsf\fR\fI count\fR
+.RS 4
Skip forward
-\fBcount\fR
+\fIcount\fR
(default: 1) files.
-.TP
-\fBbsf\fR\fB count\fR
+.RE
+.PP
+\fBbsf\fR\fI count\fR
+.RS 4
Skip backward
-\fBcount\fR
+\fIcount\fR
(default: 1) files.
-.TP
-\fBasf\fR\fB count\fR
+.RE
+.PP
+\fBasf\fR\fI count\fR
+.RS 4
Position to file number
-\fBcount\fR
+\fIcount\fR
(default: 0) where zero is beginning of tape. This is the same as a
\fBrewind\fR
followed by a
-\fBfsf\fR\fBcount\fR.
-.TP
+\fBfsf\fR
+\fIcount\fR.
+.RE
+.PP
\fBrewind\fR
+.RS 4
Rewind to beginning of tape.
-.TP
+.RE
+.PP
\fBoffline|rewoffl\fR
+.RS 4
Rewind to beginning of tape and unload the tape from the drive.
-.TP
+.RE
+.PP
\fBstatus\fR
+.RS 4
Report status information about the drive. Which data reported, and what it means, depends on the underlying operating system, and may include:
-.RS
-.TP
+.RS 4
+.PP
ONLINE
+.RS 4
Indicates the drive is online and ready.
-.TP
+.RE
+.PP
OFFLINE
+.RS 4
Indicates the drive is offline or not ready.
-.TP
+.RE
+.PP
BOT
+.RS 4
Indicates the drive is at beginning of tape.
-.TP
+.RE
+.PP
EOT
+.RS 4
Indicates the drive is at end of tape.
-.TP
+.RE
+.PP
PROTECTED
+.RS 4
Indicates the tape is write protected.
-.TP
+.RE
+.PP
ds
+.RS 4
Device status.
-.TP
+.RE
+.PP
er
+.RS 4
Error register.
-.TP
+.RE
+.PP
fileno
+.RS 4
Current tape file number.
-.TP
+.RE
+.PP
blkno
+.RS 4
Current tape block number file.
.RE
+.RE
+.RE
.sp
.it 1 an-trap
.nr an-no-space-flag 1
.nr an-break-flag 1
.br
\fBNote\fR
-Many systems only report good data when a tape is in the drive and ready.
.PP
-
+Many systems only report good data when a tape is in the drive and ready.
.SH "AUTHOR"
.PP
Marc Mengel
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMOVERVIEW" 8 "" "" ""
+.\" Title: amoverview
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMOVERVIEW" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amoverview - display file systems processed by Amanda over time
+amoverview \- display file systems processed by Amanda over time
.SH "SYNOPSIS"
.HP 11
-\fBamoverview\fR [[-config ] \fIconfig\fR] [-hostwidth \fIwidth\fR] [-diskwidth \fIwidth\fR] [-skipmissed] [-last] [-num0] [-togo0] [-verbose]
+\fBamoverview\fR [[\-config\ ]\ \fIconfig\fR] [\-hostwidth\ \fIwidth\fR] [\-diskwidth\ \fIwidth\fR] [\-skipmissed] [\-last] [\-num0] [\-togo0] [\-verbose]
.SH "DESCRIPTION"
.PP
\fBAmoverview\fR
displays a chart showing hosts and file systems processed by
-\fBAmanda\fR
+\fIAmanda\fR
along with the backup level performed each day.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-config\fR \fIconfig\fR
+.PP
+\fB\-config\fR \fIconfig\fR
+.RS 4
Use configuration
-\fBconfig\fR
+\fIconfig\fR
instead of configuration daily.
-.TP
-\fB-hostwidth\fR \fIwidth\fR
+.RE
+.PP
+\fB\-hostwidth\fR \fIwidth\fR
+.RS 4
Set
\fBhost\fR
field column width to
-\fBwidth\fR
+\fIwidth\fR
characters instead of 8.
-.TP
-\fB-diskwidth\fR \fIwidth\fR
+.RE
+.PP
+\fB\-diskwidth\fR \fIwidth\fR
+.RS 4
Set
\fBdisk\fR
field column width to
-\fBwidth\fR
+\fIwidth\fR
characters instead of 20.
-.TP
-\fB-skipmissed\fR
+.RE
+.PP
+\fB\-skipmissed\fR
+.RS 4
Compacts the output by only printing stats for the days
-\fBAmanda\fR
+\fIAmanda\fR
actually ran.
-.TP
-\fB-last\fR
+.RE
+.PP
+\fB\-last\fR
+.RS 4
Outputs the last status of each disk at the start. Useful for long tapecycles and/or sparse reports.
-.TP
-\fB-num0\fR
+.RE
+.PP
+\fB\-num0\fR
+.RS 4
Outputs the number of level 0 dumps for each disk.
-.TP
-\fB-togo0\fR
+.RE
+.PP
+\fB\-togo0\fR
+.RS 4
Outputs the number of runs until the last level 0 dump is overwritten.
-.TP
-\fB-verbose\fR
+.RE
+.PP
+\fB\-verbose\fR
+.RS 4
\fBAmoverview\fR
can take a long while on large systems. This option reports intermediate steps while it is working.
+.RE
.SH "RESULTS"
.PP
\fBamoverview\fR
.PP
A number indicates the level of backup and it succeeded. An "E" indicates an error for that day. You get an "E" for all errors, like failed to connect, datatimeout, computer crashed, etc, but also for failing to write to tape.
.PP
-You can have an "E" followed by a number if a filesystem ran into end-of-tape once (gives an "E", and later that day, you flush it to a second tape (a number: the level, indicating success). If the flush failed too, you get a double "EE" for that day.
+You can have an "E" followed by a number if a filesystem ran into end\-of\-tape once (gives an "E", and later that day, you flush it to a second tape (a number: the level, indicating success). If the flush failed too, you get a double "EE" for that day.
.PP
You can also have a double code if you have two tapes in the changer and
-\fBAmanda\fR
+\fIAmanda\fR
failed to write to tape the first time because it hit end of tape (resulting in "E0", for a full, "E1" for an incremental etc.) or twice with error ("EE"), and may a successful flush afterwards giving maybe "EE0". (Only the latest 2 characters are printed).
.SH "EXAMPLE"
.PP
This shows the
\fI/home\fR
file system on
-\fBhost2\fR
+\fIhost2\fR
was backed up at level 3 on the 8th, 9th and 10th of December, had a full backup on the 11th, a level 1 on the 12th and a level 2 on the 13th.
+.sp
+.RS 4
.nf
-
# amoverview
date 12 12 12 12 12 12
host disk 08 09 10 11 12 13
host2 /opt 1 1 1 1 1 1
host2 /var 1 1 0 1 1 1
.fi
+.RE
.SH "SEE ALSO"
.PP
\fBamadmin\fR(8),
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMPLOT" 8 "" "" ""
+.\" Title: amplot
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMPLOT" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amplot - visualize the behavior of Amanda
+amplot \- visualize the behavior of Amanda
.SH "SYNOPSIS"
.HP 7
-\fBamplot\fR [-b] [-c] [-e] [-g] [-l] [-p] [-t \fIT\fR] \fIamdump_files\fR
+\fBamplot\fR [\-b] [\-c] [\-e] [\-g] [\-l] [\-p] [\-t\ \fIT\fR] \fIamdump_files\fR
.br
.SH "DESCRIPTION"
reads an
\fBamdump\fR
output file that
-\fBAmanda\fR
+\fIAmanda\fR
generates each run (e.g.
-\fBamdump.1\fR) and translates the information into a picture format that may be used to determine how your installation is doing and if any parameters need to be changed.
+\fIamdump.1\fR) and translates the information into a picture format that may be used to determine how your installation is doing and if any parameters need to be changed.
\fBAmplot\fR
also prints out
\fBamdump\fR
is a shell script that executes an
\fBawk\fR
program
-\fB\fR(\fBamplot.awk\fR) to scan the
+(\fIamplot.awk\fR) to scan the
\fBamdump\fR
output file. It then executes a
\fBgnuplot\fR
program
-\fB\fR(\fBamplot.g\fR) to generate the graph. The
+(\fIamplot.g\fR) to generate the graph. The
\fBawk\fR
program is written in an enhanced version of awk, such as GNU awk
-\fB\fR(\fBgawk\fR
+(\fIgawk\fR
version 2.15 or later) or
\fBnawk\fR.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-b\fR
+.PP
+\fB\-b\fR
+.RS 4
Generate b/w postscript file (need
-\fB-p\fR).
-.TP
-\fB-c\fR
+\fB\-p\fR).
+.RE
+.PP
+\fB\-c\fR
+.RS 4
Compress
-\fBamdump_files\fR
+\fIamdump_files\fR
after plotting.
-.TP
-\fB-e\fR
+.RE
+.PP
+\fB\-e\fR
+.RS 4
Extend the X (time) axis if needed.
-.TP
-\fB-g\fR
+.RE
+.PP
+\fB\-g\fR
+.RS 4
Direct
-\fBgnuplot\fR
+\fIgnuplot\fR
output directly to the X11 display (default).
-.TP
-\fB-p\fR
+.RE
+.PP
+\fB\-p\fR
+.RS 4
Direct postscript output to file
-\fB\fR\fBYYYYMMDD\fR\fB.ps\fR
+\fIYYYYMMDD\fR\fI.ps\fR
(opposite of
-\fB-g\fR).
-.TP
-\fB-l\fR
+\fB\-g\fR).
+.RE
+.PP
+\fB\-l\fR
+.RS 4
Generate landscape oriented output (needs
-\fB-p\fR).
-.TP
-\fB-t \fR\fBT\fR
+\fB\-p\fR).
+.RE
+.PP
+\fB\-t \fR\fIT\fR
+.RS 4
Set the right edge of the plot to be
-\fBT\fR
+\fIT\fR
hours.
+.RE
.PP
The
-\fBamdump_files\fR
+\fIamdump_files\fR
may be in various compressed formats
-\fB\fR(\fBcompress\fR,
+(\fIcompress\fR,
\fBgzip\fR,
\fBpact\fR,
\fBcompact\fR).
\fBamdump\fR
was started. The Y axis is divided into 5 regions:
.PP
-\fBQUEUES:\fR
+\fIQUEUES:\fR
How many backups have not been started, how many are waiting on space in the holding disk and how many have been transferred successfully to tape.
.PP
-\fB%BANDWIDTH:\fR
+\fI%BANDWIDTH:\fR
Percentage of allowed network bandwidth in use.
.PP
-\fBHOLDING DISK:\fR
+\fIHOLDING DISK:\fR
The higher line depicts space allocated on the holding disk to backups in progress and completed backups waiting to be written to tape. The lower line depicts the fraction of the holding disk containing completed backups waiting to be written to tape including the file currently being written to tape. The scale is percentage of the holding disk.
.PP
-\fBTAPE:\fR
+\fITAPE:\fR
Tape drive usage.
.PP
-\fB%DUMPERS:\fR
+\fI%DUMPERS:\fR
Percentage of active dumpers.
.PP
The idle period at the left of the graph is time
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "BUGS"
.PP
Reports lines it does not recognize, mainly error cases but some are legitimate lines the program needs to be taught about.
\fBsh\fR(1),
\fBcompress\fR(1),
\fBgzip\fR(1)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMRECOVER" 8 "" "" ""
+.\" Title: amrecover
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMRECOVER" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amrecover - Amanda index database browser
+amrecover \- Amanda index database browser
.SH "SYNOPSIS"
.HP 10
-\fBamrecover\fR [[-C] \fIconfig\fR] [-s \fIindex-server\fR] [-t \fItape-server\fR] [-d \fItape-device\fR] [-o \fIclientconfigoption\fR]*
-
+\fBamrecover\fR [\-C\ \fIconfig\fR] [\-s\ \fIindex\-server\fR] [\-t\ \fItape\-server\fR] [\-d\ \fItape\-device\fR] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmrecover\fR
browses the database of
-\fBAmanda\fR
+\fIAmanda\fR
index files to determine which tapes contain files to recover. Furthermore, it is able to recover files.
.PP
In order to restore files in place, you must invoke
to move into that directory, otherwise a directory tree that resembles the backed up filesystem will be created in the current directory. See the examples below for details.
.PP
Amrecover will read the
-\fBamanda-client.conf\fR
+\fBamanda\-client.conf\fR
file and the
-\fIconfig\fR\fB/amanda-client.conf\fR
+\fIconfig\fR\fB/amanda\-client.conf\fR
file.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
.sp
.it 1 an-trap
.nr an-break-flag 1
.br
\fBNote\fR
-The Default values are those set at compile-time.
-Use \fBamrestore\fR to recover client-encrypted or
-client-custom-compressed tapes..TP
-\fB[ -C ] config\fR
-\fBAmanda\fR
+.PP
+The Default values are those set at compile\-time. Use
+\fBamrestore\fR
+to recover client\-encrypted or client\-custom\-compressed tapes.
+.PP
+\fB[ \-C ] config\fR
+.RS 4
+\fIAmanda\fR
configuration.
-.TP
-\fB-s index-server\fR
+.RE
+.PP
+\fB\-s index\-server\fR
+.RS 4
Host that runs the index daemon.
-.TP
-\fB-t tape-server\fR
+.RE
+.PP
+\fB\-t tape\-server\fR
+.RS 4
Host that runs the tape server daemon.
-.TP
-\fB-d tape-device\fR
+.RE
+.PP
+\fB\-d tape\-device\fR
+.RS 4
Tape device to use on the tape server host.
-.TP
-\fB-o\fR \fIclientconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIclientconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "COMMANDS"
.PP
\fBAmrecover\fR
\fBamrecover\fR.
.PP
The purpose of browsing the database is to build up a
-\fBrestore list\fR
+\fIrestore list\fR
of files to be extracted from the backup system. The following commands are available:
-.TP
+.PP
\fBsethost hostname\fR
+.RS 4
Specifies which host to look at backup files for (default: the local host).
-.TP
-\fBsetdate YYYY-MM-DD-HH-MM[-SS] | YYYY-MM-DD\fR
+.RE
+.PP
+\fBsetdate YYYY\-MM\-DD\-HH\-MM[\-SS] | YYYY\-MM\-DD\fR
+.RS 4
Set the restore time (default: now). File listing commands only return information on backup images for this day, for the day before with the next lower dump level, and so on, until the most recent level 0 backup on or before the specified date is encountered.
.sp
For example, if:
.sp
+.RS 4
.nf
-
-1996-07-01 was a level 0 backup
-1996-07-02 through 1996-07-05 were level 1 backups
-1996-07-06 through 1997-07-08 were level 2 backups
-
+1996\-07\-01 was a level 0 backup
+1996\-07\-02 through 1996\-07\-05 were level 1 backups
+1996\-07\-06 through 1997\-07\-08 were level 2 backups
.fi
+.RE
.sp
then the command
-\fBsetdate 1997-07-08-00\fR
+\fBsetdate 1997\-07\-08\-00\fR
would yield files from the following days:
.sp
+.RS 4
.nf
-
-1997-07-08 (the latest level 2 backup)
-1997-07-05 (the latest level 1 backup)
-1997-07-01 (the latest level 0 backup)
-
+1997\-07\-08 (the latest level 2 backup)
+1997\-07\-05 (the latest level 1 backup)
+1997\-07\-01 (the latest level 0 backup)
.fi
+.RE
.sp
Only the most recent version of a file will be presented.
.sp
The following abbreviated date specifications are accepted:
-.RS
-.TP
-\fB--MM-DD\fR
+.RS 4
+.PP
+\fB\-\-MM\-DD\fR
+.RS 4
dates in the current year
-.TP
-\fB---DD\fR
+.RE
+.PP
+\fB\-\-\-DD\fR
+.RS 4
dates in the current month of the current year
.RE
-.TP
-\fBsetdisk \fIdiskname\fR [\fImountpoint\fR]\fR
+.RE
+.RE
+.PP
+\fBsetdisk \fR\fIdiskname\fR [\fImountpoint\fR]
+.RS 4
Specifies which disk to consider (default: the disk holding the working directory where
\fBamrecover\fR
is started). It can only be set after the host is set with
\fBsethost\fR.
-\fBDiskname\fR
+\fIDiskname\fR
is the device name specified in the
-\fBamanda.conf\fR
+\fIamanda.conf\fR
or
-\fBdisklist\fR
+\fIdisklist\fR
configuration file. The disk must be local to the host. If
-\fBmountpoint\fR
+\fImountpoint\fR
is not specified, all pathnames will be relative to the (unknown) mount point instead of full pathnames.
-.TP
-\fBlisthost [diskdevice]\fR
+.RE
+.PP
+\fBlisthost \fR[\fIdiskdevice\fR]
+.RS 4
List all
\fBhost\fR
-.TP
-\fBlistdisk [diskdevice]\fR
+.RE
+.PP
+\fBlistdisk \fR[\fIdiskdevice\fR]
+.RS 4
List all
\fBdiskname\fR
-.TP
-\fBsettape [[server]:][tapedev|default]\fR
-Specifies the host to use as the tape server, and which of its tape devices to use. If the server is omitted, but the colon is not, the server name reverts to the configure-time default. If the tape device is omitted, it remains unchanged. To use the default tape device selected by the tape server, the word
-\fBdefault\fR
+.RE
+.PP
+\fBsettape \fR[[\fIserver\fR]:][\fItapedev\fR|\fIdefault\fR]
+.RS 4
+Specifies the host to use as the tape server, and which of its tape devices to use. If the server is omitted, but the colon is not, the server name reverts to the configure\-time default. If the tape device is omitted, it remains unchanged. To use the default tape device selected by the tape server, the word
+\fIdefault\fR
must be specified. If no argument is specified, or the argument is an empty string, no changes occur, and the current settings are displayed.
.sp
If you want amrecover to use your changer, the
-\fBtapedev\fR
+\fItapedev\fR
must be equal to the amrecover_changer setting on the server.
.sp
If you need to change the protocol (tape:, rait:, file:, null:) then you must specify the hostname.
+.sp
+.RS 4
.nf
-
settape 192.168.0.10:file:/file1
.fi
+.RE
You can change the tape device when amrecover ask you to load the tape:
+.sp
+.RS 4
.nf
-
Load tape DMP014 now
Continue? [Y/n/t]: t
Tape device: server2:/dev/nst2
Continue? [Y/n/t]: Y
Using tape /dev/nst2 from server server2.
.fi
-.TP
-\fBsetmode mode\fR
+.RE
+.RE
+.PP
+\fBsetmode \fR\fImode\fR
+.RS 4
Set the extraction mode for Samba shares. If
-\fBmode\fR
+\fImode\fR
is
\fBsmb\fR, shares are sent to the Samba server to be restored back onto the PC. If
-\fBmode\fR
+\fImode\fR
is
\fBtar\fR, they are extracted on the local machine the same way tar volumes are extracted.
-.TP
+.RE
+.PP
\fBmode\fR
+.RS 4
Displays the extracting mode for Samba shares.
-.TP
+.RE
+.PP
\fBhistory\fR
+.RS 4
Show the backup history of the current host and disk. Dates, levels, tapes and file position on tape of each backup are displayed.
-.TP
+.RE
+.PP
\fBpwd\fR
+.RS 4
Display the name of the current backup working directory.
-.TP
+.RE
+.PP
\fBcd dir\fR
+.RS 4
Change the backup working directory to
-\fBdir.\fR
+\fIdir.\fR
If the mount point was specified with
\fBsetdisk\fR, this can be a full pathname or it can be relative to the current backup working directory. If the mount point was not specified, paths are relative to the mount point if they start with "/", otherwise they are relative to the current backup working directory. The
-\fBdir\fR
+\fIdir\fR
can be a shell style wildcards.
-.TP
-\fBcdx dir\fR
+.RE
+.PP
+\fBcdx \fR\fIdir\fR
+.RS 4
Like the
\fBcd\fR
command but allow regular expression.
-.TP
+.RE
+.PP
\fBlpwd\fR
+.RS 4
Display the
\fBamrecover\fR
working directory. Files will be restored under this directory, relative to the backed up filesystem.
-.TP
-\fBlcd path\fR
+.RE
+.PP
+\fBlcd \fR\fIpath\fR
+.RS 4
Change the
\fBamrecover\fR
working directory to
-\fBpath\fR.
-.TP
+\fIpath\fR.
+.RE
+.PP
\fBls\fR
+.RS 4
List the contents of the current backup working directory. See the description of the
\fBsetdate\fR
command for how the view of the directory is built up. The backup date is shown for each file.
-.TP
-\fBadd item1 item2 ...\fR
+.RE
+.PP
+\fBadd \fR\fIitem1 item2 ...\fR
+.RS 4
Add the specified files or directories to the restore list. Each item may have shell style wildcards.
-.TP
-\fBaddx item1 item2 ...\fR
+.RE
+.PP
+\fBaddx \fR\fIitem1 item2 ...\fR
+.RS 4
Add the specified files or directories to the restore list. Each item may be a regular expression.
-.TP
-\fBdelete item1 item2 ...\fR
+.RE
+.PP
+\fBdelete \fR\fIitem1 item2 ...\fR
+.RS 4
Delete the specified files or directories from the restore list. Each item may have shell style wildcards.
-.TP
-\fBdeletex item1 item2 ...\fR
+.RE
+.PP
+\fBdeletex \fR\fIitem1 item2 ...\fR
+.RS 4
Delete the specified files or directories from the restore list. Each item may be a regular expression.
-.TP
-\fBlist file\fR
+.RE
+.PP
+\fBlist \fR\fIfile\fR
+.RS 4
Display the contents of the restore list. If a file name is specified, the restore list is written to that file. This can be used to manually extract the files from the
-\fBAmanda\fR
+\fIAmanda\fR
tapes with
\fBamrestore\fR.
-.TP
+.RE
+.PP
\fBclear\fR
+.RS 4
Clear the restore list.
-.TP
+.RE
+.PP
\fBquit\fR
+.RS 4
Close the connection to the index server and exit.
-.TP
+.RE
+.PP
\fBexit\fR
+.RS 4
Close the connection to the index server and exit.
-.TP
+.RE
+.PP
\fBextract\fR
+.RS 4
Start the extract sequence (see the examples below). Make sure the local working directory is the root of the backed up filesystem, or another directory that will behave like that. Use
\fBlpwd\fR
to display the local working directory, and
\fBlcd\fR
to change it.
-.TP
+.RE
+.PP
\fBhelp\fR
+.RS 4
Display a brief list of these commands.
+.RE
.SH "EXAMPLES"
.PP
The following shows the recovery of an old
-\fBsyslog\fR
+\fIsyslog\fR
file.
+.sp
+.RS 4
.nf
-
# cd /var/log
-# ls -l syslog.7
+# ls \-l syslog.7
syslog.7: No such file or directory
# amrecover
AMRECOVER Version 2.4.2. Contacting server on oops ...
-220 oops \fBAmanda\fR index server (2.4.2) ready.
-Setting restore date to today (1997-12-09)
-200 Working date set to 1997-12-09.
+220 oops \fIAmanda\fR index server (2.4.2) ready.
+Setting restore date to today (1997\-12\-09)
+200 Working date set to 1997\-12\-09.
200 Config set to daily.
-200 Dump host set to this-host.some.org.
+200 Dump host set to this\-host.some.org.
$CWD '/var/log' is on disk '/var' mounted at '/var'.
200 Disk set to /var.
/var/log
-WARNING: not on root of selected filesystem, check man-page!
+WARNING: not on root of selected filesystem, check man\-page!
amrecover> ls
-1997-12-09 daemon.log
-1997-12-09 syslog
-1997-12-08 authlog
-1997-12-08 sysidconfig.log
-1997-12-08 syslog.0
-1997-12-08 syslog.1
-1997-12-08 syslog.2
-1997-12-08 syslog.3
-1997-12-08 syslog.4
-1997-12-08 syslog.5
-1997-12-08 syslog.6
-1997-12-08 syslog.7
+1997\-12\-09 daemon.log
+1997\-12\-09 syslog
+1997\-12\-08 authlog
+1997\-12\-08 sysidconfig.log
+1997\-12\-08 syslog.0
+1997\-12\-08 syslog.1
+1997\-12\-08 syslog.2
+1997\-12\-08 syslog.3
+1997\-12\-08 syslog.4
+1997\-12\-08 syslog.5
+1997\-12\-08 syslog.6
+1997\-12\-08 syslog.7
amrecover> add syslog.7
Added /log/syslog.7
amrecover> lpwd
set owner/mode for '.'? [yn] n
amrecover> quit
200 Good bye.
-# ls -l syslog.7
+# ls \-l syslog.7
total 26
--rw-r--r-- 1 root other 12678 Oct 14 16:36 syslog.7
+\-rw\-r\-\-r\-\- 1 root other 12678 Oct 14 16:36 syslog.7
.fi
+.RE
.PP
If you do not want to overwrite existing files, create a subdirectory to run
\fBamrecover\fR
from and then move the restored files afterward.
+.sp
+.RS 4
.nf
-
# cd /var
# (umask 077 ; mkdir .restore)
# cd .restore
# amrecover
AMRECOVER Version 2.4.2. Contacting server on oops ...
-...
+\&...
amrecover> cd log
/var/log
amrecover> ls
-...
+\&...
amrecover> add syslog.7
Added /log/syslog.7
amrecover> lpwd
amrecover> extract
Extracting files using tape drive /dev/nst0 on host 192.168.0.10
-...
+\&...
amrecover> quit
200 Good bye.
-# mv -i log/syslog.7 ../log/syslog.7-restored
+# mv \-i log/syslog.7 ../log/syslog.7\-restored
# cd ..
-# rm -fr .restore
+# rm \-fr .restore
.fi
+.RE
.PP
If you need to run
\fBamrestore\fR
control it, use the
\fBlist\fR
command after browsing to display the needed tapes.
+.sp
+.RS 4
.nf
-
# cd /var/log
# amrecover
AMRECOVER Version 2.4.2. Contacting server on oops ...
-...
+\&...
amrecover> ls
-...
+\&...
amrecover> add syslog syslog.6 syslog.7
Added /log/syslog
Added /log/syslog.6
Added /log/syslog.7
amrecover> list
-TAPE DMP014 LEVEL 0 DATE 1997-12-08
+TAPE DMP014 LEVEL 0 DATE 1997\-12\-08
/log/syslog.7
/log/syslog.6
-TAPE DMP015 LEVEL 1 DATE 1997-12-09
+TAPE DMP015 LEVEL 1 DATE 1997\-12\-09
/log/syslog
amrecover> quit
.fi
+.RE
.PP
The
\fBhistory\fR
command shows each tape that has a backup of the current disk along with the date of the backup, the level, the tape label and the file position on the tape. All active tapes are listed, not just back to the most recent full dump.
.PP
Tape file position zero is a label. The first backup image is in file position one.
+.sp
+.RS 4
.nf
-
# cd /var/log
# amrecover
AMRECOVER Version 2.4.2. Contacting server on oops ...
-...
+\&...
amrecover> history
-200- Dump history for config "daily" host "this-host.some.org" disk "/var"
-201- 1997-12-09 1 DMP015 9
-201- 1997-12-08 1 DMP014 11
-201- 1997-12-07 0 DMP013 22
-201- 1997-12-06 1 DMP012 16
-201- 1997-12-05 1 DMP011 9
-201- 1997-12-04 0 DMP010 11
-201- 1997-12-03 1 DMP009 7
-201- 1997-12-02 1 DMP008 7
-201- 1997-12-01 1 DMP007 9
-201- 1997-11-30 1 DMP006 6
-...
+200\- Dump history for config "daily" host "this\-host.some.org" disk "/var"
+201\- 1997\-12\-09 1 DMP015 9
+201\- 1997\-12\-08 1 DMP014 11
+201\- 1997\-12\-07 0 DMP013 22
+201\- 1997\-12\-06 1 DMP012 16
+201\- 1997\-12\-05 1 DMP011 9
+201\- 1997\-12\-04 0 DMP010 11
+201\- 1997\-12\-03 1 DMP009 7
+201\- 1997\-12\-02 1 DMP008 7
+201\- 1997\-12\-01 1 DMP007 9
+201\- 1997\-11\-30 1 DMP006 6
+\&...
amrecover> quit
.fi
+.RE
.SH "ENVIRONMENT"
.PP
-\fBPAGER\fRThe
+\fBPAGER\fR
+The
\fBls\fR
and
\fBlist\fR
commands will use $PAGER to display the file lists. Defaults to
-\fBmore\fR
+\fImore\fR
if PAGER is not set.
.PP
\fBAMANDA_SERVER\fR
-If set, $AMANDA_SERVER will be used as index-server. The value will take precedence over the compiled default, but will be overridden by the -s switch.
+If set, $AMANDA_SERVER will be used as index\-server. The value will take precedence over the compiled default, but will be overridden by the \-s switch.
.PP
\fBAMANDA_TAPE_SERVER\fR
-If set, $AMANDA_TAPE_SERVER will be used as tape-server. The value will take precedence over the compiled default, but will be overridden by the -t switch.
+If set, $AMANDA_TAPE_SERVER will be used as tape\-server. The value will take precedence over the compiled default, but will be overridden by the \-t switch.
.SH "AUTHOR"
.PP
Alan M. McIvor
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
-\fBamanda-client.conf\fR(5),
+\fBamanda\-client.conf\fR(5),
\fBamrestore\fR(8),
\fBamfetchdump\fR(8),
\fBreadline\fR(3)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMREPORT" 8 "" "" ""
+.\" Title: amreport
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMREPORT" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amreport - generate a formatted output of statistics for an Amanda run
+amreport \- generate a formatted output of statistics for an Amanda run
.SH "SYNOPSIS"
.HP 9
-\fBamreport\fR [\fIconfig\fR] [-i] [-M \fIaddress\fR] [-l \fIlogfile\fR] [-f \fIoutputfile\fR] [-p \fIpostscriptfile\fR] [-o \fIconfigoption\fR]*
-
+\fBamreport\fR [\fIconfig\fR] [\-i] [\-M\ \fIaddress\fR] [\-l\ \fIlogfile\fR] [\-f\ \fIoutputfile\fR] [\-p\ \fIpostscriptfile\fR] [\-o\ \fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmreport\fR
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fBconfig\fR
+.PP
+\fIconfig\fR
+.RS 4
Name of the configuration to process.
-.TP
-\fB-i\fR
+.RE
+.PP
+\fB\-i\fR
+.RS 4
Don't email the report.
-.TP
-\fB-M\fR \fIaddress\fR
+.RE
+.PP
+\fB\-M\fR \fIaddress\fR
+.RS 4
Mail the report to
-\fBaddress\fR
+\fIaddress\fR
instead of the
\fBmailto\fR
value from
-\fBamanda.conf\fR.
-.TP
-\fB-l\fR \fIlogfile\fR
+\fIamanda.conf\fR.
+.RE
+.PP
+\fB\-l\fR \fIlogfile\fR
+.RS 4
Name of the log file to parse to generate the report. If a log file is not specified, it defaults to the file:
+.RE
.PP
-\fBlogdir\fR/log
+\fIlogdir\fR/log
.PP
where
-\fBlogdir\fR
+\fIlogdir\fR
is the log directory defined in amanda.conf.
-.TP
-\fB-f\fR \fIoutputfile\fR
+.PP
+\fB\-f\fR \fIoutputfile\fR
+.RS 4
Normally,
\fBamreport\fR
-sends the report via e-mail to the
-\fBmailto\fR
+sends the report via e\-mail to the
+\fImailto\fR
user as defined in the amanda.conf file. If
-\fBoutputfile\fR
+\fIoutputfile\fR
is specified, then the report is put in
-\fBoutputfile\fR.
-.TP
-\fB-p\fR \fIpostscriptfile\fR
+\fIoutputfile\fR.
+.RE
+.PP
+\fB\-p\fR \fIpostscriptfile\fR
+.RS 4
Send the postscript output to the file
-\fBpostscriptfile\fR
+\fIpostscriptfile\fR
instead of to the
\fBlpr\fR(1)
command. This option has an effect only if the
-\fBlbl-templ\fR
+\fIlbl\-templ\fR
directive is specified in amanda.conf.
-.TP
-\fB-o\fR \fIconfigoption\fR
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "LABEL PRINTING"
.PP
-\fBAmanda\fR
-can print postscript labels describing the contents of tape(s) written in a run. The labels are designed to be folded and inserted into the tape case along with the tape or hole punched and put in a 3-ring binder. Various label templates are provided to format data for different tape sizes.
+\fIAmanda\fR
+can print postscript labels describing the contents of tape(s) written in a run. The labels are designed to be folded and inserted into the tape case along with the tape or hole punched and put in a 3\-ring binder. Various label templates are provided to format data for different tape sizes.
.PP
-The information printed varies slightly between label templates due to size constraints. Labels contain one line for each host/file-system pair and may also contain the file number on the tape, the level of the dump, the original size of the dump and the size of the (possibly compressed) tape file.
+The information printed varies slightly between label templates due to size constraints. Labels contain one line for each host/file\-system pair and may also contain the file number on the tape, the level of the dump, the original size of the dump and the size of the (possibly compressed) tape file.
.PP
Add the
-\fBlbl-templ\fR
+\fIlbl\-templ\fR
parameter to the tapetype definition in amanda.conf to enable labels. If you don't add this line to your tapetype definition,
\fBamreport\fR
will not print tape labels.
.PP
You may use the
-\fBremap='I'>printer\fR
+\fIremap='I'>printer\fR
keyword in amanda.conf to print to other than the system default printer.
.SH "TEMPLATES"
.PP
-\fBAmanda\fR
+\fIAmanda\fR
provides label templates for the following tape types. These are pretty generic labels and should be easy to customize for other tape types or particular site needs.
.sp
+.RS 4
.nf
-
* ExaByte 8mm tapes
* DAT 4mm tapes
* DLT tapes
-* 3-ring binder
-
+* 3\-ring binder
.fi
+.RE
.sp
.PP
-The 3-ring binder type is the most generic. It may be used to make a hardcopy log of the tapes.
+The 3\-ring binder type is the most generic. It may be used to make a hardcopy log of the tapes.
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamflush\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMRESTORE" 8 "" "" ""
+.\" Title: amrestore
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMRESTORE" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amrestore - extract backup images from an Amanda tape
+amrestore \- extract backup images from an Amanda tape
.SH "SYNOPSIS"
.HP 10
-\fBamrestore\fR [-r -c -C] [-b \fIblocksize\fR] [-f \fIfileno\fR] [-l \fIlabel\fR] [-p] [-h] \fItapedevice\fR|Â \fIholdingfile\fR [\fIhostname\fR [\fIdiskname\fR [\fIdatestamp\fR [\fIhostname\fR [\fIdiskname\fR [\fIdatestamp\fR ...]]]]]]
+\fBamrestore\fR [\-r | \-c | \-C] [\-b | \fIblocksize\fR] [\-f | \fIfileno\fR] [\-l | \fIlabel\fR] [\-p] [\-h] \fItapedevice\fR|\ \fIholdingfile\fR [\fIhostname\fR [\fIdiskname\fR [\fIdatestamp\fR [\fIhostname\fR [\fIdiskname\fR [\fIdatestamp\fR | ...]]]]]]
.SH "DESCRIPTION"
.PP
\fBAmrestore\fR
extracts backup images from the tape mounted on
-\fBtapedevice\fR
+\fItapedevice\fR
or from the holding disk file
-\fBholdingfile\fR
+\fIholdingfile\fR
that match
-\fBhostname\fR,
-\fBdiskname\fR
+\fIhostname\fR,
+\fIdiskname\fR
and
-\fBdatestamp\fR
+\fIdatestamp\fR
patterns given on the command line. The tape or holding file must be in a format written by the
\fBamdump\fR
or
program.
.PP
If
-\fBdiskname\fR
+\fIdiskname\fR
is not specified, all backups on the tape for the previous
-\fBhostname\fR
+\fIhostname\fR
are candidates. If
-\fBdatestamp\fR
+\fIdatestamp\fR
is not specified, all backups on the tape for the previous
-\fBhostname\fR
+\fIhostname\fR
and
-\fBdiskname\fR
+\fIdiskname\fR
are candidates. If no
-\fBhostname\fR,
-\fBdiskname\fR
+\fIhostname\fR,
+\fIdiskname\fR
or
-\fBdatestamp\fR
+\fIdatestamp\fR
are specified, every backup on the tape is a candidate.
.PP
-\fBHostname\fR
+\fIHostname\fR
and
-\fBdiskname\fR
+\fIdiskname\fR
are special expressions described in the "HOST & DISK EXPRESSION" section of
\fBamanda\fR(8).
-\fBDatestamp\fR
+\fIDatestamp\fR
are special expression described in the "DATESTAMP EXPRESSION" section of
\fBamanda\fR(8). For example, if
-\fBdiskname\fR
+\fIdiskname\fR
is "rz[23]a", it would match disks
\fBrz2a\fR
and
\fBrz3a\fR.
.PP
-\fBDatestamp\fR
+\fIDatestamp\fR
is useful if
\fBamflush\fR
writes multiple backup runs to a single tape.
.PP
Unless
-\fB-p\fR
+\fB\-p\fR
is used, candidate backup images are extracted to files in the current directory named:
.PP
-\fBhostname.diskname.datestamp.dumplevel\fR
+\fIhostname.diskname.datestamp.dumplevel\fR
.PP
Amrestore doesn't use a changer, it restore from the tape already loaded in the
-\fBtapedevice.\fR
+\fItapedevice.\fR
.SH "OPTIONS"
-.TP
-\fB-b\fR
+.PP
+\fB\-b\fR
+.RS 4
Set the blocksize used to read the tape or holding file. All holding files must be read with a blocksize of 32 KBytes.
\fBAmrestore\fR
should normally be able to determine the blocksize for tapes on its own and not need this parameter.
+.RE
.PP
The default is 32 KBytes.
-.TP
-\fB-f\fR
+.PP
+\fB\-f\fR
+.RS 4
Do a rewind followed by a fsf <fileno> before trying to restore an image.
-.TP
-\fB-l\fR
+.RE
+.PP
+\fB\-l\fR
+.RS 4
Check if we restoring from the tape with the right
-\fBlabel\fR
-.TP
-\fB-p\fR
+\fIlabel\fR
+.RE
+.PP
+\fB\-p\fR
+.RS 4
Pipe output. The first matching backup image is sent to standard output, which is normally a pipe to
\fBrestore\fR
or
\fBtar\fR, then
\fBamrestore\fR
-quits. It may be run again to continue selecting backups to process. Make sure you specify the no-rewind
-\fBtapedevice\fR
+quits. It may be run again to continue selecting backups to process. Make sure you specify the no\-rewind
+\fItapedevice\fR
when doing this.
+.RE
.PP
Note:
\fBrestore\fR
may report "short read" errors when reading from a pipe. Most versions of
\fBrestore\fR
support a blocking factor option to let you set the read block size, and you should set it to 2. See the example below.
-.TP
-\fB-c\fR
+.PP
+\fB\-c\fR
+.RS 4
Compress output using the fastest method the compression program provides.
\fBAmrestore\fR
normally writes output files in a format understood by
\fBrestore\fR
or
\fBtar\fR, even if the backups on the tape are compressed. With the
-\fB-c\fR
+\fB\-c\fR
or
-\fB-C\fR
+\fB\-C\fR
option,
\fBamrestore\fR
writes all files in compressed format, even if the backups on the tape are not compressed. Output file names will have a
-.Z
+\fB.Z\fR
or
-.gz
+\fB.gz\fR
extension depending on whether
\fBcompress\fR
or
\fBgzip\fR
is the preferred compression program. This option is useful when the current directory disk is small.
-.TP
-\fB-C\fR
+.RE
+.PP
+\fB\-C\fR
+.RS 4
Compress output using the best method the compression program provides (may be very CPU intensive). See the notes above about the
-\fB-c\fR
+\fB\-c\fR
option.
-.TP
-\fB-r\fR
+.RE
+.PP
+\fB\-r\fR
+.RS 4
Raw output. Backup images are output exactly as they are on the tape, including the
\fBamdump\fR
headers. Output file names will have a
-.RAW
+\fB.RAW\fR
extension. This option is only useful for debugging and other strange circumstances.
-.TP
-\fB-h\fR
+.RE
+.PP
+\fB\-h\fR
+.RS 4
Header output. The tape header block is output at the beginning of each file. This is like
-\fB-r\fR
+\fB\-r\fR
except
-\fB-c\fR
+\fB\-c\fR
or
-\fB-C\fR
+\fB\-C\fR
may also be used to compress the result.
\fBAmrecover\fR
uses the header to determine the restore program to use.
+.RE
+.PP
+If a header is written (\-r or \-h), only 32 KBytes are output regardless of the tape blocksize. This makes the resulting image usable as a holding file.
.PP
-If a header is written (-r or -h), only 32 KBytes are output regardless of the tape blocksize. This makes the resulting image usable as a holding file.
-.TP
-\fB-o\fR \fIconfigoption\fR
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
See the "\fBCONFIGURATION OVERWRITE\fR" section in
\fBamanda\fR(8).
+.RE
.SH "EXAMPLES"
.PP
The following does an interactive restore of disk
-\fBrz3g\fR
+\fIrz3g\fR
from host
-\fBseine\fR, to restore particular files. Note the use of the
+\fIseine\fR, to restore particular files. Note the use of the
\fBb\fR
option to
-\fBrestore\fR, which causes it to read in units of two 512-byte blocks (1 Kbyte) at a time. This helps keep it from complaining about short reads.
+\fBrestore\fR, which causes it to read in units of two 512\-byte blocks (1 Kbyte) at a time. This helps keep it from complaining about short reads.
.sp
+.RS 4
.nf
-
-% amrestore -p /dev/nrmt9 seine rz3g | restore -ivbf 2 -
-
+% amrestore \-p /dev/nrmt9 seine rz3g | restore \-ivbf 2 \-
.fi
+.RE
.sp
.PP
The next example extracts all backup images for host
-\fBseine\fR. This is the usual way to extract all data for a host after a disk crash.
+\fIseine\fR. This is the usual way to extract all data for a host after a disk crash.
.sp
+.RS 4
.nf
-
% amrestore /dev/nrmt9 seine
-
.fi
+.RE
.sp
.PP
If the backup datestamp in the above example is
19910125
and
-\fBseine\fR
+\fIseine\fR
has level 0 backups of disks
-\fBrz1a\fR
+\fIrz1a\fR
and
-\fBrz1g\fR
+\fIrz1g\fR
on the tape, these files will be created in the current directory:
.sp
+.RS 4
.nf
-
seine.rz1a.19910125.0
seine.rz1g.19910125.0
-
.fi
+.RE
.sp
.PP
You may also use
\fBamrestore\fR
to extract a backup image from a holding disk file that has not yet been flushed to tape:
.sp
+.RS 4
.nf
-
-% amrestore -p /amanda/20001119/seine.rz1a.2 | restore -ivbf 2 -
-
+% amrestore \-p /amanda/20001119/seine.rz1a.2 | restore \-ivbf 2 \-
.fi
+.RE
.sp
.PP
\fBAmrestore\fR
may be used to generate a listing of images on a tape:
.sp
+.RS 4
.nf
-
-% mt -f /dev/nrmt9 rewind
-% amrestore -p /dev/nrmt9 no-such-host > /dev/null
-
+% mt \-f /dev/nrmt9 rewind
+% amrestore \-p /dev/nrmt9 no\-such\-host > /dev/null
.fi
+.RE
.sp
.PP
This asks
\fBamrestore\fR
to find images for host
-\fBno-such-host\fR. It will not find any entries that match, but along the way will report each image it skips.
+\fBno\-such\-host\fR. It will not find any entries that match, but along the way will report each image it skips.
.SH "CAVEATS"
.PP
-\fBGNU-tar\fR
+\fBGNU\-tar\fR
must be used to restore files from backup images created with the GNUTAR dumptype. Vendor tar programs sometimes fail to read GNU tar images.
.SH "AUTHOR"
.PP
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamdump\fR(8),
\fBamflush\fR(8),
-\fBtar\fR(1)\fBrestore\fR(8)
-
+\fBtar\fR(1)
+\fBrestore\fR(8)
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMRMTAPE" 8 "" "" ""
+.\" Title: amrmtape
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMRMTAPE" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amrmtape - remove a tape from the Amanda database
+amrmtape \- remove a tape from the Amanda database
.SH "SYNOPSIS"
.HP 9
-\fBamrmtape\fR [-n] [-v] [-q] [-d] \fIconfig\fR \fIlabel\fR
+\fBamrmtape\fR [\-n] [\-v] [\-q] [\-d] \fIconfig\fR \fIlabel\fR
.SH "DESCRIPTION"
.PP
\fBAmrmtape\fR
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-n\fR
+.PP
+\fB\-n\fR
+.RS 4
Generate new
-\fBtapelist\fR
+\fItapelist\fR
and database files with
-\fBlabel\fR
+\fIlabel\fR
removed, but leave them in
\fI/tmp\fR
and do not update the original copies.
-.TP
-\fB-v\fR
+.RE
+.PP
+\fB\-v\fR
+.RS 4
List backups of hosts and disks that are being discarded. Enabled by default.
-.TP
-\fB-q\fR
+.RE
+.PP
+\fB\-q\fR
+.RS 4
Opposite of
-\fB-v\fR.
-.TP
-\fB-d\fR
+\fB\-v\fR.
+.RE
+.PP
+\fB\-d\fR
+.RS 4
Run in debugging mode so all executed commands are shown.
+.RE
.SH "EXAMPLE"
.PP
Remove tape labeled
-\fBDAILY034\fR
+\fIDAILY034\fR
from the
-\fBDailySet1\fR
+\fIDailySet1\fR
configuration.
+.sp
+.RS 4
.nf
-
# amrmtape DailySet1 DAILY034
.fi
+.RE
.SH "AUTHOR"
.PP
-Adrian T. Filipi-Martin
+Adrian T. Filipi\-Martin
<atf3r@cs.virginia.edu>: Original text
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamadmin\fR(8),
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMSTATUS" 8 "" "" ""
+.\" Title: amstatus
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMSTATUS" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amstatus - display the state of an Amanda run
+amstatus \- display the state of an Amanda run
.SH "SYNOPSIS"
.HP 9
-\fBamstatus\fR [--config] \fIconfig\fR [--file \fIamdumpfile\fR] [--summary] [--dumping] [--waitdumping] [--waittaper] [--dumpingtape] [--writingtape] [--finished] [--failed] [--estimate] [--gestimate] [--stats]
+\fBamstatus\fR [\-\-config] \fIconfig\fR [\-\-file\ \fIamdumpfile\fR] [\-\-summary] [\-\-dumping] [\-\-waitdumping] [\-\-waittaper] [\-\-dumpingtape] [\-\-writingtape] [\-\-finished] [\-\-failed] [\-\-estimate] [\-\-gestimate] [\-\-stats]
.SH "DESCRIPTION"
.PP
\fBAmstatus\fR
gives the current state of the
-\fBAmanda\fR
+\fIAmanda\fR
run specified by the
-\fBconfig\fR
+\fIconfig\fR
configuration. If there is no active
-\fBAmanda\fR
+\fIAmanda\fR
running, it summarizes the result of the last run. It may also be used to summarize the results of a previous run.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
.PP
-All options may be abbreviated to the shortest non-ambiguous sub-string. If no options are given, everything is displayed.
-.TP
-\fB[--config] config\fR
+All options may be abbreviated to the shortest non\-ambiguous sub\-string. If no options are given, everything is displayed.
+.PP
+\fB[\-\-config] config\fR
+.RS 4
Specify the
-\fBAmanda\fR
+\fIAmanda\fR
configuration you want to display the state for.
-.TP
-\fB--file amdumpfile\fR
+.RE
+.PP
+\fB\-\-file amdumpfile\fR
+.RS 4
Specify an alternate file instead of the
-\fBamdump\fR
+\fIamdump\fR
or
-\fBamflush\fR
+\fIamflush\fR
file.
-.TP
-\fB--summary\fR
+.RE
+.PP
+\fB\-\-summary\fR
+.RS 4
Display a summary of the state of the run.
-.TP
-\fB--dumping\fR
+.RE
+.PP
+\fB\-\-dumping\fR
+.RS 4
Display all partitions that are dumping.
-.TP
-\fB--waitdumping|wdumping\fR
+.RE
+.PP
+\fB\-\-waitdumping|wdumping\fR
+.RS 4
Display all partitions that are waiting to be dumped.
-.TP
-\fB--waittaper|wtaper\fR
+.RE
+.PP
+\fB\-\-waittaper|wtaper\fR
+.RS 4
Display all partitions dumped that are waiting to be written to tape.
-.TP
-\fB--dumpingtape|dtape\fR
+.RE
+.PP
+\fB\-\-dumpingtape|dtape\fR
+.RS 4
Display all partitions that are dumping directly to tape.
-.TP
-\fB--writingtape|wtape\fR
+.RE
+.PP
+\fB\-\-writingtape|wtape\fR
+.RS 4
Display all partitions that are writing to tape.
-.TP
-\fB--finished\fR
+.RE
+.PP
+\fB\-\-finished\fR
+.RS 4
Display all partitions that are dumped and written to tape.
-.TP
-\fB--failed|error\fR
+.RE
+.PP
+\fB\-\-failed|error\fR
+.RS 4
Display all partitions that failed.
-.TP
-\fB--estimate\fR
+.RE
+.PP
+\fB\-\-estimate\fR
+.RS 4
Display all partitions whose estimate is finished. Works only during the estimate phase.
-.TP
-\fB--gestimate|gettingestimate\fR
+.RE
+.PP
+\fB\-\-gestimate|gettingestimate\fR
+.RS 4
Display all partitions whose estimate is not finished. Works only during the estimate phase.
-.TP
-\fB--stats|statistics\fR
-Display statistics about active-time of taper and dumpers.
+.RE
+.PP
+\fB\-\-stats|statistics\fR
+.RS 4
+Display statistics about active\-time of taper and dumpers.
+.RE
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
\fBamdump\fR(8),
\fBamrestore\fR(8),
\fBamadmin\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMTAPE" 8 "" "" ""
+.\" Title: amtape
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMTAPE" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amtape - user interface to Amanda tape changer controls
+amtape \- user interface to Amanda tape changer controls
.SH "SYNOPSIS"
.HP 7
-\fBamtape\fR \fIconfig\fR \fIcommand\fR [\fIcommand\fRÂ \fIoptions\fR]
+\fBamtape\fR \fIconfig\fR \fIcommand\fR [\fIcommand_options\fR...] [\fB\-o\ \fR\fIconfigoption\fR]...
.SH "DESCRIPTION"
.PP
\fBAmtape\fR
performs tape changer control operations. It uses the underlying tape changer script defined by the
\fBtpchanger\fR
option for a particular
-\fBAmanda\fR
+\fIAmanda\fR
configuration as specified by the
-\fBconfig\fR
+\fIconfig\fR
argument.
.PP
Tape changers maintain a notion of the
-\fBcurrent\fR
+\fIcurrent\fR
and
-\fBnext\fR
+\fInext\fR
slot for each configuration. These may or may not correspond to an actual physical state of the device, but do tend to minimize searching through the tape storage slots. If the desired tape is in the current slot, it is likely the next tape needed is in the next slot rather than at some random position in the storage slots.
.PP
See the
\fBamanda\fR(8)
man page for more details about
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "COMMANDS"
-.TP
+.PP
\fBreset\fR
+.RS 4
Reset the tape changer to a known state. The
-\fBcurrent\fR
+\fIcurrent\fR
slot is set to the
-\fBfirst\fR
-slot. Other device-specific side effects may occur. Some gravity stackers need to be reset to the top position by hand. This command notifies
-\fBAmanda\fR
+\fIfirst\fR
+slot. Other device\-specific side effects may occur. Some gravity stackers need to be reset to the top position by hand. This command notifies
+\fIAmanda\fR
the stacker is back in that position.
-.TP
+.RE
+.PP
\fBeject\fR
+.RS 4
If a tape is loaded in the drive, it is ejected and returned to the slot from which it was loaded.
-.TP
+.RE
+.PP
\fBclean\fR
+.RS 4
If a cleaning tape is defined for the changer, it is used to clean the drive.
-.TP
+.RE
+.PP
\fBshow\fR
+.RS 4
Show the contents of all slots. This can be slow.
-.TP
-\fBlabel\fR \fBlabel\fR
+.RE
+.PP
+\fBlabel\fR \fIlabel\fR
+.RS 4
Search for and load the
-\fBAmanda\fR
+\fIAmanda\fR
tape with label
-\fBlabel\fR.
-.TP
+\fIlabel\fR.
+.RE
+.PP
\fBtaper\fR
+.RS 4
Perform the
\fBtaper\fR
scan algorithm. Load the next tape in the configuration's tape sequence, or a fresh tape with a suitable label.
-.TP
+.RE
+.PP
\fBdevice\fR
+.RS 4
Display the name of the current tape device on
-\fBstdout\fR.
-.TP
+\fIstdout\fR.
+.RE
+.PP
\fBcurrent\fR
+.RS 4
Display the current slot.
-.TP
+.RE
+.PP
\fBupdate\fR
+.RS 4
Update the changer label database, if it has one, to match the tapes now available.
-.TP
-\fBslot\fR \fBslot\fR
+.RE
+.PP
+\fBslot\fR \fIslot\fR
+.RS 4
Eject any tape in the drive and put it away, then load the tape from slot
-\fBslot\fR
+\fIslot\fR
and reset
-\fBcurrent\fR.
-.TP
+\fIcurrent\fR.
+.RE
+.PP
\fBslot current\fR
+.RS 4
Eject any tape in the drive and put it away, then load the tape from the current slot.
-.TP
+.RE
+.PP
\fBslot prev\fR
+.RS 4
Eject any tape in the drive and put it away, then load the tape from the previous slot and reset
-\fBcurrent\fR.
-.TP
+\fIcurrent\fR.
+.RE
+.PP
\fBslot next\fR
+.RS 4
Eject any tape in the drive and put it away, then load the tape from the next slot and reset
-\fBcurrent\fR.
-.TP
+\fIcurrent\fR.
+.RE
+.PP
\fBslot first\fR
+.RS 4
Eject any tape in the drive and put it away, then load the tape from the first slot and reset
-\fBcurrent\fR.
-.TP
+\fIcurrent\fR.
+.RE
+.PP
\fBslot last\fR
+.RS 4
Eject any tape in the drive and put it away, then load the tape from the last slot and reset
-\fBcurrent\fR.
-.TP
+\fIcurrent\fR.
+.RE
+.PP
\fBslot advance\fR
+.RS 4
Eject any tape in the drive and put it away. Advance
-\fBcurrent\fR
+\fIcurrent\fR
to the next tape, but do not load it.
+.RE
+.PP
+\fB\-o\fR \fIconfigoption\fR
+.RS 4
+See the "\fBCONFIGURATION OVERWRITE\fR" section in
+\fBamanda\fR(8).
+.RE
.PP
-This is useful with non-gravity stackers to unload the last tape used and set up
-\fBAmanda\fR
+This is useful with non\-gravity stackers to unload the last tape used and set up
+\fIAmanda\fR
for the next run. If you just use
\fBeject\fR, the current tape will be mounted again in the next run, where it will be rejected as being still in use, ejected and the next tape requested. Using
\fBslot next\fR
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMTAPETYPE" 8 "" "" ""
+.\" Title: amtapetype
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMTAPETYPE" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amtapetype - generate a tapetype definition.
+amtapetype \- generate a tapetype definition.
.SH "SYNOPSIS"
.HP 11
-\fBamtapetype\fR [-h] [-c] [-o] [-b \fIblocksize\fR] -e \fIestsize\fR [-f \fItapedev\fR] [-t \fItypename\fR]
+\fBamtapetype\fR [\-h] [\-c] [\-o] [\-b\ \fIblocksize\fR] \-e\ \fIestsize\fR [\-f\ \fItapedev\fR] [\-t\ \fItypename\fR]
.SH "DESCRIPTION"
.PP
\fBamtapetype\fR
generates a tapetype entry for
-\fBAmanda\fR.
+\fIAmanda\fR.
.SH "OPTIONS"
-.TP
-\fB-h\fR
+.PP
+\fB\-h\fR
+.RS 4
Display an help message.
-.TP
-\fB-c\fR
+.RE
+.PP
+\fB\-c\fR
+.RS 4
Run only the hardware compression detection heuristic test and stop. This takes a few minutes only.
-.TP
-\fB-o\fR
+.RE
+.PP
+\fB\-o\fR
+.RS 4
Overwrite the tape, even if it's an
-\fBAmanda\fR
+\fIAmanda\fR
tape.
-.TP
-\fB-b\fR\fI blocksize\fR
+.RE
+.PP
+\fB\-b\fR\fI blocksize\fR
+.RS 4
record block size (default: 32k)
-.TP
-\fB-e\fR\fI estsize\fR
+.RE
+.PP
+\fB\-e\fR\fI estsize\fR
+.RS 4
estimated tape size (No default!)
-.TP
-\fB-f\fR\fI tapedev\fR
+.RE
+.PP
+\fB\-f\fR\fI tapedev\fR
+.RS 4
tape device name (default: $TAPE) The device to perform the test.
-.TP
-\fB-t\fR\fI typename\fR
-tapetype name (default: unknown-tapetype)
+.RE
+.PP
+\fB\-t\fR\fI typename\fR
+.RS 4
+tapetype name (default: unknown\-tapetype)
+.RE
.SH "EXAMPLE"
.PP
Generate a tapetype definition for your tape device:
.sp
+.RS 4
.nf
-
-% amtapetype -f /dev/nst0 -e 150G
-
+% amtapetype \-f /dev/nst0 \-e 150G
.fi
+.RE
.SH "NOTES"
.PP
Hardware compression is detected by measuring the writing speed difference of the tape drive when writing an amount of compressable and uncompresseable data. It does not rely on the status bits of the tape drive or the OS parameters. If your tape drive has very large buffers or is very fast, the program could fail to detect hardware compression status reliably.
.PP
-During the first pass, it writes files that are estimated to be 1% of the expected tape capacity. It gets the expected capacity from the -e command line flag, or defaults to 1 GByte. In a perfect world (which means there is zero chance of this happening with tapes :-), there would be 100 files and 100 file marks.
+During the first pass, it writes files that are estimated to be 1% of the expected tape capacity. It gets the expected capacity from the \-e command line flag, or defaults to 1 GByte. In a perfect world (which means there is zero chance of this happening with tapes :\-), there would be 100 files and 100 file marks.
.PP
During the second pass, the file size is cut in half. In that same fairyland world, this means 200 files and 200 file marks.
.PP
.PP
So if we wrote 1.0 GBytes on the first pass and 100 file marks, and 0.9 GBytes on the second pass with 200 file marks, those additional 100 file marks in the second pass took 0.1 GBytes and therefor a file mark is 0.001 GBytes (1 MByte).
.PP
-Note that if the estimated capacity is wrong, the only thing that happens is a lot more (or less, but unlikely) files, and thus, file marks, get written. But the math still works out the same. The -e flag is there to keep the number of file marks down because they can be slow (since they force the drive to flush all its buffers to physical media).
+Note that if the estimated capacity is wrong, the only thing that happens is a lot more (or less, but unlikely) files, and thus, file marks, get written. But the math still works out the same. The \-e flag is there to keep the number of file marks down because they can be slow (since they force the drive to flush all its buffers to physical media).
.PP
-All sorts of things might happen to cause the amount of data written to vary enough to generate a big file mark size guess. A little more "shoe shining" because of the additional file marks (and flushes), dirt left on the heads from the first pass of a brand new tape, the temperature/humidity changed during the multi-hour run, a different amount of data was written after the last file mark before EOT was reported, etc.
+All sorts of things might happen to cause the amount of data written to vary enough to generate a big file mark size guess. A little more "shoe shining" because of the additional file marks (and flushes), dirt left on the heads from the first pass of a brand new tape, the temperature/humidity changed during the multi\-hour run, a different amount of data was written after the last file mark before EOT was reported, etc.
.PP
Note that the file mark size might really be zero for whatever device this is, and it was just the measured capacity variation that caused
\fBamtapetype\fR
.SH "SEE ALSO"
.PP
\fBamanda\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMTOC" 8 "" "" ""
+.\" Title: amtoc
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMTOC" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amtoc - generate TOC (Table Of Contents) for an Amanda run
+amtoc \- generate TOC (Table Of Contents) for an Amanda run
.SH "SYNOPSIS"
.HP 6
-\fBamtoc\fR [-a] [-i] [-t] [-f \fIfile\fR] [-s \fIsubs\fR] [-w] [--] \fIlogfile\fR
+\fBamtoc\fR [\-a] [\-i] [\-t] [\-f\ \fIfile\fR] [\-s\ \fIsubs\fR] [\-w] [\-\-] \fIlogfile\fR
.SH "DESCRIPTION"
.PP
-\fBAmtoc\fR
+\fIAmtoc\fR
generates a table of contents for an
-\fBAmanda\fR
+\fIAmanda\fR
run. It's a perl script (if you don't have perl, install it first!).
.SH "OPTIONS"
-.TP
-\fB-a\fR
+.PP
+\fB\-a\fR
+.RS 4
The output file name will be
-\fBlabel-of-the-tape\fR.toc in the same directory as
-\fBlogfile\fR.
-.TP
-\fB-i\fR
+\fIlabel\-of\-the\-tape\fR.toc in the same directory as
+\fIlogfile\fR.
+.RE
+.PP
+\fB\-i\fR
+.RS 4
Display help about
\fBamtoc\fR.
-.TP
-\fB-t\fR
+.RE
+.PP
+\fB\-t\fR
+.RS 4
Generate the output in tabular form.
-.TP
-\fB-f file\fR
-Write the output to a file ('-' for stdout).
-.TP
-\fB-s subs\fR
+.RE
+.PP
+\fB\-f file\fR
+.RS 4
+Write the output to a file ('\-' for stdout).
+.RE
+.PP
+\fB\-s subs\fR
+.RS 4
Evaluate the output file name from
-\fBsubs\fR, with $_ set to
-\fBlabel-of-the-tape\fR. The
-\fB-a\fR
+\fIsubs\fR, with $_ set to
+\fIlabel\-of\-the\-tape\fR. The
+\fB\-a\fR
option is equivalent to
-\fB-s\fR\fI's/$_/.toc/'\fR.
-.TP
-\fB-w\fR
-Separate tapes with form-feeds and display blank lines before totals.
-.TP
-\fB--\fR
+\fB\-s\fR
+\fI's/$_/.toc/'\fR.
+.RE
+.PP
+\fB\-w\fR
+.RS 4
+Separate tapes with form\-feeds and display blank lines before totals.
+.RE
+.PP
+\fB\-\-\fR
+.RS 4
Marks the last option so the next parameter is the
-\fBlogfile\fR.
-.TP
+\fIlogfile\fR.
+.RE
+.PP
\fBlogfile\fR
-(use '-' for stdin)
+.RS 4
+(use '\-' for stdin)
+.RE
.SH "OUTPUT FORMAT"
.PP
The standard output has five fields separated by two spaces:
.sp
+.RS 4
.nf
-
# Server:/partition date level size[Kb]
-0 daily-05: 19991005 - -
+0 daily\-05: 19991005 \- \-
1 cuisun15:/cuisun15/home 19991005 1 96
2 cuinfs:/export/dentiste 19991005 1 96
...
103 cuisg11:/ 19991005 0 4139136
-103 total: - - 16716288
-
+103 total: \- \- 16716288
.fi
+.RE
.PP
-In tabular format (-t), this would look like:
+In tabular format (\-t), this would look like:
.sp
+.RS 4
.nf
-
# Server:/partition date lev size[Kb]
- 0 daily-05: 19991005 - -
+ 0 daily\-05: 19991005 \- \-
1 cuisun15:/cuisun15/home 19991005 1 96
2 cuinfs:/export/dentiste 19991005 1 96
...
103 cuisg11:/ 19991005 0 4139136
-103 total: - - 16716288
-
+103 total: \- \- 16716288
.fi
+.RE
.SH "USAGE"
.PP
The easiest way to use it is to run
\fBamtoc\fR
right after
-\fBamdump\fR
+\fIamdump\fR
in the
-\fBcron job:\fR
+\fIcron job:\fR
.sp
+.RS 4
.nf
-
-amdump daily ; logdir=`amgetconf daily logdir` ; log=`ls -1t $logdir/log.*.[0-9] | head -1` ; amtoc -a $log
-
+amdump daily ; logdir=`amgetconf daily logdir` ; log=`ls \-1t $logdir/log.*.[0\-9] | head \-1` ; amtoc \-a $log
.fi
+.RE
.sp
.PP
-which will generate /usr/local/etc/amanda//daily/\fBtape_label\fR.toc. You may also want to call
+which will generate /usr/local/etc/amanda//daily/\fItape_label\fR.toc. You may also want to call
\fBamtoc\fR
after an
-\fBamflush\fR.
+\fIamflush\fR.
.SH "SEE ALSO"
.PP
\fBamanda\fR(8),
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
-
+\fIAmanda\fR\-documentation: XML\-conversion
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMVERIFY" 8 "" "" ""
+.\" Title: amverify
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMVERIFY" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amverify - check an Amanda tape for errors
+amverify \- check an Amanda tape for errors
.SH "SYNOPSIS"
.HP 9
-\fBamverify\fR \fIconfig\fR [\fIslot\fRÂ [\fIruntapes\fR]]
+\fBamverify\fR \fIconfig\fR [\fIslot\fR\ [\fIruntapes\fR]]
.SH "DESCRIPTION"
.PP
\fBAmverify\fR
to /dev/null. This still determines if the tape is readable, but does not do any internal consistency check on the image.
.PP
If
-\fBconfig\fR
+\fIconfig\fR
is set up to use a tape changer, the
-\fBslot\fR
+\fIslot\fR
argument may be used to choose the first tape to process. Otherwise, the
\fBcurrent\fR
slot is used.
.PP
Stefan G. Weichinger,
<sgw@amanda.org>, maintainer of the
-\fBAmanda\fR-documentation: XML-conversion
+\fIAmanda\fR\-documentation: XML\-conversion
.SH "SEE ALSO"
.PP
\fBamrestore\fR(8),
\fBamanda\fR(8),
\fBamverifyrun\fR(8)
-
-.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "AMVERIFYRUN" 8 "" "" ""
+.\" Title: amverifyrun
+.\" Author:
+.\" Generator: DocBook XSL Stylesheets v1.72.0 <http://docbook.sf.net/>
+.\" Date: 02/07/2007
+.\" Manual:
+.\" Source:
+.\"
+.TH "AMVERIFYRUN" "8" "02/07/2007" "" ""
+.\" disable hyphenation
+.nh
+.\" disable justification (adjust text to left margin only)
+.ad l
.SH "NAME"
-amverifyrun - check the tapes written by the last Amanda run
+amverifyrun \- check the tapes written by the last Amanda run
.SH "SYNOPSIS"
.HP 12
\fBamverifyrun\fR \fIconfig\fR
.PP
\fBAmverifyrun\fR
read the log from the last
-\fBAmanda\fR
+\fIAmanda\fR
run to find the slot of the first tape used and the number of tapes used. It call
\fBamverify\fR
with these argument.
.PP
\fBamanda\fR(8),
\fBamverify\fR(8)
-
<command>amadmin</command>
<arg choice='plain'><replaceable>config</replaceable></arg>
<arg choice='plain'><replaceable>command</replaceable></arg>
- <group><replaceable><arg choice='plain'>command</arg><arg choice='plain'>options</arg></replaceable></group>
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='opt' rep='repeat'><replaceable>command_options</replaceable></arg>
+ <arg choice='plain' rep='repeat'><group><option>-o </option><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
The tape label or holding disk filename,
file number,
and status are displayed.</para>
-<para>The <option>--sort</option> option changes the sort order using the following flags:</para>
-
-<para><emphasis remap='B'>h</emphasis> host name
-<emphasis remap='B'>k</emphasis> disk name
-<emphasis remap='B'>d</emphasis> dump date
-<emphasis remap='B'>l</emphasis> backup level
-<emphasis remap='B'>p</emphasis> dump part
-<emphasis remap='B'>b</emphasis> tape label</para>
+<para>The <option>--sort</option> option changes the sort order using the following flags:
+<programlisting>
+<emphasis>h</emphasis>: host name
+<emphasis>k</emphasis>: disk name
+<emphasis>d</emphasis>: dump date
+<emphasis>l</emphasis>: backup level
+<emphasis>p</emphasis>: dump part
+<emphasis>b</emphasis>: tape label
+</programlisting></para>
<para>An uppercase letter reverses the sort order for that key.
The default sort order is <emphasis remap='B'>hkdlpb</emphasis>.</para>
on
<emphasis remap='I'>hostname</emphasis>
from the &A; database.</para>
-<note>If you do not also remove the disk from the
+<note><para>If you do not also remove the disk from the
<emphasis remap='I'>disklist</emphasis>
-file, &A; will treat it as a new disk during the next run.</note>
+file, &A; will treat it as a new disk during the next run.</para>
+</note>
</listitem>
</varlistentry>
<programlisting>
$ amadmin daily find machine-c /var
date host disk lv tape or file file part status
-2000\-11\-09 machine\-c /var 0 000110 9 -- OK
-2000\-11\-08 machine\-c /var 2 000109 2 -- OK
-2000\-11\-07 machine\-c /var 2 /amanda/20001107/machine-c._var.2 0 OK
-2000\-11\-06 machine\-c /var 2 000107 2 -- OK
-2000\-11\-05 machine\-c /var 2 000106 3 -- OK
-2000\-11\-04 machine\-c /var 2 000105 2 -- OK
-2000\-11\-03 machine\-c /var 2 000104 2 -- OK
-2000\-11\-02 machine\-c /var 2 000103 2 -- OK
-2000\-11\-01 machine\-c /var 1 000102 5 -- OK
-2000\-10\-31 machine\-c /var 1 000101 3 -- OK
+2000-11-09 machine-c /var 0 000110 9 -- OK
+2000-11-08 machine-c /var 2 000109 2 -- OK
+2000-11-07 machine-c /var 2 /amanda/20001107/machine-c._var.2 0 OK
+2000-11-06 machine-c /var 2 000107 2 -- OK
+2000-11-05 machine-c /var 2 000106 3 -- OK
+2000-11-04 machine-c /var 2 000105 2 -- OK
+2000-11-03 machine-c /var 2 000104 2 -- OK
+2000-11-02 machine-c /var 2 000103 2 -- OK
+2000-11-01 machine-c /var 1 000102 5 -- OK
+2000-10-31 machine-c /var 1 000101 3 -- OK
</programlisting>
<para>Forget about the
Aespipe is available from <ulink url="http://loop-aes.sourceforge.net"/></para>
<para>&amaespipe; will search for the aespipe program in the following directories:
/usr/bin:/usr/local/bin:/sbin:/usr/sbin. </para>
-&amaespipe; is called by &amcrypt; for &A; data encryption.
+<para>&amaespipe; is called by &amcrypt; for &A; data encryption.</para>
<para>&amaespipe; is based on aespipe's bzaespipe program.
It calls aespipe to encrypt data using AES256 as the encryption and SHA256 as the
hash function. GPG key should be stored in $AMANDA_HOME/.gnupg/am_key.gpg.
<listitem>
<para>Some number of weeks (days*7).</para>
-<note>The value
+<note><para>The value
<emphasis remap='B'>inf</emphasis>
may be used in most places where an integer is expected
-to mean an infinite amount.
+to mean an infinite amount.</para>
<para>Boolean arguments may have any of the values
<emphasis remap='B'>y</emphasis>,
</programlisting>
is really a short hand for
<programlisting>tapedev tape:/dev/rmt/0mn
-</programlisting>.</para>
+</programlisting></para>
</listitem>
</varlistentry>
<varlistentry>
<emphasis remap='B'>tapetype</emphasis>
is used to limit the amount of data written. When the limit is reached, the driver will simulate end of tape.</para>
-<note>This driver should only be used for debugging and testing,
+<note><para>This driver should only be used for debugging and testing,
and probably only with the
<emphasis remap='B'>record</emphasis>
option set to
-<emphasis remap='I'>no</emphasis>.</note>
+<emphasis remap='I'>no</emphasis>.
+</para>
+</note>
</listitem>
</varlistentry>
by listing it first in the password field followed
by a percent sign and then the password.
For instance:</para>
-
<programlisting>
//some-pc/home normalpw
//another-pc/disk otheruser%otherpw
</programlisting>
-
-With clear text passwords, this file should obviously be tightly protected.
-It only needs to be readable by the &A;-user on the Samba server.
-
+<para>With clear text passwords, this file should obviously be tightly protected.
+It only needs to be readable by the &A;-user on the Samba server. </para>
<para>You can find further information in the
<emphasis remap='B'>docs/SAMBA</emphasis>
<!-- TODO: edit link -->
the host or disk.</para>
-<literallayout remap='.nf'>
-. word separator for a host
-/ word separator for a disk
-^ anchor at left
-$ anchor at right
-? match exactly one character except the separator
-* match zero or more characters except the separator
-** match zero or more characters including the separator
-</literallayout>
+<informaltable frame="none">
+<tgroup cols="2" align="left">
+<tbody>
+
+<row>
+<entry>. </entry>
+<entry>word separator for a host</entry>
+</row>
+
+<row>
+<entry>/</entry>
+<entry>word separator for a disk</entry>
+</row>
+
+<row>
+<entry>^</entry>
+<entry>anchor at left</entry>
+</row>
+
+<row>
+<entry>$</entry>
+<entry>anchor at right</entry>
+</row>
+
+<row>
+<entry>?</entry>
+<entry>match exactly one character except the separator</entry>
+</row>
+
+<row>
+<entry>*</entry>
+<entry>match zero or more characters except the separator</entry>
+</row>
+
+<row>
+<entry>**</entry>
+<entry>match zero or more characters including the separator</entry>
+</row>
+</tbody>
+</tgroup>
+</informaltable>
<para>Some examples:</para>
-<literallayout remap='.nf'>
-EXPRESSION WILL MATCH WILL NOT MATCH
-hosta hosta hostb
- hoSTA.dOMAIna.ORG
- foo.hosta.org
-host host hosta
-host? hosta host
- hostb
-ho*na hoina ho.aina.org
-ho**na hoina
- ho.aina.org
-^hosta hosta foo.hosta.org
-sda* /dev/sda1
- /dev/sda12
-/opt/ opt (disk) opt (host)
-.opt. opt (host) opt (disk)
-/ / any other disk
-/usr /usr
- /usr/opt
-/usr$ /usr /usr/opt
-</literallayout>
+<informaltable frame="none">
+<tgroup cols="3" align="left">
+<tbody>
+
+<row>
+<entry>EXPRESSION </entry>
+<entry>WILL MATCH</entry>
+<entry>WILL NOT MATCH</entry>
+</row>
+
+<row>
+<entry>hosta</entry>
+<entry>hosta</entry>
+<entry>hostb</entry>
+</row>
+
+<row>
+<entry></entry>
+<entry>hoSTA.dOMAIna.ORG</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry></entry>
+<entry>foo.hosta.org</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry>host</entry>
+<entry>host</entry>
+<entry>hosta</entry>
+</row>
+
+<row>
+<entry>host?</entry>
+<entry>hosta</entry>
+<entry>host</entry>
+</row>
+
+<row>
+<entry></entry>
+<entry>hostb</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry>ho*na</entry>
+<entry>hoina</entry>
+<entry>ho.aina.org</entry>
+</row>
+
+<row>
+<entry>ho**na</entry>
+<entry>hoina</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry></entry>
+<entry>ho.aina.org</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry>^hosta</entry>
+<entry>hosta</entry>
+<entry>foo.hosta.org</entry>
+</row>
+
+<row>
+<entry>sda*</entry>
+<entry>/dev/sda1</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry></entry>
+<entry>/dev/sda12</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry>/opt</entry>
+<entry>opt (disk)</entry>
+<entry>opt (host)</entry>
+</row>
+
+<row>
+<entry>.opt.</entry>
+<entry>opt (host)</entry>
+<entry>opt (disk)</entry>
+</row>
+
+<row>
+<entry>/</entry>
+<entry>/</entry>
+<entry>any other disk</entry>
+</row>
+
+<row>
+<entry>/usr</entry>
+<entry>/usr</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry></entry>
+<entry>/usr/opt</entry>
+<entry></entry>
+</row>
+
+<row>
+<entry>/usr$</entry>
+<entry>/usr</entry>
+<entry>/usr/opt</entry>
+</row>
+
+</tbody>
+</tgroup>
+</informaltable>
</refsect1>
Leading ^ is removed. Trailing $ forces an exact match.</para>
<informaltable frame="all">
-<tgroup cols="2" alignment="left">
+<tgroup cols="2" align="left">
<tbody>
<row>
<listitem>
<para>Some number of weeks (days*7).</para>
-<note>The value
+<note><para>The value
<emphasis remap='B'>inf</emphasis>
may be used in most places where an integer is expected
-to mean an infinite amount.
+to mean an infinite amount.</para>
<para>Boolean arguments may have any of the values
<emphasis remap='B'>y</emphasis>,
The number of days in the backup cycle.
Each disk will get a full backup at least this often.
Setting this to zero tries to do a full backup each run.</para>
-<note>This parameter may also be set in a specific
+<note><para>This parameter may also be set in a specific
<emphasis remap='B'>dumptype</emphasis>
(see below).
This value sets the default for all
<emphasis remap='B'>amanda.conf</emphasis>
before any
<emphasis remap='B'>dumptype</emphasis>s
-are defined.</note>
+are defined.</para>
+</note>
</listitem>
</varlistentry>
-
+
<varlistentry>
<term><emphasis remap='B'>runspercycle</emphasis> <emphasis remap='I'> int</emphasis></term>
<listitem>
<listitem>
<para>Default:
<emphasis remap='I'>tttTTTTTTT</emphasis>.
-The priority order of each dumper:</para>
+The priority order of each dumper:
-<itemizedlist>
-<listitem><para>s: smallest size</para></listitem>
-<listitem><para>S: largest size</para></listitem>
-<listitem><para>t: smallest time</para></listitem>
-<listitem><para>T: largest time</para></listitem>
-<listitem><para>b: smallest bandwidth</para></listitem>
-<listitem><para>B: largest bandwidth</para></listitem>
-</itemizedlist>
+<programlisting>
+s: smallest size
+S: largest size
+t: smallest time
+T: largest time
+b: smallest bandwidth
+B: largest bandwidth
+</programlisting></para>
</listitem>
</varlistentry>
of three parts which are separated by a equal sign ('=') and a colon (':') (see the example).
These three parts specify:</para>
- <itemizedlist>
+ <orderedlist>
<listitem>
<para>the name of the column, which may be:</para>
- <itemizedlist>
- <listitem><para>Compress (compression ratio)</para></listitem>
- <listitem><para>Disk (client disk name)</para></listitem>
- <listitem><para>DumpRate (dump rate in KBytes/sec)</para></listitem>
- <listitem><para>DumpTime (total dump time in hours:minutes)</para></listitem>
- <listitem><para>HostName (client host name)</para></listitem>
- <listitem><para>Level (dump level)</para></listitem>
- <listitem><para>OrigKB (original image size in KBytes)</para></listitem>
- <listitem><para>OutKB (output image size in KBytes)</para></listitem>
- <listitem><para>TapeRate (tape writing rate in KBytes/sec)</para></listitem>
- <listitem><para>TapeTime (total tape time in hours:minutes)</para></listitem>
- </itemizedlist>
+ <programlisting>
+ Compress (compression ratio)
+ Disk (client disk name)
+ DumpRate (dump rate in KBytes/sec)
+ DumpTime (total dump time in hours:minutes)
+ HostName (client host name)
+ Level (dump level)
+ OrigKB (original image size in KBytes)
+ OutKB (output image size in KBytes)
+ TapeRate (tape writing rate in KBytes/sec)
+ TapeTime (total tape time in hours:minutes)
+ </programlisting>
</listitem>
<listitem>
-<para>the amount of space to display before the column (used to get whitespace between columns).</para>
+<para>the amount of space to display before the column (used to get whitespace between columns).</para><para/>
</listitem>
<listitem>
<para>the width of the column itself.
If set to a negative value, the width will be calculated on demand to fit the largest entry in
this column.</para>
</listitem>
- </itemizedlist>
-
-<para>Here is an example:</para>
+ </orderedlist>
+<para>Here is an example:
<programlisting>
-<para>columnspec "Disk=1:18,HostName=0:10,OutKB=1:7"</para>
-</programlisting>
+columnspec "Disk=1:18,HostName=0:10,OutKB=1:7"
+</programlisting></para>
+<para>
The above will display the disk information in 18 characters
and put one space before it. The hostname column will be 10 characters wide with
no space to the left. The output KBytes column is seven characters wide
-with one space before it.
+with one space before it.</para>
</listitem>
</varlistentry>
A comment string describing this holding disk.</para>
</listitem>
</varlistentry>
+
<varlistentry>
<term><emphasis remap='B'>directory</emphasis> <emphasis remap='I'> disk</emphasis></term>
<listitem>
The path to this holding area.</para>
</listitem>
</varlistentry>
+
<varlistentry>
<term><emphasis remap='B'>use</emphasis> <emphasis remap='I'> int</emphasis></term>
<listitem>
-Default:
+<para>Default:
<emphasis remap='I'>0 Gb</emphasis>.
Amount of space that can be used in this holding disk area.
If the value is zero, all available space on the file system is used.
-If the value is negative, &A; will use all available space minus that value.
+If the value is negative, &A; will use all available space minus that value.</para>
</listitem>
</varlistentry>
+
<varlistentry>
<term><emphasis remap='B'>chunksize</emphasis> <emphasis remap='I'> int</emphasis></term>
<listitem>
-Default:
+<para>Default:
<emphasis remap='I'>1 Gb</emphasis>.
Holding disk chunk size. Dumps larger than the specified size will be stored in multiple
holding disk files. The size of each chunk will not exceed the specified value.
However, even though dump images are split in the holding disk, they are concatenated as
they are written to tape, so each dump image still corresponds to a single continuous
-tape section.
+tape section.</para>
-If 0 is specified, &A; will create holding disk chunks as large as
-((INT_MAX/1024)-64) Kbytes.
+<para>If 0 is specified, &A; will create holding disk chunks as large as
+((INT_MAX/1024)-64) Kbytes.</para>
-Each holding disk chunk includes a 32 Kbyte header, so the minimum
-chunk size is 64 Kbytes (but that would be really silly).
+<para>Each holding disk chunk includes a 32 Kbyte header, so the minimum
+chunk size is 64 Kbytes (but that would be really silly).</para>
-Operating systems that are limited to a maximum file size of 2 Gbytes
+<para>Operating systems that are limited to a maximum file size of 2 Gbytes
actually cannot handle files that large.
They must be at least one byte less than 2 Gbytes.
Since &A; works with 32 Kbyte blocks, and
to handle the final read at the end of the chunk, the chunk size
should be at least 64 Kbytes (2 * 32 Kbytes) smaller than the maximum
-file size, e.g. 2047 Mbytes.
+file size, e.g. 2047 Mbytes.</para>
</listitem>
</varlistentry>
</variablelist>
but usually less CPU overhead. Or to specify <emphasis remap='B'>Custom</emphasis>
to use your own compression method. (See dumptype custom-compress in example/amanda.conf for reference)</para>
-
-
<para>So the <emphasis remap='B'>compress</emphasis> options line may be one of:</para>
-<itemizedlist>
-<listitem><para>compress none</para></listitem>
-<listitem><para>compress [client] fast</para></listitem>
-<listitem><para>compress [client] best</para></listitem>
-<listitem><para>compress client custom</para>
-<para>Specify client_custom_compress "PROG"</para>
-<para>PROG must not contain white space and it must accept -d for uncompress.</para></listitem>
-<listitem><para>compress server fast</para></listitem>
-<listitem><para>compress server best</para></listitem>
-<listitem><para>compress server custom</para>
-<para>Specify server_custom_compress "PROG"</para>
-<para>PROG must not contain white space and it must accept -d for uncompress.</para></listitem>
-</itemizedlist>
-
+<variablelist remap='TP'>
+ <varlistentry>
+ <term>compress none</term><listitem><para/></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>compress client fast</term><listitem><para/></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>compress client best</term><listitem><para/></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>compress client custom</term>
+ <listitem>
+ <para>Specify <emphasis>client_custom_compress</emphasis> "PROG"</para>
+ <para>PROG must not contain white space and it must accept -d for uncompress.</para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>compress server fast</term><listitem><para/></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>compress server best</term><listitem><para/></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>compress server custom</term>
+ <listitem>
+ <para>Specify <emphasis>server_custom_compress</emphasis> "PROG"</para>
+ <para>PROG must not contain white space and it must accept -d for uncompress.</para>
+ </listitem>
+ </varlistentry>
+</variablelist>
<para>Note that some tape devices do compression and this option has nothing
to do with whether that is used. If hardware compression is used (usually via a particular tape device name
or <emphasis remap='B'>mt</emphasis> option), &A; (software) compression should be disabled.</para>
<para>So the <emphasis remap='B'>encrypt</emphasis> options line may be one
of:</para>
-<itemizedlist>
-<listitem><para>encrypt none</para></listitem>
-<listitem><para>encrypt client</para>
-<para>Specify client_encrypt "PROG"</para>
-<para>PROG must not contain white space.</para>
-<para>Specify client_decrypt_option "decryption-parameter" Default: "-d"</para>
-<para>decryption-parameter must not contain white space.</para>
-<para>(See dumptype server-encrypt-fast in example/amanda.conf for reference)</para>
-</listitem>
-<listitem><para>encrypt server</para>
-<para>Specify server_encrypt "PROG"</para>
-<para>PROG must not contain white space.</para>
-<para>Specify server_decrypt_option "decryption-parameter" Default: "-d"</para>
-<para>decryption-parameter must not contain white space.</para>
-<para>(See dumptype client-encrypt-nocomp in example/amanda.conf for reference)</para>
-</listitem>
-</itemizedlist>
-</listitem>
+<variablelist remap='TP'>
+ <varlistentry>
+ <term>encrypt none</term><listitem><para/></listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>encrypt client</term>
+ <listitem>
+ <para>Specify client_encrypt "PROG"</para>
+ <para>PROG must not contain white space.</para>
+ <para>Specify client_decrypt_option "decryption-parameter" Default: "-d"</para>
+ <para>decryption-parameter must not contain white space.</para>
+ <para>(See dumptype server-encrypt-fast in example/amanda.conf for reference)</para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>encrypt server</term>
+ <listitem>
+ <para>Specify server_encrypt "PROG"</para>
+ <para>PROG must not contain white space.</para>
+ <para>Specify server_decrypt_option "decryption-parameter" Default: "-d"</para>
+ <para>decryption-parameter must not contain white space.</para>
+ <para>(See dumptype client-encrypt-nocomp in example/amanda.conf for reference)</para>
+ </listitem>
+ </varlistentry>
+</variablelist>
<para>Note that current logic assumes compression then encryption during
backup(thus decrypt then uncompress during restore). So specifying
client-encryption AND server-compression is not supported.
<emphasis remap='I'>amcrypt</emphasis> which is a wrapper of
<emphasis remap='I'>aespipe</emphasis> is provided as a reference
symmetric encryption program.</para>
+</listitem>
</varlistentry>
<listitem>
<para>Default: <emphasis remap='I'>client</emphasis>.
Determine the way &A; does it's estimate.</para>
-<itemizedlist>
-<listitem>
-<para>client:</para>
-<para>
-Use the same program as the dumping program, this is the most accurate way to do estimates, but it can take a long time.
-</para>
-</listitem>
-<listitem>
-<para>calcsize:</para>
-<para>Use a faster program to do estimates, but the result is less accurate.</para>
-</listitem>
-<listitem>
-<para>server:</para>
-<para>Use only statistics from the previous run to give an estimate,
-it takes only a few seconds but the result is not accurate if your disk
-usage changes from day to day.
-</para>
- </listitem>
- </itemizedlist>
- </listitem>
+<variablelist remap='TP'>
+ <varlistentry>
+ <term>client</term>
+ <listitem>
+ <para>Use the same program as the dumping program, this is the most
+ accurate way to do estimates, but it can take a long time.</para>
+ </listitem>
</varlistentry>
+ <varlistentry>
+ <term>calcsize</term>
+ <listitem>
+ <para>Use a faster program to do estimates, but the result is less accurate.</para>
+ </listitem>
+ </varlistentry>
+ <varlistentry>
+ <term>server</term>
+ <listitem>
+ <para>Use only statistics from the previous run to give an estimate,
+ it takes only a few seconds but the result is not accurate if your disk
+ usage changes from day to day.</para>
+ </listitem>
+ </varlistentry>
+</variablelist>
+</listitem>
+</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>exclude</emphasis> [ <emphasis remap='I'>list|file</emphasis> ][[optional][ <emphasis remap='I'>append</emphasis> ][ <emphasis remap='I'> string</emphasis> ]+]</term>
+ <term><emphasis remap='B'>exclude</emphasis> [ list|file ][[optional][ append ][ <emphasis remap='I'>string</emphasis> ]+]</term>
<listitem>
<para>Default:
<emphasis remap='I'>file</emphasis>.
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>holdingdisk</emphasis> [ <emphasis remap='I'>never|auto|required]</emphasis> ]</term>
+ <term><emphasis remap='B'>holdingdisk</emphasis> [ never|auto|required ]</term>
<listitem>
<para>Default:
<emphasis remap='I'>auto</emphasis>.
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>include</emphasis> [ <emphasis remap='I'>list|file</emphasis> ][[optional][ <emphasis remap='I'>append</emphasis> ][ <emphasis remap='I'> string</emphasis> ]+]</term>
+ <term><emphasis remap='B'>include</emphasis> [ list|file ][[optional][ append ][ <emphasis remap='I'>string</emphasis> ]+]</term>
<listitem>
<para>Default:
<emphasis remap='I'>file</emphasis>
<para>Include expressions must always be specified as relative to the
head directory of the DLE.</para>
-<note>For globbing to work at all, even the limited single level,
-the top level directory of the DLE must be readable by the &A; user.</note>
+<note><para>For globbing to work at all, even the limited single level,
+the top level directory of the DLE must be readable by the &A; user.</para>
+</note>
<para>With the <emphasis remap='B'>append</emphasis> keyword, the
<emphasis remap='I'>string</emphasis> is appended to the current list, without it, the
<term><emphasis remap='B'>filemark</emphasis> <emphasis remap='I'> int</emphasis></term>
<listitem>
<para>Default:
-<emphasis remap='I'>1000 bytes</emphasis>.
-How large a file mark (tape mark) is, measured in bytes.
+<emphasis remap='I'>1 kbytes</emphasis>.
+How large a file mark (tape mark) is, measured in kbytes.
If the size is only known in some linear measurement (e.g. inches),
-convert it to bytes using the device density.</para>
+convert it to kbytes using the device density.</para>
</listitem>
</varlistentry>
<varlistentry>
<term><emphasis remap='B'>blocksize</emphasis> <emphasis remap='I'> int</emphasis></term>
<listitem>
<para>Default:
-<emphasis remap='I'>32</emphasis>.
+<emphasis remap='I'>32 kbytes</emphasis>.
How much data will be written in each tape record expressed in KiloBytes.
The tape record size (= blocksize) can not be reduced below the default 32 KBytes.
The parameter blocksize can only be raised if &A; was compiled with the configure option
<arg choice='opt'>-am</arg>
<arg choice='opt'>-w</arg>
<arg choice='opt'>-sclt</arg>
- <group><arg choice='plain'>-M</arg><arg choice='plain'><replaceable>address</replaceable></arg></group>*
+ <arg choice='opt'>-M <replaceable>address</replaceable></arg>
<arg choice='plain'><replaceable>config</replaceable></arg>
- <group><arg choice='plain'><replaceable>host</replaceable></arg><arg choice='opt'><replaceable>disk</replaceable></arg>*</group>*
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='opt' rep='repeat'>
+ <arg choice='plain'><replaceable>host</replaceable></arg>
+ <arg choice='opt' rep='repeat'><replaceable>disk</replaceable></arg>
+ </arg>
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
<varlistentry>
<term><option>-c</option></term>
<listitem>
-<para>Run the client host checks.Multiple specific clients can be
+<para>Run the client host checks. Multiple specific clients can be
checked by specifying the client name.</para>
</listitem>
</varlistentry>
<emphasis remap='I'>amanda.conf</emphasis>
option)
to allow for unexpected overruns.</para>
-<note>Even though this message is listed as a warning, it causes &amcheck; to exit with a non-zero status.</note>
+<note><para>Even though this message is listed as a warning, it causes &amcheck; to exit with a non-zero status.</para>
+</note>
</listitem>
</varlistentry>
</variablelist>
url="http://loop-aes.sourceforge.net"/></para>
<para>&amcrypt; will search for the aespipe program in the following directories:
/usr/bin:/usr/local/bin:/sbin:/usr/sbin.</para>
-&amcrypt; calls &amaespipe; and pass the
+<para>&amcrypt; calls &amaespipe; and pass the
<emphasis remap='B'>passphrase</emphasis> through file descriptor 3.
-The passphrase should be stored in ~amanda/.am_passphrase.
+The passphrase should be stored in ~amanda/.am_passphrase.</para>
</refsect1>
<refsect1><title>How to create encryption keys for amcrypt</title>
-1. Create 65 random encryption keys and encrypt those keys using gpg. Reading
+<para>1. Create 65 random encryption keys and encrypt those keys using gpg. Reading
from /dev/random may take indefinitely long if kernel's random entropy pool
is empty. If that happens, do some other work on some other console (use
-keyboard, mouse and disks).
+keyboard, mouse and disks).</para>
<para> head -c 2925 /dev/random | uuencode -m - | head -n 66 | tail -n 65 \
| gpg --symmetric -a > ~amanda/.gnupg/am_key.gpg
</para>
<refsect1><title>Key and Passphrase</title>
<para>&amcrypt; uses the same key to encrypt and decrypt data.</para>
-It is very important to store and protect the key and the passphrase
+<para>It is very important to store and protect the key and the passphrase
properly. Encrypted backup data can <emphasis remap='B'>only</emphasis> be recovered with the correct key and
-passphrase.
+passphrase.</para>
</refsect1>
<refsect1><title>SEE ALSO</title>
<cmdsynopsis>
<command>amdump</command>
<arg choice='plain'><replaceable>config</replaceable></arg>
- <group><arg choice='plain'><replaceable>host</replaceable></arg><arg choice='opt'><replaceable>disk</replaceable></arg>*</group>*
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='opt' rep='repeat'>
+ <arg choice='plain'><replaceable>host</replaceable></arg>
+ <arg choice='opt' rep='repeat'><replaceable>disk</replaceable></arg>
+ </arg>
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
</arg>
</arg>
</arg>
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
piece as an individual file and reassembles them only after all have
been restored.</para>
-<note>This requires at least double the size of your dump in free
-disk space, in order to build the final assembled dumpfile.</note>
+<note><para>This requires at least double the size of your dump in free
+disk space, in order to build the final assembled dumpfile.</para>
+</note>
<para>This behavior is implicitly invoked in circumstances where knowing the
location of all dumps on tape in advance is not possible, such as when
</refsect1>
<refsect1><title>CAVEATS</title>
-<command>Amfetchdump</command> is dependent on accessing your server's config,
+<para><command>Amfetchdump</command> is dependent on accessing your server's config,
tape changer, and (normally) dump logs. As such, it's not necessarily
the most useful tool when those have all been wiped out and you
desperately need to pull things from your tape. Pains have been taken
<citerefentry><refentrytitle>amrestore</refentrytitle><manvolnum>8</manvolnum></citerefentry>
or
<citerefentry><refentrytitle>dd</refentrytitle><manvolnum>8</manvolnum></citerefentry>
-instead.
+instead.</para>
</refsect1>
<refsect1><title>AUTHOR</title>
<arg choice='opt'>-b</arg>
<arg choice='opt'>-f</arg>
<arg choice='opt'>-s</arg>
- <group><arg choice='plain'>-D</arg><arg choice='plain'><replaceable>datestamp</replaceable></arg></group>*
+ <arg choice='opt'>-D <replaceable>datestamp</replaceable></arg>
<arg choice='plain'><replaceable>config</replaceable></arg>
- <group><arg choice='plain'><replaceable>host</replaceable></arg><arg choice='opt'><replaceable>disk</replaceable></arg>*</group>*
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='opt' rep='repeat'>
+ <arg choice='plain'><replaceable>host</replaceable></arg>
+ <arg choice='opt' rep='repeat'><replaceable>disk</replaceable></arg>
+ </arg>
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
<cmdsynopsis>
<command>amgetconf</command>
<arg choice='opt'><replaceable>config</replaceable></arg>
+ <arg choice='opt'><replaceable>--list</replaceable></arg>
<arg choice='plain'><replaceable>parameter</replaceable></arg>
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
<variablelist remap='TP'>
<varlistentry>
- <term><emphasis remap='B'>-o</emphasis> <replaceable>configoption</replaceable></term>
+ <term><emphasis remap='B'>--list</emphasis></term>
+ <listitem>
+<para>The parameter must be 'tapetype', 'dumptype, 'holdingdisk' or 'interface'. It will output, one by line, the list of identifier for the parameter.</para>
+<variablelist remap='TP'>
+<varlistentry>
+ <term>--list tapetype</term>
+ <listitem>
+ <para>Output the list of tapetype, one by line.</para>
+ </listitem>
+</varlistentry>
+<varlistentry>
+ <term>--list dumptype</term>
+ <listitem>
+ <para>Output the list of dumptype, one by line.</para>
+ </listitem>
+</varlistentry>
+<varlistentry>
+ <term>--list holdingdisk</term>
+ <listitem>
+ <para>Output the list of holdingdisk, one by line.</para>
+ </listitem>
+</varlistentry>
+<varlistentry>
+ <term>--list interface</term>
+ <listitem>
+ <para>Output the list of interface, one by line.</para>
+ </listitem>
+</varlistentry>
+</variablelist>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><emphasis remap='B'>parameter</emphasis></term>
+ <listitem>
+ <para>It could be one of the below format:</para>
+<variablelist remap='TP'>
+<varlistentry>
+ <term>runtapes</term><listitem><para></para></listitem>
+</varlistentry>
+<varlistentry>
+ <term>DUMPTYPE:no-compress:compress</term><listitem><para></para></listitem>
+</varlistentry>
+<varlistentry>
+ <term>TAPETYPE:HP-DAT:length</term><listitem><para></para></listitem>
+</varlistentry>
+<varlistentry>
+ <term>INTERFACE:local:use</term><listitem><para></para></listitem>
+</varlistentry>
+<varlistentry>
+ <term>HOLDINGDISK:hd1:use</term><listitem><para></para></listitem>
+</varlistentry>
+</variablelist>
+ </listitem>
+ </varlistentry>
+
+<varlistentry>
+<term><emphasis remap='B'>-o</emphasis> <replaceable>configoption</replaceable></term>
<listitem>
<para>See the "<emphasis remap='B'>CONFIGURATION OVERWRITE</emphasis>" section in <citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
</listitem>
<arg choice='opt'>-f </arg>
<arg choice='plain'><replaceable>config</replaceable></arg>
<arg choice='plain'><replaceable>label</replaceable></arg>
- <group><arg choice='plain'>slot</arg><arg choice='plain'><replaceable>slot</replaceable></arg></group>
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='opt'>slot <replaceable>slot</replaceable></arg>
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
</varlistentry>
</variablelist>
-<note>Many systems only report good data when a tape is in the drive and ready.
+<note><para>Many systems only report good data when a tape is in the drive and ready.</para>
</note>
-<para />
</refsect1>
<refsect1><title>AUTHOR</title>
<refsynopsisdiv>
<cmdsynopsis>
<command>amrecover</command>
- <group><arg choice='opt'>-C </arg><arg choice='plain'><replaceable>config</replaceable></arg></group>
- <group><arg choice='plain'>-s </arg><arg choice='plain'><replaceable>index-server</replaceable></arg></group>
- <group><arg choice='plain'>-t </arg><arg choice='plain'><replaceable>tape-server</replaceable></arg></group>
- <group><arg choice='plain'>-d </arg><arg choice='plain'><replaceable>tape-device</replaceable></arg></group>
- <group><arg choice='plain'>-o </arg><arg choice='plain'><replaceable>clientconfigoption</replaceable></arg></group>*
+ <arg choice='opt'>-C <replaceable>config</replaceable></arg>
+ <arg choice='opt'>-s <replaceable>index-server</replaceable></arg>
+ <arg choice='opt'>-t <replaceable>tape-server</replaceable></arg>
+ <arg choice='opt'>-d <replaceable>tape-device</replaceable></arg>
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
</refsect1>
<refsect1><title>OPTIONS</title>
-<note>The Default values are those set at compile-time.
+<note><para>The Default values are those set at compile-time.
Use <command>amrestore</command> to recover client-encrypted or
-client-custom-compressed tapes.</note>
+client-custom-compressed tapes.</para>
+</note>
<variablelist remap='TP'>
<varlistentry>
<term><emphasis remap='B'>[ -C ] config</emphasis></term>
<!-- .RE -->
<variablelist remap='TP'>
<varlistentry>
- <term><emphasis remap='B'>setdisk <arg
- choice='plain'><replaceable>diskname</replaceable></arg> <arg
- choice='opt'><replaceable>mountpoint</replaceable></arg></emphasis></term>
+ <term><emphasis remap='B'>setdisk </emphasis><emphasis remap='I'>diskname</emphasis> [<emphasis remap='I'>mountpoint</emphasis>]</term>
<listitem>
<para>Specifies which disk to consider
(default: the disk holding the working directory where
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>listhost [diskdevice]</emphasis></term>
+ <term><emphasis remap='B'>listhost </emphasis>[<emphasis remap='I'>diskdevice</emphasis>]</term>
<listitem>
<para>List all
<emphasis remap='B'>host</emphasis></para>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>listdisk [diskdevice]</emphasis></term>
+ <term><emphasis remap='B'>listdisk </emphasis>[<emphasis remap='I'>diskdevice</emphasis>]</term>
<listitem>
<para>List all
<emphasis remap='B'>diskname</emphasis></para>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>settape [[server]:][tapedev|default]</emphasis></term>
+ <term><emphasis remap='B'>settape </emphasis>[[<emphasis remap='I'>server</emphasis>]:][<emphasis remap='I'>tapedev</emphasis>|<emphasis remap='I'>default</emphasis>]</term>
<listitem>
<para>Specifies the host to use as the tape server, and which of its tape
devices to use.
<programlisting>
settape 192.168.0.10:file:/file1
</programlisting>
-
<para>You can change the tape device when amrecover ask you to load the tape:</para>
<programlisting>
<variablelist remap='TP'>
<varlistentry>
- <term><emphasis remap='B'>setmode mode</emphasis></term>
+ <term><emphasis remap='B'>setmode </emphasis><emphasis remap='I'>mode</emphasis></term>
<listitem>
<para>Set the extraction mode for Samba shares.
If
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>cdx dir</emphasis></term>
+ <term><emphasis remap='B'>cdx </emphasis><emphasis remap='I'>dir</emphasis></term>
<listitem>
<para>Like the
<emphasis remap='B'>cd</emphasis>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>lcd path</emphasis></term>
+ <term><emphasis remap='B'>lcd </emphasis><emphasis remap='I'>path</emphasis></term>
<listitem>
<para>Change the
<command>amrecover</command>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>add item1 item2 ...</emphasis></term>
+ <term><emphasis remap='B'>add </emphasis><emphasis remap='I'>item1 item2 ...</emphasis></term>
<listitem>
<para>Add the specified files or directories to the restore list.
Each item may have shell style wildcards.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>addx item1 item2 ...</emphasis></term>
+ <term><emphasis remap='B'>addx </emphasis><emphasis remap='I'>item1 item2 ...</emphasis></term>
<listitem>
<para>Add the specified files or directories to the restore list.
Each item may be a regular expression.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>delete item1 item2 ...</emphasis></term>
+ <term><emphasis remap='B'>delete </emphasis><emphasis remap='I'>item1 item2 ...</emphasis></term>
<listitem>
<para>Delete the specified files or directories from the restore list.
Each item may have shell style wildcards.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>deletex item1 item2 ...</emphasis></term>
+ <term><emphasis remap='B'>deletex </emphasis><emphasis remap='I'>item1 item2 ...</emphasis></term>
<listitem>
<para>Delete the specified files or directories from the restore list.
Each item may be a regular expression.</para>
</listitem>
</varlistentry>
<varlistentry>
- <term><emphasis remap='B'>list file</emphasis></term>
+ <term><emphasis remap='B'>list </emphasis><emphasis remap='I'>file</emphasis></term>
<listitem>
<para>Display the contents of the restore list.
If a file name is specified,
<command>amreport</command>
<arg choice='opt'><replaceable>config</replaceable></arg>
<arg choice='opt'>-i</arg>
- <group><arg choice='plain'>-M</arg><arg choice='plain'><replaceable>address</replaceable></arg></group>
- <group><arg choice='plain'>-l</arg><arg choice='plain'><replaceable>logfile</replaceable></arg></group>
- <group><arg choice='plain'>-f</arg><arg choice='plain'><replaceable>outputfile</replaceable></arg></group>
- <group><arg choice='plain'>-p</arg><arg choice='plain'><replaceable>postscriptfile</replaceable></arg></group>
- <group><arg choice='plain'>-o</arg><arg choice='plain'><replaceable>configoption</replaceable></arg></group>*
+ <arg choice='opt'>-M <replaceable>address</replaceable></arg>
+ <arg choice='opt'>-l <replaceable>logfile</replaceable></arg>
+ <arg choice='opt'>-f <replaceable>outputfile</replaceable></arg>
+ <arg choice='opt'>-p <replaceable>postscriptfile</replaceable></arg>
+ <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
<command>amtape</command>
<arg choice='plain'><replaceable>config</replaceable></arg>
<arg choice='plain'><replaceable>command</replaceable></arg>
- <arg choice='opt'><arg choice='plain'><replaceable>command</replaceable></arg><arg choice='plain'><replaceable>options</replaceable></arg></arg>
+ <arg choice='opt' rep='repeat'><replaceable>command_options</replaceable></arg>
+ <arg choice='plain' rep='repeat'><group><option>-o </option><replaceable>configoption</replaceable></group></arg>
</cmdsynopsis>
</refsynopsisdiv>
to the next tape, but do not load it.</para>
</listitem>
</varlistentry>
+
+ <varlistentry>
+ <term><emphasis remap='B'>-o</emphasis> <replaceable>configoption</replaceable></term>
+ <listitem>
+<para>See the "<emphasis remap='B'>CONFIGURATION OVERWRITE</emphasis>"
+ section in <citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
+ </listitem>
+ </varlistentry>
+
</variablelist>
<para>This is useful with non-gravity stackers to unload the last tape used
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version='1.0'>
-<xsl:import href="settings.xsl"/>
<xsl:import href="http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl"/>
+<xsl:import href="settings.xsl"/>
+
<xsl:param name="chunk.section.depth" select="0"/>
<xsl:param name="chunk.first.sections" select="1"/>
<xsl:param name="use.id.as.filename" select="1"/>
</xsl:if>
</xsl:template>
-<xsl:template match="refentry">
-
- <xsl:variable name="section" select="refmeta/manvolnum"/>
- <xsl:variable name="name" select="refnamediv/refname[1]"/>
- <xsl:variable name="base.dir" select="$base.dir"/>
- <!-- standard man page width is 64 chars; 6 chars needed for the two
- (x) volume numbers, and 2 spaces, leaves 56 -->
- <xsl:variable name="twidth" select="(74 - string-length(refmeta/refentrytitle)) div 2"/>
-
- <xsl:variable name="reftitle"
- select="substring(refmeta/refentrytitle, 1, $twidth)"/>
-
- <xsl:variable name="title">
- <xsl:choose>
- <xsl:when test="refentryinfo/title">
- <xsl:value-of select="refentryinfo/title"/>
- </xsl:when>
- <xsl:when test="../referenceinfo/title">
- <xsl:value-of select="../referenceinfo/title"/>
- </xsl:when>
- </xsl:choose>
- </xsl:variable>
-
- <xsl:variable name="date">
- <xsl:choose>
- <xsl:when test="refentryinfo/date">
- <xsl:value-of select="refentryinfo/date"/>
- </xsl:when>
- <xsl:when test="../referenceinfo/date">
- <xsl:value-of select="../referenceinfo/date"/>
- </xsl:when>
- </xsl:choose>
- </xsl:variable>
-
- <xsl:variable name="productname">
- <xsl:choose>
- <xsl:when test="refentryinfo/productname">
- <xsl:value-of select="refentryinfo/productname"/>
- </xsl:when>
- <xsl:when test="../referenceinfo/productname">
- <xsl:value-of select="../referenceinfo/productname"/>
- </xsl:when>
- </xsl:choose>
- </xsl:variable>
-
- <xsl:call-template name="write.text.chunk">
- <xsl:with-param name="filename"
- select="concat($base.dir, normalize-space ($name), '.', $section)"/>
- <xsl:with-param name="content">
- <xsl:text>.\"Generated by db2man.xsl. Don't modify this, modify the source.
-.de Sh \" Subsection
-.br
-.if t .Sp
-.ne 5
-.PP
-\fB\\$1\fR
-.PP
-..
-.de Sp \" Vertical space (when we can't use .PP)
-.if t .sp .5v
-.if n .sp
-..
-.de Ip \" List item
-.br
-.ie \\n(.$>=3 .ne \\$3
-.el .ne 3
-.IP "\\$1" \\$2
-..
-.TH "</xsl:text>
- <xsl:value-of select="translate($reftitle,'abcdefghijklmnopqrstuvwxyz', 'ABCDEFGHIJKLMNOPQRSTUVWXYZ')"/>
- <xsl:text>" </xsl:text>
- <xsl:value-of select="refmeta/manvolnum[1]"/>
- <xsl:text> "</xsl:text>
- <xsl:value-of select="normalize-space($date)"/>
- <xsl:text>" "</xsl:text>
- <xsl:value-of select="normalize-space($productname)"/>
- <xsl:text>" "</xsl:text>
- <xsl:value-of select="$title"/>
- <xsl:text>"
-</xsl:text>
- <xsl:apply-templates/>
- <xsl:text> </xsl:text>
-
- <!-- Author section -->
- <xsl:choose>
- <xsl:when test="refentryinfo//author">
- <xsl:apply-templates select="refentryinfo" mode="authorsect"/>
- </xsl:when>
- </xsl:choose>
- </xsl:with-param>
- </xsl:call-template>
-</xsl:template>
-
<xsl:template match="informalexample|screen|programlisting">
<xsl:text>.nf </xsl:text>
<xsl:apply-templates/>
<xsl:text>.fi </xsl:text>
</xsl:template>
-<xsl:template match="//emphasis">
- <xsl:text>\fB</xsl:text>
- <xsl:apply-templates/>
- <xsl:text>\fR</xsl:text>
-</xsl:template>
-
<xsl:template match="para|simpara|remark" mode="list">
<xsl:variable name="foo">
<xsl:apply-templates/>
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amrecover.c,v 1.7 2006/07/25 18:27:57 martinea Exp $
+ * $Id: amrecover.c,v 1.7.2.2 2006/12/12 14:56:38 martinea Exp $
*
* an interactive program for recovering backed-up files
*/
#include "amanda.h"
#include "version.h"
-//#ifdef HAVE_NETINET_IN_SYSTM_H
-//#include <netinet/in_systm.h>
-//#endif
-//#include <netinet/in.h>
-//#ifdef HAVE_NETINET_IP_H
-//#include <netinet/ip.h>
-//#endif
#include "stream.h"
#include "amfeatures.h"
#include "amrecover.h"
/*NOTREACHED*/
}
cwd_length = strlen(cwd);
- dbprintf(("guess_disk: %d: \"%s\"\n", cwd_length, cwd));
+ dbprintf(("guess_disk: %zu: \"%s\"\n", cwd_length, cwd));
if (open_fstab() == 0) {
return -1;
while (get_fstab_nextentry(&fsent))
{
current_length = fsent.mntdir ? strlen(fsent.mntdir) : (size_t)0;
- dbprintf(("guess_disk: %d: %d: \"%s\": \"%s\"\n",
+ dbprintf(("guess_disk: %zu: %zu: \"%s\": \"%s\"\n",
longest_match,
current_length,
fsent.mntdir ? fsent.mntdir : "(mntdir null)",
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: extract_list.c,v 1.6 2006/08/24 01:57:15 paddy_s Exp $
+ * $Id: extract_list.c,v 1.6.2.1 2006/11/08 17:11:39 martinea Exp $
*
* implements the "extract" command in amrecover
*/
regex = "\\.[/]*$";
}
else if(strcmp(regex, "[^/]*[/]*$") == 0) { /* "*" */
- //regex =
regex = "([^/.]|\\.[^/]+|[^/.][^/]*)[/]*$";
} else {
/* remove "/" at end of path */
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amrecover.c,v 1.73 2006/07/25 18:27:57 martinea Exp $
+ * $Id: amrecover.c,v 1.73.2.2 2007/01/24 18:33:30 martinea Exp $
*
* an interactive program for recovering backed-up files
*/
switch (i) {
case 'C':
add_client_conf(CLN_CONF, optarg);
- //config = newstralloc(config, optarg);
break;
case 's':
add_client_conf(CLN_INDEX_SERVER, optarg);
- //server_name = newstralloc(server_name, optarg);
break;
case 't':
add_client_conf(CLN_TAPE_SERVER, optarg);
- //tape_server_name = newstralloc(tape_server_name, optarg);
break;
case 'd':
add_client_conf(CLN_TAPEDEV, optarg);
- //tape_device_name = newstralloc(tape_device_name, optarg);
break;
case 'U':
report_bad_client_arg();
- amfree(server_name);
- server_name = getenv("AMANDA_SERVER");
- if(!server_name) server_name = client_getconf_str(CLN_INDEX_SERVER);
+ server_name = NULL;
+ if (client_getconf_seen(CLN_INDEX_SERVER) == -2) { /* command line argument */
+ server_name = client_getconf_str(CLN_INDEX_SERVER);
+ }
+ if (!server_name) {
+ server_name = getenv("AMANDA_SERVER");
+ if (server_name) {
+ printf("Using index server from environment AMANDA_SERVER (%s)\n", server_name);
+ }
+ }
+ if (!server_name) {
+ server_name = client_getconf_str(CLN_INDEX_SERVER);
+ }
+ if (!server_name) {
+ error("No index server set");
+ /*NOTREACHED*/
+ }
server_name = stralloc(server_name);
- amfree(tape_server_name);
- tape_server_name = getenv("AMANDA_TAPESERVER");
- if(!tape_server_name) tape_server_name = client_getconf_str(CLN_TAPE_SERVER);
+ tape_server_name = NULL;
+ if (client_getconf_seen(CLN_TAPE_SERVER) == -2) { /* command line argument */
+ tape_server_name = client_getconf_str(CLN_TAPE_SERVER);
+ }
+ if (!tape_server_name) {
+ tape_server_name = getenv("AMANDA_TAPE_SERVER");
+ if (!tape_server_name) {
+ tape_server_name = getenv("AMANDA_TAPESERVER");
+ if (tape_server_name) {
+ printf("Using tape server from environment AMANDA_TAPESERVER (%s)\n", tape_server_name);
+ }
+ } else {
+ printf("Using tape server from environment AMANDA_TAPE_SERVER (%s)\n", tape_server_name);
+ }
+ }
+ if (!tape_server_name) {
+ tape_server_name = client_getconf_str(CLN_TAPE_SERVER);
+ }
+ if (!tape_server_name) {
+ error("No tape server set");
+ /*NOTREACHED*/
+ }
tape_server_name = stralloc(tape_server_name);
amfree(tape_device_name);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: display_commands.c,v 1.22 2006/07/05 19:42:17 martinea Exp $
+ * $Id: display_commands.c,v 1.22.2.1 2006/12/22 15:10:26 martinea Exp $
*
* implements the directory-display related commands in amrecover
*/
char *disk_path_slash_dot = NULL;
char *s;
int ch;
+ char *qdisk_path;
if (disk_path == NULL) {
printf("Directory must be set before getting listing\n");
clear_dir_list();
- cmd = stralloc2("OLSD ", disk_path);
+ qdisk_path = quote_string(disk_path);
+ cmd = stralloc2("OLSD ", qdisk_path);
+ amfree(qdisk_path);
if (send_command(cmd) == -1) {
amfree(cmd);
amfree(disk_path_slash);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: extract_list.c,v 1.117 2006/08/24 01:57:15 paddy_s Exp $
+ * $Id: extract_list.c,v 1.117.2.2 2006/12/22 15:10:26 martinea Exp $
*
* implements the "extract" command in amrecover
*/
ssize_t j;
char *dir, *dir_undo, dir_undo_ch = '\0';
char *ditem_path = NULL;
+ char *qditem_path = NULL;
char *l = NULL;
int added;
char *s, *fp, *quoted;
regex = "\\.[/]*$";
}
else if(strcmp(regex, "[^/]*[/]*$") == 0) { /* "*" */
- //regex =
regex = "([^/.]|\\.[^/]+|[^/.][^/]*)[/]*$";
} else {
/* remove "/" at end of path */
ditem_path = newstralloc(ditem_path, ditem->path);
clean_pathname(ditem_path);
- cmd = stralloc2("ORLD ", ditem_path);
+ qditem_path = quote_string(ditem_path);
+ cmd = stralloc2("ORLD ", qditem_path);
+ amfree(qditem_path);
if(send_command(cmd) == -1) {
amfree(cmd);
amfree(ditem_path);
int level = 0;
off_t fileno;
char *ditem_path = NULL;
+ char *qditem_path;
char *l = NULL;
int deleted;
char *s;
ditem_path = newstralloc(ditem_path, ditem->path);
clean_pathname(ditem_path);
- cmd = stralloc2("ORLD ", ditem_path);
+ qditem_path = quote_string(ditem_path);
+ cmd = stralloc2("ORLD ", qditem_path);
+ amfree(qditem_path);
if(send_command(cmd) == -1) {
amfree(cmd);
amfree(ditem_path);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: set_commands.c,v 1.26 2006/07/05 13:14:58 martinea Exp $
+ * $Id: set_commands.c,v 1.26.2.1 2006/12/22 15:10:27 martinea Exp $
*
* implements the "set" commands in amrecover
*/
#include "amanda.h"
+#include "util.h"
#include "amrecover.h"
#ifdef SAMBA_CLIENT
char * date)
{
char *cmd = NULL;
+ char *qdisk_path;
clear_dir_list();
is still valid at the new date, and if not set directory to
mount_point */
if (disk_path != NULL) {
- cmd = newstralloc2(cmd, "OISD ", disk_path);
+ qdisk_path = quote_string(disk_path);
+ cmd = newstralloc2(cmd, "OISD ", qdisk_path);
+ amfree(qdisk_path);
if (exchange(cmd) == -1)
exit(1);
if (server_happy())
char * mtpt)
{
char *cmd = NULL;
+ char *qdsk;
if (is_extract_list_nonempty())
{
}
clear_dir_list();
- cmd = stralloc2("DISK ", dsk);
+ qdsk = quote_string(dsk);
+ cmd = stralloc2("DISK ", qdsk);
+ amfree(qdsk);
if (converse(cmd) == -1)
exit(1);
amfree(cmd);
char * amdevice)
{
char *cmd = NULL;
+ char *qamdevice;
if(amdevice) {
- cmd = stralloc2("LISTDISK ", amdevice);
+ qamdevice = quote_string(amdevice);
+ cmd = stralloc2("LISTDISK ", qamdevice);
+ amfree(qamdevice);
if (converse(cmd) == -1)
exit(1);
amfree(cmd);
{
char *cmd = NULL;
char *new_dir = NULL;
+ char *qnew_dir;
char *dp, *de;
char *ldir = NULL;
}
}
- cmd = stralloc2("OISD ", new_dir);
+ qnew_dir = quote_string(new_dir);
+ cmd = stralloc2("OISD ", qnew_dir);
+ amfree(qnew_dir);
if (exchange(cmd) == -1) {
exit(1);
/*NOTREACHED*/
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amfetchdump.c,v 1.16.2.1 2006/09/27 12:04:09 martinea Exp $
+ * $Id: amfetchdump.c,v 1.16.2.2 2007/01/18 20:07:55 martinea Exp $
*
* retrieves specific dumps from a set of amanda tapes
*/
usage();
/*NOTREACHED*/
}
+ arg_state = ARG_GET_HOST;
+ break;
}
}
* Authors: the Amanda Development Team. Its members are listed in a
* file named AUTHORS, in the root directory of this distribution.
*/
-/* $Id: amidxtaped.c,v 1.73.2.1 2006/09/27 12:04:09 martinea Exp $
+/* $Id: amidxtaped.c,v 1.73.2.3 2006/11/01 12:26:22 martinea Exp $
*
* This daemon extracts a dump image off a tape for amrecover and
* returns it over the network. It basically, reads a number of
char *conf_tapetype;
tapetype_t *tape;
char *line;
+ char *tapedev;
+#ifndef DEBUG_CODE
+ int i;
+#endif
safe_fd(DATA_FD_OFFSET, 4);
safe_cd();
use_changer = 1;
}
+ tapedev = getconf_str(CNF_TAPEDEV);
/* If we'll be stepping on the tape server's devices, lock them. */
if(re_config &&
- (use_changer || (rst_flags->alt_tapedev &&
- strcmp(rst_flags->alt_tapedev,
- getconf_str(CNF_TAPEDEV)) == 0) ) ) {
+ (use_changer || (rst_flags->alt_tapedev && tapedev &&
+ strcmp(rst_flags->alt_tapedev, tapedev) == 0) ) ) {
dbprintf(("%s: Locking devices\n", get_pname()));
parent_pid = getpid();
atexit(cleanup);
get_pname(), rst_flags->pipe_to_fd));
+ tapedev = getconf_str(CNF_TAPEDEV);
if(get_lock == 0 &&
re_config &&
- (use_changer || (rst_flags->alt_tapedev &&
- strcmp(rst_flags->alt_tapedev,
- getconf_str(CNF_TAPEDEV)) == 0) ) ) {
+ (use_changer || (rst_flags->alt_tapedev && tapedev &&
+ strcmp(rst_flags->alt_tapedev, tapedev) == 0) ) ) {
send_message(cmdout, rst_flags, their_features,
"%s exists: amdump or amflush is already running, "
"or you must run amcleanup",
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amrestore.c,v 1.63 2006/07/25 18:58:10 martinea Exp $
+ * $Id: amrestore.c,v 1.63.2.1 2006/11/08 17:11:40 martinea Exp $
*
* retrieves files from an amanda tape
*/
case 'p': rst_flags->pipe_to_fd = fileno(stdout); break;
case 'h': rst_flags->headers = 1; break;
case 'f':
- filefsf = (off_t)strtoll(optarg, &e, 10);
+ filefsf = (off_t)OFF_T_STRTOL(optarg, &e, 10);
/*@ignore@*/
if(*e != '\0') {
error("invalid fileno value \"%s\"", optarg);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: restore.c,v 1.52.2.2 2006/09/27 14:04:27 martinea Exp $
+ * $Id: restore.c,v 1.52.2.7 2007/01/04 20:20:48 martinea Exp $
*
* retrieves files from an amanda tape
*/
error("restore: write error = %s", strerror(errno));
/*NOTREACHED*/
}
- error("Short write: wrote %d bytes expected %d.", s, bytes_read);
+ error("Short write: wrote %zd bytes expected %zd.", s, bytes_read);
/*NOTREACHCED*/
}
wc += (off_t)bytes_read;
amfree(tmp_filename);
tmp_filename = tmpstr;
}
- final_filename = stralloc(tmp_filename);
- tmp_filename = newvstralloc(tmp_filename, ".tmp", NULL);
+ final_filename = tmp_filename;
+ tmp_filename = vstralloc(final_filename, ".tmp", NULL);
if((dest = open(tmp_filename, (O_CREAT | O_RDWR | O_TRUNC),
CREAT_MODE)) < 0) {
error("could not create output file %s: %s",
error("write error: %s", strerror(errno));
/*NOTREACHED*/
} else {
- error("write error: %d instead of %d", w, DISK_BLOCK_BYTES);
+ error("write error: %zd instead of %d", w, DISK_BLOCK_BYTES);
/*NOTREACHED*/
}
}
error("restore: write error: %s", strerror(errno));
/* NOTREACHED */
} else if (s < bytes_read) {
- error("restore: wrote %d of %d bytes: %s",
+ error("restore: wrote %zd of %zd bytes: %s",
s, bytes_read, strerror(errno));
/* NOTREACHED */
}
"enter, ^D to finish reading tapes\n");
}
fflush(prompt_out);
- if((input = agets(stdin)) == NULL)
+ if((input = agets(prompt_in)) == NULL)
ret = -1;
}
seentapes_t *seentapes = NULL;
int ret;
+ if(!prompt_out) prompt_out = stderr;
+
dbprintf(("search_tapes(prompt_out=%d, prompt_in=%d, use_changer=%d, "
"tapelist=%p, "
"match_list=%p, flags=%p, features=%p)\n",
fileno(prompt_out), fileno(prompt_in), use_changer, tapelist,
match_list, flags, their_features));
- if(!prompt_out) prompt_out = stderr;
-
if(flags->blocksize)
blocksize = (size_t)flags->blocksize;
else if(blocksize == (size_t)SSIZE_MAX)
/* Suss what tape device we're using, whether there's a changer, etc. */
if(!use_changer || (have_changer = changer_init()) == 0) {
- if(flags->alt_tapedev) cur_tapedev = stralloc(flags->alt_tapedev);
- else if(!cur_tapedev) cur_tapedev = getconf_str(CNF_TAPEDEV);
+ if (flags->alt_tapedev) {
+ cur_tapedev = stralloc(flags->alt_tapedev);
+ } else if(!cur_tapedev) {
+ cur_tapedev = getconf_str(CNF_TAPEDEV);
+ if (cur_tapedev == NULL) {
+ error("No tapedev specified");
+ }
+ }
/* XXX oughta complain if no config is loaded */
fprintf(stderr, "%s: Using tapedev %s\n", get_pname(), cur_tapedev);
have_changer = 0;
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
* University of Maryland at College Park
*/
/*
- * $Id: amadmin.c,v 1.124 2006/07/26 15:17:37 martinea Exp $
+ * $Id: amadmin.c,v 1.124.2.1 2006/11/01 14:45:39 martinea Exp $
*
* controlling process for the Amanda backup system
*/
am_host_t *hp;
interface_t *ip;
sle_t *excl;
- time_t st;
- struct tm *stm;
hp = dp->host;
ip = hp->netif;
printf(" record %s\n", (dp->record? "YES" : "NO"));
printf(" index %s\n", (dp->index? "YES" : "NO"));
- st = dp->start_t;
- if(st) {
- stm = localtime(&st);
- if (stm)
- printf(" starttime %d:%02d:%02d\n",
- stm->tm_hour, stm->tm_min, stm->tm_sec);
- else
- printf(" starttime BAD DATE\n");
- }
+ printf(" starttime %04d\n", (int)dp->starttime);
if(dp->tape_splitsize > (off_t)0) {
printf(" tape_splitsize " OFF_T_FMT "\n",
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amcheck.c,v 1.149.2.2 2006/09/21 11:16:57 martinea Exp $
+ * $Id: amcheck.c,v 1.149.2.10 2007/02/05 18:54:13 martinea Exp $
*
* checks for common problems in server and clients
*/
exit(1);
#endif
break;
- case 's': do_localchk = do_clientchk = do_tapechk = 1;
+ case 's': do_localchk = do_tapechk = 1;
break;
case 'c': do_clientchk = 1;
break;
}
}
- conf_ctimeout = getconf_time(CNF_CTIMEOUT);
+ conf_ctimeout = getconf_int(CNF_CTIMEOUT);
conf_diskfile = getconf_str(CNF_DISKFILE);
if (*conf_diskfile == '/') {
error("mailfd write: %s", strerror(errno));
/*NOTREACHED*/
} else {
- error("mailfd write: wrote %d instead of %d", w, r);
+ error("mailfd write: wrote %zd instead of %zd", w, r);
/*NOTREACHED*/
}
}
amfree(tape_dir);
amfree(holdfile);
tapename = getconf_str(CNF_TAPEDEV);
- if (strncmp(tapename, "null:", 5) == 0) {
+ if (tapename == NULL) {
+ if (getconf_str(CNF_TPCHANGER) == NULL) {
+ fprintf(outf, "WARNING: No tapedev or tpchanger specified\n");
+ testtape = 0;
+ do_tapechk = 0;
+ }
+ } else if (strncmp(tapename, "null:", 5) == 0) {
fprintf(outf,
"WARNING: tapedev is %s, dumps will be thrown away\n",
tapename);
quoted, (OFF_T_FMT_TYPE)holdingdisk_get_disksize(hdp));
disklow = 1;
}
- else if(holdingdisk_get_disksize(hdp) == (off_t)0) {
- fprintf(outf, "WARNING: holding disk %s: "
- "use nothing because 'use' is set to 0\n",
- quoted);
- }
else if(holdingdisk_get_disksize(hdp) > (off_t)0) {
if(fs.avail < holdingdisk_get_disksize(hdp)) {
fprintf(outf,
quoted,
(OFF_T_FMT_TYPE)(fs.avail/(off_t)unitdivisor),
displayunit,
- (OFF_T_FMT_TYPE)(fs.avail + holdingdisk_get_disksize(hdp) / (off_t)unitdivisor),
+ (OFF_T_FMT_TYPE)((fs.avail + holdingdisk_get_disksize(hdp)) / (off_t)unitdivisor),
displayunit);
}
}
tape_status = taper_scan(NULL, &label, &datestamp, &tapename,
FILE_taperscan_output_callback, outf);
+ if (tapename) {
+ if (tape_access(tapename,F_OK) == -1) {
+ fprintf(outf, "ERROR: Can't access device %s: %s\n", tapename,
+ strerror(errno));
+ }
+ if (tape_access(tapename,R_OK) == -1) {
+ fprintf(outf, "ERROR: Can't read device %s: %s\n", tapename,
+ strerror(errno));
+ }
+ if (tape_access(tapename,W_OK) == -1) {
+ fprintf(outf, "ERROR: Can't write to device %s: %s\n", tapename,
+ strerror(errno));
+ }
+ }
if (tape_status < 0) {
tape_t *exptape = lookup_last_reusable_tape(0);
fprintf(outf, " (expecting ");
amfree(conf_infofile);
infobad = 1;
} else {
+ char *errmsg = NULL;
+ if (check_infofile(conf_infofile, &origq, &errmsg) == -1) {
+ fprintf(outf, "ERROR: Can't copy infofile: %s\n", errmsg);
+ amfree(errmsg);
+ }
strappend(conf_infofile, "/");
}
amfree(quoted);
fi
if test -h /proc/1/exe ; then
- if test $# -eq 1 ; then
- KILL_ENABLE=0
- conf=$1
- shift;
- elif test $# -eq 2 && test "$1" == "-k" ; then
+ if test $# -ge 2 && test "$1" == "-k" ; then
KILL_ENABLE=1
conf=$2
shift
shift
+ elif test $# -ge 1 ; then
+ KILL_ENABLE=0
+ conf=$1
+ shift;
else
echo "Usage: amcleanup [-k] conf"
exit 1
fi
else
- if test $# -ne 1 ; then
+ if test $# -lt 1 ; then
echo "Usage: amcleanup conf"
exit 1
else
conf=$1
+ shift
KILL_ENABLE=0
fi
fi
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amcleanupdisk.c,v 1.22 2006/07/25 18:27:57 martinea Exp $
+ * $Id: amcleanupdisk.c,v 1.22.2.1 2006/10/03 18:57:25 martinea Exp $
*/
#include "amanda.h"
/* Don't die when child closes pipe */
signal(SIGPIPE, SIG_IGN);
- if(main_argc != 2) {
- error("Usage: amcleanupdisk%s <confdir>", versionsuffix());
+ if(main_argc < 2) {
+ error("Usage: amcleanupdisk%s <config>", versionsuffix());
/*NOTREACHED*/
}
exit 1
fi
+exit_status=0;
conf=$1
if [ ! -d $confdir/$conf ]; then
umask 077
+exit_code=0
# Plan and drive the dumps.
#exec </dev/null >$errfile 2>&1
touch $errfile
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
exec </dev/null 2>>$errfile 1>&2
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
echo "amdump: start at `date`"
echo "amdump: datestamp `date +%Y%m%d`"
+echo "amdump: starttime `date +%Y%m%d%H%M%S`"
$libexecdir/planner$SUF $conf "$@" | $libexecdir/driver$SUF $conf "$@"
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
echo "amdump: end at `date`"
# Send out a report on the dumps.
$sbindir/amreport$SUF $conf "$@"
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
# Roll the log file to its datestamped name.
$libexecdir/amlogroll$SUF $conf "$@"
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
# Trim the log file to those for dumps that still exist.
$libexecdir/amtrmlog$SUF $conf "$@"
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
# Trim the index file to those for dumps that still exist.
$libexecdir/amtrmidx$SUF $conf "$@"
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
# Keep a debug log through the tapecycle plus a couple of days.
maxdays=`expr $tapecycle + 2`
while [ $days -ge 2 ]; do
ndays=`expr $days - 1`
mv $errfile.$ndays $errfile.$days
+ exit_code=$?
+ echo $exit_code
+ [ $exit_code -ne 0 ] && exit_status=$exit_code
days=$ndays
done
mv $errfile $errfile.1
+exit_code=$?
+[ $exit_code -ne 0 ] && exit_status=$exit_code
-exit 0
+exit $exit_status
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amflush.c,v 1.95 2006/07/25 21:41:24 martinea Exp $
+ * $Id: amflush.c,v 1.95.2.3 2007/02/01 19:25:15 martinea Exp $
*
* write files from work directory onto tape
*/
char **new_argv, **my_argv;
char *errstr;
struct tm *tm;
+ char *tapedev;
+ char *tpchanger;
safe_fd(-1, 0);
safe_cd();
logroll_program = vstralloc(libexecdir, "/", "amlogroll", versionsuffix(),
NULL);
+ tapedev = getconf_str(CNF_TAPEDEV);
+ tpchanger = getconf_str(CNF_TPCHANGER);
+ if (tapedev == NULL && tpchanger == NULL) {
+ error("No tapedev or tpchanger specified");
+ }
+
if(datearg) {
sle_t *dir, *next_dir;
int i, ok;
error("BAD DATE"); /* should never happen */
fprintf(stderr, "amflush: start at %s\n", date_string);
fprintf(stderr, "amflush: datestamp %s\n", amflush_timestamp);
+ fprintf(stderr, "amflush: starttime %s\n", construct_timestamp(NULL));
log_add(L_START, "date %s", amflush_timestamp);
/* START DRIVER */
* University of Maryland at College Park
*/
/*
- * $Id: amindex.c,v 1.15 2006/05/25 01:47:19 johnfranks Exp $
+ * $Id: amindex.c,v 1.15.2.1 2006/11/24 18:05:05 martinea Exp $
*
* index control
*/
return buf;
}
+
+char *
+getoldindexfname(
+ char * host,
+ char * disk,
+ char * date,
+ int level)
+{
+ char *conf_indexdir;
+ char *buf;
+ char level_str[NUM_STR_SIZE];
+ char datebuf[14 + 1];
+ char *dc = NULL;
+ char *pc;
+ int ch;
+
+ if (date != NULL) {
+ dc = date;
+ pc = datebuf;
+ while (pc < datebuf + SIZEOF(datebuf)) {
+ ch = *dc++;
+ *pc++ = (char)ch;
+ if (ch == '\0') {
+ break;
+ } else if (! isdigit (ch)) {
+ pc--;
+ }
+ }
+ datebuf[SIZEOF(datebuf)-1] = '\0';
+ dc = datebuf;
+
+ snprintf(level_str, SIZEOF(level_str), "%d", level);
+ }
+
+ host = old_sanitise_filename(host);
+ if (disk != NULL) {
+ disk = old_sanitise_filename(disk);
+ }
+
+ conf_indexdir = getconf_str(CNF_INDEXDIR);
+ if (*conf_indexdir == '/') {
+ conf_indexdir = stralloc(conf_indexdir);
+ } else {
+ conf_indexdir = stralloc2(config_dir, conf_indexdir);
+ }
+ /*
+ * Note: vstralloc() will stop at the first NULL, which might be
+ * "disk" or "dc" (datebuf) rather than the full file name.
+ */
+ buf = vstralloc(conf_indexdir, "/",
+ host, "/",
+ disk, "/",
+ dc, "_",
+ level_str, COMPRESS_SUFFIX,
+ NULL);
+
+ amfree(conf_indexdir);
+ amfree(host);
+ amfree(disk);
+
+ return buf;
+}
* University of Maryland at College Park
*/
/*
- * $Id: amindex.h,v 1.8 2006/05/25 01:47:19 johnfranks Exp $
+ * $Id: amindex.h,v 1.8.2.1 2006/11/24 18:05:06 martinea Exp $
*
* headers for index control
*/
#include "conffile.h"
char *getindexfname(char *host, char *disk, char *date, int level);
+char *getoldindexfname(char *host, char *disk, char *date, int level);
#endif /* AMINDEX_H */
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amindexd.c,v 1.106.2.2 2006/09/27 12:04:09 martinea Exp $
+ * $Id: amindexd.c,v 1.106.2.9 2007/02/07 15:23:45 martinea Exp $
*
* This is the server daemon part of the index client/server system.
* It is assumed that this is launched from inetd instead of being
#include "tapefile.h"
#include "util.h"
#include "amandad.h"
+#include "pipespawn.h"
#include <grp.h>
static int are_dumps_compressed(void);
static char *amindexd_nicedate (char *datestamp);
static int cmp_date (const char *date1, const char *date2);
+static char *clean_backslash(char *line);
int main(int, char **);
static REMOVE_ITEM *
struct stat stat_filename;
int result;
size_t len;
+ int pipe_from_gzip;
+ int pipe_to_sort;
+ int indexfd;
+ int nullfd;
+ int debugfd;
+ int debugnullfd;
+ char line[STR_SIZE];
+ FILE *pipe_stream;
+ pid_t pid_gzip;
+ pid_t pid_sort;
+ amwait_t wait_status;
+
filename = stralloc(filename_gz);
len = strlen(filename);
return NULL;
}
- cmd = vstralloc(UNCOMPRESS_PATH,
#ifdef UNCOMPRESS_OPT
- " ", UNCOMPRESS_OPT,
+# define PARAM_UNCOMPRESS_OPT UNCOMPRESS_OPT
+#else
+# define PARAM_UNCOMPRESS_OPT skip_argument
#endif
- " \'", filename_gz, "\'",
- " 2>/dev/null",
- " | (LC_ALL=C; export LC_ALL ; sort) ",
- " > ", "\'", filename, "\'",
- NULL);
- dbprintf(("%s: uncompress command: %s\n",
- debug_prefix_time(NULL), cmd));
- if (system(cmd) != 0) {
- *emsg = newvstralloc(*emsg, "\"", cmd, "\" failed", NULL);
- unlink(filename);
- errno = -1;
+
+ debugfd = dbfd();
+ debugnullfd = 0;
+ if(debugfd < 0) {
+ debugfd = open("/dev/null", O_WRONLY);
+ debugnullfd = 1;
+ }
+
+ nullfd = open("/dev/null", O_RDONLY);
+ indexfd = open(filename,O_WRONLY|O_CREAT, 0600);
+ if (indexfd == -1) {
+ *emsg = newvstralloc(*emsg, "Can't open '",
+ filename, "' for writting: ",
+ strerror(errno),
+ NULL);
+ dbprintf(("%s\n",*emsg));
+ amfree(filename);
+ return NULL;
+ }
+
+ /* start the uncompress process */
+ putenv(stralloc("LC_ALL=C"));
+ pid_gzip = pipespawn(UNCOMPRESS_PATH, STDOUT_PIPE,
+ &nullfd, &pipe_from_gzip, &debugfd,
+ UNCOMPRESS_PATH, PARAM_UNCOMPRESS_OPT,
+ filename_gz, NULL);
+ aclose(nullfd);
+
+ pipe_stream = fdopen(pipe_from_gzip,"r");
+ if(pipe_stream == NULL) {
+ *emsg = newvstralloc(*emsg, "Can't fdopen pipe from gzip: ",
+ strerror(errno),
+ NULL);
+ dbprintf(("%s\n",*emsg));
amfree(filename);
- amfree(cmd);
return NULL;
}
+ /* start the sort process */
+ pid_sort = pipespawn(SORT_PATH, STDIN_PIPE,
+ &pipe_to_sort, &indexfd, &debugfd,
+ SORT_PATH, NULL);
+ if (debugnullfd == 1)
+ aclose(debugfd);
+ aclose(indexfd);
+
+ /* send all ouput from uncompress process to sort process */
+ /* clean the data with clean_backslash */
+ while (fgets(line, STR_SIZE, pipe_stream) != NULL) {
+ if (line[0] != '\0') {
+ if (index(line,'/')) {
+ clean_backslash(line);
+ fullwrite(pipe_to_sort,line,strlen(line));
+ }
+ }
+ }
+
+ fclose(pipe_stream);
+ aclose(pipe_to_sort);
+ if (waitpid(pid_gzip, &wait_status, 0) < 0) {
+ if (!WIFEXITED(wait_status)) {
+ dbprintf(("Uncompress exited with signal %d",
+ WTERMSIG(wait_status)));
+ } else if (WEXITSTATUS(wait_status) != 0) {
+ dbprintf(("Uncompress exited with status %d",
+ WEXITSTATUS(wait_status)));
+ } else {
+ dbprintf(("Uncompres returned negative value: %s",
+ strerror(errno)));
+ }
+ }
+ if (waitpid(pid_sort, &wait_status, 0)) {
+ if (!WIFEXITED(wait_status)) {
+ dbprintf(("Sort exited with signal %d",
+ WTERMSIG(wait_status)));
+ } else if (WEXITSTATUS(wait_status) != 0) {
+ dbprintf(("Sort exited with status %d",
+ WEXITSTATUS(wait_status)));
+ } else {
+ dbprintf(("Sort returned negative value: %s",
+ strerror(errno)));
+ }
+ }
+
/* add at beginning */
remove_file = (REMOVE_ITEM *)alloc(SIZEOF(REMOVE_ITEM));
remove_file->filename = stralloc(filename);
int recursive,
char ** emsg)
{
- char *line = NULL;
+ char line[STR_SIZE];
char *old_line = NULL;
char *filename = NULL;
char *filename_gz;
char *s;
int ch;
size_t len_dir_slash;
+ struct stat statbuf;
if (strcmp(dir, "/") == 0) {
dir_slash = stralloc(dir);
filename_gz = getindexfname(dump_hostname, disk_name, dump_item->date,
dump_item->level);
+ if (stat(filename_gz, &statbuf) < 0 && errno == ENOENT) {
+ amfree(filename_gz);
+ filename_gz = getoldindexfname(dump_hostname, disk_name,
+ dump_item->date, dump_item->level);
+ }
if((filename = uncompress_file(filename_gz, emsg)) == NULL) {
amfree(filename_gz);
amfree(dir_slash);
len_dir_slash=strlen(dir_slash);
- while ((line = agets(fp)) != NULL) {
+ while (fgets(line, STR_SIZE, fp) != NULL) {
if (line[0] != '\0') {
+ if(line[strlen(line)-1] == '\n')
+ line[strlen(line)-1] = '\0';
if(strncmp(dir_slash, line, len_dir_slash) == 0) {
if(!recursive) {
s = line + len_dir_slash;
if(old_line == NULL || strcmp(line, old_line) != 0) {
add_dir_list_item(dump_item, line);
amfree(old_line);
- old_line = line;
- line = NULL;
+ old_line = stralloc(line);
}
}
}
- /*@i@*/ amfree(line);
}
afclose(fp);
/*@i@*/ amfree(old_line);
char *dir)
{
DUMP_ITEM *item;
- char *line = NULL;
+ char line[STR_SIZE];
FILE *fp;
int last_level;
char *ldir = NULL;
amfree(ldir);
return -1;
}
- for(; (line = agets(fp)) != NULL; free(line)) {
+ while (fgets(line, STR_SIZE, fp) != NULL) {
if (line[0] == '\0')
continue;
+ if(line[strlen(line)-1] == '\n')
+ line[strlen(line)-1] = '\0';
if (strncmp(line, ldir, ldir_len) != 0) {
continue; /* not found yet */
}
amfree(filename);
amfree(ldir);
- amfree(line);
afclose(fp);
return 0;
}
return 0;
}
- dbprintf(("%s: No tapedev or changer in config site.\n",
+ dbprintf(("%s: No tapedev or tpchanger in config site.\n",
debug_prefix_time(NULL)));
- reply(501, "Tapedev or changer not set in config file.");
+ reply(501, "Tapedev or tpchanger not set in config file.");
return -1;
}
{
return strncmp(date1, date2, strlen(date2));
}
+
+static char *
+clean_backslash(
+ char *line)
+{
+ char *s = line, *s1, *s2;
+ char *p = line;
+ int i;
+
+ while(*s != '\0') {
+ if (*s == '\\') {
+ s++;
+ s1 = s+1;
+ s2 = s+2;
+ if (*s != '\0' && isdigit(*s) &&
+ *s1 != '\0' && isdigit(*s1) &&
+ *s2 != '\0' && isdigit(*s2)) {
+ /* this is \000, an octal value */
+ i = ((*s)-'0')*64 + ((*s1)-'0')*8 + ((*s2)-'0');
+ *p++ = i;
+ s += 3;
+ } else if (*s == '\\') { /* we remove one / */
+ *p++ = *s++;
+ } else { /* we keep the / */
+ *p++ = '\\';
+ *p++ = *s++;
+ }
+ } else {
+ *p++ = *s++;
+ }
+ }
+ *p = '\0';
+
+ return line;
+}
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amlabel.c,v 1.53 2006/07/25 18:27:57 martinea Exp $
+ * $Id: amlabel.c,v 1.53.2.2 2007/02/06 14:07:44 martinea Exp $
*
* write an Amanda label on a tape
*/
new_argv[0], conffile);
usage();
}
- tapename = stralloc(getconf_str(CNF_TAPEDEV));
+ tapename = getconf_str(CNF_TAPEDEV);
+ if (tapename == NULL) {
+ error("No tapedev specified");
+ } else {
+ tapename = stralloc(tapename);
+ }
#ifdef HAVE_LIBVTBLC
rawtapedev = stralloc(getconf_str(CNF_RAWTAPEDEV));
#endif /* HAVE_LIBVTBLC */
error("couldn't write tapelist: %s", strerror(errno));
/*NOTREACHED*/
}
+
+ if (have_changer) {
+ changer_label(outslot, label);
+ }
} /* write tape list */
printf(", done.\n");
} else {
use Carp;
use POSIX;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
sub Usage {
print STDERR <<END;
Usage: $0 [[-config] CONFIG] [-hostwidth width] [-diskwidth width] [-skipmissed] [-last] [-num0] [-togo0] [-verbose]
die "$0: error in opening `$amadmin $opt_config find' pipe: $!\n";
<$fh>;
while (<$fh>) {
-print "'$_'\n";
chomp;
next if /found Amanda directory/;
next if /skipping cruft directory/;
next if /skip-incr/;
- ($date, $host, $disk, $level, $tape, $file, $part, $status) = quotewords(" ", 0, $_);
+
+ ($date, $time, $host, $disk, $level, $tape, $file, $part, $status) = shellwords($_);
+
next if $date eq 'date';
next if $date eq 'Warning:';
next if $date eq 'Scanning';
next if $date eq "";
+
+ if($time !~/^\d\d:\d\d:\d\d$/) {
+ $status = $part;
+ $part = $file;
+ $file = $tape;
+ $tape = $level;
+ $level = $disk;
+ $disk = $host;
+ $host = $time;
+ }
+
if ($date =~ /^\d\d\d\d-\d\d-\d\d$/) {
- defined($level{$host}{$disk}{$date}) or
- $level{$host}{$disk}{$date} = '';
- $level{$host}{$disk}{$date} .= ($status eq 'OK') ? $level : 'E';
- $dates{$date}++;
+ if(defined $disks{$host}{$disk}) {
+ defined($level{$host}{$disk}{$date}) or
+ $level{$host}{$disk}{$date} = '';
+ $level{$host}{$disk}{$date} .= ($status eq 'OK') ? $level : 'E';
+ $dates{$date}++;
+ }
}
else {
print "bad date $date in $_\n";
require "newgetopt.pl";
use Time::Local;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
$confdir="@CONFIG_DIR@";
$prefix='@prefix@';
$prefix=$prefix; # avoid warnings about possible typo
$exec_prefix=$exec_prefix; # ditto
$sbindir="@sbindir@";
+#$STATUS_STRANGE = 2;
+$STATUS_FAILED = 4;
+$STATUS_MISSING = 8;
+$STATUS_TAPE = 16;
+$exit_status = 0;
+
$USE_VERSION_SUFFIXES='@USE_VERSION_SUFFIXES@';
$suf = '';
if ( $USE_VERSION_SUFFIXES =~ /^yes$/i ) {
}
+if ( ! -e "$confdir/$conf" ) {
+ print "Configuration directory '" . $confdir/$conf . "' doesn't exist\n";
+ exit 1;
+}
if ( ! -d "$confdir/$conf" ) {
- die "amstatus$suf: could not find directory $confdir/$conf";
+ print "Configuration directory '" . $confdir/$conf . "' is not a directory\n";
+ exit 1;
}
-$oldPATH = $ENV{'PATH'};
-$ENV{'PATH'} = "/bin:/usr/bin:/usr/sbin:/sbin"; # force known path
-
$pwd = `pwd`;
chomp $pwd;
chdir "$confdir/$conf";
}
$unit=`$sbindir/amgetconf$suf displayunit`;
-$ENV{'PATH'} = $oldPATH;
chomp($unit);
$unitdivisor=1;
if($unit eq 'K') {
$ntsize{$nb_tape} = 0;
$ntesize{$nb_tape} = 0;
$tape_size = 0;
+$driver_finished = 0;
while(<AMDUMP>) {
chomp;
if(/(amdump|amflush): start at (.*)/) {
print " from $2\n";
- $starttime=&unctime(split(/[ ]+/,$2));
}
- elsif(/amdump: datestamp (\S+)/) {
- $gdatestamp = $1;
+ elsif(/(amdump|amflush): datestamp (\S+)/) {
+ $gdatestamp = $2;
if(!defined $datestamp{$gdatestamp}) {
$datestamp{$gdatestamp} = 1;
push @datestamp, $gdatestamp;
}
+ $starttime=&set_starttime($2);
+ }
+ elsif(/(amdump|amflush): starttime (\S+)/) {
+ $starttime=&set_starttime($2);
}
elsif(/planner: timestamp (\S+)/) {
$gdatestamp = $1;
$taper_started{$hostpart}=1;
$taper_finished{$hostpart}=0;
$taper_time{$hostpart}=$1;
+ $ntchunk_size = 0;
}
#features (maybe missing features)
elsif(/driver: send-cmd time (\S+) to taper: FILE-WRITE (\d+-\d+) (\S+) (\S+) (\S*) (\S+) (\d*) (\S+)/){
$taper_started{$hostpart}=1;
$taper_finished{$hostpart}=0;
$taper_time{$hostpart}=$1;
+ $ntchunk_size = 0;
}
elsif(/driver: send-cmd time (\S+) to taper: PORT-WRITE (\d+-\d+) (\S+) (\S+) \d+( \d+|)/){
$current_time=$1;
$taper_started{$hostpart}=1;
$taper_finished{$hostpart}=0;
$taper_time{$hostpart}=$1;
+ $ntchunk_size = 0;
}
elsif(/driver: send-cmd time (\S+) to taper: PORT-WRITE (\d+-\d+) (\S+) (\S+) (\S+) \d+ \d+/){
$current_time=$1;
$taper_started{$hostpart}=1;
$taper_finished{$hostpart}=0;
$taper_time{$hostpart}=$1;
+ $ntchunk_size = 0;
}
elsif(/driver: result time (\S+) from taper: (DONE|PARTIAL) (\d+-\d+) (\S+) (\d+) "?\[sec (\S+) kb (\d+) kps/) {
$current_time=$1;
$size{$hostpart}=$size;
}
$ntpartition{$nb_tape}++;
- $ntsize{$nb_tape} += $size{$hostpart};
+ $ntsize{$nb_tape} += $size{$hostpart} - $ntchunk_size;
if(defined $esize{$hostpart} && $esize{$hostpart} > 1) {
- $ntesize{$nb_tape} += $esize{$hostpart};
+ $ntesize{$nb_tape} += $esize{$hostpart} - $ntchunk_size;
}
else {
- $ntesize{$nb_tape} += $size{$hostpart};
+ $ntesize{$nb_tape} += $size{$hostpart} - $ntchunk_size;
}
if ($3 eq "PARTIAL") {
$partial{$hostpart} = 1;
else {
$partial{$hostpart} = 0;
}
+ if($ntchunk_size > 0) {
+ $ntchunk{$nb_tape}++;
+ }
}
elsif(/driver: result time (\S+) from taper: (TRY-AGAIN|TAPE-ERROR) (\d+-\d+) (.+)/) {
$current_time=$1;
$ntpartition{$nb_tape} = 0;
$ntsize{$nb_tape} = 0;
$ntesize{$nb_tape} = 0;
+ $ntchunk{$nb_tape} = 0;
+ }
+ elsif(/splitting chunk that started at \d*kb after (\d*)kb/) {
+ $ntchunk{$nb_tape}++;
+ $ntsize{$nb_tape} += $1;
+ $ntesize{$nb_tape} += $1;
+ $ntchunk_size += $1;
+ }
+ elsif(/driver: FINISHED/) {
+ $driver_finished = 1;
}
else {
#print "Ignoring: $_\n";
printf "%-${maxnamelength}s%2d", "$host:$partition", $level{$hostpart};
printf " no estimate\n";
}
+ $exit_status |= $STATUS_FAILED;
$fpartition++;
+ $fsize+=$esize{$hostpart};
}
}
else {
$desize += $esize{$hostpart};
}
if(defined $dump_started{$hostpart} &&
- $dump_started{$hostpart} == 1 &&
+ $dump_started{$hostpart} == 1 &&
+ $dump_finished{$hostpart} == -1) {
+ if(defined $opt_failed) {
+ printf "%8s ", $datestamp if defined $opt_date;
+ printf "%-${maxnamelength}s%2d", "$host:$partition", $level{$hostpart};
+ printf "%9d$unit", $esize{$hostpart};
+ print " dump to tape failed: " . $error{$hostpart};
+ print "\n";
+ }
+ $exit_status |= $STATUS_FAILED;
+ $fpartition++;
+ $fsize+=$esize{$hostpart};
+ }
+ elsif(defined $dump_started{$hostpart} &&
+ $dump_started{$hostpart} == 1 &&
$dump_finished{$hostpart} == 0 &&
$taper_started{$hostpart} == 1) {
if( defined $opt_dumpingtape ) {
}
print "\n";
}
+ $exit_status |= $STATUS_TAPE;
$tfpartition++;
$tfsize += $xsize;
if( defined $starttime ) {
print " (", &showtime($taper_time{$hostpart}), ")";
}
- print ", PARTIAL" if defined $partial{$hostpart} &&
- $partial{$hostpart} == 1;
+ if(defined $partial{$hostpart} && $partial{$hostpart} == 1) {
+ print ", PARTIAL";
+ $exit_status |= $STATUS_FAILED;
+ }
print "\n";
}
$tpartition++;
printf "%-${maxnamelength}s%2d", "$host:$partition", $level{$hostpart};
printf " " . $error{$hostpart} . "\n";
}
+ $exit_status |= $STATUS_FAILED;
+
$fpartition++;
$fsize+=$esize{$hostpart};
}
printf "%9d$unit", $esize{$hostpart};
print " wait for dumping $error{$hostpart}\n";
}
+ if($driver_finished == 1) {
+ $exit_status |= $STATUS_MISSING;
+ }
$wpartition++;
$wsize += $esize{$hostpart};
}
}
print "\n";
}
+ $exit_status |= $STATUS_FAILED;
$fpartition++;
$fsize+=$esize{$hostpart};
}
print " (", &showtime($dump_time{$hostpart}), ")";
}
print ", wait for writing to tape";
- print ", PARTIAL" if defined $partial{$hostpart} &&
- $partial{$hostpart} == 1;;
+ if(defined $partial{$hostpart} && $partial{$hostpart} == 1) {
+ print ", PARTIAL";
+ $exit_status |= $STATUS_FAILED;
+ }
print "\n";
}
$dpartition++;
printf "%-${maxnamelength}s%2d", "$host:$partition", $level{$hostpart};
printf "%9d$unit", $size{$hostpart};
print " waiting to flush";
- print ", PARTIAL" if defined $partial{$hostpart} &&
- $partial{$hostpart} == 1;
+ if(defined $partial{$hostpart} && $partial{$hostpart} == 1) {
+ print ", PARTIAL";
+ $exit_status |= $STATUS_FAILED;
+ }
print "\n";
}
$wfpartition++;
if($nb_tape > 1 || $tape_size != 0) {
for($i=1; $i <= $nb_tape; $i++) {
if($tape_size != 0) {
- printf " tape %-3d : %3d %9d$unit %9d$unit (%6.2f%%) %s\n",
+ printf " tape %-3d : %3d %9d$unit %9d$unit (%6.2f%%) %s",
$i, $ntpartition{$i}, $ntsize{$i}, $ntesize{$i}, 100*$ntsize{$i}/$tape_size, $ntlabel{$i};
+ if($ntchunk{$i} > 0) {
+ printf " (%d chunks)", $ntchunk{$i};
+ }
+ print "\n";
}
else {
printf " tape %-3d : %3d %9d$unit %9d$unit %s\n",
}
}
+exit $exit_status;
+
sub make_hostpart() {
local($host,$partition,$datestamp) = @_;
return $time;
}
+sub set_starttime() {
+ my (@tl);
+ my ($time);
+ my ($date);
+
+ # Preset an array of values in case some parts are not passed as
+ # arguments. This lets the date, etc, be omitted and default to
+ # today.
+
+ ($date)=@_;
+ @tl = localtime;
+
+ $tl[5] = substr($date, 0, 4) if(length($date) >= 4);
+ $tl[4] = substr($date, 4, 2)-1 if(length($date) >= 6);
+ $tl[3] = substr($date, 6, 2) if(length($date) >= 8);
+ $tl[2] = substr($date, 8, 2) if(length($date) >= 10);
+ $tl[1] = substr($date, 10, 2) if(length($date) >= 12);
+ $tl[0] = substr($date, 12, 2) if(length($date) >= 14);
+
+ $time = &timelocal (@tl);
+
+ return $time;
+}
+
sub showtime() {
my($delta)=shift;
my($oneday)=24*60*60;
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: amtape.c,v 1.47 2006/07/25 18:27:57 martinea Exp $
+ * $Id: amtape.c,v 1.47.2.2 2006/10/30 12:00:19 martinea Exp $
*
* tape changer interface program
*/
{
int i;
- fprintf(stderr, "Usage: amtape%s <conf> <command>\n", versionsuffix());
+ fprintf(stderr, "Usage: amtape%s <conf> <command> {<args>} [-o configoption]*\n", versionsuffix());
fprintf(stderr, "\tValid commands are:\n");
for (i = 0; i < NCMDS; i++)
fprintf(stderr, "\t\t%s\n", cmdtab[i].usage);
uid_t uid_dumpuser;
char *dumpuser;
struct passwd *pw;
+ int new_argc;
+ char **new_argv;
safe_fd(-1, 0);
safe_cd();
erroutput_type = ERR_INTERACTIVE;
- if(argc < 3) usage();
+ parse_server_conf(argc, argv, &new_argc, &new_argv);
+ if(new_argc < 3) usage();
- config_name = argv[1];
+ config_name = new_argv[1];
config_dir = vstralloc(CONFIG_DIR, "/", config_name, "/", NULL);
conffile = stralloc2(config_dir, CONFFILE_NAME);
/* switch on command name */
- argc -= 2; argv += 2;
+ new_argc -= 2; new_argv += 2;
for (i = 0; i < NCMDS; i++)
- if (strcmp(argv[0], cmdtab[i].name) == 0) {
- (*cmdtab[i].fn)(argc, argv);
+ if (strcmp(new_argv[0], cmdtab[i].name) == 0) {
+ (*cmdtab[i].fn)(new_argc, new_argv);
break;
}
if (i == NCMDS) {
- fprintf(stderr, "%s: unknown command \"%s\"\n", argv0, argv[0]);
+ fprintf(stderr, "%s: unknown command \"%s\"\n", argv0, new_argv[0]);
usage();
}
&init;
+delete @ENV{'IFS', 'CDPATH', 'ENV', 'BASH_ENV', 'PATH'};
+$ENV{'PATH'} = "/usr/bin:/usr/sbin:/sbin:/bin";
+
$dir=$logfile;
$dir =~ s/[^\/]*$//;
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: changer.c,v 1.36.2.1 2006/09/27 14:04:27 martinea Exp $
+ * $Id: changer.c,v 1.36.2.2 2007/01/25 19:47:37 martinea Exp $
*
* interface routines for tape changers
*/
exitcode = 2;
goto done;
case 0:
- if(dup2(fd[1], 1) == -1 || dup2(fd[1], 2) == -1) {
+ if(dup2(fd[1], 1) == -1 || dup2(dbfd(), 2) == -1) {
changer_resultstr = vstralloc ("<error> ",
"could not open pipe to \"",
cmdstr,
* University of Maryland at College Park
*/
/*
- * $Id: conffile.c,v 1.156 2006/07/26 15:17:37 martinea Exp $
+ * $Id: conffile.c,v 1.156.2.9 2007/01/11 13:06:10 martinea Exp $
*
* read configuration file
*/
{ CONF_INPARALLEL , CONFTYPE_INT , read_int , CNF_INPARALLEL , validate_inparallel },
{ CONF_DUMPORDER , CONFTYPE_STRING , read_string , CNF_DUMPORDER , NULL },
{ CONF_MAXDUMPS , CONFTYPE_INT , read_int , CNF_MAXDUMPS , validate_positive1 },
- { CONF_ETIMEOUT , CONFTYPE_TIME , read_time , CNF_ETIMEOUT , NULL },
- { CONF_DTIMEOUT , CONFTYPE_TIME , read_time , CNF_DTIMEOUT , validate_positive1 },
- { CONF_CTIMEOUT , CONFTYPE_TIME , read_time , CNF_CTIMEOUT , validate_positive1 },
+ { CONF_ETIMEOUT , CONFTYPE_INT , read_int , CNF_ETIMEOUT , NULL },
+ { CONF_DTIMEOUT , CONFTYPE_INT , read_int , CNF_DTIMEOUT , validate_positive1 },
+ { CONF_CTIMEOUT , CONFTYPE_INT , read_int , CNF_CTIMEOUT , validate_positive1 },
{ CONF_TAPEBUFS , CONFTYPE_INT , read_int , CNF_TAPEBUFS , validate_positive1 },
{ CONF_RAWTAPEDEV , CONFTYPE_STRING , read_string , CNF_RAWTAPEDEV , NULL },
{ CONF_COLUMNSPEC , CONFTYPE_STRING , read_string , CNF_COLUMNSPEC , NULL },
{ CONF_AMRECOVER_CHECK_LABEL, CONFTYPE_BOOL , read_bool , CNF_AMRECOVER_CHECK_LABEL, NULL },
{ CONF_UNKNOWN , CONFTYPE_INT , NULL , CNF_CNF , NULL }
};
+
+t_conf_var tapetype_var [] = {
+ { CONF_COMMENT , CONFTYPE_STRING, read_string, TAPETYPE_COMMENT , NULL },
+ { CONF_LBL_TEMPL, CONFTYPE_STRING, read_string, TAPETYPE_LBL_TEMPL, NULL },
+ { CONF_BLOCKSIZE, CONFTYPE_SIZE , read_size , TAPETYPE_BLOCKSIZE, validate_blocksize },
+ { CONF_LENGTH , CONFTYPE_AM64 , read_am64 , TAPETYPE_LENGTH , validate_positive0 },
+ { CONF_FILEMARK , CONFTYPE_AM64 , read_am64 , TAPETYPE_FILEMARK , NULL },
+ { CONF_SPEED , CONFTYPE_INT , read_int , TAPETYPE_SPEED , validate_positive0 },
+ { CONF_FILE_PAD , CONFTYPE_BOOL , read_bool , TAPETYPE_FILE_PAD , NULL },
+ { CONF_UNKNOWN , CONFTYPE_INT , NULL , TAPETYPE_TAPETYPE , NULL }
+};
+
+t_conf_var dumptype_var [] = {
+ { CONF_COMMENT , CONFTYPE_STRING , read_string , DUMPTYPE_COMMENT , NULL },
+ { CONF_AUTH , CONFTYPE_STRING , read_string , DUMPTYPE_SECURITY_DRIVER , NULL },
+ { CONF_BUMPDAYS , CONFTYPE_INT , read_int , DUMPTYPE_BUMPDAYS , NULL },
+ { CONF_BUMPMULT , CONFTYPE_REAL , read_real , DUMPTYPE_BUMPMULT , NULL },
+ { CONF_BUMPSIZE , CONFTYPE_AM64 , read_am64 , DUMPTYPE_BUMPSIZE , NULL },
+ { CONF_BUMPPERCENT , CONFTYPE_INT , read_int , DUMPTYPE_BUMPPERCENT , NULL },
+ { CONF_COMPRATE , CONFTYPE_REAL , get_comprate, DUMPTYPE_COMPRATE , NULL },
+ { CONF_COMPRESS , CONFTYPE_INT , get_compress, DUMPTYPE_COMPRESS , NULL },
+ { CONF_ENCRYPT , CONFTYPE_INT , get_encrypt , DUMPTYPE_ENCRYPT , NULL },
+ { CONF_DUMPCYCLE , CONFTYPE_INT , read_int , DUMPTYPE_DUMPCYCLE , validate_positive0 },
+ { CONF_EXCLUDE , CONFTYPE_EXINCLUDE, get_exclude , DUMPTYPE_EXCLUDE , NULL },
+ { CONF_INCLUDE , CONFTYPE_EXINCLUDE, get_exclude , DUMPTYPE_INCLUDE , NULL },
+ { CONF_IGNORE , CONFTYPE_BOOL , read_bool , DUMPTYPE_IGNORE , NULL },
+ { CONF_HOLDING , CONFTYPE_HOLDING , get_holding , DUMPTYPE_HOLDINGDISK , NULL },
+ { CONF_INDEX , CONFTYPE_BOOL , read_bool , DUMPTYPE_INDEX , NULL },
+ { CONF_KENCRYPT , CONFTYPE_BOOL , read_bool , DUMPTYPE_KENCRYPT , NULL },
+ { CONF_MAXDUMPS , CONFTYPE_INT , read_int , DUMPTYPE_MAXDUMPS , validate_positive1 },
+ { CONF_MAXPROMOTEDAY , CONFTYPE_INT , read_int , DUMPTYPE_MAXPROMOTEDAY , validate_positive0 },
+ { CONF_PRIORITY , CONFTYPE_PRIORITY , get_priority, DUMPTYPE_PRIORITY , NULL },
+ { CONF_PROGRAM , CONFTYPE_STRING , read_string , DUMPTYPE_PROGRAM , NULL },
+ { CONF_RECORD , CONFTYPE_BOOL , read_bool , DUMPTYPE_RECORD , NULL },
+ { CONF_SKIP_FULL , CONFTYPE_BOOL , read_bool , DUMPTYPE_SKIP_FULL , NULL },
+ { CONF_SKIP_INCR , CONFTYPE_BOOL , read_bool , DUMPTYPE_SKIP_INCR , NULL },
+ { CONF_STARTTIME , CONFTYPE_TIME , read_time , DUMPTYPE_STARTTIME , NULL },
+ { CONF_STRATEGY , CONFTYPE_INT , get_strategy, DUMPTYPE_STRATEGY , NULL },
+ { CONF_TAPE_SPLITSIZE , CONFTYPE_AM64 , read_am64 , DUMPTYPE_TAPE_SPLITSIZE , validate_positive0 },
+ { CONF_SPLIT_DISKBUFFER , CONFTYPE_STRING , read_string , DUMPTYPE_SPLIT_DISKBUFFER , NULL },
+ { CONF_ESTIMATE , CONFTYPE_INT , get_estimate, DUMPTYPE_ESTIMATE , NULL },
+ { CONF_SRV_ENCRYPT , CONFTYPE_STRING , read_string , DUMPTYPE_SRV_ENCRYPT , NULL },
+ { CONF_CLNT_ENCRYPT , CONFTYPE_STRING , read_string , DUMPTYPE_CLNT_ENCRYPT , NULL },
+ { CONF_AMANDAD_PATH , CONFTYPE_STRING , read_string , DUMPTYPE_AMANDAD_PATH , NULL },
+ { CONF_CLIENT_USERNAME , CONFTYPE_STRING , read_string , DUMPTYPE_CLIENT_USERNAME , NULL },
+ { CONF_SSH_KEYS , CONFTYPE_STRING , read_string , DUMPTYPE_SSH_KEYS , NULL },
+ { CONF_SRVCOMPPROG , CONFTYPE_STRING , read_string , DUMPTYPE_SRVCOMPPROG , NULL },
+ { CONF_CLNTCOMPPROG , CONFTYPE_STRING , read_string , DUMPTYPE_CLNTCOMPPROG , NULL },
+ { CONF_FALLBACK_SPLITSIZE, CONFTYPE_AM64 , read_am64 , DUMPTYPE_FALLBACK_SPLITSIZE, NULL },
+ { CONF_SRV_DECRYPT_OPT , CONFTYPE_STRING , read_string , DUMPTYPE_SRV_DECRYPT_OPT , NULL },
+ { CONF_CLNT_DECRYPT_OPT , CONFTYPE_STRING , read_string , DUMPTYPE_CLNT_DECRYPT_OPT , NULL },
+ { CONF_UNKNOWN , CONFTYPE_INT , NULL , DUMPTYPE_DUMPTYPE , NULL }
+};
+
+t_conf_var holding_var [] = {
+ { CONF_DIRECTORY, CONFTYPE_STRING, read_string, HOLDING_DISKDIR , NULL },
+ { CONF_COMMENT , CONFTYPE_STRING, read_string, HOLDING_COMMENT , NULL },
+ { CONF_USE , CONFTYPE_AM64 , read_am64 , HOLDING_DISKSIZE , validate_use },
+ { CONF_CHUNKSIZE, CONFTYPE_AM64 , read_am64 , HOLDING_CHUNKSIZE, validate_chunksize },
+ { CONF_UNKNOWN , CONFTYPE_INT , NULL , HOLDING_HOLDING , NULL }
+};
+
/*
** ------------------------
** External entry points
val->v.am64 = ((AM64_MAX / 1024) - (2 * DISK_BLOCK_KB));
}
else if(val->v.am64 < 0) {
- conf_parserror("Negative chunksize (%lld) is no longer supported", val->v.am64);
+ conf_parserror("Negative chunksize ("OFF_T_FMT") is no longer supported",
+ val->v.am64);
}
val->v.am64 = am_floor(val->v.am64, (off_t)DISK_BLOCK_KB);
+ if (val->v.am64 < 2*DISK_BLOCK_KB) {
+ conf_parserror("chunksize must be at least %dkb", 2*DISK_BLOCK_KB);
+ }
}
void
char *str)
{
static char *tmpstr;
- char number[NUM_STR_SIZE];
t_conf_var *np;
keytab_t *kt;
char *s;
char ch;
+ char *first_delim;
+ char *second_delim;
+ tapetype_t *tp;
+ dumptype_t *dp;
+ interface_t *ip;
+ holdingdisk_t *hp;
tmpstr = stralloc(str);
s = tmpstr;
if(islower((int)ch))
s[-1] = (char)toupper(ch);
}
- for(kt = server_keytab; kt->token != CONF_UNKNOWN; kt++) {
- if(kt->keyword && strcmp(kt->keyword, tmpstr) == 0)
- break;
- }
- if(kt->token == CONF_UNKNOWN)
- return NULL;
+ first_delim = strchr(tmpstr, ':');
+ if (first_delim) {
+ *first_delim = '\0';
+ first_delim++;
+ second_delim = strchr(first_delim,':');
+ if(!second_delim) {
+ amfree(tmpstr);
+ return(NULL);
+ }
+ *second_delim = '\0';
+ second_delim++;
- for(np = server_var; np->token != CONF_UNKNOWN; np++) {
- if(np->token == kt->token)
- break;
- }
+ for(kt = server_keytab; kt->token != CONF_UNKNOWN; kt++) {
+ if(kt->keyword && strcmp(kt->keyword, second_delim) == 0)
+ break;
+ }
- if(np->token == CONF_UNKNOWN) return NULL;
+ if(kt->token == CONF_UNKNOWN)
+ return NULL;
- if(np->type == CONFTYPE_INT) {
- snprintf(number, sizeof(number), "%d", server_conf[np->parm].v.i);
- tmpstr = newstralloc(tmpstr, number);
- } else if(np->type == CONFTYPE_BOOL) {
- if(getconf_boolean(np->parm) == 0) {
- tmpstr = newstralloc(tmpstr, "off");
+ if (strcmp(tmpstr, "TAPETYPE") == 0) {
+ tp = lookup_tapetype(first_delim);
+ if (!tp) {
+ amfree(tmpstr);
+ return(NULL);
+ }
+ for(np = tapetype_var; np->token != CONF_UNKNOWN; np++) {
+ if(np->token == kt->token)
+ break;
+ }
+ if (np->token == CONF_UNKNOWN) return NULL;
+ tmpstr = stralloc(conf_print(&tp->value[np->parm], 0));
+ } else if (strcmp(tmpstr, "DUMPTYPE") == 0) {
+ dp = lookup_dumptype(first_delim);
+ if (!dp) {
+ amfree(tmpstr);
+ return(NULL);
+ }
+ for(np = dumptype_var; np->token != CONF_UNKNOWN; np++) {
+ if(np->token == kt->token)
+ break;
+ }
+ if (np->token == CONF_UNKNOWN) return NULL;
+ tmpstr = stralloc(conf_print(&dp->value[np->parm], 0));
+ } else if (strcmp(tmpstr, "HOLDINGDISK") == 0) {
+ hp = lookup_holdingdisk(first_delim);
+ if (!hp) {
+ amfree(tmpstr);
+ return(NULL);
+ }
+ for(np = holding_var; np->token != CONF_UNKNOWN; np++) {
+ if(np->token == kt->token)
+ break;
+ }
+ if (np->token == CONF_UNKNOWN) return NULL;
+ tmpstr = stralloc(conf_print(&hp->value[np->parm], 0));
+ } else if (strcmp(tmpstr, "INTERFACE") == 0) {
+ ip = lookup_interface(first_delim);
+ if (!ip) {
+ amfree(tmpstr);
+ return(NULL);
+ }
+ for(np = holding_var; np->token != CONF_UNKNOWN; np++) {
+ if(np->token == kt->token)
+ break;
+ }
+ if (np->token == CONF_UNKNOWN) return NULL;
+ tmpstr = stralloc(conf_print(&ip->value[np->parm], 0));
} else {
- tmpstr = newstralloc(tmpstr, "on");
+ amfree(tmpstr);
+ return(NULL);
}
- } else if(np->type == CONFTYPE_REAL) {
- snprintf(number, sizeof(number), "%lf", server_conf[np->parm].v.r);
- tmpstr = newstralloc(tmpstr, number);
- } else if(np->type == CONFTYPE_AM64){
- snprintf(number, sizeof(number), OFF_T_FMT,
- (OFF_T_FMT_TYPE)server_conf[np->parm].v.am64);
- tmpstr = newstralloc(tmpstr, number);
} else {
- tmpstr = newstralloc(tmpstr, getconf_str(np->parm));
+ for(kt = server_keytab; kt->token != CONF_UNKNOWN; kt++) {
+ if(kt->keyword && strcmp(kt->keyword, tmpstr) == 0)
+ break;
+ }
+
+ if(kt->token == CONF_UNKNOWN)
+ return NULL;
+
+ for(np = server_var; np->token != CONF_UNKNOWN; np++) {
+ if(np->token == kt->token)
+ break;
+ }
+
+ if(np->token == CONF_UNKNOWN) return NULL;
+
+ tmpstr = stralloc(conf_print(&server_conf[np->parm], 0));
}
return tmpstr;
}
+
+char *
+getconf_list(
+ char *listname)
+{
+ char *result = NULL;
+ tapetype_t *tp;
+ dumptype_t *dp;
+ interface_t *ip;
+ holdingdisk_t *hp;
+
+ if (strcasecmp(listname,"tapetype") == 0) {
+ result = stralloc("");
+ for(tp = tapelist; tp != NULL; tp=tp->next) {
+ result = vstrextend(&result, tp->name, "\n", NULL);
+ }
+ } else if (strcasecmp(listname,"dumptype") == 0) {
+ result = stralloc("");
+ for(dp = dumplist; dp != NULL; dp=dp->next) {
+ result = vstrextend(&result, dp->name, "\n", NULL);
+ }
+ } else if (strcasecmp(listname,"holdingdisk") == 0) {
+ result = stralloc("");
+ for(hp = holdingdisks; hp != NULL; hp=hp->next) {
+ result = vstrextend(&result, hp->name, "\n", NULL);
+ }
+ } else if (strcasecmp(listname,"interface") == 0) {
+ result = stralloc("");
+ for(ip = interface_list; ip != NULL; ip=ip->next) {
+ result = vstrextend(&result, ip->name, "\n", NULL);
+ }
+ }
+ return result;
+}
+
+
int
getconf_seen(
confparm_t parm)
return NULL;
}
+holdingdisk_t *
+lookup_holdingdisk(
+ char *str)
+{
+ holdingdisk_t *p;
+
+ for(p = holdingdisks; p != NULL; p = p->next) {
+ if(strcasecmp(p->name, str) == 0) return p;
+ }
+ return NULL;
+}
+
interface_t *
lookup_interface(
char *str)
#ifdef DEFAULT_TAPE_DEVICE
s = DEFAULT_TAPE_DEVICE;
#else
- s = "/dev/rmt8";
+ s = NULL;
#endif
conf_init_string(&server_conf[CNF_TAPEDEV], s);
#ifdef DEFAULT_CHANGER_DEVICE
conf_init_string (&server_conf[CNF_TPCHANGER] , "");
conf_init_int (&server_conf[CNF_RUNTAPES] , 1);
conf_init_int (&server_conf[CNF_MAXDUMPS] , 1);
- conf_init_time (&server_conf[CNF_ETIMEOUT] , (time_t)300);
- conf_init_time (&server_conf[CNF_DTIMEOUT] , (time_t)1800);
- conf_init_time (&server_conf[CNF_CTIMEOUT] , (time_t)30);
+ conf_init_int (&server_conf[CNF_ETIMEOUT] , 300);
+ conf_init_int (&server_conf[CNF_DTIMEOUT] , 1800);
+ conf_init_int (&server_conf[CNF_CTIMEOUT] , 30);
conf_init_int (&server_conf[CNF_TAPEBUFS] , 20);
conf_init_string (&server_conf[CNF_RAWTAPEDEV] , s);
conf_init_string (&server_conf[CNF_PRINTER] , "");
return 1;
}
-t_conf_var holding_var [] = {
- { CONF_DIRECTORY, CONFTYPE_STRING, read_string, HOLDING_DISKDIR , NULL },
- { CONF_COMMENT , CONFTYPE_STRING, read_string, HOLDING_COMMENT , NULL },
- { CONF_USE , CONFTYPE_AM64 , read_am64 , HOLDING_DISKSIZE , validate_use },
- { CONF_CHUNKSIZE, CONFTYPE_AM64 , read_am64 , HOLDING_CHUNKSIZE, validate_chunksize },
- { CONF_UNKNOWN , CONFTYPE_INT , NULL , HOLDING_HOLDING , NULL }
-};
-
static void
get_holdingdisk(
void)
}
-t_conf_var dumptype_var [] = {
- { CONF_COMMENT , CONFTYPE_STRING , read_string , DUMPTYPE_COMMENT , NULL },
- { CONF_AUTH , CONFTYPE_STRING , read_string , DUMPTYPE_SECURITY_DRIVER , NULL },
- { CONF_BUMPDAYS , CONFTYPE_INT , read_int , DUMPTYPE_BUMPDAYS , NULL },
- { CONF_BUMPMULT , CONFTYPE_REAL , read_real , DUMPTYPE_BUMPMULT , NULL },
- { CONF_BUMPSIZE , CONFTYPE_AM64 , read_am64 , DUMPTYPE_BUMPSIZE , NULL },
- { CONF_BUMPPERCENT , CONFTYPE_INT , read_int , DUMPTYPE_BUMPPERCENT , NULL },
- { CONF_COMPRATE , CONFTYPE_REAL , get_comprate, DUMPTYPE_COMPRATE , NULL },
- { CONF_COMPRESS , CONFTYPE_INT , get_compress, DUMPTYPE_COMPRESS , NULL },
- { CONF_ENCRYPT , CONFTYPE_INT , get_encrypt , DUMPTYPE_ENCRYPT , NULL },
- { CONF_DUMPCYCLE , CONFTYPE_INT , read_int , DUMPTYPE_DUMPCYCLE , validate_positive0 },
- { CONF_EXCLUDE , CONFTYPE_EXINCLUDE, get_exclude , DUMPTYPE_EXCLUDE , NULL },
- { CONF_INCLUDE , CONFTYPE_EXINCLUDE, get_exclude , DUMPTYPE_INCLUDE , NULL },
- { CONF_IGNORE , CONFTYPE_BOOL , read_bool , DUMPTYPE_IGNORE , NULL },
- { CONF_HOLDING , CONFTYPE_HOLDING , get_holding , DUMPTYPE_HOLDINGDISK , NULL },
- { CONF_INDEX , CONFTYPE_BOOL , read_bool , DUMPTYPE_INDEX , NULL },
- { CONF_KENCRYPT , CONFTYPE_BOOL , read_bool , DUMPTYPE_KENCRYPT , NULL },
- { CONF_MAXDUMPS , CONFTYPE_INT , read_int , DUMPTYPE_MAXDUMPS , validate_positive1 },
- { CONF_MAXPROMOTEDAY , CONFTYPE_INT , read_int , DUMPTYPE_MAXPROMOTEDAY , validate_positive0 },
- { CONF_PRIORITY , CONFTYPE_PRIORITY , get_priority, DUMPTYPE_PRIORITY , NULL },
- { CONF_PROGRAM , CONFTYPE_STRING , read_string , DUMPTYPE_PROGRAM , NULL },
- { CONF_RECORD , CONFTYPE_BOOL , read_bool , DUMPTYPE_RECORD , NULL },
- { CONF_SKIP_FULL , CONFTYPE_BOOL , read_bool , DUMPTYPE_SKIP_FULL , NULL },
- { CONF_SKIP_INCR , CONFTYPE_BOOL , read_bool , DUMPTYPE_SKIP_INCR , NULL },
- { CONF_STARTTIME , CONFTYPE_TIME , read_time , DUMPTYPE_START_T , NULL },
- { CONF_STRATEGY , CONFTYPE_INT , get_strategy, DUMPTYPE_STRATEGY , NULL },
- { CONF_TAPE_SPLITSIZE , CONFTYPE_AM64 , read_am64 , DUMPTYPE_TAPE_SPLITSIZE , validate_positive0 },
- { CONF_SPLIT_DISKBUFFER , CONFTYPE_STRING , read_string , DUMPTYPE_SPLIT_DISKBUFFER , NULL },
- { CONF_ESTIMATE , CONFTYPE_INT , get_estimate, DUMPTYPE_ESTIMATE , NULL },
- { CONF_SRV_ENCRYPT , CONFTYPE_STRING , read_string , DUMPTYPE_SRV_ENCRYPT , NULL },
- { CONF_CLNT_ENCRYPT , CONFTYPE_STRING , read_string , DUMPTYPE_CLNT_ENCRYPT , NULL },
- { CONF_AMANDAD_PATH , CONFTYPE_STRING , read_string , DUMPTYPE_AMANDAD_PATH , NULL },
- { CONF_CLIENT_USERNAME , CONFTYPE_STRING , read_string , DUMPTYPE_CLIENT_USERNAME , NULL },
- { CONF_SSH_KEYS , CONFTYPE_STRING , read_string , DUMPTYPE_SSH_KEYS , NULL },
- { CONF_SRVCOMPPROG , CONFTYPE_STRING , read_string , DUMPTYPE_SRVCOMPPROG , NULL },
- { CONF_CLNTCOMPPROG , CONFTYPE_STRING , read_string , DUMPTYPE_CLNTCOMPPROG , NULL },
- { CONF_FALLBACK_SPLITSIZE, CONFTYPE_AM64 , read_am64 , DUMPTYPE_FALLBACK_SPLITSIZE, NULL },
- { CONF_SRV_DECRYPT_OPT , CONFTYPE_STRING , read_string , DUMPTYPE_SRV_DECRYPT_OPT , NULL },
- { CONF_CLNT_DECRYPT_OPT , CONFTYPE_STRING , read_string , DUMPTYPE_CLNT_DECRYPT_OPT , NULL },
- { CONF_UNKNOWN , CONFTYPE_INT , NULL , DUMPTYPE_DUMPTYPE , NULL }
-};
-
dumptype_t *
read_dumptype(
char *name,
conf_init_am64 (&dpcur.value[DUMPTYPE_BUMPSIZE] , server_conf[CNF_BUMPSIZE].v.am64);
conf_init_int (&dpcur.value[DUMPTYPE_BUMPDAYS] , server_conf[CNF_BUMPDAYS].v.i);
conf_init_real (&dpcur.value[DUMPTYPE_BUMPMULT] , server_conf[CNF_BUMPMULT].v.r);
- conf_init_time (&dpcur.value[DUMPTYPE_START_T] , (time_t)0);
+ conf_init_time (&dpcur.value[DUMPTYPE_STARTTIME] , (time_t)0);
conf_init_strategy (&dpcur.value[DUMPTYPE_STRATEGY] , DS_STANDARD);
conf_init_estimate (&dpcur.value[DUMPTYPE_ESTIMATE] , ES_CLIENT);
conf_init_compress (&dpcur.value[DUMPTYPE_COMPRESS] , COMP_FAST);
}
}
-t_conf_var tapetype_var [] = {
- { CONF_COMMENT , CONFTYPE_STRING, read_string, TAPETYPE_COMMENT , NULL },
- { CONF_LBL_TEMPL, CONFTYPE_STRING, read_string, TAPETYPE_LBL_TEMPL, NULL },
- { CONF_BLOCKSIZE, CONFTYPE_SIZE , read_size , TAPETYPE_BLOCKSIZE, validate_blocksize },
- { CONF_LENGTH , CONFTYPE_AM64 , read_am64 , TAPETYPE_LENGTH , validate_positive0 },
- { CONF_FILEMARK , CONFTYPE_AM64 , read_am64 , TAPETYPE_FILEMARK , NULL },
- { CONF_SPEED , CONFTYPE_INT , read_int , TAPETYPE_SPEED , validate_positive0 },
- { CONF_FILE_PAD , CONFTYPE_BOOL , read_bool , TAPETYPE_FILE_PAD , NULL },
- { CONF_UNKNOWN , CONFTYPE_INT , NULL , TAPETYPE_TAPETYPE , NULL }
-};
-
static void
get_tapetype(void)
{
conf_init_string(&tpcur.value[TAPETYPE_COMMENT] , "");
conf_init_string(&tpcur.value[TAPETYPE_LBL_TEMPL], "");
conf_init_size (&tpcur.value[TAPETYPE_BLOCKSIZE], DISK_BLOCK_KB);
- conf_init_am64 (&tpcur.value[TAPETYPE_LENGTH] , (off_t)2000 * 1024);
- conf_init_am64 (&tpcur.value[TAPETYPE_FILEMARK] , (off_t)1000);
+ conf_init_am64 (&tpcur.value[TAPETYPE_LENGTH] , (off_t)2000);
+ conf_init_am64 (&tpcur.value[TAPETYPE_FILEMARK] , (off_t)1);
conf_init_int (&tpcur.value[TAPETYPE_SPEED] , 200);
conf_init_bool (&tpcur.value[TAPETYPE_FILE_PAD] , 1);
}
if(tok == CONF_LIST) {
file = 0;
get_conftoken(CONF_ANY);
+ exclude = val->v.exinclude.sl_list;
}
else {
file = 1;
if(tok == CONF_EFILE) get_conftoken(CONF_ANY);
+ exclude = val->v.exinclude.sl_file;
}
- val->v.exinclude.type = file;
- exclude = val->v.exinclude.sl;
ckseen(&val->seen);
if(tok == CONF_OPTIONAL) {
if(got_one == 0) { free_sl(exclude); exclude = NULL; }
- val->v.exinclude.sl = exclude;
+ if (file == 0)
+ val->v.exinclude.sl_list = exclude;
+ else
+ val->v.exinclude.sl_file = exclude;
val->v.exinclude.optional = optional;
}
if(kt->token == CONF_UNKNOWN)
error("server bad token");
- printf("%-21s %s\n", kt->keyword, conf_print(&server_conf[i]));
+ printf("%-21s %s\n", kt->keyword, conf_print(&server_conf[i], 1));
}
for(hp = holdingdisks; hp != NULL; hp = hp->next) {
if(kt->token == CONF_UNKNOWN)
error("holding bad token");
- printf(" %-9s %s\n", kt->keyword, conf_print(&hp->value[i]));
+ printf(" %-9s %s\n", kt->keyword, conf_print(&hp->value[i], 1));
}
printf("}\n");
}
if(kt->token == CONF_UNKNOWN)
error("tapetype bad token");
- printf(" %-9s %s\n", kt->keyword, conf_print(&tp->value[i]));
+ printf(" %-9s %s\n", kt->keyword, conf_print(&tp->value[i], 1));
}
printf("}\n");
}
for(dp = dumplist; dp != NULL; dp = dp->next) {
- if(dp->seen == -1)
- prefix = "#";
- else
- prefix = "";
- printf("\n%sDEFINE DUMPTYPE %s {\n", prefix, dp->name);
- for(i=0; i < DUMPTYPE_DUMPTYPE; i++) {
- for(np=dumptype_var; np->token != CONF_UNKNOWN; np++)
- if(np->parm == i) break;
- if(np->token == CONF_UNKNOWN)
- error("dumptype bad value");
-
- for(kt = server_keytab; kt->token != CONF_UNKNOWN; kt++)
- if(kt->token == np->token) break;
- if(kt->token == CONF_UNKNOWN)
- error("dumptype bad token");
-
- printf("%s %-19s %s\n", prefix, kt->keyword, conf_print(&dp->value[i]));
+ if (strncmp(dp->name, "custom(", 7) != 0) {
+ if(dp->seen == -1)
+ prefix = "#";
+ else
+ prefix = "";
+ printf("\n%sDEFINE DUMPTYPE %s {\n", prefix, dp->name);
+ for(i=0; i < DUMPTYPE_DUMPTYPE; i++) {
+ for(np=dumptype_var; np->token != CONF_UNKNOWN; np++)
+ if(np->parm == i) break;
+ if(np->token == CONF_UNKNOWN)
+ error("dumptype bad value");
+
+ for(kt = server_keytab; kt->token != CONF_UNKNOWN; kt++)
+ if(kt->token == np->token) break;
+ if(kt->token == CONF_UNKNOWN)
+ error("dumptype bad token");
+
+ if (dp->value[i].type == CONFTYPE_EXINCLUDE) {
+ printf("%s %-19s %s\n", prefix, kt->keyword,
+ conf_print_exinclude(&dp->value[i], 1, 0));
+ printf("%s %-19s %s\n", prefix, kt->keyword,
+ conf_print_exinclude(&dp->value[i], 1, 1));
+ } else {
+ printf("%s %-19s %s\n", prefix, kt->keyword,
+ conf_print(&dp->value[i], 1));
+ }
+ }
+ printf("%s}\n", prefix);
}
- printf("%s}\n", prefix);
}
for(ip = interface_list; ip != NULL; ip = ip->next) {
if(kt->token == CONF_UNKNOWN)
error("interface bad token");
- printf("%s %-9s %s\n", prefix, kt->keyword, conf_print(&ip->value[i]));
+ printf("%s %-9s %s\n", prefix, kt->keyword, conf_print(&ip->value[i], 1));
}
printf("%s}\n",prefix);
}
}
}
+char **
+get_config_options(
+ int first)
+{
+ char **config_options;
+ char **config_option;
+ command_option_t *command_options;
+ int nb_server_options = 0;
+
+ for(command_options = server_options; command_options->name != NULL;
+ command_options++) {
+ nb_server_options++;
+ }
+ config_options = alloc((first+nb_server_options+1)*SIZEOF(char *));
+ for(command_options = server_options,
+ config_option = config_options + first;
+ command_options->name != NULL; command_options++) {
+ *config_option = vstralloc("-o", command_options->name, "=",
+ command_options->value, NULL);
+ config_option++;
+ }
+ *config_option = NULL;
+ return(config_options);
+}
+
void
report_bad_conf_arg(void)
{
* University of Maryland at College Park
*/
/*
- * $Id: conffile.h,v 1.72 2006/07/26 15:17:37 martinea Exp $
+ * $Id: conffile.h,v 1.72.2.3 2006/11/09 14:35:10 martinea Exp $
*
* interface for config file reading code
*/
DUMPTYPE_BUMPSIZE,
DUMPTYPE_BUMPDAYS,
DUMPTYPE_BUMPMULT,
- DUMPTYPE_START_T,
+ DUMPTYPE_STARTTIME,
DUMPTYPE_STRATEGY,
DUMPTYPE_ESTIMATE,
DUMPTYPE_COMPRESS,
#define dumptype_get_bumpsize(dumptype) get_conftype_am64 (&dumptype->value[DUMPTYPE_BUMPSIZE])
#define dumptype_get_bumpdays(dumptype) get_conftype_int (&dumptype->value[DUMPTYPE_BUMPDAYS])
#define dumptype_get_bumpmult(dumptype) get_conftype_real (&dumptype->value[DUMPTYPE_BUMPMULT])
-#define dumptype_get_start_t(dumptype) get_conftype_time (&dumptype->value[DUMPTYPE_START_T])
+#define dumptype_get_starttime(dumptype) get_conftype_time (&dumptype->value[DUMPTYPE_STARTTIME])
#define dumptype_get_strategy(dumptype) get_conftype_strategy (&dumptype->value[DUMPTYPE_STRATEGY])
#define dumptype_get_estimate(dumptype) get_conftype_estimate (&dumptype->value[DUMPTYPE_ESTIMATE])
#define dumptype_get_compress(dumptype) get_conftype_compress (&dumptype->value[DUMPTYPE_COMPRESS])
void parse_server_conf(int parse_argc, char **parse_argv, int *new_argc,
char ***new_argv);
+char **get_config_options(int);
void report_bad_conf_arg(void);
void free_server_config(void);
char *getconf_str(confparm_t parameter);
int getconf_taperalgo(confparm_t parameter);
char *getconf_byname(char *confname);
+char *getconf_list(char *listname);
dumptype_t *lookup_dumptype(char *identifier);
dumptype_t *read_dumptype(char *name, FILE *from, char *fname, int *linenum);
tapetype_t *lookup_tapetype(char *identifier);
+holdingdisk_t *lookup_holdingdisk(char *identifier);
interface_t *lookup_interface(char *identifier);
holdingdisk_t *getconf_holdingdisks(void);
long int getconf_unit_divisor(void);
* University of Maryland at College Park
*/
/*
- * $Id: diskfile.c,v 1.95 2006/07/26 15:17:37 martinea Exp $
+ * $Id: diskfile.c,v 1.95.2.12 2007/01/26 14:33:24 martinea Exp $
*
* read disklist file
*/
int ch, dup = 0;
char *line = *line_p;
int line_num = *line_num_p;
+ struct tm *stm;
+ time_t st;
+ char *shost, *sdisk;
+ am_host_t *p;
+ disk_t *dp;
assert(filename != NULL);
assert(line_num > 0);
s[-1] = '\0';
host = lookup_host(fp);
if (host == NULL) {
- hostname = stralloc(fp);
- malloc_mark(hostname);
+ hostname = stralloc(fp);
+ malloc_mark(hostname);
} else {
- hostname = host->hostname;
+ hostname = stralloc(host->hostname);
+ if (strcmp(host->hostname, fp) != 0) {
+ disk_parserror(filename, line_num, "Same host with different case: \"%s\" and \"%s\".", host->hostname, fp);
+ return -1;
+ }
+ }
+
+ shost = sanitise_filename(hostname);
+ for (p = hostlist; p != NULL; p = p->next) {
+ char *shostp = sanitise_filename(p->hostname);
+ if (!strcmp(hostname, p->hostname) &&
+ strcmp(shost, shostp)) {
+ disk_parserror(filename, line_num, "Two host are mapping to the same name: \"%s\" and \"%s\"", p->hostname, hostname);
+ return(-1);
+ }
+ else if (strcasecmp(hostname, p->hostname) &&
+ match_host(hostname, p->hostname) &&
+ match_host(p->hostname, hostname)) {
+ disk_parserror(filename, line_num, "Duplicate host name: \"%s\" and \"%s\"", p->hostname, hostname);
+ return(-1);
+ }
+ amfree(shostp);
}
+ amfree(shost);
skip_whitespace(s, ch);
if(ch == '\0' || ch == '#') {
/* diskdevice */
dumptype = NULL;
diskdevice = NULL;
- dumptype = unquote_string(fp);
if(fp[0] != '{') {
+ dumptype = unquote_string(fp);
if ((dtype = lookup_dumptype(dumptype)) == NULL) {
diskdevice = dumptype;
skip_whitespace(s, ch);
fp = s - 1;
skip_quoted_string(s, ch);
s[-1] = '\0';
- dumptype = unquote_string(fp);
+ if (fp[0] != '{') {
+ dumptype = unquote_string(fp);
+ }
}
}
- else
- amfree(dumptype);
/* check for duplicate disk */
- if(host && (disk = lookup_disk(hostname, diskname)) != NULL) {
- disk_parserror(filename, line_num,
- "duplicate disk record, previous on line %d", disk->line);
- dup = 1;
- } else {
+ disk = NULL;
+ if (host) {
+ if ((disk = lookup_disk(hostname, diskname)) != NULL) {
+ dup = 1;
+ } else {
+ disk = host->disks;
+ do {
+ if (match_disk(diskname, disk->name) &&
+ match_disk(disk->name, diskname)) {
+ dup = 1;
+ } else {
+ disk = disk->hostnext;
+ }
+ }
+ while (dup == 0 && disk != NULL);
+ }
+ if (dup == 1) {
+ disk_parserror(filename, line_num,
+ "duplicate disk record, previous on line %d",
+ disk->line);
+ }
+ }
+ if (!disk) {
disk = alloc(SIZEOF(disk_t));
malloc_mark(disk);
disk->line = line_num;
disk->inprogress = 0;
}
+ if (host) {
+ sdisk = sanitise_filename(diskname);
+ for (dp = host->disks; dp != NULL; dp = dp->next) {
+ char *sdiskp = sanitise_filename(dp->name);
+ if (strcmp(diskname, dp->name) != 0 &&
+ strcmp(sdisk, sdiskp) == 0) {
+ disk_parserror(filename, line_num,
+ "Two disk are mapping to the same name: \"%s\" and \"%s\""
+ ", you must use different diskname",
+ dp->name, diskname);
+ return(-1);
+ }
+ amfree(sdiskp);
+ }
+ amfree(sdisk);
+ }
+
if (fp[0] == '{') {
s[-1] = (char)ch;
s = fp+2;
amfree(line);
dtype = read_dumptype(vstralloc("custom(", hostname,
- ":", disk->name, ")", 0),
+ ":", disk->name, ")", NULL),
diskf, (char*)filename, line_num_p);
if (dtype == NULL || dup) {
disk_parserror(filename, line_num,
disk->dtype_name = dtype->name;
disk->program = dumptype_get_program(dtype);
- if(dumptype_get_exclude(dtype).type == 0) {
- disk->exclude_list = duplicate_sl(dumptype_get_exclude(dtype).sl);
- disk->exclude_file = NULL;
- }
- else {
- disk->exclude_file = duplicate_sl(dumptype_get_exclude(dtype).sl);
- disk->exclude_list = NULL;
- }
+ disk->exclude_list = duplicate_sl(dumptype_get_exclude(dtype).sl_list);
+ disk->exclude_file = duplicate_sl(dumptype_get_exclude(dtype).sl_file);
disk->exclude_optional = dumptype_get_exclude(dtype).optional;
- if(dumptype_get_include(dtype).type == 0) {
- disk->include_list = duplicate_sl(dumptype_get_include(dtype).sl);
- disk->include_file = NULL;
- }
- else {
- disk->include_file = duplicate_sl(dumptype_get_include(dtype).sl);
- disk->include_list = NULL;
- }
+ disk->include_list = duplicate_sl(dumptype_get_include(dtype).sl_list);
+ disk->include_file = duplicate_sl(dumptype_get_include(dtype).sl_file);
disk->include_optional = dumptype_get_include(dtype).optional;
disk->priority = dumptype_get_priority(dtype);
disk->dumpcycle = dumptype_get_dumpcycle(dtype);
disk->bumpsize = dumptype_get_bumpsize(dtype);
disk->bumpdays = dumptype_get_bumpdays(dtype);
disk->bumpmult = dumptype_get_bumpmult(dtype);
- disk->start_t = dumptype_get_start_t(dtype);
+ disk->starttime = dumptype_get_starttime(dtype);
+ disk->start_t = 0;
+ if (disk->starttime > 0) {
+ st = time(NULL);
+ disk->start_t = st;
+ stm = localtime(&st);
+ disk->start_t -= stm->tm_sec + 60 * stm->tm_min + 3600 * stm->tm_hour;
+ disk->start_t += disk->starttime / 100 * 3600 +
+ disk->starttime % 100 * 60;
+ if ((disk->start_t - st) < -43200)
+ disk->start_t += 86400;
+ }
disk->strategy = dumptype_get_strategy(dtype);
disk->estimate = dumptype_get_estimate(dtype);
disk->compress = dumptype_get_compress(dtype);
host->start_t = 0;
host->up = NULL;
host->features = NULL;
+ } else {
+ amfree(hostname);
}
host->netif = netif;
* University of Maryland at College Park
*/
/*
- * $Id: diskfile.h,v 1.38 2006/06/22 20:41:33 martinea Exp $
+ * $Id: diskfile.h,v 1.38.2.1 2006/11/01 14:45:41 martinea Exp $
*
* interface for disklist file reading code
*/
off_t bumpsize;
int bumpdays;
double bumpmult;
+ time_t starttime; /* start this dump after this time */
time_t start_t; /* start this dump after this time */
int strategy; /* what dump strategy to use */
int estimate; /* what estimate strategy to use */
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: driver.c,v 1.198 2006/08/24 01:57:16 paddy_s Exp $
+ * $Id: driver.c,v 1.198.2.6 2006/12/27 14:44:48 martinea Exp $
*
* controlling process for the Amanda backup system
*/
/* check that we don't do many dump in a day and usetimestamps is off */
if(strlen(driver_timestamp) == 8) {
- char *conf_logdir = getconf_str(CNF_LOGDIR);
- char *logfile = vstralloc(conf_logdir, "/log.",
- driver_timestamp, ".0", NULL);
- char *oldlogfile = vstralloc(conf_logdir, "/oldlog/log.",
- driver_timestamp, ".0", NULL);
- if(access(logfile, F_OK) == 0 || access(oldlogfile, F_OK) == 0) {
- log_add(L_WARNING, "WARNING: This is not the first amdump run today. Enable the usetimestamps option in the configuration file if you want to run amdump more than once per calendar day.");
- }
- amfree(oldlogfile);
- amfree(logfile);
+ if (!nodump) {
+ char *conf_logdir = getconf_str(CNF_LOGDIR);
+ char *logfile = vstralloc(conf_logdir, "/log.",
+ driver_timestamp, ".0", NULL);
+ char *oldlogfile = vstralloc(conf_logdir, "/oldlog/log.",
+ driver_timestamp, ".0", NULL);
+ if(access(logfile, F_OK) == 0 || access(oldlogfile, F_OK) == 0) {
+ log_add(L_WARNING, "WARNING: This is not the first amdump run today. Enable the usetimestamps option in the configuration file if you want to run amdump more than once per calendar day.");
+ }
+ amfree(oldlogfile);
+ amfree(logfile);
+ }
hd_driver_timestamp = construct_timestamp(NULL);
}
else {
dumper->pid = -1;
break;
}
- if (pid == dumper->chunker->pid) {
+ if (dumper->chunker && pid == dumper->chunker->pid) {
who = stralloc(dumper->chunker->name);
dumper->chunker->pid = -1;
break;
update_info_dumper(dp, sched(dp)->origsize,
sched(dp)->dumpsize, sched(dp)->dumptime);
log_add(L_STATS, "estimate %s %s %s %d [sec %ld nkb " OFF_T_FMT
- " ckb " OFF_T_FMT " kps %d]",
+ " ckb " OFF_T_FMT " kps %lu]",
dp->host->hostname, dp->name, sched(dp)->datestamp,
sched(dp)->level,
sched(dp)->est_time, (OFF_T_FMT_TYPE)sched(dp)->est_nsize,
/* result_argv[2] always contains the serial number */
sdp = serial2disk(result_argv[2]);
if (sdp != dp) {
- error("%s: Invalid serial number", get_pname(), result_argv[2]);
+ error("%s: Invalid serial number: %s", get_pname(), result_argv[2]);
/*NOTREACHED*/
}
}
/* result_argv[2] always contains the serial number */
sdp = serial2disk(result_argv[2]);
if (sdp != dp) {
- error("%s: Invalid serial number", get_pname(), result_argv[2]);
+ error("%s: Invalid serial number: %s", get_pname(), result_argv[2]);
/*NOTREACHED*/
}
}
int ch;
off_t flush_size = (off_t)0;
char *qname = NULL;
+ OFF_T_FMT_TYPE nsize_;
+ OFF_T_FMT_TYPE csize_;
+ OFF_T_FMT_TYPE degr_nsize_;
+ OFF_T_FMT_TYPE degr_csize_;
(void)cookie; /* Quiet unused parameter warning */
s[-1] = '\0';
skip_whitespace(s, ch); /* find the native size */
- if(ch == '\0' || sscanf(s - 1, OFF_T_FMT,
- (OFF_T_FMT_TYPE *)&nsize) != 1) {
+ nsize_ = (OFF_T_FMT_TYPE)0;
+ if(ch == '\0' || sscanf(s - 1, OFF_T_FMT, &nsize_) != 1) {
error("schedule line %d: syntax error (bad nsize)", line);
/*NOTREACHED*/
}
+ nsize = nsize_;
skip_integer(s, ch);
skip_whitespace(s, ch); /* find the compressed size */
- if(ch == '\0' || sscanf(s - 1, OFF_T_FMT,
- (OFF_T_FMT_TYPE *)&csize) != 1) {
+ csize_ = (OFF_T_FMT_TYPE)0;
+ if(ch == '\0' || sscanf(s - 1, OFF_T_FMT, &csize_) != 1) {
error("schedule line %d: syntax error (bad csize)", line);
/*NOTREACHED*/
}
+ csize = csize_;
skip_integer(s, ch);
skip_whitespace(s, ch); /* find the time number */
s[-1] = '\0';
skip_whitespace(s, ch); /* find the degr native size */
- if(ch == '\0' || sscanf(s - 1, OFF_T_FMT,
- (OFF_T_FMT_TYPE *)°r_nsize) != 1) {
+ degr_nsize_ = (OFF_T_FMT_TYPE)0;
+ if(ch == '\0' || sscanf(s - 1, OFF_T_FMT, °r_nsize_) != 1) {
error("schedule line %d: syntax error (bad degr nsize)", line);
/*NOTREACHED*/
}
+ degr_nsize = degr_nsize_;
skip_integer(s, ch);
skip_whitespace(s, ch); /* find the degr compressed size */
- if(ch == '\0' || sscanf(s - 1, OFF_T_FMT,
- (OFF_T_FMT_TYPE *)°r_csize) != 1) {
+ degr_csize_ = (OFF_T_FMT_TYPE)0;
+ if(ch == '\0' || sscanf(s - 1, OFF_T_FMT, °r_csize_) != 1) {
error("schedule line %d: syntax error (bad degr csize)", line);
/*NOTREACHED*/
}
+ degr_csize = degr_csize_;
skip_integer(s, ch);
skip_whitespace(s, ch); /* find the degr time number */
free_serial(result_argv[2]);
+ dumpsize = (off_t)0;
if (*result_argv[5] == '"') {
/* String was quoted */
rc = sscanf(result_argv[5],"\"[sec %lf kb " OFF_T_FMT " ",
* University of Maryland at College Park
*/
/*
- * $Id: driverio.c,v 1.92 2006/08/24 01:57:16 paddy_s Exp $
+ * $Id: driverio.c,v 1.92.2.2 2006/12/12 14:56:39 martinea Exp $
*
* I/O-related functions for driver program
*/
startup_tape_process(
char *taper_program)
{
- int fd[2];
+ int fd[2];
+ char **config_options;
if(socketpair(AF_UNIX, SOCK_STREAM, 0, fd) == -1) {
error("taper pipe: %s", strerror(errno));
aclose(fd[0]);
if(dup2(fd[1], 0) == -1 || dup2(fd[1], 1) == -1)
error("taper dup2: %s", strerror(errno));
- execle(taper_program, "taper", config_name, (char *)0, safe_env());
+ config_options = get_config_options(2);
+ config_options[0] = "taper";
+ config_options[1] = config_name;
+ execve(taper_program, config_options, safe_env());
error("exec %s: %s", taper_program, strerror(errno));
/*NOTREACHED*/
dumper_t *dumper,
char *dumper_program)
{
- int fd[2];
+ int fd[2];
+ char **config_options;
if(socketpair(AF_UNIX, SOCK_STREAM, 0, fd) == -1) {
error("%s pipe: %s", dumper->name, strerror(errno));
aclose(fd[0]);
if(dup2(fd[1], 0) == -1 || dup2(fd[1], 1) == -1)
error("%s dup2: %s", dumper->name, strerror(errno));
- execle(dumper_program,
- dumper->name ? dumper->name : "dumper",
- config_name,
- (char *)0,
- safe_env());
+ config_options = get_config_options(2);
+ config_options[0] = dumper->name ? dumper->name : "dumper",
+ config_options[1] = config_name;
+ execve(dumper_program, config_options, safe_env());
error("exec %s (%s): %s", dumper_program,
dumper->name, strerror(errno));
/*NOTREACHED*/
chunker_t *chunker,
char *chunker_program)
{
- int fd[2];
+ int fd[2];
+ char **config_options;
if(socketpair(AF_UNIX, SOCK_STREAM, 0, fd) == -1) {
error("%s pipe: %s", chunker->name, strerror(errno));
error("%s dup2: %s", chunker->name, strerror(errno));
/*NOTREACHED*/
}
- execle(chunker_program,
- chunker->name ? chunker->name : "chunker",
- config_name,
- (char *)0,
- safe_env());
+ config_options = get_config_options(2);
+ config_options[0] = chunker->name ? chunker->name : "chunker",
+ config_options[1] = config_name;
+ execve(chunker_program, config_options, safe_env());
error("exec %s (%s): %s", chunker_program,
chunker->name, strerror(errno));
/*NOTREACHED*/
amfree(qdest);
amfree(qname);
} else {
- error("Write command without disk and holding disk.\n",
+ error("%s command without disk and holding disk.\n",
cmdstr[cmd]);
/*NOTREACHED*/
}
* Authors: the Amanda Development Team. Its members are listed in a
* file named AUTHORS, in the root directory of this distribution.
*/
-/* $Id: dumper.c,v 1.190 2006/08/30 19:53:57 martinea Exp $
+/* $Id: dumper.c,v 1.190.2.2 2006/11/08 17:11:41 martinea Exp $
*
* requests remote amandad processes to dump filesystems
*/
signal(SIGPIPE, SIG_IGN);
- conf_dtimeout = getconf_time(CNF_DTIMEOUT);
+ conf_dtimeout = getconf_int(CNF_DTIMEOUT);
protocol_init();
}
#if 1
-//#if defined(PACKET_DEBUG)
fprintf(stderr, "got response:\n----\n%s\n----\n\n", pkt->body);
#endif
* University of Maryland at College Park
*/
/*
- * $Id: getconf.c,v 1.26 2006/07/25 19:00:56 martinea Exp $
+ * $Id: getconf.c,v 1.26.2.3 2007/01/16 12:36:47 martinea Exp $
*
* a little wrapper to extract config variables for shell scripts
*/
char *conffile;
char *parmname;
int i;
+ int asklist;
char number[NUM_STR_SIZE];
int new_argc, my_argc;
char **new_argv, **my_argv;
+ int myarg;
safe_fd(-1, 0);
signal(SIGPIPE, SIG_IGN);
if(my_argc < 2) {
- fprintf(stderr, "Usage: %s [config] <parmname> [-o configoption]*\n", pgm);
+ fprintf(stderr, "Usage: %s [config] [--list] <parmname> [-o configoption]*\n", pgm);
exit(1);
}
- if (my_argc > 2) {
+ asklist = 0;
+ myarg = 1;
+ if (strcmp(my_argv[1],"--list") == 0) {
+ asklist = 1;
+ myarg = 2;
+ } else if (my_argc > 2 && strcmp(my_argv[2],"--list") == 0) {
+ asklist = 1;
+ myarg = 3;
+ } else if (my_argc > 2) {
+ myarg = 2;
+ }
+
+ if (myarg > asklist+1) {
config_name = stralloc(my_argv[1]);
config_dir = vstralloc(CONFIG_DIR, "/", config_name, "/", NULL);
- parmname = my_argv[2];
} else {
char my_cwd[STR_SIZE];
if ((config_name = strrchr(my_cwd, '/')) != NULL) {
config_name = stralloc(config_name + 1);
}
- parmname = my_argv[1];
}
+ if (myarg >= my_argc) {
+ error("Must specify a parameter");
+ }
+ parmname = my_argv[myarg];
safe_cd();
amfree(conffile);
dbrename(config_name, DBG_SUBDIR_SERVER);
report_bad_conf_arg();
- result = getconf_byname(parmname);
+ if (asklist) {
+ result = getconf_list(parmname);
+ } else {
+ result = getconf_byname(parmname);
+ }
}
if (result == NULL) {
get_pname(), parmname);
fflush(stderr);
} else {
- puts(result);
+ if (asklist)
+ fputs(result, stdout); /* don't add a '\n' */
+ else
+ puts(result); /* add a '\n' */
}
free_new_argv(new_argc, new_argv);
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: planner.c,v 1.206.2.1 2006/09/27 11:24:39 martinea Exp $
+ * $Id: planner.c,v 1.206.2.6 2006/11/24 18:05:06 martinea Exp $
*
* backup schedule planner for the Amanda backup system.
*/
int new_argc, my_argc;
char **new_argv, **my_argv;
int nb_disk;
- char *errstr;
+ char *errstr = NULL;
safe_fd(-1, 0);
error("could not open info db \"%s\"", conf_infofile);
/*NOTREACHED*/
}
+ if (check_infofile(conf_infofile, &origq, &errstr) == -1) {
+ log_add(L_WARNING, "problem copying infofile: %s", errstr);
+ amfree(errstr);
+ }
amfree(conf_infofile);
conf_tapetype = getconf_str(CNF_TAPETYPE);
conf_dumpcycle = getconf_int(CNF_DUMPCYCLE);
conf_runspercycle = getconf_int(CNF_RUNSPERCYCLE);
conf_tapecycle = getconf_int(CNF_TAPECYCLE);
- conf_etimeout = getconf_time(CNF_ETIMEOUT);
+ conf_etimeout = getconf_int(CNF_ETIMEOUT);
conf_reserve = getconf_int(CNF_RESERVE);
conf_autoflush = getconf_boolean(CNF_AUTOFLUSH);
conf_usetimestamps = getconf_boolean(CNF_USETIMESTAMPS);
* We use ctimeout for the "noop" request because it should be
* very fast and etimeout has other side effects.
*/
- timeout = getconf_time(CNF_CTIMEOUT);
+ timeout = getconf_int(CNF_CTIMEOUT);
}
secdrv = security_getdriver(hostp->disks->security_driver);
int tch;
char *qname;
char *disk;
+ OFF_T_FMT_TYPE size_;
hostp = (am_host_t *)datap;
hostp->up = HOST_READY;
s = t;
ch = tch;
- if (sscanf(t - 1, "%d SIZE " OFF_T_FMT , &level,
- (OFF_T_FMT_TYPE *)&size) != 2) {
+ size_ = (OFF_T_FMT_TYPE)0;
+ if (sscanf(t - 1, "%d SIZE " OFF_T_FMT , &level, &size_) != 2) {
goto bad_msg;
}
+ size = size_;
dp = lookup_hostdisk(hostp, disk);
amfree(disk);
full_size = est_tape_size(dp, 0);
if (full_size > tapetype_get_length(tape) * (off_t)avail_tapes) {
char *qname = quote_string(dp->name);
- log_add(L_WARNING, "disk %s:%s, full dump (" OFF_T_FMT
- "KB) will be larger than available tape space",
- dp->host->hostname, qname,
- (OFF_T_FMT_TYPE)full_size);
+ if (conf_runtapes > 1 && dp->tape_splitsize == (off_t)0) {
+ log_add(L_WARNING, "disk %s:%s, full dump (" OFF_T_FMT
+ "KB) will be larger than available tape space"
+ ", you could define a splitsize",
+ dp->host->hostname, qname,
+ (OFF_T_FMT_TYPE)full_size);
+ } else {
+ log_add(L_WARNING, "disk %s:%s, full dump (" OFF_T_FMT
+ "KB) will be larger than available tape space",
+ dp->host->hostname, qname,
+ (OFF_T_FMT_TYPE)full_size);
+ }
amfree(qname);
}
* University of Maryland at College Park
*/
/*
- * $Id: reporter.c,v 1.132 2006/08/28 17:02:48 martinea Exp $
+ * $Id: reporter.c,v 1.132.2.1 2007/01/26 13:12:43 martinea Exp $
*
* nightly Amanda Report generator
*/
/* don't have (or need) a skipped type except internally to reporter */
#define L_SKIPPED L_MARKER
+
+#define STATUS_STRANGE 2
+#define STATUS_FAILED 4
+#define STATUS_MISSING 8
+#define STATUS_TAPE 16
+
typedef struct line_s {
struct line_s *next;
char *str;
/* count files to tape */
static int tapefcount = 0;
+static int exit_status = 0;
static char *run_datestamp;
static char *tape_labels = NULL;
static int last_run_tapes = 0;
}
dbclose();
- return 0;
+ return exit_status;
}
/* ----- */
fprintf(mailf, "%s\n",
tmp=TextRule(OrigKB, TapeRate, "FAILED"));
amfree(tmp);
+ exit_status |= STATUS_FAILED;
continue;
}
if(dp == NULL) {
addtostrange(hostname, diskname, level,
"ERROR [not in disklist]");
+ exit_status |= STATUS_FAILED;
amfree(hostname);
amfree(diskname);
amfree(datestamp);
tapestart_error = newstralloc(tapestart_error, s - 1);
if(nl) *nl = '\n';
degraded_mode = 1;
+ exit_status |= STATUS_TAPE;;
return;
}
/* else some other tape error, handle like other errors */
dp = lookup_disk(hostname, diskname);
if(dp == NULL) {
addtostrange(hostname, qdiskname, level, "ERROR [not in disklist]");
+ exit_status |= STATUS_FAILED;
amfree(hostname);
amfree(diskname);
amfree(datestamp);
str = vstralloc("STRANGE", " ", strangestr, NULL);
addtostrange(repdata->disk->host->hostname, qdisk, repdata->level, str);
+ exit_status |= STATUS_STRANGE;
amfree(qdisk);
amfree(str);
amfree(strangestr);
addline(&errdet, curstr);
}
addline(&errdet,"\\--------");
+ exit_status |= STATUS_FAILED;
}
return;
}
if(dp->todo && data(dp) == NULL) {
qdisk = quote_string(dp->name);
addtostrange(dp->host->hostname, qdisk, -987, "RESULTS MISSING");
+ exit_status |= STATUS_MISSING;
amfree(qdisk);
}
}
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: server_util.c,v 1.17 2006/05/25 01:47:20 johnfranks Exp $
+ * $Id: server_util.c,v 1.17.2.1 2006/11/24 18:05:07 martinea Exp $
*
*/
return(NULL);
}
+
+int check_infofile(
+ char *infodir,
+ disklist_t *dl,
+ char **errmsg)
+{
+ disk_t *dp, *diskp;
+ char *hostinfodir, *old_hostinfodir, *Xhostinfodir;
+ char *diskdir, *old_diskdir, *Xdiskdir;
+ char *infofile, *old_infofile, *Xinfofile;
+ struct stat statbuf;
+ int other_dle_match;
+
+ if (stat(infodir, &statbuf) != 0) {
+ return 0;
+ }
+
+ for (dp = dl->head; dp != NULL; dp = dp->next) {
+ hostinfodir = sanitise_filename(dp->host->hostname);
+ diskdir = sanitise_filename(dp->name);
+ infofile = vstralloc(infodir, "/", hostinfodir, "/", diskdir,
+ "/info", NULL);
+ if (stat(infofile, &statbuf) == -1 && errno == ENOENT) {
+ old_hostinfodir = old_sanitise_filename(dp->host->hostname);
+ old_diskdir = old_sanitise_filename(dp->name);
+ old_infofile = vstralloc(infodir, old_hostinfodir, "/",
+ old_diskdir, "/info", NULL);
+ if (stat(old_infofile, &statbuf) == 0) {
+ other_dle_match = 0;
+ diskp = dl->head;
+ while (diskp != NULL) {
+ Xhostinfodir = sanitise_filename(diskp->host->hostname);
+ Xdiskdir = sanitise_filename(diskp->name);
+ Xinfofile = vstralloc(infodir, "/", Xhostinfodir, "/",
+ Xdiskdir, "/info", NULL);
+ if (strcmp(old_infofile, Xinfofile) == 0) {
+ other_dle_match = 1;
+ diskp = NULL;
+ }
+ else {
+ diskp = diskp->next;
+ }
+ }
+ if (other_dle_match == 0) {
+ if(mkpdir(infofile, (mode_t)02755, (uid_t)-1,
+ (gid_t)-1) == -1)
+ *errmsg = vstralloc("Can't create directory for ",
+ infofile, NULL);
+ return -1;
+ if(copy_file(infofile, old_infofile, errmsg) == -1)
+ return -1;
+ }
+ }
+ }
+ }
+ return 0;
+}
* file named AUTHORS, in the root directory of this distribution.
*/
/*
- * $Id: server_util.h,v 1.11 2006/05/25 01:47:20 johnfranks Exp $
+ * $Id: server_util.h,v 1.11.2.1 2006/11/24 18:05:07 martinea Exp $
*
*/
#ifndef SERVER_UTIL_H
#define SERVER_UTIL_H
#include "util.h"
+#include "diskfile.h"
#define MAX_ARGS 32
int dumper_cmd(struct dumper_s *dumper, cmd_t cmd, struct disk_s *dp);
char *amhost_get_security_conf(char *string, void *arg);
+int check_infofile(char *infodir, disklist_t *dl, char **errmsg);
#endif /* SERVER_UTIL_H */
* Authors: the Amanda Development Team. Its members are listed in a
* file named AUTHORS, in the root directory of this distribution.
*/
-/* $Id: taper.c,v 1.144 2006/08/24 11:23:32 martinea Exp $
+/* $Id: taper.c,v 1.144.2.7 2007/01/18 12:57:16 martinea Exp $
*
* moves files from holding disk to tape, or from a socket to tape
*/
/*NOTREACHED*/
}
- tapedev = stralloc(getconf_str(CNF_TAPEDEV));
+ tapedev = getconf_str(CNF_TAPEDEV);
tapetype = getconf_str(CNF_TAPETYPE);
tt = lookup_tapetype(tapetype);
#ifdef HAVE_LIBVTBLC
if ((buffers = attach_buffers(size)) != NULL) {
break;
}
- log_add(L_INFO, "attach_buffers: (%d tapebuf%s: %d bytes) %s",
+ log_add(L_INFO, "attach_buffers: (%d tapebuf%s: %zu bytes) %s",
conf_tapebufs,
(conf_tapebufs == 1) ? "" : "s",
size,
dbprintf(("create_split_buffer: fallback size " OFF_T_FMT "\n",
(OFF_T_FMT_TYPE)splitsize));
log_add(L_INFO,
- "%s: using fallback split size of %dkb to buffer %s in-memory",
- buff_err, splitsize, id_string);
+ "%s: using fallback split size of " OFF_T_FMT "kb to buffer %s in-memory",
+ buff_err, (OFF_T_FMT_TYPE)splitsize, id_string);
amfree(buff_err);
if (splitsize > mem_splitsize) {
amfree(mem_splitbuf);
if (mmap_splitbuffer_fd != -1) {
#ifdef HAVE_MMAP
#ifdef HAVE_SYS_MMAN_H
- if (splitbuf != NULL)
- munmap(splitbuf, (size_t)mmap_splitsize);
+ if (mmap_splitbuf != NULL) {
+ munmap(mmap_splitbuf, (size_t)mmap_splitsize);
+ mmap_splitbuf = NULL;
+ }
#endif
#endif
aclose(mmap_splitbuffer_fd);
mmap_splitsize = 0;
}
if (mem_splitbuf) {
- amfree(splitbuf);
+ amfree(mem_splitbuf);
mem_splitsize = 0;
}
}
taper_timestamp = newstralloc(taper_timestamp, cmdargs.argv[2]);
+ if (tapedev == NULL) {
+ if (getconf_str(CNF_TPCHANGER) == NULL) {
+ putresult(TAPE_ERROR, "[No tapedev or tpchanger defined]\n");
+ log_add(L_ERROR, "No tapedev or tpchanger defined");
+ dbprintf(("taper: No tapedev or tpchanger defined\n"));
+ exit(1);
+ }
+ } else {
+ tapedev = stralloc(tapedev);
+ }
+
tape_started = 0;
if (syncpipe_put('S', 0) == -1) {
put_syncpipe_fault_result(NULL);
}
file.blocksize = tt_blocksize;
build_header(bp->buffer, &file, tt_blocksize);
- kbytesread += (off_t)(tt_blocksize/1024); /* XXX shady */
file.type = F_CONT_DUMPFILE;
syncpipe_init(getp, putp);
tape_started = 0;
idlewait = times_zero;
+ if (tapedev != NULL) {
+ tapedev = stralloc(tapedev);
+ }
while (1) {
startclock();
}
if ((tape_fd = tape_open(tapedev, O_WRONLY)) == -1) {
if (errno == EACCES) {
- errstr = newstralloc(errstr,
- "writing label: tape is write protected");
+ errstr = newstralloc2(errstr,
+ "writing label: tape is write protected or I don't have write permission on ", tapedev);
} else {
errstr = newstralloc2(errstr,
"writing label: ", strerror(errno));
*/
/*
- * $Id: taperscan.c,v 1.17 2006/07/12 12:28:19 martinea Exp $
+ * $Id: taperscan.c,v 1.17.2.1 2006/10/03 11:35:52 martinea Exp $
*
* This contains the implementation of the taper-scan algorithm, as it is
* used by taper, amcheck, and amtape. See the header file taperscan.h for
}
else {
*tapedev = stralloc(getconf_str(CNF_TAPEDEV));
- result = scan_read_label(*tapedev, wantlabel,
- gotlabel, timestamp, &error_message);
- taperscan_output_callback(data, error_message);
- amfree(error_message);
+ if (*tapedev == NULL) {
+ result = -1;
+ taperscan_output_callback(data, "No tapedev spefified");
+ } else {
+ *tapedev = stralloc(*tapedev);
+ result = scan_read_label(*tapedev, wantlabel,
+ gotlabel, timestamp, &error_message);
+ taperscan_output_callback(data, error_message);
+ amfree(error_message);
+ }
}
return result;
LIBTOOL = @LIBTOOL@
LIBTOOL_DEPS = @LIBTOOL_DEPS@
LL_FMT = @LL_FMT@
+LL_RFMT = @LL_RFMT@
LN_S = @LN_S@
LTALLOCA = @LTALLOCA@
LTLIBOBJS = @LTLIBOBJS@
SET_MAKE = @SET_MAKE@
SHELL = @SHELL@
SNAPSHOT_STAMP = @SNAPSHOT_STAMP@
+SORT = @SORT@
STRIP = @STRIP@
USE_VERSION_SUFFIXES = @USE_VERSION_SUFFIXES@
VDUMP = @VDUMP@
*/
/*
- * $Id: output-file.c,v 1.14 2006/07/06 15:04:18 martinea Exp $
+ * $Id: output-file.c,v 1.14.2.1 2006/11/20 22:34:39 martinea Exp $
*
* tapeio.c virtual tape interface for a file device.
*
if (volume_info[fd].fd >= 0 && fi->ri_count == 0 &&
(rfd = open(recordfilename, O_RDONLY)) >= 0) {
for (; (line = areads(rfd)) != NULL; free(line)) {
- n = sscanf(line,
- OFF_T_FMT " " OFF_T_FMT " " SIZE_T_FMT,
- (OFF_T_FMT_TYPE *)&start_record,
- (OFF_T_FMT_TYPE *)&end_record,
- (SIZE_T_FMT_TYPE *)&record_size);
+ /* We play this game because OFF_T_FMT_TYPE is not
+ necessarily the same as off_t, and we need to cast the
+ actual value (not just the pointer. */
+ OFF_T_FMT_TYPE start_record_ = (OFF_T_FMT_TYPE)0;
+ OFF_T_FMT_TYPE end_record_ = (OFF_T_FMT_TYPE)0;
+ n = sscanf(line, OFF_T_FMT " " OFF_T_FMT " " SIZE_T_FMT,
+ &start_record_, &end_record_, &record_size);
+ start_record = start_record_;
+ end_record = end_record_;
+
if (n == 3) {
ri_p = &fi->ri;
amtable_alloc((void **)ri_p,