[Aptitude-devel] Bug#826783: libapt-pkg5.0: aptitude aborts due to a fd leak
Manuel A. Fernandez Montecelo
manuel.montezelo at gmail.com
Sun Jun 12 14:10:36 UTC 2016
Control: tags -1 + moreinfo
Hi Jiri,
2016-06-09 02:42 Jiri Palecek:
>
>Then I looked at the file descriptors that were open:
>[...]
>aptitude 2856 root 0u CHR 136,2 0t0 5 /dev/pts/2
>aptitude 2856 root 1u CHR 136,2 0t0 5 /dev/pts/2
>aptitude 2856 root 2u CHR 136,2 0t0 5 /dev/pts/2
>aptitude 2856 root 3uW REG 8,6 0 2474525 /var/lib/dpkg/lock
>aptitude 2856 root 4r REG 8,6 4413957 2475249 /var/lib/dpkg/status
>aptitude 2856 root 5r REG 8,6 48049 2064548 /var/lib/apt/lists/_home_jirka_public%5fhtml_ltp_dists_sid_main_binary-i386_Packages
>aptitude 2856 root 6r REG 8,6 22244 2064707 /var/lib/apt/lists/emacs.naquadah.org_unstable_Packages
>aptitude 2856 root 7r REG 8,6 7692 2065017 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 8r REG 8,6 9603 2065060 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 9r REG 8,6 4606 2065265 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 10r REG 8,6 6224 2065213 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_contrib_binary-i386_Packages.lz4
>aptitude 2856 root 11r REG 8,6 371262 2065168 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_main_i18n_Translation-en.lz4
>aptitude 2856 root 12r REG 8,6 755795 2065166 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_main_binary-i386_Packages.lz4
>aptitude 2856 root 13r REG 8,6 134176 2065093 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 14r REG 8,6 127605 2064999 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 15r REG 8,6 81846 2065091 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 16r REG 8,6 93960 2065094 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_contrib_binary-i386_Packages.lz4
>aptitude 2856 root 17r REG 8,6 9964496 2065162 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_main_i18n_Translation-en.lz4
>aptitude 2856 root 18r REG 8,6 967240 2065167 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_main_i18n_Translation-cs.lz4
>aptitude 2856 root 19r REG 8,6 15028352 2065059 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_main_binary-i386_Packages.lz4
>aptitude 2856 root 20r REG 8,6 126208 2065195 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 21r REG 8,6 139261 2065124 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 22r REG 8,6 74845 2064698 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 23r REG 8,6 99424 2065072 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_contrib_binary-i386_Packages.lz4
>aptitude 2856 root 24r REG 8,6 9510768 2065084 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_main_i18n_Translation-en.lz4
>aptitude 2856 root 25r REG 8,6 931870 2065147 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_main_i18n_Translation-cs.lz4
>aptitude 2856 root 26r REG 8,6 16558917 2065078 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_main_binary-i386_Packages.lz4
>aptitude 2856 root 27r REG 8,6 9750 2065281 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_experimental_main_binary-i386_Packages.lz4
>aptitude 2856 root 28r REG 8,6 8969 2065243 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_unstable_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 29r REG 8,6 337438 2065144 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_unstable_main_binary-i386_Packages.lz4
>aptitude 2856 root 30r REG 8,6 9351 2065222 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_stable_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 31r REG 8,6 319256 2065136 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_stable_main_binary-i386_Packages.lz4
>aptitude 2856 root 32r REG 8,6 9346 2065218 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 33r REG 8,6 338152 2065080 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_main_binary-i386_Packages.lz4
>aptitude 2856 root 34uW REG 0,20 0 38732 /run/lock/aptitude
>aptitude 2856 root 35r REG 8,6 4413957 2475249 /var/lib/dpkg/status
>aptitude 2856 root 36r REG 8,6 48049 2064548 /var/lib/apt/lists/_home_jirka_public%5fhtml_ltp_dists_sid_main_binary-i386_Packages
>aptitude 2856 root 37r REG 8,6 22244 2064707 /var/lib/apt/lists/emacs.naquadah.org_unstable_Packages
>aptitude 2856 root 38r REG 8,6 7692 2065017 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 39r REG 8,6 9603 2065060 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 40r REG 8,6 4606 2065265 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 41r REG 8,6 6224 2065213 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_contrib_binary-i386_Packages.lz4
>aptitude 2856 root 42r REG 8,6 371262 2065168 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_main_i18n_Translation-en.lz4
>aptitude 2856 root 43r REG 8,6 755795 2065166 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_main_binary-i386_Packages.lz4
>aptitude 2856 root 44r REG 8,6 134176 2065093 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 45r REG 8,6 127605 2064999 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 46r REG 8,6 81846 2065091 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 47r REG 8,6 93960 2065094 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_contrib_binary-i386_Packages.lz4
>aptitude 2856 root 48r REG 8,6 9964496 2065162 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_main_i18n_Translation-en.lz4
>aptitude 2856 root 49r REG 8,6 967240 2065167 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_main_i18n_Translation-cs.lz4
>aptitude 2856 root 50r REG 8,6 15028352 2065059 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_unstable_main_binary-i386_Packages.lz4
>aptitude 2856 root 51r REG 8,6 126208 2065195 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 52r REG 8,6 139261 2065124 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 53r REG 8,6 74845 2064698 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 54r REG 8,6 99424 2065072 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_contrib_binary-i386_Packages.lz4
>aptitude 2856 root 55r REG 8,6 9510768 2065084 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_main_i18n_Translation-en.lz4
>aptitude 2856 root 56r REG 8,6 931870 2065147 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_main_i18n_Translation-cs.lz4
>aptitude 2856 root 57r REG 8,6 16558917 2065078 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_testing_main_binary-i386_Packages.lz4
>aptitude 2856 root 58r REG 8,6 9750 2065281 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_experimental_main_binary-i386_Packages.lz4
>aptitude 2856 root 59r REG 8,6 8969 2065243 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_unstable_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 60r REG 8,6 337438 2065144 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_unstable_main_binary-i386_Packages.lz4
>aptitude 2856 root 61r REG 8,6 9351 2065222 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_stable_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 62r REG 8,6 319256 2065136 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_stable_main_binary-i386_Packages.lz4
>aptitude 2856 root 63r REG 8,6 9346 2065218 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 64r REG 8,6 338152 2065080 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_main_binary-i386_Packages.lz4
>aptitude 2856 root 65r REG 8,6 262053 2065073 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_main_source_Sources.lz4
>aptitude 2856 root 66r REG 8,6 262053 2065073 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_main_source_Sources.lz4
>aptitude 2856 root 67r REG 8,6 6575 2065169 /var/lib/apt/lists/debian-mirrors.sdinet.de_deb-multimedia_dists_testing_non-free_source_Sources.lz4
>aptitude 2856 root 68r REG 8,6 7692 2065017 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_non-free_i18n_Translation-en.lz4
>aptitude 2856 root 69r REG 8,6 9603 2065060 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_non-free_binary-i386_Packages.lz4
>aptitude 2856 root 70r REG 8,6 4606 2065265 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_contrib_i18n_Translation-en.lz4
>aptitude 2856 root 71r REG 8,6 6224 2065213 /var/lib/apt/lists/ftp.cz.debian.org_debian_dists_experimental_contrib_binary-i386_Packages.lz4
>... and so on
Did you actually see more file descriptors here, at the point where you
cut the text?
With apt 1.2.13 installed, fixing LZ4 and other leaks, I can see 2
"copies" of the file descriptors as above (probably because aptitude
creates threads for the UI, downloads, etc), but no matter what I do, I
cannot see more than 2 "copies" of the descriptors.
Depending on the operation (package lists updates, package downloads,
installations), I see a few more, including pipes, but not many more
than that. So that means, far below 1083 -- something like 30.
If they were indeed leaks, I can see how having a long-running session
of aptitude and updating available packages many times, could have
caused this. Were you using aptitude in that way?
However, I downgraded apt packages to 1.2.12 (before the fix for LZ4
leaks), set the options to keep indices compressed etc., repeated the
operations described above, and similar results -- only 20~30 file
descriptors.
So I am a bit out of clues.
Cheers.
--
Manuel A. Fernandez Montecelo <manuel.montezelo at gmail.com>
More information about the Aptitude-devel
mailing list