1<HTML> 2<HEAD> 3<TITLE> 4[Chapter 4] 4.8 Logging Configuration Options</title><META NAME="DC.title" CONTENT=""><META NAME="DC.creator" CONTENT=""><META NAME="DC.publisher" CONTENT="O'Reilly & Associates, Inc."><META NAME="DC.date" CONTENT="1999-11-05T21:32:18Z"><META NAME="DC.type" CONTENT="Text.Monograph"><META NAME="DC.format" CONTENT="text/html" SCHEME="MIME"><META NAME="DC.source" CONTENT="" SCHEME="ISBN"><META NAME="DC.language" CONTENT="en-US"><META NAME="generator" CONTENT="Jade 1.1/O'Reilly DocBook 3.0 to HTML 4.0"></head> 5<BODY BGCOLOR="#FFFFFF" TEXT="#000000" link="#990000" vlink="#0000CC"> 6<table BORDER="0" CELLPADDING="0" CELLSPACING="0" width="90%"> 7<tr> 8<td width="25%" valign="TOP"> 9<img hspace=10 vspace=10 src="gifs/samba.s.gif" 10alt="Using Samba" align=left valign=top border=0> 11</td> 12<td height="105" valign="TOP"> 13<br> 14<H2>Using Samba</H2> 15<font size="-1"> 16Robert Eckstein, David Collier-Brown, Peter Kelly 17<br>1st Edition November 1999 18<br>1-56592-449-5, Order Number: 4495 19<br>416 pages, $34.95 20</font> 21<p> <a href="http://www.oreilly.com/catalog/samba/">Buy the hardcopy</a> 22<p><a href="index.html">Table of Contents</a> 23</td> 24</tr> 25</table> 26<hr size=1 noshade> 27<!--sample chapter begins --> 28 29<center> 30<DIV CLASS="htmlnav"> 31<TABLE WIDTH="515" BORDER="0" CELLSPACING="0" CELLPADDING="0"> 32<TR> 33<TD ALIGN="LEFT" VALIGN="TOP" WIDTH="172"> 34<A CLASS="sect1" HREF="ch04_07.html" TITLE="4.7 Virtual Servers"> 35<IMG SRC="gifs/txtpreva.gif" ALT="Previous: 4.7 Virtual Servers" BORDER="0"></a></td><TD ALIGN="CENTER" VALIGN="TOP" WIDTH="171"> 36<B> 37<FONT FACE="ARIEL,HELVETICA,HELV,SANSERIF" SIZE="-1"> 38<A CLASS="chapter" REL="up" HREF="ch04_01.html" TITLE="4. Disk Shares "> 39Chapter 4<br> 40Disk Shares </a></font></b></td><TD ALIGN="RIGHT" VALIGN="TOP" WIDTH="172"> 41<A CLASS="chapter" HREF="ch05_01.html" TITLE="5. Browsing and Advanced Disk Shares "> 42<IMG SRC="gifs/txtnexta.gif" ALT="Next: 5. Browsing and Advanced Disk Shares " BORDER="0"></a></td></tr></table> <hr noshade size=1></center> 43</div> 44<blockquote> 45<div> 46<H2 CLASS="sect1"> 47<A CLASS="title" NAME="ch04-29331"> 484.8 Logging Configuration Options</a></h2><P CLASS="para">Occasionally, we need to find out what Samba is up to. This is especially true when Samba is performing an unexpected action or is not performing at all. To find out this information, we need to check Samba's log files to see exactly why it did what it did.</p><P CLASS="para"> 49Samba log files can be as brief or verbose as you like. Here is an example of what a Samba log file looks like:</p><PRE CLASS="programlisting"> 50[1999/07/21 13:23:25, 3] smbd/service.c:close_cnum(514) 51 phoenix (192.168.220.101) closed connection to service IPC$ 52[1999/07/21 13:23:25, 3] smbd/connection.c:yield_connection(40) 53 Yielding connection to IPC$ 54[1999/07/21 13:23:25, 3] smbd/process.c:process_smb(615) 55 Transaction 923 of length 49 56[1999/07/21 13:23:25, 3] smbd/process.c:switch_message(448) 57 switch message SMBread (pid 467) 58[1999/07/21 13:23:25, 3] lib/doscalls.c:dos_ChDir(336) 59 dos_ChDir to /home/samba 60[1999/07/21 13:23:25, 3] smbd/reply.c:reply_read(2199) 61 read fnum=4207 num=2820 nread=2820 62[1999/07/21 13:23:25, 3] smbd/process.c:process_smb(615) 63 Transaction 924 of length 55 64[1999/07/21 13:23:25, 3] smbd/process.c:switch_message(448) 65 switch message SMBreadbraw (pid 467) 66[1999/07/21 13:23:25, 3] smbd/reply.c:reply_readbraw(2053) 67 readbraw fnum=4207 start=130820 max=1276 min=0 nread=1276 68[1999/07/21 13:23:25, 3] smbd/process.c:process_smb(615) 69 Transaction 925 of length 55 70[1999/07/21 13:23:25, 3] smbd/process.c:switch_message(448) 71 switch message SMBreadbraw (pid 467) </pre><P CLASS="para"> 72Many of these options are of use only to Samba programmers. However, we will go over the meaning of some of these entries in more detail in <a href="ch09_01.html"><b>Chapter 9, <CITE CLASS="chapter">Troubleshooting Samba</cite></b></a>.</p><P CLASS="para"> 73Samba contains six options that allow users to describe how and where logging information should be written. Each of these options are global options and cannot appear inside a share definition. Here is an up-to-date configuration file that covers each of the share and logging options that we've seen so far:</p><PRE CLASS="programlisting"> 74[global] 75 netbios name = HYDRA 76 server string = Samba %v on (%I) 77 workgroup = SIMPLE 78 79 # Networking configuration options 80 hosts allow = 192.168.220. 134.213.233. localhost 81 hosts deny = 192.168.220.102 82 interfaces = 192.168.220.100/255.255.255.0 \ 83 134.213.233.110/255.255.255.0 84 bind interfaces only = yes 85 86 # Debug logging information 87 log level = 2 88 log file = /var/log/samba.log.%m 89 max log size = 50 90 debug timestamp = yes 91 92[data] 93 path = /home/samba/data 94 browseable = yes 95 guest ok = yes 96 comment = Data Drive 97 volume = Sample-Data-Drive 98 writeable = yes 99 </pre><P CLASS="para"> 100 Here, we've added a custom log file that reports information up to debug level 2. This is a relatively light debugging level. The logging level ranges from 1 to 10, where level 1 provides only a small amount of information and level 10 provides a plethora of low-level information. Level 2 will provide us with useful debugging information without wasting disk space on our server. In practice, you should avoid using log levels greater than 3 unless you are programming Samba.</p><P CLASS="para"> 101This file is located in the <I CLASS="filename"> 102/var/log</i> directory thanks to the <CODE CLASS="literal"> 103log</code> <CODE CLASS="literal"> 104file</code> configuration option. However, we can use variable substitution to create log files specifically for individual users or clients, such as with the <CODE CLASS="literal"> 105%m</code> variable in the following line:</p><PRE CLASS="programlisting"> 106log file = /usr/local/logs/samba.log.%m</pre><P CLASS="para"> 107Isolating the log messages can be invaluable in tracking down a network error if you know the problem is coming from a specific machine or user.</p><P CLASS="para"> 108We've added another precaution to the log files: no one log file can exceed 50 kilobytes in size, as specified by the <CODE CLASS="literal"> 109max</code> <CODE CLASS="literal"> 110log</code> <CODE CLASS="literal"> 111size</code> option. If a log file exceeds this size, the contents are moved to a file with the same name but with the suffix <EM CLASS="emphasis"> 112.old</em> appended. If the <EM CLASS="emphasis"> 113.old</em> file already exists, it is overwritten and its contents are lost. The original file is cleared, waiting to receive new logging information. This prevents the hard drive from being overwhelmed with Samba log files during the life of our daemons.</p><P CLASS="para"> 114For convenience, we have decided to leave the debug timestamp in the logs with the <CODE CLASS="literal"> 115debug</code> <CODE CLASS="literal"> 116timestamp</code> option, which is the default behavior. This will place a timestamp next to each message in the logging file. If we were not interested in this information, we could specify <CODE CLASS="literal"> 117no</code> for this option instead.</p><DIV CLASS="sect2"> 118<H3 CLASS="sect2"> 119<A CLASS="title" NAME="ch04-97929"> 1204.8.1 Using syslog</a></h3><P CLASS="para"> 121If you wish to use the system logger (<I CLASS="filename">syslog</i>) in addition to or in place of the standard Samba logging file, Samba provides options for this as well. However, to use <I CLASS="filename"> 122syslog</i>, the first thing you will have to do is make sure that Samba was built with the <CODE CLASS="literal"> 123configure</code> <CODE CLASS="literal"> 124--with-syslog</code> option. See <a href="ch02_01.html"><b>Chapter 2</b></a> for more information on configuring and compiling Samba.</p><P CLASS="para"> 125Once that is done, you will need to configure your <I CLASS="filename"> 126/etc/syslog.conf</i> to accept logging information from Samba. If there is not already a <CODE CLASS="literal"> 127daemon.*</code> entry in the <CODE CLASS="replaceable"> 128<I> 129/etc/syslog.conf</i></code> file, add the following:</p><PRE CLASS="programlisting"> 130daemon.* /var/log/daemon.log</pre><P CLASS="para"> 131This specifies that any logging information from system daemons will be stored in the <I CLASS="filename"> 132/var/log/daemon.log</i> file. This is where the Samba information will be stored as well. From there, you can specify the following global option in your configuration file:</p><PRE CLASS="programlisting"> 133syslog = 2</pre><P CLASS="para"> 134This specifies that any logging messages with a level of 1 will be sent to both the <I CLASS="filename"> 135syslog</i> and the Samba logging files. (The mappings to <I CLASS="filename"> 136syslog</i> priorities are described in the upcoming section "syslog.") Let's assume that we set the regular <CODE CLASS="literal"> 137log</code> <CODE CLASS="literal"> 138level</code> option above to 4. Any logging messages with a level of 2, 3, or 4 will be sent to the Samba logging files, but not to the <I CLASS="filename"> 139syslog</i>. Only level 1 logging messages will be sent to both. If the <CODE CLASS="literal"> 140syslog</code> value exceeds the <CODE CLASS="literal"> 141log</code> <CODE CLASS="literal"> 142level</code> value, nothing will be written to the <I CLASS="filename"> 143syslog</i>.</p><P CLASS="para"> 144If you want to specify that messages be sent only to <I CLASS="filename"> 145syslog</i> - and not to the standard Samba logging files - you can place this option in the configuration file:</p><PRE CLASS="programlisting"> 146syslog only = yes</pre><P CLASS="para"> 147If this is the case, any logging information above the number specified in the <CODE CLASS="literal"> 148syslog</code> option will be discarded, just like the <CODE CLASS="literal"> 149log</code> <CODE CLASS="literal"> 150level</code> option.</p></div><DIV CLASS="sect2"> 151<H3 CLASS="sect2"> 152<A CLASS="title" NAME="ch04-pgfId-961771"> 1534.8.2 Logging Configuration Options</a></h3><P CLASS="para"> 154<A CLASS="xref" HREF="ch04_08.html#ch04-92838"> 155Table 4.7</a> lists each of the logging configuration options that Samba can use. </p><br> 156<TABLE CLASS="table" BORDER="1" CELLPADDING="3"> 157<CAPTION CLASS="table"> 158<A CLASS="title" NAME="ch04-92838"> 159Table 4.7: Global Configuration Options </a></caption><THEAD CLASS="thead"> 160<TR CLASS="row" VALIGN="TOP"> 161<TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 162<P CLASS="para"> 163Option</p></th><TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 164<P CLASS="para"> 165Parameters</p></th><TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 166<P CLASS="para"> 167Function</p></th><TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 168<P CLASS="para"> 169Default</p></th><TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 170<P CLASS="para"> 171Scope</p></th></tr></thead><TBODY CLASS="tbody"> 172<TR CLASS="row" VALIGN="TOP"> 173<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 174<P CLASS="para"> 175<CODE CLASS="literal"> 176log file</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 177<P CLASS="para"> 178string (fully-qualified filename)</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 179<P CLASS="para"> 180Sets the name and location of the log file that Samba is to use. Uses standard variables.</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 181<P CLASS="para"> 182Specified in Samba makefile</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 183<P CLASS="para"> 184Global</p></td></tr><TR CLASS="row" VALIGN="TOP"> 185<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 186<P CLASS="para"> 187<CODE CLASS="literal"> 188log level</code></p><P CLASS="para"> 189<CODE CLASS="literal"> 190(debug level)</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 191<P CLASS="para"> 192numerical (0-10)</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 193<P CLASS="para"> 194Sets the amount of log/debug messages that are sent to the log file. 0 is none, 3 is considerable.</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 195<P CLASS="para"> 196<CODE CLASS="literal"> 1971</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 198<P CLASS="para"> 199Global</p></td></tr><TR CLASS="row" VALIGN="TOP"> 200<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 201<P CLASS="para"> 202<CODE CLASS="literal"> 203max log size</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 204<P CLASS="para"> 205numerical (size in KB)</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 206<P CLASS="para"> 207Sets the maximum size of log file. After the log exceeds this size, the file will be renamed to <EM CLASS="emphasis"> 208.bak </em>and a new log file started.</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 209<P CLASS="para"> 210<CODE CLASS="literal"> 2115000</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 212<P CLASS="para"> 213Global</p></td></tr><TR CLASS="row" VALIGN="TOP"> 214<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 215<P CLASS="para"> 216<CODE CLASS="literal"> 217debug</code></p><P CLASS="para"> 218<CODE CLASS="literal"> 219timestamp (timestamp logs)</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 220<P CLASS="para"> 221boolean</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 222<P CLASS="para"> 223If no, doesn't timestamp logs, making them easier to read during heavy debugging.</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 224<P CLASS="para"> 225<CODE CLASS="literal"> 226yes</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 227<P CLASS="para"> 228Global</p></td></tr><TR CLASS="row" VALIGN="TOP"> 229<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 230<P CLASS="para"> 231<CODE CLASS="literal"> 232syslog</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 233<P CLASS="para"> 234numerical (0-10)</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 235<P CLASS="para"> 236Sets level of messages sent to <EM CLASS="emphasis"> 237syslog</em>. Those levels below <CODE CLASS="literal"> 238syslog level</code> will be sent to the system logger.</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 239<P CLASS="para"> 240<CODE CLASS="literal"> 2411</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 242<P CLASS="para"> 243Global</p></td></tr><TR CLASS="row" VALIGN="TOP"> 244<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 245<P CLASS="para"> 246<CODE CLASS="literal"> 247syslog only</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 248<P CLASS="para"> 249boolean</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 250<P CLASS="para"> 251If yes, uses <EM CLASS="emphasis"> 252syslog</em> entirely and sends no output to the standard Samba log files.</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 253<P CLASS="para"> 254<CODE CLASS="literal"> 255no</code></p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 256<P CLASS="para"> 257Global</p></td></tr></tbody></table><DIV CLASS="sect3"> 258<H4 CLASS="sect3"> 259<A CLASS="title" NAME="ch04-log-file-option"> 2604.8.2.1 log file</a></h4><P CLASS="para"> 261On our server, Samba outputs log information to text files in the <I CLASS="filename"> 262var</i> subdirectory of the Samba home directory, as set by the makefile during the build. The <CODE CLASS="literal"> 263log</code> <CODE CLASS="literal"> 264file</code> option can be used to reset the name of the log file to another location. For example, to reset the name and location of the Samba log file to <I CLASS="filename"> 265/usr/local/logs/samba.log</i>, you could use the following:</p><PRE CLASS="programlisting"> 266[global] 267 log file = /usr/local/logs/samba.log</pre><P CLASS="para"> 268You may use variable substitution to create log files specifically for individual users or clients.</p><P CLASS="para"> 269You can override the default log file location using the <CODE CLASS="literal"> 270-l</code> command-line switch when either daemon is started. However, this does not override the <CODE CLASS="literal"> 271log</code> <CODE CLASS="literal"> 272file</code> option. If you do specify this parameter, initial logging information will be sent to the file specified after <CODE CLASS="literal"> 273-l</code> (or the default specified in the Samba makefile) until the daemons have processed the <I CLASS="filename"> 274smb.conf</i> file and know to redirect it to a new log file.</p></div><DIV CLASS="sect3"> 275<H4 CLASS="sect3"> 276<A CLASS="title" NAME="ch04-pgfId-953284"> 2774.8.2.2 log level</a></h4><P CLASS="para"> 278The <CODE CLASS="literal"> 279log</code> <CODE CLASS="literal"> 280level</code> option sets the amount of data to be logged. Normally this is left at 0 or 1. However, if you have a specific problem you may want to set it at 3, which provides the most useful debugging information you would need to track down a problem. Levels above 3 provide information that's primarily for the developers to use for chasing internal bugs, and slows down the server considerably. Therefore, we recommend that you avoid setting this option to anything above 3. </p><PRE CLASS="programlisting"> 281[global] 282log file = /usr/local/logs/samba.log.%m 283log level = 3</pre></div><DIV CLASS="sect3"> 284<H4 CLASS="sect3"> 285<A CLASS="title" NAME="ch04-pgfId-960212"> 2864.8.2.3 max log size</a></h4><P CLASS="para"> 287The <CODE CLASS="literal"> 288max</code> <CODE CLASS="literal"> 289log</code> <CODE CLASS="literal"> 290size</code> option sets the maximum size, in kilobytes, of the debugging log file that Samba keeps. When the log file exceeds this size, the current log file is renamed to add an <EM CLASS="emphasis"> 291.old</em> extension (erasing any previous file with that name) and a new debugging log file is started with the original name. For example:</p><PRE CLASS="programlisting"> 292[global] 293log file = /usr/local/logs/samba.log.%m 294max log size = 1000</pre><P CLASS="para"> 295Here, if the size of any log file exceeds one megabyte in size, Samba renames the log file <EM CLASS="emphasis"> 296samba.log. </em><CODE CLASS="replaceable"> 297<I> 298machine-name</i></code><EM CLASS="emphasis"> 299.old</em> and a new log file is generated. If there was a file there previously with the <EM CLASS="emphasis"> 300.old</em> extension, Samba deletes it. We highly recommend setting this option in your configuration files because debug logging (even at lower levels) can covertly eat away at your available disk space. Using this option protects unwary administrators from suddenly discovering that most of their disk space has been swallowed up by a single Samba log file.</p></div><DIV CLASS="sect3"> 301<H4 CLASS="sect3"> 302<A CLASS="title" NAME="ch04-pgfId-953294"> 3034.8.2.4 debug timestamp or timestamp logs</a></h4><P CLASS="para"> 304If you happen to be debugging a network problem and you find that the date-stamp and timestamp information within the Samba log lines gets in the way, you can turn it off by giving either the <CODE CLASS="literal"> 305timestamp</code> <CODE CLASS="literal"> 306logs</code> or the <CODE CLASS="literal"> 307debug</code> <CODE CLASS="literal"> 308timestamp</code> option (they're synonymous) a value of <CODE CLASS="literal"> 309no</code>. For example, a regular Samba log file presents its output in the following form:</p><PRE CLASS="programlisting"> 31012/31/98 12:03:34 hydra (192.168.220.101) connect to server network as user davecb</pre><P CLASS="para"> 311With a <CODE CLASS="literal"> 312no</code> value for this option, the output would appear without the datestamp or the timestamp:</p><PRE CLASS="programlisting"> 313hydra (192.168.220.101) connect to server network as user davecb</pre></div><DIV CLASS="sect3"> 314<H4 CLASS="sect3"> 315<A CLASS="title" NAME="ch04-78696"> 3164.8.2.5 syslog</a></h4><P CLASS="para">The <CODE CLASS="literal"> 317syslog</code> option causes Samba log messages to be sent to the Unix system logger. The type of log information to be sent is specified as the parameter for this argument. Like the <CODE CLASS="literal"> 318log</code> <CODE CLASS="literal"> 319level</code> option, it can be a number from 0 to 10. Logging information with a level less than the number specified will be sent to the system logger. However, debug logs equal to or above the <CODE CLASS="literal"> 320syslog</code> level, but less than log level, will still be sent to the standard Samba log files. To get around this, use the <CODE CLASS="literal"> 321syslog</code> <CODE CLASS="literal"> 322only</code> option. For example:</p><PRE CLASS="programlisting"> 323[global] 324 log level = 3 325 syslog = 1</pre><P CLASS="para"> 326With this, all logging information with a level of 0 would be sent to the standard Samba logs and the system logger, while information with levels 1, 2, and 3 would be sent only to the standard Samba logs. Levels above 3 are not logged at all. Note that all messages sent to the system logger are mapped to a priority level that the <EM CLASS="emphasis"> 327syslog</em> process understands, as shown in <A CLASS="xref" HREF="ch04_08.html#ch04-80576"> 328Table 4.8</a>. The default level is 1. </p><br> 329<TABLE CLASS="table" BORDER="1" CELLPADDING="3"> 330<CAPTION CLASS="table"> 331<A CLASS="title" NAME="ch04-80576"> 332Table 4.8: Syslog Priority Conversion </a></caption><THEAD CLASS="thead"> 333<TR CLASS="row" VALIGN="TOP"> 334<TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 335<P CLASS="para"> 336Log Level</p></th><TH CLASS="entry" ALIGN="LEFT" ROWSPAN="1" COLSPAN="1"> 337<P CLASS="para"> 338Syslog Priority</p></th></tr></thead><TBODY CLASS="tbody"> 339<TR CLASS="row" VALIGN="TOP"> 340<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 341<P CLASS="para"> 3420</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 343<P CLASS="para"> 344<CODE CLASS="literal"> 345LOG_ERR</code></p></td></tr><TR CLASS="row" VALIGN="TOP"> 346<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 347<P CLASS="para"> 3481</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 349<P CLASS="para"> 350<CODE CLASS="literal"> 351LOG_WARNING</code></p></td></tr><TR CLASS="row" VALIGN="TOP"> 352<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 353<P CLASS="para"> 3542</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 355<P CLASS="para"> 356<CODE CLASS="literal"> 357LOG_NOTICE</code></p></td></tr><TR CLASS="row" VALIGN="TOP"> 358<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 359<P CLASS="para"> 3603</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 361<P CLASS="para"> 362<CODE CLASS="literal"> 363LOG_INFO</code></p></td></tr><TR CLASS="row" VALIGN="TOP"> 364<TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 365<P CLASS="para"> 3664 and above</p></td><TD CLASS="entry" ROWSPAN="1" COLSPAN="1"> 367<P CLASS="para"> 368<CODE CLASS="literal"> 369LOG_DEBUG</code></p></td></tr></tbody></table><P CLASS="para"> 370If you wish to use <EM CLASS="emphasis"> 371syslog</em>, you will have to run <CODE CLASS="literal"> 372configure</code> <CODE CLASS="literal"> 373--with-syslog</code> when compiling Samba, and you will need to configure your <I CLASS="filename"> 374/etc/syslog.conf</i> to suit. (See the section <A CLASS="xref" HREF="ch04_08.html#ch04-97929"> 375Section 4.8.1, Using syslog</a>, earlier in this chapter.)</p></div><DIV CLASS="sect3"> 376<H4 CLASS="sect3"> 377<A CLASS="title" NAME="ch04-pgfId-953338"> 3784.8.2.6 syslog only</a></h4><P CLASS="para"> 379The <CODE CLASS="literal"> 380syslog</code> <CODE CLASS="literal"> 381only</code> option tells Samba not to use the regular logging files - the system logger only. To enable this, specify the following option in the global ection of the Samba configuration file:</p><PRE CLASS="programlisting"> 382[global] 383 syslog only = yes </pre></div></div></div></blockquote> 384<div> 385<center> 386<hr noshade size=1><TABLE WIDTH="515" BORDER="0" CELLSPACING="0" CELLPADDING="0"> 387<TR> 388<TD ALIGN="LEFT" VALIGN="TOP" WIDTH="172"> 389<A CLASS="sect1" HREF="ch04_07.html" TITLE="4.7 Virtual Servers"> 390<IMG SRC="gifs/txtpreva.gif" ALT="Previous: 4.7 Virtual Servers" BORDER="0"></a></td><TD ALIGN="CENTER" VALIGN="TOP" WIDTH="171"> 391<A CLASS="book" HREF="index.html" TITLE=""> 392<IMG SRC="gifs/txthome.gif" ALT="" BORDER="0"></a></td><TD ALIGN="RIGHT" VALIGN="TOP" WIDTH="172"> 393<A CLASS="chapter" HREF="ch05_01.html" TITLE="5. Browsing and Advanced Disk Shares "> 394<IMG SRC="gifs/txtnexta.gif" ALT="Next: 5. Browsing and Advanced Disk Shares " BORDER="0"></a></td></tr><TR> 395<TD ALIGN="LEFT" VALIGN="TOP" WIDTH="172"> 3964.7 Virtual Servers</td><TD ALIGN="CENTER" VALIGN="TOP" WIDTH="171"> 397<A CLASS="index" HREF="inx.html" TITLE="Book Index"> 398<IMG SRC="gifs/index.gif" ALT="Book Index" BORDER="0"></a></td><TD ALIGN="RIGHT" VALIGN="TOP" WIDTH="172"> 3995. Browsing and Advanced Disk Shares </td></tr></table><hr noshade size=1></center> 400</div> 401 402<!-- End of sample chapter --> 403<CENTER> 404<FONT SIZE="1" FACE="Verdana, Arial, Helvetica"> 405<A HREF="http://www.oreilly.com/"> 406<B>O'Reilly Home</B></A> <B> | </B> 407<A HREF="http://www.oreilly.com/sales/bookstores"> 408<B>O'Reilly Bookstores</B></A> <B> | </B> 409<A HREF="http://www.oreilly.com/order_new/"> 410<B>How to Order</B></A> <B> | </B> 411<A HREF="http://www.oreilly.com/oreilly/contact.html"> 412<B>O'Reilly Contacts<BR></B></A> 413<A HREF="http://www.oreilly.com/international/"> 414<B>International</B></A> <B> | </B> 415<A HREF="http://www.oreilly.com/oreilly/about.html"> 416<B>About O'Reilly</B></A> <B> | </B> 417<A HREF="http://www.oreilly.com/affiliates.html"> 418<B>Affiliated Companies</B></A><p> 419<EM>© 1999, O'Reilly & Associates, Inc.</EM> 420</FONT> 421</CENTER> 422</BODY> 423</html> 424