Bug 1150289

Summary: systemctl hibernate (and other situation) error message not helpful
Product: [Fedora] Fedora Reporter: Hin-Tak Leung <htl10>
Component: systemdAssignee: systemd-maint
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: johannbg, jsynacek, lnykryn, msekleta, s, systemd-maint, vpavlin, zbyszek
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: initscripts-9.56.1-2.fc21 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-10-28 21:49:08 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Hin-Tak Leung 2014-10-07 20:32:08 UTC
Description of problem:
Follow up to:
https://bugzilla.redhat.com/show_bug.cgi?id=986370#c3

On secure boot systems, running "systemctl hibernate" fails,
with an advice to see "journalctl -xn". It offers only the last 10 lines,
which are often just rubbish from gnome shell extensions, network manager
renewing leases, etc.
The advice should really ask the user to page-backwards, rather than just 10 lines.


The advice offered should be equivalent to 

     tac /var/log/messages |less

rather than 

     tail -n 10  /var/log/messages

as it seems to do.

Version-Release number of selected component (if applicable):
systemd-208-22.fc20.x86_64

How reproducible:
always


Steps to Reproduce:
1. try 'systemctl hibernate' on secureboot system
2. follow its advice on  see "journalctl -xn"
3.

Actual results:
"journalctl -xn" not always indicate where the error is, just 10 lines of rubbish from gnome extensions or other unrelated things.

Expected results:
See 
---------
systemd-sleep[3367]: Failed to write mode to /sys/power/disk: Operation not permitted
---------

Additional info:

page backward indefinitely, instead of just 10 lines, should be prefered.

Comment 1 Hin-Tak Leung 2014-10-08 11:26:25 UTC
The 10 lines from journalctl -xn is also not helpful when 'systemctl start sshd.service' fails. 

https://bugzilla.redhat.com/show_bug.cgi?id=1150286#c4

But I learned not to use journalctl anyway.

Comment 2 Hin-Tak Leung 2014-10-08 11:28:59 UTC
(In reply to Hin-Tak Leung from comment #1)
> The 10 lines from journalctl -xn is also not helpful when 'systemctl start
> sshd.service' fails. 

In this case, sshd.service itself generates more than 10 lines, (and over and over), and the important one, about 'sshd-keygen: Generating SSH2 RSA host key: [FAILED]' - is 'many' lines before the end, with 'many' >> 10.

Comment 3 Zbigniew Jędrzejewski-Szmek 2014-10-09 00:26:35 UTC
http://cgit.freedesktop.org/systemd/systemd/commit/?id=b923047d73 changes systemctl to suggest -xe. This allows paging back 1000 lines. This should go out in the next update.

Comment 4 Fedora Update System 2014-10-10 21:23:59 UTC
initscripts-9.56.1-1.fc21, systemd-216-3.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/initscripts-9.56.1-1.fc21,systemd-216-3.fc21

Comment 5 Fedora Update System 2014-10-12 05:05:13 UTC
Package initscripts-9.56.1-1.fc21, systemd-216-3.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing initscripts-9.56.1-1.fc21 systemd-216-3.fc21'
as soon as you are able to, then reboot.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-12688/initscripts-9.56.1-1.fc21,systemd-216-3.fc21
then log in and leave karma (feedback).

Comment 6 Fedora Update System 2014-10-14 04:33:46 UTC
Package systemd-216-4.fc21, initscripts-9.56.1-2.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing systemd-216-4.fc21 initscripts-9.56.1-2.fc21'
as soon as you are able to, then reboot.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-12688/initscripts-9.56.1-2.fc21,systemd-216-4.fc21
then log in and leave karma (feedback).

Comment 7 Fedora Update System 2014-10-21 17:24:49 UTC
Package initscripts-9.56.1-2.fc21, systemd-216-5.fc21:
* should fix your issue,
* was pushed to the Fedora 21 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing initscripts-9.56.1-2.fc21 systemd-216-5.fc21'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/FEDORA-2014-12688/initscripts-9.56.1-2.fc21,systemd-216-5.fc21
then log in and leave karma (feedback).

Comment 8 Fedora Update System 2014-10-28 21:49:08 UTC
initscripts-9.56.1-2.fc21, systemd-216-5.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.