Skip to content

Commit f04e81c

Browse files
committed
logging: add 'By Config File' section for log path configuration
Signed-off-by: Shizuo Fujita <fujita@clear-code.com>
1 parent f0eb09a commit f04e81c

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

deployment/logging.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,12 +148,28 @@ end
148148

149149
## Output to Log File
150150

151+
### By Command Line Option
152+
151153
By default, Fluentd outputs to the standard output. Use `-o` command line option to specify the file instead:
152154

153155
```text
154156
$ fluentd -o /path/to/log_file
155157
```
156158

159+
### By Config File
160+
161+
You can also configure the log file path using the `<log>` directive under `<system>`:
162+
163+
```text
164+
<system>
165+
<log>
166+
path /path/to/log_file
167+
</log>
168+
</system>
169+
170+
$ fluentd -o /path/to/log_file
171+
```
172+
157173
### Log Rotation Setting
158174

159175
By default, Fluentd does not rotate log files. You can configure this behavior via system-config after v1.13.0.

0 commit comments

Comments
 (0)