Bug#878700: needrestart: False positive with AppImage

2017-11-02 Thread Thomas Liske

tags 878700 fixed-upstream - moreinfo
thanks


Hi Richard,

thanks for the detailed update. The problem was a bug in needrestart
due to the inspection of a non-existing mapping in /tmp (so you also got
that many "Use of uninitialized value" warnings).

The patch for the original github issue #58[1] is already part of the
upcomming needrestart 2.12 release. I was unable to reproduce the
problem with the most recent development version.

[1] https://github.com/liske/needrestart/issues/58


Thanks,
Thomas


Richard Hector  writes:

>>> It appears that AppImage packages mount their filesystem under /tmp/,
>>> and needrestart may find that there are open binaries or libraries there
>>> but be unable to find them. Sorry, I'm not sure how to word this ...
>> 
>> yes, it seems to do some FUSE mounting which might trigger problems
>> since they are (intentional) not available for root.
>> 
>> 
>>> The symptom I see is that I'm asked to restart xfce4-session every time
>>> I run needrestart, and it appears to be the NextCloud Appimage that's
>>> triggering it.
>> 
>> I never used AppImage before. I've just tried some random apps which
>> are working fine and did not produce any false positives.
>> 
>> 
>>> From sudo needrestart -v:
>>>
>>> [main] #8534 uses obsolete /tmp/.mount_Nextcl4R40GR/usr/bin/nextcloud
>>>
>>> I can show more of that output if needed (but would try for a minimal
>>> case)
>> 
>> the content of /proc/$PID/maps and `ls -lha /proc/$PID/{root,cwd}` might
>> help. Maybe you could provide steps howto reproduce the problem (where
>> to get the AppImage, which action are required so needrestart begins to
>> report the false positive).
>
> The AppImage I was using came from here:
>
> https://nextcloud.com/install/#install-clients
> or specifically
> https://download.nextcloud.com/desktop/releases/Linux/Nextcloud-2.3.2-x86_64.AppImage
>
> I'm not actually using it any more (it has breakage with libssl issues,
> and I discovered they do actually have debian packages) ... but luckily
> it's easy to reinstall :-)
>
> To see the problem: copy the file to (eg) ~/bin, and chmod +x, and run
> it. Then sudo needrestart (in a new window, because I didn't background it).
>
> richard@zircon:~/bin$ chmod +x Nextcloud-2.3.2-x86_64.AppImage
> richard@zircon:~/bin$ ./Nextcloud-2.3.2-x86_64.AppImage
> [no further output to terminal; shows up in panel. Doesn't work properly
> due to SSL problem, but that shouldn't be relevant - it did the same
> thing before when it was working]
>
> richard@zircon:~$ sudo needrestart -v 2> needrestart-v.txt
> Running kernel seems to be up-to-date.
> No services need to be restarted.
> No containers need to be restarted.
> User sessions running outdated binaries:
>  richard @ session #2053: bash[5479]
>
> needrestart-v.txt attached to avoid wrapping.
>
> PID:
> [main] #5509 uses obsolete /tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
>
>
> /proc/5509/maps attached to avoid wrapping.
>
> richard@zircon:~$ ls -lha /proc/5509/{root,cwd}
> lrwxrwxrwx 1 richard richard 0 Nov  2 12:15 /proc/5509/cwd ->
> /home/richard/bin
> lrwxrwxrwx 1 richard richard 0 Nov  2 12:15 /proc/5509/root -> /
>
> Note that this time I'm running it from bash rather than from
> xfce4-session, so that's what I'm asked to restart.
>
> HTH, and thanks
>
> Richard
> 0040-006a2000 r-xp  00:2e 313
> /tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
> 008a2000-008ab000 r--p 002a2000 00:2e 313
> /tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
> 008ab000-008af000 rw-p 002ab000 00:2e 313
> /tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
> 01bb5000-01fb6000 rw-p  00:00 0  
> [heap]
> 7fc0f800-7fc0f8021000 rw-p  00:00 0 
> 7fc0f8021000-7fc0fc00 ---p  00:00 0 
> 7fc0ff0d2000-7fc0ff0d3000 ---p  00:00 0 
> 7fc0ff0d3000-7fc0ff8d3000 rw-p  00:00 0 
> 7fc0ff8d3000-7fc0ff8e6000 r-xp  09:00 1047530
> /lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
> 7fc0ff8e6000-7fc0ffae5000 ---p 00013000 09:00 1047530
> /lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
> 7fc0ffae5000-7fc0ffae6000 r--p 00012000 09:00 1047530
> /lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
> 7fc0ffae6000-7fc0ffae7000 rw-p 00013000 09:00 1047530
> /lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
> 7fc0ffae7000-7fc0ffaee000 r-xp  09:00 930879 
> /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
> 7fc0ffaee000-7fc0ffcee000 ---p 7000 09:00 930879 
> /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
> 7fc0ffcee000-7fc0ffcef000 r--p 7000 09:00 930879 
> /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
> 7fc0ffcef000-7fc0ffcf rw-p 8000 09:00 930879 
> /usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
> 7fc0ffcf-7fc0ffdf7000 r-xp  

Bug#878700: needrestart: False positive with AppImage

2017-11-01 Thread Richard Hector
On 02/11/17 07:46, Thomas Liske wrote:
> tags 878700 upstream moreinfo
> thanks
> 
> Hi Richard,
> 
> 
> Richard Hector  writes:
>> It appears that AppImage packages mount their filesystem under /tmp/,
>> and needrestart may find that there are open binaries or libraries there
>> but be unable to find them. Sorry, I'm not sure how to word this ...
> 
> yes, it seems to do some FUSE mounting which might trigger problems
> since they are (intentional) not available for root.
> 
> 
>> The symptom I see is that I'm asked to restart xfce4-session every time
>> I run needrestart, and it appears to be the NextCloud Appimage that's
>> triggering it.
> 
> I never used AppImage before. I've just tried some random apps which
> are working fine and did not produce any false positives.
> 
> 
>> From sudo needrestart -v:
>>
>> [main] #8534 uses obsolete /tmp/.mount_Nextcl4R40GR/usr/bin/nextcloud
>>
>> I can show more of that output if needed (but would try for a minimal
>> case)
> 
> the content of /proc/$PID/maps and `ls -lha /proc/$PID/{root,cwd}` might
> help. Maybe you could provide steps howto reproduce the problem (where
> to get the AppImage, which action are required so needrestart begins to
> report the false positive).

The AppImage I was using came from here:

https://nextcloud.com/install/#install-clients
or specifically
https://download.nextcloud.com/desktop/releases/Linux/Nextcloud-2.3.2-x86_64.AppImage

I'm not actually using it any more (it has breakage with libssl issues,
and I discovered they do actually have debian packages) ... but luckily
it's easy to reinstall :-)

To see the problem: copy the file to (eg) ~/bin, and chmod +x, and run
it. Then sudo needrestart (in a new window, because I didn't background it).

richard@zircon:~/bin$ chmod +x Nextcloud-2.3.2-x86_64.AppImage
richard@zircon:~/bin$ ./Nextcloud-2.3.2-x86_64.AppImage
[no further output to terminal; shows up in panel. Doesn't work properly
due to SSL problem, but that shouldn't be relevant - it did the same
thing before when it was working]

richard@zircon:~$ sudo needrestart -v 2> needrestart-v.txt
Running kernel seems to be up-to-date.
No services need to be restarted.
No containers need to be restarted.
User sessions running outdated binaries:
 richard @ session #2053: bash[5479]

needrestart-v.txt attached to avoid wrapping.

PID:
[main] #5509 uses obsolete /tmp/.mount_NextclC5qDvr/usr/bin/nextcloud


/proc/5509/maps attached to avoid wrapping.

richard@zircon:~$ ls -lha /proc/5509/{root,cwd}
lrwxrwxrwx 1 richard richard 0 Nov  2 12:15 /proc/5509/cwd ->
/home/richard/bin
lrwxrwxrwx 1 richard richard 0 Nov  2 12:15 /proc/5509/root -> /

Note that this time I'm running it from bash rather than from
xfce4-session, so that's what I'm asked to restart.

HTH, and thanks

Richard
0040-006a2000 r-xp  00:2e 313
/tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
008a2000-008ab000 r--p 002a2000 00:2e 313
/tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
008ab000-008af000 rw-p 002ab000 00:2e 313
/tmp/.mount_NextclC5qDvr/usr/bin/nextcloud
01bb5000-01fb6000 rw-p  00:00 0  [heap]
7fc0f800-7fc0f8021000 rw-p  00:00 0 
7fc0f8021000-7fc0fc00 ---p  00:00 0 
7fc0ff0d2000-7fc0ff0d3000 ---p  00:00 0 
7fc0ff0d3000-7fc0ff8d3000 rw-p  00:00 0 
7fc0ff8d3000-7fc0ff8e6000 r-xp  09:00 1047530
/lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
7fc0ff8e6000-7fc0ffae5000 ---p 00013000 09:00 1047530
/lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
7fc0ffae5000-7fc0ffae6000 r--p 00012000 09:00 1047530
/lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
7fc0ffae6000-7fc0ffae7000 rw-p 00013000 09:00 1047530
/lib/x86_64-linux-gnu/libgpg-error.so.0.21.0
7fc0ffae7000-7fc0ffaee000 r-xp  09:00 930879 
/usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
7fc0ffaee000-7fc0ffcee000 ---p 7000 09:00 930879 
/usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
7fc0ffcee000-7fc0ffcef000 r--p 7000 09:00 930879 
/usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
7fc0ffcef000-7fc0ffcf rw-p 8000 09:00 930879 
/usr/lib/x86_64-linux-gnu/libffi.so.6.0.4
7fc0ffcf-7fc0ffdf7000 r-xp  09:00 1047538
/lib/x86_64-linux-gnu/libgcrypt.so.20.1.6
7fc0ffdf7000-7fc07000 ---p 00107000 09:00 1047538
/lib/x86_64-linux-gnu/libgcrypt.so.20.1.6
7fc07000-7fc09000 r--p 00107000 09:00 1047538
/lib/x86_64-linux-gnu/libgcrypt.so.20.1.6
7fc09000-7fc1 rw-p 00109000 09:00 1047538
/lib/x86_64-linux-gnu/libgcrypt.so.20.1.6
7fc1-7fc100021000 rw-p  00:00 0 
7fc100021000-7fc10400 ---p  00:00 0 
7fc10400-7fc104021000 rw-p  00:00 0 

Bug#878700: needrestart: False positive with AppImage

2017-11-01 Thread Thomas Liske
tags 878700 upstream moreinfo
thanks

Hi Richard,


Richard Hector  writes:
> It appears that AppImage packages mount their filesystem under /tmp/,
> and needrestart may find that there are open binaries or libraries there
> but be unable to find them. Sorry, I'm not sure how to word this ...

yes, it seems to do some FUSE mounting which might trigger problems
since they are (intentional) not available for root.


> The symptom I see is that I'm asked to restart xfce4-session every time
> I run needrestart, and it appears to be the NextCloud Appimage that's
> triggering it.

I never used AppImage before. I've just tried some random apps which
are working fine and did not produce any false positives.


> From sudo needrestart -v:
>
> [main] #8534 uses obsolete /tmp/.mount_Nextcl4R40GR/usr/bin/nextcloud
>
> I can show more of that output if needed (but would try for a minimal
> case)

the content of /proc/$PID/maps and `ls -lha /proc/$PID/{root,cwd}` might
help. Maybe you could provide steps howto reproduce the problem (where
to get the AppImage, which action are required so needrestart begins to
report the false positive).


HTH,
Thomas


> -- Package-specific info:
> needrestart output:
> Your outdated processes:
> AppRun[8534]
>
> checkrestart output:
>
>
> -- System Information:
> Debian Release: 9.1
>   APT prefers stable-updates
>   APT policy: (500, 'stable-updates'), (500, 'stable')
> Architecture: amd64 (x86_64)
> Foreign Architectures: i386
>
> Kernel: Linux 4.9.0-3-amd64 (SMP w/4 CPU cores)
> Locale: LANG=en_NZ.utf8, LC_CTYPE=en_NZ.utf8 (charmap=UTF-8), 
> LANGUAGE=en_NZ:en (charmap=UTF-8)
> Shell: /bin/sh linked to /bin/dash
> Init: systemd (via /run/systemd/system)
>
> Versions of packages needrestart depends on:
> ii  dpkg   1.18.24
> ii  gettext-base   0.19.8.1-2
> ii  libintl-perl   1.26-2
> ii  libmodule-find-perl0.13-1
> ii  libmodule-scandeps-perl1.23-1
> ii  libproc-processtable-perl  0.53-2
> ii  libsort-naturally-perl 1.03-1
> ii  libterm-readkey-perl   2.37-1
> ii  perl   5.24.1-3+deb9u2
> ii  xz-utils   5.2.2-1.2+b1
>
> Versions of packages needrestart recommends:
> ii  libpam-systemd  232-25+deb9u1
>
> Versions of packages needrestart suggests:
> ii  libnotify-bin  0.7.7-2
>
> -- no debconf information
>

-- 

::  WWW:https://fiasko-nw.net/~thomas/  ::
   :::  Jabber:   xmpp:tho...@jabber.fiasko-nw.net  :::
::  flickr: https://www.flickr.com/photos/laugufe/  ::



Bug#878700: needrestart: False positive with AppImage

2017-10-15 Thread Richard Hector
Package: needrestart
Version: 2.11-3
Severity: normal

Dear Maintainer,

It appears that AppImage packages mount their filesystem under /tmp/,
and needrestart may find that there are open binaries or libraries there
but be unable to find them. Sorry, I'm not sure how to word this ...

The symptom I see is that I'm asked to restart xfce4-session every time
I run needrestart, and it appears to be the NextCloud Appimage that's
triggering it.

>From sudo needrestart -v:

[main] #8534 uses obsolete /tmp/.mount_Nextcl4R40GR/usr/bin/nextcloud

I can show more of that output if needed (but would try for a minimal
case)

-- Package-specific info:
needrestart output:
Your outdated processes:
AppRun[8534]

checkrestart output:


-- System Information:
Debian Release: 9.1
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.9.0-3-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_NZ.utf8, LC_CTYPE=en_NZ.utf8 (charmap=UTF-8), LANGUAGE=en_NZ:en 
(charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages needrestart depends on:
ii  dpkg   1.18.24
ii  gettext-base   0.19.8.1-2
ii  libintl-perl   1.26-2
ii  libmodule-find-perl0.13-1
ii  libmodule-scandeps-perl1.23-1
ii  libproc-processtable-perl  0.53-2
ii  libsort-naturally-perl 1.03-1
ii  libterm-readkey-perl   2.37-1
ii  perl   5.24.1-3+deb9u2
ii  xz-utils   5.2.2-1.2+b1

Versions of packages needrestart recommends:
ii  libpam-systemd  232-25+deb9u1

Versions of packages needrestart suggests:
ii  libnotify-bin  0.7.7-2

-- no debconf information