1 <?xml version="1.0" encoding="ISO-8859-1"?>
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.1.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.1.2/docbookx.dtd"
5 <!-- entities files to use -->
6 <!ENTITY % global_entities SYSTEM '../entities/global.entities'>
10 <!-- lifted from troff+man by doclifter -->
11 <refentry id='amcheck.8'>
14 <refentrytitle>amcheck</refentrytitle>
15 <manvolnum>8</manvolnum>
18 <refname>amcheck</refname>
19 <refpurpose>run &A; self-checks</refpurpose>
21 <!-- body begins here -->
24 <command>amcheck</command>
25 <arg choice='opt'>-am</arg>
26 <arg choice='opt'>-w</arg>
27 <arg choice='opt'>-sclt</arg>
28 <arg choice='opt'>-M <replaceable>address</replaceable></arg>
29 <arg choice='plain'><replaceable>config</replaceable></arg>
30 <arg choice='opt' rep='repeat'>
31 <arg choice='plain'><replaceable>host</replaceable></arg>
32 <arg choice='opt' rep='repeat'><replaceable>disk</replaceable></arg>
34 <arg choice='plain' rep='repeat'><group><arg choice='plain'>-o </arg><replaceable>configoption</replaceable></group></arg>
39 <refsect1><title>DESCRIPTION</title>
40 <para><emphasis remap='B'>Amcheck</emphasis>
41 runs a number of self-checks on both the &A; tape server host and
42 the &A; client hosts.</para>
44 <para>On the tape server host,
45 <command>amcheck</command>
46 can go through the same tape checking used at the start of the nightly
47 <emphasis remap='B'>amdump</emphasis>
48 run to verify the correct tape for the next run is mounted.</para>
50 <para><emphasis remap='B'>Amcheck</emphasis>
51 can also do a self-check on all client hosts
52 to make sure each host is running and that permissions
53 on filesystems to be backed up are correct.</para>
55 <para>You can specify many host/disk expressions, only disks that
56 match an expression will be checked. All disks are checked if no
57 expressions are given.</para>
60 <citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>
61 man page for more details about &A;.</para>
64 <refsect1><title>OPTIONS</title>
65 <variablelist remap='TP'>
67 <term><option>-s</option></term>
69 <para>Run the tape server local and tape checks (same as
70 <option>-lt</option>).</para>
74 <term><option>-c</option></term>
76 <para>Run the client host checks. Multiple specific clients can be
77 checked by specifying the client name.</para>
81 <term><option>-l</option></term>
83 <para>Run the local tests (e.g. permissions) on the server host.</para>
87 <term><option>-t</option></term>
89 <para>Run the tape tests on the server host.</para>
93 <term><option>-w</option></term>
95 <para>Enables a DESTRUCTIVE check for write-protection on the
96 tape (which would otherwise cause the subsequent
97 <emphasis remap='B'>amdump</emphasis>
100 is writable, this check causes all data after the tape label to be
101 erased. If the label_new_tapes option is enabled, this check may ERASE
102 any non-Amanda tape in the drive or changer.
103 The check enable the tape tests on the server host
104 and is only made if the tape is otherwise correct.</para>
108 <term><option>-m</option></term>
110 <para>Nothing is printed, but mail is sent if any errors are detected.
112 <emphasis remap='B'>mailto</emphasis>
113 address specified in the
114 <emphasis remap='I'>amanda.conf</emphasis>
116 <emphasis remap='I'>address</emphasis>
123 <term><option>-a</option></term>
127 but the mail is always sent.</para>
132 <term><option>-M</option> <replaceable>address</replaceable></term>
134 <para>Mail the report to
135 <emphasis remap='I'>address</emphasis>
137 <emphasis remap='B'>mailto</emphasis>
139 <emphasis remap='I'>amanda.conf</emphasis>.
141 <option>-m</option>.</para>
146 <term><replaceable>host</replaceable> [<replaceable>disk</replaceable>]*</term>
148 <para>Specify the host and disk on which the command will work.</para>
153 <term><emphasis remap='B'>-o</emphasis> <replaceable>configoption</replaceable></term>
155 <para>See the "<emphasis remap='B'>CONFIGURATION OVERRIDE</emphasis>" section in <citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>.</para>
161 <option>-cs</option>.</para>
164 <refsect1><title>EXAMPLES</title>
165 <para>In this example, both the tape server and client tests are run.
166 The results are displayed on standard output.</para>
170 &A; Tape Server Host Check
171 -----------------------------
172 /amanda2/amanda/work: 911475 KB disk space available, that's plenty.
173 NOTE: skipping tape-writable test.
175 Server check took 34.966 seconds.
177 &A; Backup Client Hosts Check
178 --------------------------------
179 WARNING: northstar: selfcheck request timed out. Host down?
180 WARNING: drinkme: selfcheck request timed out. Host down?
181 WARNING: scruffy: selfcheck request timed out. Host down?
182 Client check: 136 hosts checked in 51.945 seconds, 3 problems found.
184 (brought to you by &A; 2.5.0)
187 <para>In this example, if the line
188 <emphasis remap='B'>mailto csd-amanda</emphasis>
190 <emphasis remap='I'>amanda.conf</emphasis>,
192 <emphasis remap='B'>csd-amanda</emphasis>
193 if the server check returns an error.</para>
196 % amcheck -s -m daily
200 <refsect1><title>MESSAGES</title>
201 <variablelist remap='TP'>
203 <term>fatal slot <emphasis remap='I'>slot</emphasis>: <emphasis remap='I'>error message</emphasis></term>
206 The tape changer detected some kind of fatal error while trying to load slot
207 <emphasis remap='I'>slot</emphasis>.</para>
211 <term>slot <emphasis remap='I'>slot</emphasis>: <emphasis remap='I'>error message</emphasis></term>
214 The tape changer detected some kind of non-fatal error
215 (e.g. an empty slot was detected)
216 while trying to load slot
217 <emphasis remap='I'>slot</emphasis>,
218 or an error was detected trying to read the tape label.</para>
222 <term>slot <emphasis remap='I'>slot</emphasis>: date <emphasis remap='I'>YYYYMMDD</emphasis> label <emphasis remap='I'>label</emphasis> (<emphasis remap='I'>result</emphasis>)</term>
226 <emphasis remap='I'>label</emphasis>
228 <emphasis remap='I'>slot</emphasis>
229 was loaded and found to have been last written on
230 <emphasis remap='I'>YYYYMMDD</emphasis>.
231 If the tape is new, the date field will be an
232 <emphasis remap='I'>X</emphasis>.
234 <emphasis remap='I'>result</emphasis>
235 may be one of:</para>
237 <variablelist remap='TP'>
239 <term>exact label match</term>
241 <para>This is the expected tape.</para>
245 <term>no match</term>
247 <para>This label does not match the
248 <emphasis remap='B'>labelstr</emphasis>
250 <emphasis remap='I'>amanda.conf</emphasis>.
251 Tape scanning will continue.</para>
255 <term>active tape</term>
257 <para>This tape is still active and cannot be overwritten.
258 Tape scanning will continue.</para>
262 <term>first labelstr match</term>
264 <para>This tape is the first one that matches the
265 <emphasis remap='B'>labelstr</emphasis>
267 <emphasis remap='I'>amanda.conf</emphasis>.
268 Tape scanning will continue if necessary.</para>
272 <term>labelstr match</term>
274 <para>This tape is the next one that matches the
275 <emphasis remap='B'>labelstr</emphasis>
277 <emphasis remap='I'>amanda.conf</emphasis>.
278 Tape scanning will continue.</para>
286 <term>ERROR: cannot look up dump user <emphasis remap='I'>user</emphasis></term>
290 <emphasis remap='I'>user</emphasis>
292 <emphasis remap='I'>amanda.conf</emphasis>
293 could not be found in the system password information.</para>
297 <term>ERROR: cannot look up my own uid (<emphasis remap='I'>uid</emphasis>)</term>
301 <emphasis remap='I'>uid</emphasis>
303 <command>amcheck</command>
304 could not be found in the system password information.</para>
308 <term>ERROR: running as user <emphasis remap='I'>runuser</emphasis> instead of <emphasis remap='I'>dumpuser</emphasis></term>
311 <emphasis remap='B'>Amcheck</emphasis>
312 should be run as the dump user
313 <emphasis remap='I'>dumpuser</emphasis>
315 <emphasis remap='I'>amanda.conf</emphasis>
317 <emphasis remap='I'>runuser</emphasis>.</para>
321 <term>ERROR: program dir <emphasis remap='I'>directory</emphasis>: not accessible</term>
324 The directory &A; expects to find its auxiliary programs in,
325 <emphasis remap='I'>directory</emphasis>,
326 is not accessible.</para>
330 <term>ERROR: program <emphasis remap='I'>program</emphasis>: does not exist</term>
334 <emphasis remap='I'>program</emphasis>
335 needed on the tape server could not be found.</para>
339 <term>ERROR: program <emphasis remap='I'>program</emphasis>: not a file</term>
343 <emphasis remap='I'>program</emphasis>
344 needed on the tape server exists but is not a file.</para>
348 <term>ERROR: program <emphasis remap='I'>program</emphasis>: not executable</term>
352 <emphasis remap='I'>program</emphasis>
353 needed on the tape server exists but is not executable.</para>
357 <term>WARNING: program <emphasis remap='I'>program</emphasis>: not setuid-root</term>
361 <emphasis remap='I'>program</emphasis>
362 needed on the tape server exists but should be owned by user "root"
367 <term>ERROR: <emphasis remap='I'>XXX</emphasis> dir <emphasis remap='I'>directory</emphasis>: not writable</term>
371 <emphasis remap='I'>directory</emphasis>
372 is either not writable,
373 i.e. the dump user will not be able to create or remove files,
374 or cannot be accessed, perhaps because a parent directory
375 does not allow search permission.
377 <emphasis remap='I'>XXX</emphasis>
380 <variablelist remap='TP'>
384 <para>for the &A; log directory (see
385 <emphasis remap='B'>logdir</emphasis>
387 <emphasis remap='B'>amanda.conf</emphasis>)</para>
393 <para>for the directory that holds the old log files (see
394 <emphasis remap='B'>logdir</emphasis>
396 <emphasis remap='B'>amanda.conf</emphasis>)</para>
402 <para>for an &A; database information directory (see
403 <emphasis remap='B'>curinfo</emphasis>
405 <emphasis remap='B'>amanda.conf</emphasis>)
412 <para>for an &A; index directory (see
413 <emphasis remap='B'>indexdir</emphasis>
415 <emphasis remap='B'>amanda.conf</emphasis>)</para>
419 <term>tapelist</term>
421 <para>for the &A; tapelist directory (see
422 <emphasis remap='B'>tapelist</emphasis>
424 <emphasis remap='B'>amanda.conf</emphasis>)</para>
432 <term>NOTE: <emphasis remap='I'>XXX</emphasis> dir <emphasis remap='I'>directory</emphasis>: does not exist</term>
435 A database (info) or index directory does not exist or cannot be accessed.
436 This might just mean this is a new client or disk,
437 but if that is not the case, this should be treated as an error.</para>
441 <term>NOTE: it will be created on the next run</term>
444 This indicates the info directory listed in the previous message
445 will be created on the next run.</para>
449 <term>ERROR: <emphasis remap='I'>XXX</emphasis> dir <emphasis remap='I'>name</emphasis>: not a directory</term>
452 <emphasis remap='B'>Amcheck</emphasis>
454 <emphasis remap='I'>name</emphasis>
456 but it is something else (e.g. file).</para>
460 <term>WARNING: info file <filename>file</filename>: does not exist</term>
464 <emphasis remap='I'>file</emphasis>
465 does not exist in the text format database.
466 Since the parent directories do exist,
467 the file should already have been created.</para>
471 <term>ERROR: info file <filename>name</filename>: not a file</term>
474 <emphasis remap='B'>Amcheck</emphasis>
476 <emphasis remap='I'>name</emphasis>
478 but it is something else (e.g. file).</para>
482 <term>ERROR: info file <filename>file</filename>: not readable</term>
485 The text format database file
486 <emphasis remap='I'>file</emphasis>
487 is not readable.</para>
491 <term>ERROR: log file <filename>file</filename>: not writable</term>
495 <emphasis remap='I'>file</emphasis>
497 <emphasis remap='B'>log</emphasis>
499 <emphasis remap='B'>logdir</emphasis>
501 <emphasis remap='B'>amanda.conf</emphasis>)
502 is either not writable,
503 or cannot be accessed, perhaps because a parent directory
504 does not allow search permission.</para>
508 <term>ERROR: tape list <emphasis remap='I'>tapelist</emphasis>: not writable</term>
512 <emphasis remap='I'>tapelist</emphasis>
514 <emphasis remap='B'>tapelist</emphasis>
516 <emphasis remap='B'>amanda.conf</emphasis>)
517 is not writable or was not found.</para>
521 <term>ERROR: tape list <emphasis remap='I'>tapelist</emphasis>: parse error</term>
525 <emphasis remap='I'>tapelist</emphasis>
527 <emphasis remap='B'>tapelist</emphasis>
529 <emphasis remap='B'>amanda.conf</emphasis>)
530 could not be read or parsed.</para>
534 <term>WARNING: tapedev is /dev/null, dumps will be thrown away</term>
538 <emphasis remap='B'>tapedev</emphasis>
540 <emphasis remap='B'>amanda.conf</emphasis>
542 <filename>/dev/null</filename>
543 and &A; uses that when debugging to throw all the dump images away.</para>
547 <term>WARNING: hold file <filename>file</filename> exists</term>
551 <emphasis remap='I'>file</emphasis>
552 exists and will cause
553 <emphasis remap='B'>amdump</emphasis>
554 to pause at the beginning until it is removed.</para>
558 <term>ERROR: holding disk <emphasis remap='I'>disk</emphasis>: statfs: <emphasis remap='I'>error message</emphasis></term>
561 An error was returned from the
562 <emphasis remap='I'>statfs</emphasis>
563 system call on holding disk
564 <emphasis remap='I'>disk</emphasis>
565 (maybe because it does not exist).</para>
569 <term>ERROR: holding disk <emphasis remap='I'>disk</emphasis>: not writable</term>
573 <emphasis remap='I'>disk</emphasis>,
575 probably because the caller does not have write permission
576 or a parent directory does not allow search permission.</para>
580 <term>WARNING: holding disk <emphasis remap='I'>disk</emphasis>: available space unknown <emphasis remap='I'>N</emphasis> KB requested.</term>
583 <emphasis remap='B'>Amcheck</emphasis>
584 could not determine the amount of available space on holding disk
585 <emphasis remap='I'>disk</emphasis>
586 to see if there were at least
587 <emphasis remap='I'>N</emphasis>
588 KBytes available.</para>
592 <term>WARNING: holding disk <emphasis remap='I'>disk</emphasis>: only <emphasis remap='I'>F</emphasis> KB free (<emphasis remap='I'>R</emphasis> KB requested).</term>
595 <emphasis remap='I'>amanda.conf</emphasis>
597 <emphasis remap='I'>R</emphasis>
598 KBytes of free space on holding disk
599 <emphasis remap='I'>disk</emphasis>,
601 <emphasis remap='I'>F</emphasis>
602 KBytes were available.
603 10 MBytes is subtracted for each backup process
605 <emphasis remap='B'>inparallel</emphasis>
606 <emphasis remap='I'>amanda.conf</emphasis>
608 to allow for unexpected overruns.</para>
609 <note><para>Even though this message is listed as a warning, it causes &amcheck; to exit with a non-zero status.</para>
615 <variablelist remap='TP'>
617 <term>Holding disk <emphasis remap='I'>disk</emphasis>: <emphasis remap='I'>N</emphasis> KB disk space available, that's plenty.</term>
620 There was sufficient free space on holding disk
621 <emphasis remap='I'>disk</emphasis>.</para>
625 <term>WARNING: holding disk <emphasis remap='I'>disk</emphasis>: only <emphasis remap='I'>F</emphasis> KB free, using nothing</term>
629 <emphasis remap='I'>disk</emphasis>
631 <emphasis remap='I'>F</emphasis>
632 KBytes of free space, but that is not enough for what is requested in
633 <emphasis remap='I'>amanda.conf</emphasis>.</para>
637 <term>Holding disk <emphasis remap='I'>disk</emphasis>: <emphasis remap='I'>F</emphasis> KB disk space available, using <emphasis remap='I'>U</emphasis> KB</term>
641 <emphasis remap='I'>disk</emphasis>
643 <emphasis remap='I'>F</emphasis>
644 KBytes of free space and &A; will be using up to
645 <emphasis remap='I'>U</emphasis>
650 <term>WARNING: if a tape changer is not available, runtapes must be set to 1.</term>
654 <emphasis remap='B'>runtapes</emphasis>
655 <emphasis remap='I'>amanda.conf</emphasis>
656 option must be set to 1 if the
657 <emphasis remap='B'>tpchanger</emphasis>
658 <emphasis remap='I'>amanda.conf</emphasis>
659 option is not set.</para>
663 <term>ERROR: <emphasis remap='I'>error message</emphasis>.</term>
666 An error was detected while initializing the tape changer.</para>
670 <term>ERROR: <emphasis remap='I'>tape device</emphasis>: <emphasis remap='I'>error message</emphasis>.</term>
673 An error was detected while processing the tape label.</para>
677 <term>ERROR: cannot overwrite active tape <emphasis remap='I'>label</emphasis>.</term>
681 <emphasis remap='I'>label</emphasis>
682 is still active and cannot be used.</para>
686 <term>ERROR: label <emphasis remap='I'>label</emphasis> doesn't match labelstr <emphasis remap='I'>pattern</emphasis> .</term>
690 <emphasis remap='I'>label</emphasis>
692 <emphasis remap='B'>labelstr</emphasis>
693 <emphasis remap='I'>amanda.conf</emphasis>
698 <term>(expecting a new tape)</term>
701 The tape is not OK and a new tape was expected.</para>
705 <term>(expecting tape <emphasis remap='I'>label</emphasis> or a new tape)</term>
708 The tape is not OK and either tape
709 <emphasis remap='I'>label</emphasis>
710 or a new tape was expected.</para>
714 <term>ERROR: tape <emphasis remap='I'>label</emphasis> label ok, but is not writable.</term>
718 <emphasis remap='I'>label</emphasis>
719 is OK, but the write enable test failed.</para>
723 <term>Tape <emphasis remap='I'>label</emphasis> is writable.</term>
727 <emphasis remap='I'>label</emphasis>
728 is OK and the write enable test succeeded.</para>
732 <term>NOTE: skipping tape-writable test.</term>
735 The tape write test (see the
737 option) was not enabled.</para>
741 <term>WARNING: skipping tape test because amdump or amflush seem to be running</term>
742 <term>WARNING: if they are not, you must run amcleanup</term>
746 <command>amcheck</command>
748 <emphasis remap='B'>amdump</emphasis>
750 <emphasis remap='B'>amflush</emphasis>
751 were running because a log file or amdump file exists.
752 If they are not running, you probably need to run
753 <emphasis remap='B'>amcleanup</emphasis>
754 to clear up a previous failure.
755 Otherwise, you need to wait until they complete before running
756 <command>amcheck</command><literal>.</literal></para>
760 <term>NOTE: skipping tape checks</term>
763 The tape tests are being skipped because you used the
765 command line option.</para>
769 <term>WARNING: <emphasis remap='I'>compress</emphasis> is not executable, server-compression and indexing will not work</term>
773 <emphasis remap='I'>compress</emphasis>
775 so compression on the tape server host and creating index files will not work.</para>
779 <term>Tape <emphasis remap='I'>label</emphasis> label ok.</term>
783 <emphasis remap='I'>label</emphasis>
789 <term>Server check took <emphasis remap='I'>S</emphasis> seconds.</term>
792 Reports how long the tape server host checks took.</para>
796 <term>ERROR: <emphasis remap='I'>host</emphasis>: could not resolve hostname</term>
799 Could not look up client hostname
800 <emphasis remap='I'>host</emphasis>.</para>
804 <term>Client check: <emphasis remap='I'>H</emphasis> hosts checked in <emphasis remap='I'>S</emphasis> seconds, <emphasis remap='I'>N</emphasis> problems found.</term>
807 Reports the number of client hosts checked,
808 how long it took and the number of errors detected.</para>
812 <term>WARNING: <emphasis remap='I'>host</emphasis>: selfcheck request timed out. Host down?</term>
815 There was no response from
816 <emphasis remap='I'>host</emphasis>
817 when trying to do the client checks.
818 The host might really be down or it might not be configured properly.</para>
822 <term>ERROR: <emphasis remap='I'>host</emphasis> NAK: <emphasis remap='I'>message</emphasis></term>
825 <emphasis remap='I'>Host</emphasis>
826 reported a negative acknowledgment error of
827 <emphasis remap='I'>message</emphasis>
828 to the status check request.</para>
832 <term>ERROR: <emphasis remap='I'>host</emphasis> NAK: [NAK parse failed]</term>
835 <emphasis remap='B'>Amcheck</emphasis>
836 could not parse the negative acknowledgment error from
837 <emphasis remap='I'>host</emphasis>.
838 There might be an &A; version mismatch between the host running
839 <command>amcheck</command>
841 <emphasis remap='I'>host</emphasis>.</para>
845 <term>ERROR: <emphasis remap='I'>host</emphasis> [mutual-authentication failed]</term>
848 Kerberos authentication failed while contacting
849 <emphasis remap='I'>host</emphasis>.</para>
853 <term>ERROR: <emphasis remap='I'>host</emphasis>: <emphasis remap='I'>message</emphasis></term>
857 <emphasis remap='I'>message</emphasis>
858 was reported by the status check on
859 <emphasis remap='I'>host</emphasis>.</para>
865 <refsect1><title>AUTHOR</title>
866 <para>James da Silva, &email.jds; : Original text</para>
867 <para>&maintainer.sgw;: XML-conversion</para>
870 <refsect1><title>SEE ALSO</title>
871 <para><citerefentry><refentrytitle>amanda</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
872 <citerefentry><refentrytitle>amdump</refentrytitle><manvolnum>8</manvolnum></citerefentry>,
873 <ulink url="http://wiki.zmanda.com"/>