[linux-lvm] [lvm2cmd] Heap destruction by lvm2_exit()?
Hubert Kario
hubert at kario.pl
Wed Aug 1 16:17:03 UTC 2012
On Wednesday 01 of August 2012 13:24:13 Alasdair G Kergon wrote:
> Your test program works for me:
>
> $ valgrind ./a.out
> ==14092== Memcheck, a memory error detector
> ==14092== Copyright (C) 2002-2009, and GNU GPL'd, by Julian Seward et al.
> ==14092== Using Valgrind-3.5.0 and LibVEX; rerun with -h for copyright
> info ==14092== Command: ./a.out
> ==14092==
> Some text to output
> Variable before: "Other text"
> Variable after: "Other text"
> ==14092==
> ==14092== HEAP SUMMARY:
> ==14092== in use at exit: 0 bytes in 0 blocks
> ==14092== total heap usage: 161 allocs, 161 frees, 10,620,400 bytes allocated
> ==14092==
> ==14092== All heap blocks were freed -- no leaks are possible
> ==14092==
> ==14092== For counts of detected and suppressed errors, rerun with: -v
> ==14092== ERROR SUMMARY: 0 errors from 0 contexts (suppressed: 6 from 6)
You've got 6 supressions, while I've got 3. Could be that errors I see are
hidden from You.
Try running with
valgrind -v ./a.out
I've re-worked the application to work with only one lvm2 handle and it's
been stable for the past 17h while with multiple lvm2_exit()'s called it would crash
after 2-3minutes...
> What version of lvm2 are you using?
lvm2 2.02.96-2
gcc-multilib 4.7.1-1
valgrind 3.7.0-2
> Retest with upstream source?
> What lvm configure options are you using?
It is vanilla upstream source, Archlinux package doesn't use any
distro-specific patches, it's compiled with
./configure --prefix=/ --sbindir=/sbin --sysconfdir=/etc --localstatedir=/var --datarootdir=/usr/share \
--includedir=/usr/include --with-usrlibdir=/usr/lib --libdir=/usr/lib --with-udev-prefix=/usr \
--with-systemdsystemunitdir=/usr/lib/systemd/system --enable-pkgconfig --enable-readline \
--enable-dmeventd --enable-cmdlib --enable-applib --enable-udev_sync --enable-udev_rules \
--with-default-locking-dir=/run/lock/lvm
make
Regards,
--
Hubert Kario
hubert at kario.pl kario at wit.edu.pl https://hubert.kario.pl
PGP: 30D7 71F5 2F6F B157 872C D811 A1D0 6BC9 8956 DCFE
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://listman.redhat.com/archives/linux-lvm/attachments/20120801/4f51e465/attachment.sig>
More information about the linux-lvm
mailing list