mirror of
https://github.com/rsyslog/rsyslog.git
synced 2025-12-16 13:20:41 +01:00
this parameter was added, but it had no effect as it was not passed down to the driver layer. This has been fixed. That also now enables us to use dynamically-assigned port, which are very useful for further testbench stabilization. Quite some false positives occurred because the pre-selected port was already in use again when rsyslog started.
21 lines
628 B
Bash
Executable File
21 lines
628 B
Bash
Executable File
#!/bin/bash
|
|
# addd 2016-05-13 by RGerhards, released under ASL 2.0
|
|
|
|
. ${srcdir:=.}/diag.sh init
|
|
generate_conf
|
|
add_conf '
|
|
module(load="../plugins/imtcp/.libs/imtcp")
|
|
input(type="imtcp" port="0" listenPortFileName="'$RSYSLOG_DYNNAME'.tcpflood_port")
|
|
|
|
template(name="outfmt" type="string" string="%msg:F,58:2%\n")
|
|
:msg, contains, "msgnum:" action(type="omfile" template="outfmt"
|
|
file=`echo $RSYSLOG_OUT_LOG`)
|
|
'
|
|
startup
|
|
assign_tcpflood_port $RSYSLOG_DYNNAME.tcpflood_port
|
|
tcpflood -p'$TCPFLOOD_PORT' -m10000
|
|
shutdown_when_empty # shut down rsyslogd when done processing messages
|
|
wait_shutdown
|
|
seq_check 0 9999
|
|
exit_test
|