Bug 601878

Summary: clvmd -R segfaults when clvmd is not running
Product: Red Hat Enterprise Linux 6 Reporter: Nate Straz <nstraz>
Component: lvm2Assignee: LVM and device-mapper development team <lvm-team>
Status: CLOSED DUPLICATE QA Contact: Corey Marthaler <cmarthal>
Severity: medium Docs Contact:
Priority: low    
Version: 6.0CC: agk, dwysocha, heinzm, jbrassow, joe.thornber, mbroz, prockai
Target Milestone: rc   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-06-09 04:09:36 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Nate Straz 2010-06-08 19:47:50 UTC
Description of problem:
[root@morph-01 ~]# ps -C clvmd
  PID TTY          TIME CMD
[root@morph-01 ~]# clvmd -R
connect() failed on local socket: Connection refused
Segmentation fault (core dumped)
[root@morph-01 ~]# gdb /usr/sbin/clvmd core
Core was generated by `clvmd -R'.
Program terminated with signal 11, Segmentation fault.
#0  0x00183c65 in __libc_free (mem=0x1d16ab) at malloc.c:3724
3724      ar_ptr = arena_for_chunk(p);
(gdb) bt
#0  0x00183c65 in __libc_free (mem=0x1d16ab) at malloc.c:3724
#1  0x08059aaa in _cluster_free_request (response=0x1d16ab, num=0)
    at refresh_clvmd.c:287
#2  0x0805a5fd in refresh_clvmd (all_nodes=1) at refresh_clvmd.c:322
#3  0x0805675c in main (argc=2, argv=0xbfe52f94) at clvmd.c:319
(gdb)


Version-Release number of selected component (if applicable):
lvm2-cluster-2.02.66-2.el6.i686

How reproducible:
Easily

Steps to Reproduce:
1. service clvmd stop
2. clvmd -R
3.
  
Actual results:
core dump

Expected results:
Print error about clvmd not running and return non-zero.

Additional info:

Comment 2 RHEL Program Management 2010-06-08 20:13:19 UTC
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.

Comment 3 Milan Broz 2010-06-09 04:09:36 UTC

*** This bug has been marked as a duplicate of bug 574595 ***