RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 738484 - clvmd hangs/crash if invalid local request sent
Summary: clvmd hangs/crash if invalid local request sent
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: lvm2
Version: 6.1
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Milan Broz
QA Contact: Corey Marthaler
URL:
Whiteboard:
Depends On:
Blocks: 756082
TreeView+ depends on / blocked
 
Reported: 2011-09-14 23:20 UTC by Roman
Modified: 2013-03-01 04:10 UTC (History)
10 users (show)

Fixed In Version: lvm2-2.02.95-1.el6
Doc Type: Bug Fix
Doc Text:
Previously, if clvmd received invalid request through its socket (for example an incomplete header sent), clvmd process could crash or stay in infinite loop. Additional checks were added so such invalid packet now causes proper error reply to client and clvmd no longer crashes.
Clone Of:
Environment:
Last Closed: 2012-06-20 14:59:53 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
clvmd patch (1.60 KB, patch)
2011-09-14 23:21 UTC, Roman
no flags Details | Diff


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0962 0 normal SHIPPED_LIVE lvm2 bug fix and enhancement update 2012-06-19 21:12:11 UTC

Description Roman 2011-09-14 23:20:47 UTC
Description of problem:
clvmd hangs or crash if invalid request sent via /var/run/lvm/clvmd.sock

Version-Release number of selected component (if applicable):
lvm2-cluster-2.02.83-3.el6.x86_64

How reproducible:
always

Steps to Reproduce:
1. start clvmd
2. run perl -e 'print "\xff"x32' | socat STDIN UNIX-CONNECT:/var/run/lvm/clvmd.sock
  
Actual results:
clvmd crash or hangs and eat 100% of CPU

Expected results:
no hang or crash occurs

Additional info:
invalid request may send lvm in case of memory pressure or similar problem.
attached patch solved problem for me.

Comment 1 Roman 2011-09-14 23:21:57 UTC
Created attachment 523277 [details]
clvmd patch

Comment 3 Milan Broz 2011-09-15 11:32:41 UTC
Yes, this seem to be reasonable fix, thanks.

Comment 4 Milan Broz 2011-09-16 14:41:29 UTC
Slightly modified patch committed upstream, thanks.

Comment 10 Milan Broz 2012-04-24 18:18:45 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
Previously, if clvmd received invalid request through its socket (for example an incomplete header sent), clvmd process could crash or stay in infinite loop.
Additional checks were added so such invalid packet now causes proper error reply to client and clvmd no longer crashes.

Comment 11 Corey Marthaler 2012-04-26 21:52:47 UTC
Marking verified (SanityOnly).

Comment 13 errata-xmlrpc 2012-06-20 14:59:53 UTC
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.

http://rhn.redhat.com/errata/RHBA-2012-0962.html


Note You need to log in before you can comment on or make changes to this bug.