Imported Upstream version 2.6.0p1
[debian/amanda] / man / amgetconf.8
1 .\"     Title: amgetconf
2 .\"    Author: 
3 .\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
4 .\"      Date: 05/14/2008
5 .\"    Manual: 
6 .\"    Source: 
7 .\"
8 .TH "AMGETCONF" "8" "05/14/2008" "" ""
9 .\" disable hyphenation
10 .nh
11 .\" disable justification (adjust text to left margin only)
12 .ad l
13 .SH "NAME"
14 amgetconf - look up amanda.conf variables
15 .SH "SYNOPSIS"
16 .HP 10
17 \fBamgetconf\fR [\fIconfig\fR] [\fI\-\-list\fR] \fIparameter\fR [\-o\ \fIconfigoption\fR]...
18 .SH "DESCRIPTION"
19 .PP
20 \fBAmgetconf\fR
21 looks up parameters in
22 \fIamanda\.conf\fR, the
23 \fIAmanda\fR
24 configuration file, or from the build and runtime environment, and returns their corresponding value\.
25 .PP
26 If
27 \fIconfig\fR
28 is not specified,
29 \fBamgetconf\fR
30 assumes it is being run from the configuration directory and that
31 \fIamanda\.conf\fR
32 is present\.
33 .PP
34 If
35 \fIparameter\fR
36 begins with
37 \fIbuild\.\fR, the (case insensitive) string following the period is a build environment variable\. Variables without a value (e\.g\.
38 \fIXFSDUMP\fR
39 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\.
40 \fIUSE_AMANDAHOSTS\fR) will return
41 1
42 if the flag is set or an empty string if it is not\.
43 .PP
44 If
45 \fIparameter\fR
46 begins with
47 \fIdbopen\.\fR, the string following the period is a program name and an
48 \fIAmanda\fR
49 debug file will be created for the caller\. The name of the file is returned\.
50 .PP
51 If
52 \fIparameter\fR
53 begins with
54 \fIdbclose\.\fR, the string following the period is a program name previously used with
55 \fIdbopen\.\fR, followed by a colon (:) and the previously opened file name\.
56 .PP
57 See the
58 \fBamanda\fR(8)
59 man page for more details about
60 \fIAmanda\fR\.
61 .SH "OPTIONS"
62 .PP
63 \fB\-\-list\fR
64 .RS 4
65 The parameter must be \'tapetype\', \'dumptype, \'holdingdisk\' or \'interface\'\. It will output, one by line, the list of identifier for the parameter\.
66 .PP
67 \-\-list tapetype
68 .RS 4
69 Output the list of tapetype, one by line\.
70 .RE
71 .PP
72 \-\-list dumptype
73 .RS 4
74 Output the list of dumptype, one by line\.
75 .RE
76 .PP
77 \-\-list holdingdisk
78 .RS 4
79 Output the list of holdingdisk, one by line\.
80 .RE
81 .PP
82 \-\-list interface
83 .RS 4
84 Output the list of interface, one by line\.
85 .RE
86 .RE
87 .PP
88 \fBparameter\fR
89 .RS 4
90 It could be one of the below format:
91 .PP
92 runtapes
93 .RS 4
94 .RE
95 .PP
96 DUMPTYPE:no\-compress:compress
97 .RS 4
98 .RE
99 .PP
100 TAPETYPE:HP\-DAT:length
101 .RS 4
102 .RE
103 .PP
104 INTERFACE:local:use
105 .RS 4
106 .RE
107 .PP
108 HOLDINGDISK:hd1:use
109 .RS 4
110 .RE
111 .RE
112 .PP
113 \fB\-o\fR \fIconfigoption\fR
114 .RS 4
115 See the "\fBCONFIGURATION OVERRIDE\fR" section in
116 \fBamanda\fR(8)\.
117 .RE
118 .SH "EXAMPLE"
119 .PP
120 Find out the path to the log file directory:
121 .sp
122 .RS 4
123 .nf
124 % amgetconf daily logdir
125 /usr/local/etc/amanda//daily
126 .fi
127 .RE
128 .PP
129 Find out the current tape type:
130 .sp
131 .RS 4
132 .nf
133 % amgetconf daily tapetype
134 DLT4000\-IV
135 .fi
136 .RE
137 .PP
138 Find out the default configuration directory:
139 .sp
140 .RS 4
141 .nf
142 % amgetconf daily build\.CONFIG_DIR
143 /usr/local/etc/amanda/
144 .fi
145 .RE
146 .PP
147 Create, use and close a debug file in a script:
148 .sp
149 .RS 4
150 .nf
151 % set debug_file = `amgetconf daily dbopen\.myscript`
152 % echo debug information >> $debug_file
153 % amgetconf daily dbclose\.myscript:$debug_file
154 .fi
155 .RE
156 .sp
157 .SH "MESSAGES"
158 .PP
159 amgetconf: no such parameter \fIparam\fR
160 .RS 4
161 Parameter
162 \fIparam\fR
163 is not a known keyword (e\.g\. not a valid
164 \fIamanda\.conf\fR
165 keyword)\.
166 .RE
167 .SH "SEE ALSO"
168 .PP
169
170 \fBamanda\fR(8),
171 \fI\%http://wiki.zmanda.com\fR