Annotation of /trunk/logrotate/patches/logrotate-3.7.1-manpage-fixes.patch
Parent Directory | Revision Log
Revision 153 -
(hide annotations)
(download)
Tue May 8 20:52:56 2007 UTC (17 years, 4 months ago) by niro
File size: 15470 byte(s)
Tue May 8 20:52:56 2007 UTC (17 years, 4 months ago) by niro
File size: 15470 byte(s)
-import
1 | niro | 153 | diff -u -ruN logrotate-3.7.1.orig/logrotate.8 logrotate-3.7.1/logrotate.8 |
2 | --- logrotate-3.7.1.orig/logrotate.8 2003-08-07 07:13:14.000000000 -0400 | ||
3 | +++ logrotate-3.7.1/logrotate.8 2005-05-24 12:13:09.000000000 -0400 | ||
4 | @@ -3,7 +3,8 @@ | ||
5 | .SH NAME | ||
6 | logrotate \- rotates, compresses, and mails system logs | ||
7 | .SH SYNOPSIS | ||
8 | -\fBlogrotate\fR [-dv] [-f|--force] [-s|--state \fIfile\fR] \fIconfig_file\fR+ | ||
9 | +\fBlogrotate\fR [\fB\-dv\fR] [\fB\-f\fR|\fB\-\-force\fR] | ||
10 | +[\fB\-s\fR|\fB-\-state\ \fIstatefile\fR] \fIconfig_file\fR .. | ||
11 | .SH DESCRIPTION | ||
12 | \fBlogrotate\fR is designed to ease administration of systems that generate | ||
13 | large numbers of log files. It allows automatic rotation, compression, | ||
14 | @@ -11,16 +12,16 @@ | ||
15 | weekly, monthly, or when it grows too large. | ||
16 | .P | ||
17 | Normally, \fBlogrotate\fR is run as a daily cron job. It will not modify | ||
18 | -a log multiple times in one day unless the criterium for that log is | ||
19 | -based on the log's size and \fBlogrotate\fR is being run multiple times | ||
20 | -each day, or unless the \fB-f\fR or \fB-force\fR option is used. | ||
21 | +a log more than once in one day unless the criterion for that log is | ||
22 | +based on the log's size and \fBlogrotate\fR is being run more than once | ||
23 | +each day, or unless the \fB-f\fR or \fB-\-force\fR option is used. | ||
24 | .P | ||
25 | Any number of config files may be given on the command line. Later config | ||
26 | files may override the options given in earlier files, so the order | ||
27 | -in which the \fBlogrotate\fR config files are listed in is important. | ||
28 | +in which the \fBlogrotate\fR config files are listed is important. | ||
29 | Normally, a single config file which includes any other config files | ||
30 | which are needed should be used. See below for more information on how | ||
31 | -to use the \fIinclude\fR directive to accomplish this. If a directory | ||
32 | +to use the \fBinclude\fR directive to accomplish this. If a directory | ||
33 | is given on the command line, every file in that directory is used as | ||
34 | a config file. | ||
35 | .P | ||
36 | @@ -36,14 +37,15 @@ | ||
37 | be made to the logs or to the \fBlogrotate\fR state file. | ||
38 | |||
39 | .TP | ||
40 | -\fB-f, -\-force\fR | ||
41 | +\fB-f\fR, \fB-\-force\fR | ||
42 | Tells \fBlogrotate\fR to force the rotation, even if it doesn't think | ||
43 | this is necessary. Sometimes this is useful after adding new entries to | ||
44 | -\fBlogrotate\fR, or if old log files have been removed by hand, as the | ||
45 | -new files will be created, and logging will continue correctly. | ||
46 | +a \fBlogrotate\fR config file, or if old log files have been removed | ||
47 | +by hand, as the new files will be created, and logging will continue | ||
48 | +correctly. | ||
49 | |||
50 | .TP | ||
51 | -\fB-m, -\-mail <command>\fR | ||
52 | +\fB-m\R, \B-\-mail <command>\fR | ||
53 | Tells \fBlogrotate\fR which command to use when mailing logs. This | ||
54 | command should accept two arguments: 1) the subject of the message, and | ||
55 | 2) the recipient. The command must then read a message on standard input | ||
56 | @@ -51,22 +53,26 @@ | ||
57 | -s\fR. | ||
58 | |||
59 | .TP | ||
60 | -\fB-s, -\-state <statefile>\fR | ||
61 | +\fB-s\fR, \fB-\-state <statefile>\fR | ||
62 | Tells \fBlogrotate\fR to use an alternate state file. This is useful | ||
63 | -if logrotate is being run as a different user for various sets of | ||
64 | +if \fBlogrotate\fR is being run as a different user for various sets of | ||
65 | log files. The default state file is \fI/var/lib/logrotate/status\fR. | ||
66 | |||
67 | .TP | ||
68 | \fB-\-usage\fR | ||
69 | Prints a short usage message. | ||
70 | |||
71 | +.TP | ||
72 | +\fB-v\fR, \fB--verbose\fR | ||
73 | +Display messages during rotation. | ||
74 | + | ||
75 | .SH CONFIGURATION FILE | ||
76 | |||
77 | \fBlogrotate\fR reads everything about the log files it should be handling | ||
78 | from the series of configuration files specified on the command line. Each | ||
79 | configuration file can set global options (local definitions override | ||
80 | global ones, and later definitions override earlier ones) and specify | ||
81 | -a logfile to rotate. A simple configuration file looks like this: | ||
82 | +some logfiles to rotate. A simple configuration file looks like this: | ||
83 | |||
84 | .nf | ||
85 | .ta +3i | ||
86 | @@ -77,17 +83,17 @@ | ||
87 | rotate 5 | ||
88 | weekly | ||
89 | postrotate | ||
90 | - /sbin/killall -HUP syslogd | ||
91 | + /bin/killall -HUP syslogd | ||
92 | endscript | ||
93 | } | ||
94 | |||
95 | "/var/log/httpd/access.log" /var/log/httpd/error.log { | ||
96 | rotate 5 | ||
97 | mail www@my.org | ||
98 | - size=100k | ||
99 | + size 100k | ||
100 | sharedscripts | ||
101 | postrotate | ||
102 | - /sbin/killall -HUP httpd | ||
103 | + /bin/killall -HUP httpd | ||
104 | endscript | ||
105 | } | ||
106 | |||
107 | @@ -97,7 +103,7 @@ | ||
108 | olddir /var/log/news/old | ||
109 | missingok | ||
110 | postrotate | ||
111 | - kill -HUP `cat /var/run/inn.pid` | ||
112 | + kill -HUP `cat /var/run/inn.pid` | ||
113 | endscript | ||
114 | nocompress | ||
115 | } | ||
116 | @@ -107,23 +113,23 @@ | ||
117 | The first few lines set global options; in the example, logs are | ||
118 | compressed after they are rotated. Note that comments may appear | ||
119 | anywhere in the config file as long as the first non-whitespace | ||
120 | -character on the line is a #. | ||
121 | +character on the line is a \fB#\fR. | ||
122 | |||
123 | -The next section of the config files defined how to handle the log file | ||
124 | +The next section of the config file defines how to handle the log file | ||
125 | \fI/var/log/messages\fR. The log will go through five weekly rotations before | ||
126 | being removed. After the log file has been rotated (but before the old | ||
127 | version of the log has been compressed), the command | ||
128 | -\fI/sbin/killall -HUP syslogd\fR will be executed. | ||
129 | +\fI/bin/killall -HUP syslogd\fR will be executed. | ||
130 | |||
131 | The next section defines the parameters for both | ||
132 | \fI/var/log/httpd/access.log\fR and \fI/var/log/httpd/error.log\fR. | ||
133 | -They are rotated whenever is grows over 100k is size, and the old logs | ||
134 | +Each is rotated whenever it grows over 100k is size, and the old log | ||
135 | files are mailed (uncompressed) to www@my.org after going through 5 | ||
136 | rotations, rather then being removed. The \fBsharedscripts\fR means that | ||
137 | the \fBpostrotate\fR script will only be run once, not once for each | ||
138 | -log which is rotated. Note that the double quotes around the first filename | ||
139 | -at the beginning of this section allows logrotate to rotate logs with | ||
140 | -spaces in the name. Normal shell quoting rules apply, with ', ", and \\ | ||
141 | +log which is rotated. Note that log file names may be enclosed in | ||
142 | +quotes (and that quotes are required if the name contains spaces). | ||
143 | +Normal shell quoting rules apply, with \fB'\fR, \fB"\fR, and \fB\\\fR | ||
144 | characters supported. | ||
145 | |||
146 | The last section defines the parameters for all of the files in | ||
147 | @@ -135,29 +141,33 @@ | ||
148 | rotate all files, including previously rotated ones. A way around this | ||
149 | is to use the \fBolddir\fR directive or a more exact wildcard (such as *.log). | ||
150 | |||
151 | +If the directory \fI/var/log/news\fR does not exist, this will cause | ||
152 | +\fBlogrotate\fR to report an error. This error cannot be stopped with | ||
153 | +the \fBmissingok\fR directive. | ||
154 | + | ||
155 | Here is more information on the directives which may be included in | ||
156 | a \fBlogrotate\fR configuration file: | ||
157 | |||
158 | .TP | ||
159 | \fBcompress\fR | ||
160 | -Old versions of log files are compressed with \fBgzip\fR by default. See also | ||
161 | -\fBnocompress\fR. | ||
162 | +Old versions of log files are compressed with \fBgzip\fR(1) by default. | ||
163 | +See also \fBnocompress\fR. | ||
164 | |||
165 | .TP | ||
166 | \fBcompresscmd\fR | ||
167 | Specifies which command to use to compress log files. The default is | ||
168 | -\fBgzip\fR. See also \fBcompress\fR. | ||
169 | +\fBgzip\fR(1). See also \fBcompress\fR. | ||
170 | |||
171 | .TP | ||
172 | \fBuncompresscmd\fR | ||
173 | Specifies which command to use to uncompress log files. The default is | ||
174 | -\fBgunzip\fR. | ||
175 | +\fBgunzip\fR(1). | ||
176 | |||
177 | .TP | ||
178 | \fBcompressext\fR | ||
179 | Specifies which extension to use on compressed logfiles, if compression | ||
180 | -is enabled. The default follows that of the configured compression | ||
181 | -command. | ||
182 | +is enabled. The default follows that of the default compression | ||
183 | +command (.gz). | ||
184 | |||
185 | .TP | ||
186 | \fBcompressoptions\fR | ||
187 | @@ -174,9 +184,9 @@ | ||
188 | |||
189 | .TP | ||
190 | \fBcopytruncate\fR | ||
191 | -Truncate the original log file in place after creating a copy, | ||
192 | -instead of moving the old log file and optionally creating a new one, | ||
193 | -It can be used when some program can not be told to close its logfile | ||
194 | +Truncate the original log file to zero size in place after creating a copy, | ||
195 | +instead of moving the old log file and optionally creating a new one. | ||
196 | +It can be used when some program cannot be told to close its logfile | ||
197 | and thus might continue writing (appending) to the previous log file forever. | ||
198 | Note that there is a very small time slice between copying the file and | ||
199 | truncating it, so some logging data might be lost. | ||
200 | @@ -188,7 +198,7 @@ | ||
201 | Immediately after rotation (before the \fBpostrotate\fR script is run) | ||
202 | the log file is created (with the same name as the log file just rotated). | ||
203 | \fImode\fR specifies the mode for the log file in octal (the same | ||
204 | -as \fBchmod(2)\fR), \fIowner\fR specifies the user name who will own the | ||
205 | +as \fBchmod\fR)(2), \fIowner\fR specifies the user name who will own the | ||
206 | log file, and \fIgroup\fR specifies the group the log file will belong | ||
207 | to. Any of the log file attributes may be omitted, in which case those | ||
208 | attributes for the new file will use the same values as the original log | ||
209 | @@ -202,20 +212,20 @@ | ||
210 | .TP | ||
211 | \fBdelaycompress\fR | ||
212 | Postpone compression of the previous log file to the next rotation cycle. | ||
213 | -This has only effect when used in combination with \fBcompress\fR. | ||
214 | -It can be used when some program can not be told to close its logfile | ||
215 | +This only has effect when used in combination with \fBcompress\fR. | ||
216 | +It can be used when some program cannot be told to close its logfile | ||
217 | and thus might continue writing to the previous log file for some time. | ||
218 | |||
219 | .TP | ||
220 | \fBextension \fIext\fR | ||
221 | Log files are given the final extension \fIext\fR after rotation. If | ||
222 | -compression is used, the compression extension (normally \fB.gz\fR) | ||
223 | +compression is used, the compression extension (normally \fI.gz\fR) | ||
224 | appears after \fIext\fR. | ||
225 | |||
226 | .TP | ||
227 | \fBifempty\fR | ||
228 | -Rotate the log file even if it is empty, overiding the \fBnotifempty\fR | ||
229 | -option (ifempty is the default). | ||
230 | +Rotate the log file even if it is empty, overriding the \fBnotifempty\fR | ||
231 | +option (\fBifempty\fR is the default). | ||
232 | |||
233 | .TP | ||
234 | \fBinclude \fIfile_or_directory\fR | ||
235 | @@ -226,12 +236,12 @@ | ||
236 | which are ignored are files which are not regular files (such as | ||
237 | directories and named pipes) and files whose names end with one of | ||
238 | the taboo extensions, as specified by the \fBtabooext\fR directive. | ||
239 | -The \fBinclude\fR directive may not appear inside of a log file | ||
240 | +The \fBinclude\fR directive may not appear inside a log file | ||
241 | definition. | ||
242 | |||
243 | .TP | ||
244 | \fBmail \fIaddress\fR | ||
245 | -When a log is rotated out-of-existence, it is mailed to \fIaddress\fR. If | ||
246 | +When a log is rotated out of existence, it is mailed to \fIaddress\fR. If | ||
247 | no mail should be generated by a particular log, the \fBnomail\fR directive | ||
248 | may be used. | ||
249 | |||
250 | @@ -257,8 +267,7 @@ | ||
251 | |||
252 | .TP | ||
253 | \fBnocompress\fR | ||
254 | -Old versions of log files are not compressed with \fBgzip\fR. See also | ||
255 | -\fBcompress\fR. | ||
256 | +Old versions of log files are not compressed. See also \fBcompress\fR. | ||
257 | |||
258 | .TP | ||
259 | \fBnocopy\fR | ||
260 | @@ -281,7 +290,7 @@ | ||
261 | |||
262 | .TP | ||
263 | \fBnomail\fR | ||
264 | -Don't mail old log files to any address. | ||
265 | +Do not mail old log files to any address. | ||
266 | |||
267 | .TP | ||
268 | \fBnomissingok\fR | ||
269 | @@ -289,12 +298,12 @@ | ||
270 | |||
271 | .TP | ||
272 | \fBnoolddir\fR | ||
273 | -Logs are rotated in the same directory the log normally resides in (this | ||
274 | +Logs are rotated in the directory they normally reside in (this | ||
275 | overrides the \fBolddir\fR option). | ||
276 | |||
277 | .TP | ||
278 | \fBnosharedscripts\fR | ||
279 | -Run \fBprerotate\fR and \fBpostrotate\fR scripts for every script which | ||
280 | +Run \fBprerotate\fR and \fBpostrotate\fR scripts for every log which | ||
281 | is rotated (this is the default, and overrides the \fBsharedscripts\fR | ||
282 | option). | ||
283 | |||
284 | @@ -315,16 +324,15 @@ | ||
285 | \fBpostrotate\fR/\fBendscript\fR | ||
286 | The lines between \fBpostrotate\fR and \fBendscript\fR (both of which | ||
287 | must appear on lines by themselves) are executed after the log file is | ||
288 | -rotated. These directives may only appear inside of a log file definition. | ||
289 | -See \fBprerotate\fR as well. | ||
290 | +rotated. These directives may only appear inside a log file definition. | ||
291 | +See also \fBprerotate\fR. | ||
292 | |||
293 | .TP | ||
294 | \fBprerotate\fR/\fBendscript\fR | ||
295 | The lines between \fBprerotate\fR and \fBendscript\fR (both of which | ||
296 | must appear on lines by themselves) are executed before the log file is | ||
297 | rotated and only if the log will actually be rotated. These directives | ||
298 | -may only appear inside of a log file definition. See \fBpostrotate\fR | ||
299 | -as well. | ||
300 | +may only appear inside a log file definition. See also \fBpostrotate\fR. | ||
301 | |||
302 | .TP | ||
303 | \fBfirstaction\fR/\fBendscript\fR | ||
304 | @@ -340,30 +348,31 @@ | ||
305 | must appear on lines by themselves) are executed once after all log | ||
306 | files that match the wildcarded pattern are rotated, after postrotate script | ||
307 | is run and only if at least one log is rotated. These directives may only | ||
308 | -appear inside of a log file definition. See \fBlastaction\fR as well. | ||
309 | +appear inside a log file definition. See also \fBfirstaction\fR. | ||
310 | |||
311 | .TP | ||
312 | \fBrotate \fIcount\fR | ||
313 | -Log files are rotated <count> times before being removed or mailed to the | ||
314 | +Log files are rotated \fIcount\fR times before being removed or mailed to the | ||
315 | address specified in a \fBmail\fR directive. If \fIcount\fR is 0, old versions | ||
316 | are removed rather then rotated. | ||
317 | |||
318 | .TP | ||
319 | -\fBsize \fIsize\fR | ||
320 | +\fBsize \fIsize\fR[\fBG\fR|\fBM\fR|\fBk\fR] | ||
321 | Log files are rotated when they grow bigger then \fIsize\fR bytes. If | ||
322 | \fIsize\fR is followed by \fIM\fR, the size if assumed to be in megabytes. | ||
323 | -If the \fIk\fR is used, the size is in kilobytes. So \fBsize 100\fR, | ||
324 | -\fIsize 100k\fR, and \fIsize 100M\fR are all valid. | ||
325 | +If the \fIG\fR suffix is used, the size is in gigabytes. | ||
326 | +If the \fIk\fR suffix is used, the size is in kilobytes. So \fBsize 100\fR, | ||
327 | +\fIsize 100k\fR, \fIsize 100M\fR and \fIsize 1G\fR are all valid. | ||
328 | |||
329 | .TP | ||
330 | \fBsharedscripts\fR | ||
331 | -Normally, \fBprescript\fR and \fBpostscript\fR scripts are run for each | ||
332 | +Normally, \fBprerotate\fR and \fBpostrotate\fR scripts are run for each | ||
333 | log which is rotated, meaning that a single script may be run multiple | ||
334 | times for log file entries which match multiple files (such as the | ||
335 | -/var/log/news/* example). If \fBsharedscript\fR is specified, the scripts | ||
336 | +\fI/var/log/news/*\fR example). If \fBsharedscript\fR is specified, the scripts | ||
337 | are only run once, no matter how many logs match the wildcarded pattern. | ||
338 | However, if none of the logs in the pattern require rotating, the scripts | ||
339 | -will not be run at all. This option overrides the \fbnosharedscripts\fR | ||
340 | +will not be run at all. This option overrides the \fBnosharedscripts\fR | ||
341 | option. | ||
342 | |||
343 | .TP | ||
344 | @@ -377,18 +386,20 @@ | ||
345 | .TP | ||
346 | \fBtabooext\fR [+] \fIlist\fR | ||
347 | The current taboo extension list is changed (see the \fBinclude\fR directive | ||
348 | -for information on the taboo extensions). If a + precedes the list of | ||
349 | -extensions, the current taboo extension list is augmented, otherwise it | ||
350 | +for information on the taboo extensions). If a \fB+\fR precedes \fIlist\fR, | ||
351 | +the current taboo extension list is augmented by \fIlist\fR, otherwise it | ||
352 | is replaced. At startup, the taboo extension list | ||
353 | -contains .rpmorig, .rpmsave, ,v, .swp, .rpmnew, and ~. | ||
354 | +contains .rpmorig, .rpmsave, ,v, .swp, .rpmnew, and ~. Note that all hidden | ||
355 | +files (files starting with .) are ignored. | ||
356 | + | ||
357 | |||
358 | .TP | ||
359 | \fBweekly\fR | ||
360 | Log files are rotated if the current weekday is less then the weekday | ||
361 | of the last rotation or if more then a week has passed since the last | ||
362 | rotation. This is normally the same as rotating logs on the first day | ||
363 | -of the week, but it works better if \fIlogrotate\fR is not run every | ||
364 | -night. | ||
365 | +of the week, but if \fBlogrotate\fR is not being run every night a log | ||
366 | +rotation will happen at the first valid opportunity. | ||
367 | |||
368 | .SH FILES | ||
369 | .PD 0 | ||
370 | @@ -400,11 +411,15 @@ | ||
371 | Configuration options. | ||
372 | |||
373 | .SH SEE ALSO | ||
374 | -.IR gzip (1) | ||
375 | +.BR gzip (1) | ||
376 | |||
377 | .SH AUTHORS | ||
378 | .nf | ||
379 | Erik Troan <ewt@redhat.com> | ||
380 | .nf | ||
381 | Preston Brown <pbrown@redhat.com> | ||
382 | +.nf | ||
383 | +Corrections and changes for Debian by Paul Martin <pm@debian.org> | ||
384 | +.nf | ||
385 | +Corrections and changes for Gentoo by Daniel Gryniewicz <dang@gentoo.org> | ||
386 | .fi |