File: loggen.1

package info (click to toggle)
syslog-ng 3.8.1-10
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 47,320 kB
  • ctags: 43,937
  • sloc: ansic: 159,432; yacc: 25,059; sh: 13,574; makefile: 4,669; python: 3,468; java: 3,218; xml: 2,309; perl: 318; lex: 316; awk: 184
file content (377 lines) | stat: -rw-r--r-- 11,226 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
'\" t
.\"     Title: loggen
.\"    Author: [see the "Author" section]
.\" Generator: DocBook XSL Stylesheets v1.78.1 <http://docbook.sf.net/>
.\"      Date: 08/19/2016
.\"    Manual: The loggen manual page
.\"    Source: syslog-ng Open Source Edition 3.3
.\"  Language: English
.\"
.TH "LOGGEN" "1" "08/19/2016" "syslog\-ng Open Source Edition" "The loggen manual page"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el       .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
loggen \- Generate syslog messages at a specified rate
.SH "SYNOPSIS"
.HP \w'\fBloggen\fR\fBtarget\fR\ 'u
\fBloggen\fR [options]\fBtarget\fR [port]
.SH "DESCRIPTION"
.PP
NOTE: The loggen application is distributed with the syslog\-ng system logging application, and is usually part of the syslog\-ng package\&. The latest version of the syslog\-ng application is available at
\m[blue]\fBthe official syslog\-ng website\fR\m[]\&\s-2\u[1]\d\s+2\&.
.PP
This manual page is only an abstract; for the complete documentation of syslog\-ng, see
\m[blue]\fBThe syslog\-ng Administrator Guide\fR\m[]\&\s-2\u[2]\d\s+2\&.
.PP
The
\fBloggen\fR
application is tool to test and stress\-test your syslog server and the connection to the server\&. It can send syslog messages to the server at a specified rate, using a number of connection types and protocols, including TCP, UDP, and unix domain sockets\&. The messages can be generated automatically (repeating the
\fIPADD\fRstring over and over), or read from a file or the standard input\&.
.PP
When
\fBloggen\fR
finishes sending the messages, it displays the following statistics:
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
\fIaverage rate\fR: Average rate the messages were sent in messages/second\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
\fIcount\fR: The total number of messages sent\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
\fItime\fR: The time required to send the messages in seconds\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
\fIaverage message size\fR: The average size of the sent messages in bytes\&.
.RE
.sp
.RS 4
.ie n \{\
\h'-04'\(bu\h'+03'\c
.\}
.el \{\
.sp -1
.IP \(bu 2.3
.\}
\fIbandwidth\fR: The average bandwidth used for sending the messages in kilobytes/second\&.
.RE
.SH "OPTIONS"
.PP
\fB\-\-active\-connections <number\-of\-connections>\fR
.RS 4
Number of connections
\fBloggen\fR
will use to send messages to the destination\&. This option is usable only when using TCP or TLS connections to the destination\&. Default value: 1
.sp
The
\fBloggen\fR
utility waits until every connection is established before starting to to send messages\&. See also the
\fI\-\-idle\-connections\fR
option\&.
.RE
.PP
\fB\-\-csv\fR or \fB\-C\fR
.RS 4
Send the statistics of the sent messages to stdout as CSV\&. This can be used for plotting the message rate\&.
.RE
.PP
\fB\-\-dgram\fR or \fB\-D\fR
.RS 4
Use datagram socket (UDP or unix\-dgram) to send the messages to the target\&. Requires the
\fI\-\-inet\fR
option as well\&.
.RE
.PP
\fB\-\-dont\-parse\fR or \fB\-d\fR
.RS 4
Do not parse the lines read from the input files, send them as received\&.
.RE
.PP
\fB\-\-help\fR or \fB\-h\fR
.RS 4
Display a brief help message\&.
.RE
.PP
\fB\-\-idle\-connections <number\-of\-connections>\fR
.RS 4
Number of idle connections
\fBloggen\fR
will establish to the destination\&. Note that
\fBloggen\fR
will not send any messages on idle connections, but the connection is kept open using keep\-alive messages\&. This option is usable only when using TCP or TLS connections to the destination\&. See also the
\fI\-\-active\-connections\fR
option\&. Default value: 0
.RE
.PP
\fB\-\-inet\fR or \fB\-i\fR
.RS 4
Use the TCP (by default) or UDP (when used together with the
\fI\-\-dgram\fR
option) protocol to send the messages to the target\&.
.RE
.PP
\fB\-\-interval <seconds>\fR or \fB\-I <seconds>\fR
.RS 4
The number of seconds
\fBloggen\fR
will run\&. Default value: 10
.sp
Note that when the
\fI\-\-interval\fR
and
\fI\-\-number\fR
are used together,
\fBloggen\fR
will send messages until the period set in
\fI\-\-interval\fR
expires or the amount of messages set in
\fI\-\-number\fR
is reached, whichever happens first\&.
.RE
.PP
\fB\-\-permanent\fR or \fB\-T\fR
.RS 4
Send logs without time limit\&.
.RE
.PP
\fB\-\-ipv6\fR or \fB\-6\fR
.RS 4
Specify the destination using its IPv6 address\&. Note that the destination must have a real IPv6 address\&.
.RE
.PP
\fB\-\-loop\-reading\fR or \fB\-l\fR
.RS 4
Read the file specified in
\fI\-\-read\-file\fR
option in loop: loggen will start reading from the beginning of the file when it reaches the end of the file\&.
.RE
.PP
\fB\-\-number <number\-of\-messages>\fR or \fB\-n <number\-of\-messages>\fR
.RS 4
Number of messages to generate\&.
.sp
Note that when the
\fI\-\-interval\fR
and
\fI\-\-number\fR
are used together,
\fBloggen\fR
will send messages until the period set in
\fI\-\-interval\fR
expires or the amount of messages set in
\fI\-\-number\fR
is reached, whichever happens first\&.
.RE
.PP
\fB\-\-no\-framing\fR or \fB\-F\fR
.RS 4
Do not use the framing of the IETF\-syslog protocol style, even if the
\fIsyslog\-proto\fR
option is set\&.
.RE
.PP
\fB\-\-quiet\fR or \fB\-Q\fR
.RS 4
Output statistics only when the execution of
\fBloggen\fR
is finished\&. If not set, the statistics are displayed every second\&.
.RE
.PP
\fB\-\-rate <message/second>\fR or \fB\-r <message/second>\fR
.RS 4
The number of messages generated per second for every active connection\&. Default value: 1000
.RE
.PP
\fB\-\-read\-file <filename>\fR or \fB\-R <filename>\fR
.RS 4
Read the messages from a file and send them to the target\&. See also the
\fI\-\-skip\-tokens\fR
option\&.
.sp
Specify
\fI\-\fR
as the input file to read messages from the standard input (stdio)\&. Note that when reading messages from the standard input,
\fBloggen\fR
can only use a single thread\&. The
\fI\-R \-\fR
parameters must be placed at end of command, like:
\fBloggen 127\&.0\&.0\&.1 1061 \-\-read\-file \-\fR
.RE
        Send the given sdata (e\&.g\&. "[test name=\e"value\e"]) in case of syslog\-proto
        .PP
\fB\-\-sdata <data\-to\-send>\fR or \fB\-p <data\-to\-send>\fR
.RS 4
Send the argument of the
\fI\-\-sdata\fR
option as the SDATA part of IETF\-syslog (RFC5424 formatted) messages\&. Use it together with the
\fI\-\-syslog\-proto\fR
option\&. For example:
\fI\-\-sdata "[test name=\e"value\e"]\fR
.RE
.PP
\fB\-\-size <message\-size>\fR or \fB\-s <message\-size>\fR
.RS 4
The size of a syslog message in bytes\&. Default value: 256\&. Minimum value: 127 bytes, maximum value: 8192 bytes\&.
.RE
.PP
\fB\-\-skip\-tokens <number>\fR
.RS 4
Skip the specified number of space\-separated tokens (words) at the beginning of every line\&. For example, if the messages in the file look like
\fIfoo bar message\fR,
\fI\-\-skip\-tokens 2\fR
skips the
\fIfoo bar\fR
part of the line, and sends only the
\fImessage\fR
part\&. Works only when used together with the
\fI\-\-read\-file\fR
parameter\&. Default value: 3
.RE
.PP
\fB\-\-stream\fR or \fB\-S\fR
.RS 4
Use a stream socket (TCP or unix\-stream) to send the messages to the target\&.
.RE
.PP
\fB\-\-syslog\-proto\fR or \fB\-P\fR
.RS 4
Use the new IETF\-syslog message format as specified in RFC5424\&. By default, loggen uses the legacy BSD\-syslog message format (as described in RFC3164)\&. See also the
\fI\-\-no\-framing\fR
option\&.
.RE
.PP
\fB\-\-unix </path/to/socket>\fR or \fB\-x </path/to/socket>\fR
.RS 4
Use a UNIX domain socket to send the messages to the target\&.
.RE
.PP
\fB\-\-use\-ssl\fR or \fB\-U\fR
.RS 4
Use an SSL\-encrypted channel to send the messages to the target\&. Note that it is not possible to check the certificate of the target, or to perform mutual authentication\&.
.RE
.PP
\fB\-\-version\fR or \fB\-V\fR
.RS 4
Display version number of syslog\-ng\&.
.RE
.SH "EXAMPLES"
.PP
The following command generates 100 messages per second for ten minutes, and sends them to port 2010 of the localhost via TCP\&. Each message is 300 bytes long\&.
\fBloggen \-\-size 300 \-\-rate 100 \-\-interval 600 127\&.0\&.0\&.1 2010\fR.PP
The following command is similar to the one above, but uses the UDP protocol\&.
\fBloggen \-\-inet \-\-dgram \-\-size 300 \-\-rate 100 \-\-interval 600 127\&.0\&.0\&.1 2010\fR.PP
Send a single message on TCP6 to the
\fI::1\fR
IPv6 address, port
\fI1061\fR:
\fBloggen \-\-ipv6 \-\-number 1 ::1 1061\fR.PP
Send a single message on UDP6 to the
\fI::1\fR
IPv6 address, port
\fI1061\fR:
\fBloggen \-\-ipv6 \-\-dgram \-\-number 1 ::1 1061\fR.PP
Send a single message using a unix domain\-socket:
\fBloggen \-\-unix \-\-stream \-\-number 1 </path/to/socket>\fR.PP
Read messages from the standard input (stdio) and send them to the localhost:
\fBloggen 127\&.0\&.0\&.1 1061 \-\-read\-file \-\fR.SH "FILES"
.PP
/usr/local/bin/loggen
.SH "SEE ALSO"
.PP
\fBsyslog\-ng\&.conf\fR(5)
.PP
\m[blue]\fB\fBThe syslog\-ng Administrator Guide\fR\fR\m[]\&\s-2\u[2]\d\s+2
.PP
If you experience any problems or need help with loggen or syslog\-ng, visit the
\m[blue]\fBsyslog\-ng mailing list\fR\m[]\&\s-2\u[3]\d\s+2
.PP
\m[blue]\fB\fBThe syslog\-ng OSE 3\&.3 Administrator Guide\fR\fR\m[]\&\s-2\u[2]\d\s+2
.PP
If you experience any problems or need help with syslog\-ng, visit
\m[blue]\fBvisit the syslog\-ng wiki\fR\m[]\&\s-2\u[4]\d\s+2
or the
\m[blue]\fB\fBsyslog\-ng mailing list\fR\fR\m[]\&\s-2\u[3]\d\s+2\&.
.PP
For news and notifications about of syslog\-ng, visit the
\m[blue]\fB\fBsyslog\-ng Insider Blog\fR\fR\m[]\&\s-2\u[5]\d\s+2\&.
.SH "AUTHOR"
.PP
This manual page was written by the BalaBit Documentation Team <documentation@balabit\&.com>\&.
.SH "COPYRIGHT"
.SS ""
.PP
The authors grant permission to copy, distribute and/or modify this manual page under the terms of the GNU General Public License Version 2 or newer (GPL v2+)\&.
.SH "NOTES"
.IP " 1." 4
the official syslog-ng website
.RS 4
\%http://www.balabit.com/network-security/syslog-ng/
.RE
.IP " 2." 4
The syslog-ng Administrator Guide
.RS 4
\%http://www.balabit.com/support/documentation/
.RE
.IP " 3." 4
syslog-ng mailing list
.RS 4
\%https://lists.balabit.hu/mailman/listinfo/syslog-ng
.RE
.IP " 4." 4
visit the syslog-ng wiki
.RS 4
\%http://www.balabit.com/wiki/syslog-ng-faq
.RE
.IP " 5." 4
\fBsyslog-ng Insider Blog\fR
.RS 4
\%http://insider.blogs.balabit.com
.RE