On Tue, 2011-06-28 at 12:01 -0700, Joe Zeff wrote:
> On 06/28/2011 09:22 AM, Patrick O'Callaghan wrote:
> > After updating, I always run needs-restarting to see what running
> > processes are affected. I'm surprised more people don't seem to know
> > about this program.
>
> I do daily updates via yumex. Long ago I learned that the included
> Update Manager was very good at finding updates but would always insist
> that I wasn't on-line when it came to doing the update. I'd never heard
> of needs-restarting before, so Thanx! BTW, having run it today, I
> gather that no output means that you're OK?
Of course. In Unix or Linux the old adage applies: no news is good news.
poc
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-28-2011, 07:29 PM
Joe Zeff
gnu linux update question
On 06/28/2011 09:41 AM, Patrick O'Callaghan wrote:
> If I had to pick out a single feature to demonstrate the superiority of
> the Unix style of system, this would be it.
De gustabus and all that jazz. I prefer to explain that Linux file
systems never (well, almost never) need defragging because that's
something J. Random User can understand.
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-28-2011, 09:38 PM
Patrick O'Callaghan
gnu linux update question
On Tue, 2011-06-28 at 12:29 -0700, Joe Zeff wrote:
> On 06/28/2011 09:41 AM, Patrick O'Callaghan wrote:
> > If I had to pick out a single feature to demonstrate the superiority of
> > the Unix style of system, this would be it.
>
> De gustabus and all that jazz. I prefer to explain that Linux file
> systems never (well, almost never) need defragging because that's
> something J. Random User can understand.
Sure, but that's an implementation detail. The file reference idea is a
basic part of the system's "principles of operation" (and the reason for
the existence of inodes) which at some point the user would do well to
be aware of. Call it an aesthetic thing.
poc
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 12:17 AM
Daniel J Walsh
gnu linux update question
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 06/28/2011 01:49 PM, Genes MailLists wrote:
> On 06/28/2011 12:22 PM, Patrick O'Callaghan wrote:
>
>>
>> After updating, I always run needs-restarting to see what running
>> processes are affected. I'm surprised more people don't seem to know
>> about this program.
>>
>
>
> Does this work as regular user for you? For me - selinux makes it crash.
run ausearch -m avc -ts recent
And see if it generates any output.
SELinux error messages are written to /var/log/audit/audit.log
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org/
iEYEARECAAYFAk4KbzUACgkQrlYvE4MpobPF/wCg4fT4OQ49n3TvIA0AQ9K4gOxV
H8wAoJNzZq1VNqKfJIDCyPkv7ilcT2MX
=iXty
-----END PGP SIGNATURE-----
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 01:37 AM
Genes MailLists
gnu linux update question
On 06/28/2011 08:17 PM, Daniel J Walsh wrote:
>> Does this work as regular user for you? For me - selinux makes it crash.
> run ausearch -m avc -ts recent
>
> And see if it generates any output.
>
> SELinux error messages are written to /var/log/audit/audit.log
>
>
>
Thanks Dan - Nope no selinux logs on this one best I can tell. If I
run as user I get:
$ needs-restarting
Traceback (most recent call last):
File "/usr/bin/needs-restarting", line 137, in <module>
sys.exit(main(sys.argv))
File "/usr/bin/needs-restarting", line 117, in main
for fn in get_open_files(pid):
File "/usr/bin/needs-restarting", line 84, in get_open_files
for line in maps.readlines():
IOError: [Errno 13] Permission denied
Its odd - line 117 in needs-restarting is this fragment:
for pid in return_running_pids(uid=myuid):
try:
pid_start = os.stat('/proc/' + pid)[stat.ST_CTIME]
except OSError, e:
continue
found_match = False
for fn in get_open_files(pid):
Works fine as root.
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 02:13 AM
James McKenzie
gnu linux update question
On 6/28/11 6:37 PM, Genes MailLists wrote:
> On 06/28/2011 08:17 PM, Daniel J Walsh wrote:
>>> Does this work as regular user for you? For me - selinux makes it crash.
>> run ausearch -m avc -ts recent
>>
>> And see if it generates any output.
>>
>> SELinux error messages are written to /var/log/audit/audit.log
>>
>>
>>
> Thanks Dan - Nope no selinux logs on this one best I can tell. If I
> run as user I get:
>
> $ needs-restarting
> Traceback (most recent call last):
> File "/usr/bin/needs-restarting", line 137, in<module>
> sys.exit(main(sys.argv))
> File "/usr/bin/needs-restarting", line 117, in main
> for fn in get_open_files(pid):
> File "/usr/bin/needs-restarting", line 84, in get_open_files
> for line in maps.readlines():
> IOError: [Errno 13] Permission denied
>
>
> Its odd - line 117 in needs-restarting is this fragment:
>
>
> for pid in return_running_pids(uid=myuid):
> try:
> pid_start = os.stat('/proc/' + pid)[stat.ST_CTIME]
> except OSError, e:
> continue
> found_match = False
> for fn in get_open_files(pid):
>
> Works fine as root.
Usually ordinary users are prohibited from accessing /proc/<whatever>
from what I remember. That is why root works and joe-blow does not.
James McKenzie
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 02:51 AM
Genes MailLists
gnu linux update question
On 06/28/2011 10:13 PM, James McKenzie wrote:
> On 6/28/11 6:37 PM, Genes MailLists wrote:
>>
>> Works fine as root.
> Usually ordinary users are prohibited from accessing /proc/<whatever>
> from what I remember. That is why root works and joe-blow does not.
>
> James McKenzie
>
I'm totally fine with it - but seems to work for some - curiosity now.
I wonder if those for whom it works are in group wheel or something -
perhaps as my firstboot failed when systemd got its knickers in a twist
with the luks passwords and firstboot and i915 graphics somehow first
boot was a black screen .. dont recall now if f15 or f16 puts first user
in wheel group - and if that matters at all.
gene/
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 02:58 AM
Patrick O'Callaghan
gnu linux update question
On Tue, 2011-06-28 at 19:13 -0700, James McKenzie wrote:
> On 6/28/11 6:37 PM, Genes MailLists wrote:
> > On 06/28/2011 08:17 PM, Daniel J Walsh wrote:
> >>> Does this work as regular user for you? For me - selinux makes it crash.
> >> run ausearch -m avc -ts recent
> >>
> >> And see if it generates any output.
> >>
> >> SELinux error messages are written to /var/log/audit/audit.log
> >>
> >>
> >>
> > Thanks Dan - Nope no selinux logs on this one best I can tell. If I
> > run as user I get:
> >
> > $ needs-restarting
> > Traceback (most recent call last):
> > File "/usr/bin/needs-restarting", line 137, in<module>
> > sys.exit(main(sys.argv))
> > File "/usr/bin/needs-restarting", line 117, in main
> > for fn in get_open_files(pid):
> > File "/usr/bin/needs-restarting", line 84, in get_open_files
> > for line in maps.readlines():
> > IOError: [Errno 13] Permission denied
> >
> >
> > Its odd - line 117 in needs-restarting is this fragment:
> >
> >
> > for pid in return_running_pids(uid=myuid):
> > try:
> > pid_start = os.stat('/proc/' + pid)[stat.ST_CTIME]
> > except OSError, e:
> > continue
> > found_match = False
> > for fn in get_open_files(pid):
> >
> > Works fine as root.
> Usually ordinary users are prohibited from accessing /proc/<whatever>
> from what I remember. That is why root works and joe-blow does not.
>
> James McKenzie
>
In fact most of the contents of /proc/<pid> are world-readable. Try 'ls
-l /proc/<some-pid>'. Specifically, the smaps file is world-readable,
which is what needs-restarting uses to get the names of open files. It
essentially builds a table from the internal equivalent of "grep
fd: /proc/*/smaps".
I invariably run needs-restarting under my own user id just after
updating, and I have never seen the above traceback.
poc
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 03:00 AM
Patrick O'Callaghan
gnu linux update question
On Tue, 2011-06-28 at 22:51 -0400, Genes MailLists wrote:
> On 06/28/2011 10:13 PM, James McKenzie wrote:
> > On 6/28/11 6:37 PM, Genes MailLists wrote:
>
>
> >>
> >> Works fine as root.
> > Usually ordinary users are prohibited from accessing /proc/<whatever>
> > from what I remember. That is why root works and joe-blow does not.
> >
> > James McKenzie
> >
>
> I'm totally fine with it - but seems to work for some - curiosity now.
>
> I wonder if those for whom it works are in group wheel or something -
> perhaps as my firstboot failed when systemd got its knickers in a twist
> with the luks passwords and firstboot and i915 graphics somehow first
> boot was a black screen .. dont recall now if f15 or f16 puts first user
> in wheel group - and if that matters at all.
>
> gene/
It doesn't (just tried it to check).
poc
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines
06-29-2011, 03:04 AM
Ed Greshko
gnu linux update question
On 06/29/2011 10:51 AM, Genes MailLists wrote:
> On 06/28/2011 10:13 PM, James McKenzie wrote:
>> On 6/28/11 6:37 PM, Genes MailLists wrote:
>
>>> Works fine as root.
>> Usually ordinary users are prohibited from accessing /proc/<whatever>
>> from what I remember. That is why root works and joe-blow does not.
>>
>> James McKenzie
>>
> I'm totally fine with it - but seems to work for some - curiosity now.
>
> I wonder if those for whom it works are in group wheel or something -
> perhaps as my firstboot failed when systemd got its knickers in a twist
> with the luks passwords and firstboot and i915 graphics somehow first
> boot was a black screen .. dont recall now if f15 or f16 puts first user
> in wheel group - and if that matters at all.
>
>
I took a quick read of the python script....
It would seem that if one is not running as root it will check the PIDs
of the user invoking the command to see if any of those processes need
to be restarted.
I ran it as a user running KDE....and it took several seconds to
complete....lots of PIDs for that user.
I ran it as a user that had ssh'd in. Completed very fast....only a
couple of PIDs.
Of course an ordinary user can access many /proc/<whatever> ....
cat /proc/cpuinfo being one of many....
--
users mailing list
users@lists.fedoraproject.org
To unsubscribe or change subscription options:
https://admin.fedoraproject.org/mailman/listinfo/users
Guidelines: http://fedoraproject.org/wiki/Mailing_list_guidelines