diff options
author | Rainer Gerhards <rgerhards@adiscon.com> | 2011-06-14 15:09:41 +0200 |
---|---|---|
committer | Rainer Gerhards <rgerhards@adiscon.com> | 2011-06-14 15:09:41 +0200 |
commit | fee33477845949c2f03000044b2dbc31382b48f1 (patch) | |
tree | d8ed2472205504b72273b088486f01d42d4c98de /tests | |
parent | 7f0c927623b6425fee2c39b2d5207d7c36e32acd (diff) | |
parent | 28af40670e9dc1a85a24dfcbb093ddc1171e151f (diff) | |
download | rsyslog-fee33477845949c2f03000044b2dbc31382b48f1.tar.gz rsyslog-fee33477845949c2f03000044b2dbc31382b48f1.tar.bz2 rsyslog-fee33477845949c2f03000044b2dbc31382b48f1.zip |
Merge branch 'v5-stable' into beta
Conflicts:
ChangeLog
runtime/nsd_gtls.c
tcpsrv.c
tests/Makefile.am
Diffstat (limited to 'tests')
-rw-r--r-- | tests/Makefile.am | 3 | ||||
-rwxr-xr-x | tests/manytcp-too-few-tls.sh | 15 | ||||
-rw-r--r-- | tests/testsuites/manytcp-too-few-tls.conf | 22 |
3 files changed, 40 insertions, 0 deletions
diff --git a/tests/Makefile.am b/tests/Makefile.am index 6272c0dd..b3422297 100644 --- a/tests/Makefile.am +++ b/tests/Makefile.am @@ -104,6 +104,9 @@ TESTS += \ sndrcv_tls_anon.sh \ sndrcv_tls_anon_rebind.sh \ imtcp-tls-basic.sh +if HAVE_VALGRIND +TESTS += manytcp-too-few-tls.sh +endif endif if ENABLE_OMUXSOCK diff --git a/tests/manytcp-too-few-tls.sh b/tests/manytcp-too-few-tls.sh new file mode 100755 index 00000000..899a87dc --- /dev/null +++ b/tests/manytcp-too-few-tls.sh @@ -0,0 +1,15 @@ +# test many concurrent tcp connections +echo \[manytcp-too-few-tls.sh\]: test concurrent tcp connections +source $srcdir/diag.sh init +source $srcdir/diag.sh startup-vg manytcp-too-few-tls.conf +echo wait for DH param generation -- NOT needed in v6! +sleep 15 +# the config file specifies exactly 1100 connections +source $srcdir/diag.sh tcpflood -c1000 -m40000 +# the sleep below is needed to prevent too-early termination of the tcp listener +sleep 1 +source $srcdir/diag.sh shutdown-when-empty # shut down rsyslogd when done processing messages +source $srcdir/diag.sh wait-shutdown-vg # we need to wait until rsyslogd is finished! +source $srcdir/diag.sh check-exit-vg +source $srcdir/diag.sh seq-check 0 39999 +source $srcdir/diag.sh exit diff --git a/tests/testsuites/manytcp-too-few-tls.conf b/tests/testsuites/manytcp-too-few-tls.conf new file mode 100644 index 00000000..5269e73b --- /dev/null +++ b/tests/testsuites/manytcp-too-few-tls.conf @@ -0,0 +1,22 @@ +# Test for tcp "flood" testing +# rgerhards, 2009-04-08 +$IncludeConfig diag-common.conf + +$ModLoad ../plugins/imtcp/.libs/imtcp +$MainMsgQueueTimeoutShutdown 10000 +$MaxOpenFiles 200 +$InputTCPMaxSessions 1100 +# certificates +$DefaultNetstreamDriverCAFile testsuites/x.509/ca.pem +$DefaultNetstreamDriverCertFile testsuites/x.509/client-cert.pem +$DefaultNetstreamDriverKeyFile testsuites/x.509/client-key.pem + +$DefaultNetstreamDriver gtls # use gtls netstream driver + +$InputTCPServerStreamDriverMode 1 +$InputTCPServerStreamDriverAuthMode anon +$InputTCPServerRun 13514 + +$template outfmt,"%msg:F,58:2%\n" +$template dynfile,"rsyslog.out.log" # trick to use relative path names! +:msg, contains, "msgnum:" ?dynfile;outfmt |