Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clarity on output #84

Closed
stdedos opened this issue Oct 27, 2017 · 1 comment
Closed

Clarity on output #84

stdedos opened this issue Oct 27, 2017 · 1 comment
Assignees

Comments

@stdedos
Copy link
Contributor

stdedos commented Oct 27, 2017

root@host:~# needrestart
Scanning processes...
Scanning candidates...
Scanning linux images...
Running kernel seems to be up-to-date.
Services to be restarted:
Skipping dbus.service...
Skipping docker.service...
Skipping libvirt-bin.service...
Skipping lvm2-lvmetad.service...
No containers need to be restarted.
User sessions:
jenkins on session services is running obsolete systemd[77854]
root on session services is running obsolete systemd[7946]

Since I am running a "production server", I cannot afford to blindly restart things. So I set in the configuration the default flag to be list.

Output that says Skipping however, it translates into my head as "Ignoring from checking", instead of "I am normally restarting services, but since you want list only, I am Skipping the restart of x.service..."

As a nitpick, I'd prefer some extra spaces here and there. Example outputs:

root@host:~# needrestart
Scanning processes...
Scanning candidates...
Scanning linux images...

Running kernel seems to be up-to-date.

List of outdated Services: (or something equivalent)
* dbus.service
* docker.service
* libvirt-bin.service
* lvm2-lvmetad.service

No containers need to be restarted.

User sessions:
* jenkins on session services is running obsolete systemd[77854]
* root on session services is running obsolete systemd[7946]
@liske liske self-assigned this Oct 29, 2017
@liske liske closed this as completed in 2b893cf Dec 19, 2017
@liske
Copy link
Owner

liske commented Dec 19, 2017

I've changed the output to improve readability and replaced skipped by deferred:

# ./needrestart -r a
Scanning processes...                                                           
Scanning candidates...                                                          
Scanning linux images...                                                        

Running kernel seems to be up-to-date.

Restarting services...
 systemctl restart apache2.service bind9.service [...]

Service restarts being deferred:
 systemctl restart docker.service
 systemctl restart zfs-fuse.service

No containers need to be restarted.

User sessions running outdated binaries:
 thomas @ session #7: applet.py[4565], [...]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants