diff options
author | Ben Reser <breser@apache.org> | 2013-10-19 21:10:33 +0200 |
---|---|---|
committer | Ben Reser <breser@apache.org> | 2013-10-19 21:10:33 +0200 |
commit | 779bd67fa2f71cef6faa39885ff011e9d2291a53 (patch) | |
tree | 89314c4bbe26bfb22c6ca3021915576284625c3f /docs/manual/programs/rotatelogs.html.en | |
parent | Updates. (diff) | |
download | apache2-779bd67fa2f71cef6faa39885ff011e9d2291a53.tar.xz apache2-779bd67fa2f71cef6faa39885ff011e9d2291a53.zip |
Add an option to autocreate directories to rotatelogs.
* support/rotatelogs.c
(rotate_config): Remove const from szLogRoot since we'll be passing it to
apr_filepath_merge. Add create_path member.
(usage, dumpConfig): Update to reflect new -d option.
(doRotate): Add code that knows how to create the directories a log file
is going to go into.
(main): Add the -d option and canonicalize the incoming path with
apr_filepath_merge() so that the code in doRotate can work properly.
* docs/man/rotatelogs.8,
docs/manual/programs/rotatelogs.html.en: Update for -d option.
PR: 46669
Submitted by: Philippe Lantin <plantin cobaltgroup.com>
(which was actually a patch written by myself when I worked there)
Tweaked by: breser (ported to trunk and changed option from -p to -d)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1533810 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'docs/manual/programs/rotatelogs.html.en')
-rw-r--r-- | docs/manual/programs/rotatelogs.html.en | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/docs/manual/programs/rotatelogs.html.en b/docs/manual/programs/rotatelogs.html.en index 841ed1265d..23e163f391 100644 --- a/docs/manual/programs/rotatelogs.html.en +++ b/docs/manual/programs/rotatelogs.html.en @@ -44,6 +44,7 @@ [ -<strong>L</strong> <var>linkname</var> ] [ -<strong>p</strong> <var>program</var> ] [ -<strong>f</strong> ] + [ -<strong>d</strong> ] [ -<strong>v</strong> ] [ -<strong>e</strong> ] [ -<strong>c</strong> ] @@ -89,6 +90,11 @@ and when the first request is handled, meaning that the associated logfile does not "exist" until then, which causes problems from some automated logging tools)</dd> +<dt><code>-d</code></dt> +<dd>Creates the parent directories of the path that the log file will be +placed in if they do not already exist. This allows <code>strftime(3)</code> +formatting to be used in the path and not just the filename.</dd> + <dt><code>-t</code></dt> <dd>Causes the logfile to be truncated instead of rotated. This is useful when a log is processed in real time by a command like tail, @@ -277,4 +283,4 @@ if (typeof(prettyPrint) !== 'undefined') { prettyPrint(); } //--><!]]></script> -</body></html>
\ No newline at end of file +</body></html> |