523926a07d
The release suite fails with no permissions to dump loopback, so let's run tests in an unshare, one per test, with and start as many syslogd as needed for each test -- also easier to debug since all are then fully stand-alone. Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
30 lines
605 B
Bash
Executable File
30 lines
605 B
Bash
Executable File
#!/bin/sh
|
|
# Test FWD between two syslogd, second binds 127.0.0.2:5555
|
|
. ./start.sh
|
|
|
|
MSG="fwd and allow"
|
|
|
|
cat <<EOF >${CONFD}/fwd.conf
|
|
kern.* /dev/null
|
|
ntp.* @127.0.0.2:${PORT2} ;RFC5424
|
|
EOF
|
|
|
|
cat <<EOF >${CONFD2}/50-default.conf
|
|
kern.* /dev/null
|
|
*.*;kern.none ${LOG2} ;RFC5424
|
|
EOF
|
|
|
|
../src/syslogd -a 127.0.0.2:* -b :${PORT2} -d -F -f ${CONF2} -p ${SOCK2} -m1 -C ${CACHE2} -P ${PID2} &
|
|
|
|
kill -HUP `cat ${PID}`
|
|
sleep 2
|
|
|
|
# Enable debug for second syslogd
|
|
kill -USR1 `cat ${PID2}`
|
|
|
|
../src/logger -t fwd -p ntp.notice -u ${SOCK} -m "NTP123" ${MSG}
|
|
sleep 3
|
|
grep "fwd - NTP123 - ${MSG}" ${LOG2}
|
|
|
|
. ./stop.sh
|