AFCLIENT(8)

NAME
afclient - controls the client functions of the afbackup package

SYNOPSIS
afclient -cxtd [-RraunlOvgIiqQZwb] [-h <backup-server>] [-z <zipcmd> <unzipcmd>] [-T <to-extract-filename>] [-C <cartridge-number>] [-F <filenumber-on-tape>] [-f <archive-filename>] [-e <errorlog-filename>] [-p <server-port-number>] [-N <newer-than-filename>] [-o <user-ID>] [-k <encrption-key-file>] [-s <dont-compress-filepattern> [-s ...]] [ -H <header> ] [-V <statistics-report-file>] [<files> <directories> ...]
afclient -X <program> [ -h <backup-client> ]
afclient -?
afclient -usage

The first form is similar to tar (1), except that it contacts a backup server, if the -f option is not supplied.

The second form is used to start a program remotely on another host. In most cases this will be one of:

    afclient -X full_backup -h <some-host>
    afclient -X incr_backup -h <some-host>

Normally this host is a backup client and a backup is started this way. Only programs can be started, that reside in the directory, that is configured in the backup server's configu- ration file unter "Program-Directory".

The third form produces the following help text:

DESCRIPTION
This program is used to maintain archives on a backup server host or in a file. Archives can be created, extracted or their contents be listed. One of the following flags has always to be supplied:

-c  to create an archive

-x  to extract from an archive

-t  to list the contents of an archive

-d  to verify (compare) the contents of an archive

-C  to set a certain cartridge on the backup server (makes only sense extracting or listing with -x or -t, the writing position can't be changed by clients)

-F  to set a certain file on the backup server's tape (same applies as for -C )

-q  to printout the actual cartridge and tape file number on the backup server

-Q  to printout the cartridge and tape file number for the the next write access on the backup server

-X  followed by the full path name of a program to be started on the client. This can be used to trigger a backup remotely. If the program needs arguments, the command together with the arguments has to be enclosed by quotes

-I  to printout an index of the backups written to the actual cartridge

-w  to check the status of the streamer on the server side, e.g. whether it is ready and waiting for requests to service, see below for possible states

-c, -x, -t and -X are mutual exclusive. The other options can be supplied as needed. To set the cartridge and/or the tape file on the backup server is only making sense when not creating an archive. The serial order of writing to tape is handled by the server machine independently of the client.

More options in alphabetical order:

-a  in combination with -x : extract all files and directories in the archive

-b  don't enter buffering mode

-e <errlog>
    Use the file <errlog> to write error messages to instead of the standard error output

-f <file>
    write to or read from a file instead of querying the backup server

-g  while extracting/reading: ignore leading garbage, suppress error messages at the beginning. This is useful when extracting from tape files, that are not the first ones of a whole archive.

-H <header>
    put the supplied informational header to the begin of the backup

-h <host>
    use the backup server with the name <host> default host is the machine with the name backuphost

-i  while extracting: ignore the stored ownership and do not restore it

-k <file>
    use the contents of the given file as encryption key for authenticating to the server

-l  for each packed or unpacked filename, if sending to or receiving from a backup server in verbose mode in combination with -n: printout server name and port number at the beginning of the line, e. g.: orion%2988!

-N <file>
    while archiving: ignore files with a modification time before the one of the given file, only save newer files or such with the same age in seconds

-n  for each packed or unpacked filename, if sending to or receiving from a backup server in verbose mode: printout cartridge and tape file number at the beginning of the line, e. g.: 7.15: <filename>

-O  for each packed file creating a backup in verbose mode: printout the user-ID of the file owner at the beginning of the line prefixed with a bar | eventually behind cartridge and file number

-o <uid>
    archive or extract only files owned by the user with the given user-ID (an integer)

-p <portno>
    use a different port number for communicating with the backup server. Default is TCP-Port 2988

-R  pack or extract directories recursively with all of their contents

-r  use filenames relative to the current directory, whether they start with a slash or not

-S <cartset>
    The cartridge set to use, where <cartset> is the number of a valid cartridge set on the server side. Default is 1. This option makes sense only when creating backups with -c

-s <filepat>
    do not attempt compression on files matching the given filename pattern. This parameter may appear several times

-T <file>
    read the filenames to process from the <file>. The filenames must be separated by whitespace. If whitespace is part of a filename, it has to be enclosed by double quotes. Double quotes or backslashes within the filename have to be preceded by a backslash

-u  while extracting: remove existing files with the same name as found in the archive. Otherwise no existing files are overwritten

-V <file>
    write a report containing statistics at the end of a backup to the <file>

-v  verbose mode: print the filenames while creating or extracting, be a little more verbose while listing contents

-z <z> <uz>
    use <z> as the command, that is used to compress files, <uz> for the corresponding uncompress. The command has to read from stdin and to write to stdout. If arguments have to be supplied to <z> and/or <uz>, don't forget to use quotes

-Z  while printing out the contents: check those files in the archive that are compressed for integrity

-?  to printout this text

FILENAMES
The names of the files and directories, that have to be put into or extracted from an archive are by default read from the standard input. If you supply filenames in the command line or enter the -a flag when extracting, standard input is not read. The same is valid, if filenames are read from a file with the -T option. When reading the names from a file or from standard input, filenames have to be separated by whitespace. If a name is containing whitespace, it has to be enclosed in double quotes ( each has to be preceded by a backslash (so backslashes become double backslashes).

STATUS REPORTS
The -w option reports one of the following states, seperated by the plus character + :

READY
    the device is not in use by any program and the server side is ready to service requests

BUSY
    the device is in use and actually operated by the afbackup service

DEVINUSE
    the streamer device is in use by some program, that is not part of the afbackup service

UNAVAIL
    the streamer device is not accessible or in some other way occupied

UNLOADED
    the device is not busy, but there is no tape loaded

CHANGEABLE
    when reported together with UNLOADED, a tape can be loaded quickly e.g. using the afclient command with option -C <cartno>. It is not considered quickly, if a human operator must put the cartridge into the drive, so in this case only UNLOADED is reported. When reported with READY, the tape can be changed quickly (same understanding as before).

FILES

@clientlibdir@/@clientconf@
    Client configuration file

@clientlogdir@
    The directory for logging the client backups

@clientvardir@
    Some internal state information of the client backups.

SEE ALSO
afclientconfig(8), xafclientconfig(8), full_backup(8), incr_backup(8), afverify(8), afrestore(8), print_errors(8), afclient.conf(8), afserver.conf(8), tar(1)

AUTHOR
afbackup was written by Albert Fluegel (af@muc.de). This manpage was extracted from the text docs by Christian Meder (meder@isr.uni-stuttgart.de).