working on creating the 3.0 release tree
[Samba.git] / docs / htmldocs / testparm.1.html
blobbaf11bacac6f85484219c3330eae24e9ca4ce172
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN">
2 <HTML
3 ><HEAD
4 ><TITLE
5 >testparm</TITLE
6 ><META
7 NAME="GENERATOR"
8 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+
9 "></HEAD
10 ><BODY
11 CLASS="REFENTRY"
12 BGCOLOR="#FFFFFF"
13 TEXT="#000000"
14 LINK="#0000FF"
15 VLINK="#840084"
16 ALINK="#0000FF"
17 ><H1
18 ><A
19 NAME="TESTPARM">testparm</H1
20 ><DIV
21 CLASS="REFNAMEDIV"
22 ><A
23 NAME="AEN5"
24 ></A
25 ><H2
26 >Name</H2
27 >testparm&nbsp;--&nbsp;check an smb.conf configuration file for
28 internal correctness</DIV
29 ><DIV
30 CLASS="REFSYNOPSISDIV"
31 ><A
32 NAME="AEN8"><H2
33 >Synopsis</H2
34 ><P
35 ><B
36 CLASS="COMMAND"
37 >testparm</B
38 > [-s] [-h] [-v] [-L &#60;servername&#62;] [-t &#60;encoding&#62;] {config filename} [hostname hostIP]</P
39 ></DIV
40 ><DIV
41 CLASS="REFSECT1"
42 ><A
43 NAME="AEN18"
44 ></A
45 ><H2
46 >DESCRIPTION</H2
47 ><P
48 >This tool is part of the <A
49 HREF="samba.7.html"
50 TARGET="_top"
51 > Samba</A
52 > suite.</P
53 ><P
54 ><B
55 CLASS="COMMAND"
56 >testparm</B
57 > is a very simple test program
58 to check an <B
59 CLASS="COMMAND"
60 >smbd</B
61 > configuration file for
62 internal correctness. If this program reports no problems, you
63 can use the configuration file with confidence that <B
64 CLASS="COMMAND"
65 >smbd
66 </B
67 > will successfully load the configuration file.</P
68 ><P
69 >Note that this is <I
70 CLASS="EMPHASIS"
71 >NOT</I
72 > a guarantee that
73 the services specified in the configuration file will be
74 available or will operate as expected. </P
75 ><P
76 >If the optional host name and host IP address are
77 specified on the command line, this test program will run through
78 the service entries reporting whether the specified host
79 has access to each service. </P
80 ><P
81 >If <B
82 CLASS="COMMAND"
83 >testparm</B
84 > finds an error in the <TT
85 CLASS="FILENAME"
86 > smb.conf</TT
87 > file it returns an exit code of 1 to the calling
88 program, else it returns an exit code of 0. This allows shell scripts
89 to test the output from <B
90 CLASS="COMMAND"
91 >testparm</B
92 >.</P
93 ></DIV
94 ><DIV
95 CLASS="REFSECT1"
96 ><A
97 NAME="AEN33"
98 ></A
99 ><H2
100 >OPTIONS</H2
102 ></P
103 ><DIV
104 CLASS="VARIABLELIST"
105 ><DL
106 ><DT
107 >-s</DT
108 ><DD
110 >Without this option, <B
111 CLASS="COMMAND"
112 >testparm</B
114 will prompt for a carriage return after printing the service
115 names and before dumping the service definitions.</P
116 ></DD
117 ><DT
118 >-h</DT
119 ><DD
121 >Print usage message </P
122 ></DD
123 ><DT
124 >-L servername</DT
125 ><DD
127 >Sets the value of the %L macro to <TT
128 CLASS="REPLACEABLE"
130 >servername</I
131 ></TT
133 This is useful for testing include files specified with the
134 %L macro. </P
135 ></DD
136 ><DT
137 >-v</DT
138 ><DD
140 >If this option is specified, testparm
141 will also output all options that were not used in
143 CLASS="FILENAME"
144 >smb.conf</TT
145 > and are thus set to
146 their defaults.</P
147 ></DD
148 ><DT
149 >-t encoding</DT
150 ><DD
152 > Output data in specified encoding.
154 ></DD
155 ><DT
156 >configfilename</DT
157 ><DD
159 >This is the name of the configuration file
160 to check. If this parameter is not present then the
161 default <TT
162 CLASS="FILENAME"
163 >smb.conf</TT
164 > file will be checked.
166 ></DD
167 ><DT
168 >hostname</DT
169 ><DD
171 >If this parameter and the following are
172 specified, then <B
173 CLASS="COMMAND"
174 >testparm</B
175 > will examine the <TT
176 CLASS="PARAMETER"
178 >hosts
179 allow</I
180 ></TT
181 > and <TT
182 CLASS="PARAMETER"
184 >hosts deny</I
185 ></TT
187 parameters in the <TT
188 CLASS="FILENAME"
189 >smb.conf</TT
190 > file to
191 determine if the hostname with this IP address would be
192 allowed access to the <B
193 CLASS="COMMAND"
194 >smbd</B
195 > server. If
196 this parameter is supplied, the hostIP parameter must also
197 be supplied.</P
198 ></DD
199 ><DT
200 >hostIP</DT
201 ><DD
203 >This is the IP address of the host specified
204 in the previous parameter. This address must be supplied
205 if the hostname parameter is supplied. </P
206 ></DD
207 ></DL
208 ></DIV
209 ></DIV
210 ><DIV
211 CLASS="REFSECT1"
213 NAME="AEN77"
214 ></A
215 ><H2
216 >FILES</H2
218 ></P
219 ><DIV
220 CLASS="VARIABLELIST"
221 ><DL
222 ><DT
223 ><TT
224 CLASS="FILENAME"
225 >smb.conf</TT
226 ></DT
227 ><DD
229 >This is usually the name of the configuration
230 file used by <B
231 CLASS="COMMAND"
232 >smbd</B
235 ></DD
236 ></DL
237 ></DIV
238 ></DIV
239 ><DIV
240 CLASS="REFSECT1"
242 NAME="AEN86"
243 ></A
244 ><H2
245 >DIAGNOSTICS</H2
247 >The program will issue a message saying whether the
248 configuration file loaded OK or not. This message may be preceded by
249 errors and warnings if the file did not load. If the file was
250 loaded OK, the program then dumps all known service details
251 to stdout. </P
252 ></DIV
253 ><DIV
254 CLASS="REFSECT1"
256 NAME="AEN89"
257 ></A
258 ><H2
259 >VERSION</H2
261 >This man page is correct for version 3.0 of
262 the Samba suite.</P
263 ></DIV
264 ><DIV
265 CLASS="REFSECT1"
267 NAME="AEN92"
268 ></A
269 ><H2
270 >SEE ALSO</H2
273 HREF="smb.conf.5.html"
274 TARGET="_top"
275 ><TT
276 CLASS="FILENAME"
277 >smb.conf(5)</TT
278 ></A
281 HREF="smbd.8.html"
282 TARGET="_top"
284 CLASS="COMMAND"
285 >smbd(8)</B
286 ></A
289 ></DIV
290 ><DIV
291 CLASS="REFSECT1"
293 NAME="AEN99"
294 ></A
295 ><H2
296 >AUTHOR</H2
298 >The original Samba software and related utilities
299 were created by Andrew Tridgell. Samba is now developed
300 by the Samba Team as an Open Source project similar
301 to the way the Linux kernel is developed.</P
303 >The original Samba man pages were written by Karl Auer.
304 The man page sources were converted to YODL format (another
305 excellent piece of Open Source software, available at
307 HREF="ftp://ftp.icce.rug.nl/pub/unix/"
308 TARGET="_top"
309 > ftp://ftp.icce.rug.nl/pub/unix/</A
310 >) and updated for the Samba 2.0
311 release by Jeremy Allison. The conversion to DocBook for
312 Samba 2.2 was done by Gerald Carter</P
313 ></DIV
314 ></BODY
315 ></HTML