Please read this before reporting a bug:
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
https://wiki.archlinux.org/title/Bug_reporting_guidelines
Do NOT report bugs when a package is just outdated, or it is in the AUR. Use the 'flag out of date' link on the package page, or the Mailing List.
REPEAT: Do NOT report bugs for outdated packages!
FS#57859 - [lsof] "lsof $file" wrongly reports char devices
Attached to Project:
Arch Linux
Opened by Peter Wu (Lekensteyn) - Friday, 16 March 2018, 10:34 GMT
Last edited by Doug Newgard (Scimmia) - Saturday, 22 September 2018, 14:04 GMT
Opened by Peter Wu (Lekensteyn) - Friday, 16 March 2018, 10:34 GMT
Last edited by Doug Newgard (Scimmia) - Saturday, 22 September 2018, 14:04 GMT
|
DetailsDescription:
Assume that nothing uses /etc/hostname, try "lsof /etc/hostname". In lsof 4.89-1, it would report no output. Since lsof 4.90-1, it reports a bunch (400+) unrelated entries: COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME bash 459 peter 0u CHR 136,9 0t0 12 /dev/pts/9 bash 459 peter 1u CHR 136,9 0t0 12 /dev/pts/9 ... kded5 709 peter 35u CHR 5,2 0t0 1114 /dev/ptmx kded5 709 peter 36u CHR 136,1 0t0 4 /dev/pts/1 kwin_x11 749 peter mem CHR 226,128 14367 /dev/dri/renderD128 This broke a script of me which greps the output of lsof to detect whether a file has users, making lsof rather unusable. Reverting to 4.89-1 in meantime. |
This task depends upon
Closed by Doug Newgard (Scimmia)
Saturday, 22 September 2018, 14:04 GMT
Reason for closing: Fixed
Additional comments about closing: lsof 4.90-2
Saturday, 22 September 2018, 14:04 GMT
Reason for closing: Fixed
Additional comments about closing: lsof 4.90-2
---
00DIST
Incorporated Linux pseudoterminal endpoint processing (+|-E)
provided by Masatake YAMATO <yamato@redhat.com> with access to
test systems provided by Peter Schiffer <pschiffe@redhat.com>.
---
Until this is fixed, consider running the following between "./Configure -n linux" and "make":
sed 's/ -DHASPTYEPT//' Makefile -i
(in addition, the feature had another bug which needs the attached patch)
I'll try to reach out the authors.
Edit:
One of the contributors maintain a port for Linux here:
https://github.com/masatake/lsof-linux
but it suffers from the same problem as described originally.
Also, in case you have missed it, this is visible in the changelog:
!!!NOTE!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
! !
! It is likely that this is the last lsof revision I !
! will issue, unless serious bugs are detected, Stay !
! tuned to lsof-l for information about future support !
! of lsof. !
! !
! I thank all the many contributors to lsof over the !
! many years (20+?) I have been distributing lsof !
! versions 1, 2, 3 and 4. !
! !
! Vic Abell <abe@purdue.edu> !
! !
!!!NOTE!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
https://github.com/masatake/lsof-linux/commit/f5d024877006deb5d0a500235068f8c4f928939e
Thanks again!
Upstream was reacted very quickly and were quite helpful, kudos to Vic and Masatake!
FYI, there are additional fixes in a pre-release (4.91A, see the ftp site and Masatake's Github repo), but I think that those fixes can wait until an official "4.91" release.