Bug 1505103
| Summary: | rsyslog omrelp rebindinterval crash | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | Jarno Huuskonen <jarno.huuskonen> | ||||
| Component: | rsyslog | Assignee: | Jiří Vymazal <jvymazal> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Stefan Dordevic <sdordevi> | ||||
| Severity: | unspecified | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 7.4 | CC: | dkopecek, jarno.huuskonen, jvymazal, ksrot, qe-baseos-security, sdordevi | ||||
| Target Milestone: | rc | Keywords: | Patch, Triaged | ||||
| Target Release: | --- | ||||||
| Hardware: | x86_64 | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | rsyslog-8.24.0-14.el7 | Doc Type: | If docs needed, set a value | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2018-04-10 15:26:37 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
Here is the patch from upstream: https://github.com/rgerhards/rsyslog/commit/cc09e7a6e893157a4d7a173c78f4b0a0496e8fbd.patch Is it reproducible without TLS? (In reply to Radovan Sroka from comment #3) > Is it reproducible without TLS? Yes. (Commented out tls from client / server rsyslog.conf and confirmed with tcpdump that messages are sent in plaintext). rsyslogd crashes: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffeb3fd700 (LWP 29455)] 0x00007ffff44c70a4 in relpCltHintBurstEnd (pThis=0x7fffd0002250) at relpclt.c:371 371 relpTcpHintBurstEnd(pThis->pSess->pTcp); (gdb) bt #0 0x00007ffff44c70a4 in relpCltHintBurstEnd (pThis=0x7fffd0002250) at relpclt.c:371 #1 0x00007ffff46cebeb in endTransaction (pWrkrData=0x7fffd0002220) at omrelp.c:518 #2 0x0000555555599226 in actionTryCommit (pWti=0x555555849180, pThis=0x555555838820) at ../action.c:1237 #3 actionCommit (pThis=pThis@entry=0x555555838820, pWti=pWti@entry=0x555555849180) at ../action.c:1323 #4 0x000055555559a388 in processBatchMain (pVoid=0x555555838820, pBatch=0x5555558491b0, pWti=0x555555849180) at ../action.c:1433 #5 0x000055555558eb8f in ConsumerReg (pThis=0x555555838c50, pWti=0x555555849180) at queue.c:2005 #6 0x000055555558b66e in wtiWorker (pThis=pThis@entry=0x555555849180) at wti.c:365 #7 0x000055555558a7dd in wtpWorker (arg=0x555555849180) at wtp.c:410 #8 0x00007ffff79b0e25 in start_thread () from /lib64/libpthread.so.0 #9 0x00007ffff6aa934d in clone () from /lib64/libc.so.6 (gdb) p pThis $1 = (relpClt_t *) 0x7fffd0002250 (gdb) p pThis->pSess $2 = (relpSess_t *) 0x0 Still not able to reproduce this issue. Can you minimize this reproducer? And provide exact steps? This is still pretty complex config. > 2. restart rsyslogd: systemctl restart rsyslogd > 3. Use iptables to drop OUTPUT to rsyslog remote server (iptables -I OUTPUT 1 -p tcp -d ser.er.ip.address -j DROP Does this server really exist? Is it possible to reproduce it on localhost? > and wait rsyslog to crash What does that mean? Created attachment 1345944 [details]
proposed patch
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:0856 |
Description of problem: rsyslog (rsyslog-8.24.0-12.el7.x86_64 / rsyslog-relp-8.24.0-12.el7.x86_64) crashes if omrelp forwarding action has RebindInterval. Version-Release number of selected component (if applicable): rsyslog-8.24.0-12.el7.x86_64 / rsyslog-relp-8.24.0-12.el7.x86_64 How reproducible: Always Steps to Reproduce: 1.Set up omrelp forwarding I used: *.debug action( type="omrelp" timeout="60" conn.timeout="10" template="RSYSLOG_ForwardFormat" target="peername.example.org" port="2514" tls="on" RebindInterval="512" tls.cacert="/etc/pki/rsyslog/ca.pem" tls.mycert="/etc/pki/rsyslog/client.crt" tls.myprivkey="/etc/pki/rsyslog/client.key" tls.authmode="name" tls.permittedpeer=["peername.example.org"] queue.filename="fwd1" queue.maxdiskspace="512m" queue.maxfilesize="32m" queue.syncqueuefiles="on" # fsync queue queue.saveonshutdown="on" queue.type="LinkedList" queue.timeoutenqueue="0" queue.highwatermark="102400" queue.lowwatermark="16384" queue.timeoutshutdown="8000" action.resumeretrycount="-1" action.resumeinterval="15" action.reportSuspension="on" action.reportSuspensionContinuation="on" ) 2. restart rsyslogd: systemctl restart rsyslogd 3. Use iptables to drop OUTPUT to rsyslog remote server (iptables -I OUTPUT 1 -p tcp -d ser.er.ip.address -j DROP and wait rsyslog to crash Actual results: Running rsyslogd -n in gdb gives this: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffdbfff700 (LWP 11296)] 0x00007ffff44c70a4 in relpCltHintBurstEnd (pThis=0x7fffd4003f60) at relpclt.c:371 371 relpTcpHintBurstEnd(pThis->pSess->pTcp); (gdb) bt #0 0x00007ffff44c70a4 in relpCltHintBurstEnd (pThis=0x7fffd4002250) at relpclt.c:371 #1 0x00007ffff46cebeb in endTransaction (pWrkrData=0x7fffd4002220) at omrelp.c:518 #2 0x0000555555599226 in actionTryCommit (pWti=0x555555849240, pThis=0x555555838a20) at ../action.c:1237 #3 actionCommit (pThis=pThis@entry=0x555555838a20, pWti=pWti@entry=0x555555849240) at ../action.c:1323 #4 0x000055555559a388 in processBatchMain (pVoid=0x555555838a20, pBatch=0x555555849270, pWti=0x555555849240) at ../action.c:1433 #5 0x000055555558eb8f in ConsumerReg (pThis=0x555555838ee0, pWti=0x555555849240) at queue.c:2005 #6 0x000055555558b66e in wtiWorker (pThis=pThis@entry=0x555555849240) at wti.c:365 #7 0x000055555558a7dd in wtpWorker (arg=0x555555849240) at wtp.c:410 #8 0x00007ffff79b0e25 in start_thread () from /lib64/libpthread.so.0 #9 0x00007ffff6aa934d in clone () from /lib64/libc.so.6 (gdb) p pThis $1 = (relpClt_t *) 0x7fffd4002250 (gdb) p pThis->pSess $2 = (relpSess_t *) 0x0 Expected results: Rsyslog not crashing. Additional info: This seems to be fixed in upstream rsyslog: https://github.com/rsyslog/rsyslog/commit/3d1007ab701ec6e18c30d0db1f20bdd2a10b2930