Bug 1154768 - Systemd ignores TimeoutSec=0 in service file
Summary: Systemd ignores TimeoutSec=0 in service file
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: systemd
Version: 21
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: systemd-maint
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On: 1152220
Blocks: F21FinalFreezeException
TreeView+ depends on / blocked
 
Reported: 2014-10-20 17:09 UTC by Martin Kolman
Modified: 2014-11-12 02:38 UTC (History)
13 users (show)

Fixed In Version: kmod-18-4.fc21
Doc Type: Bug Fix
Doc Text:
Clone Of: 1152220
Environment:
Last Closed: 2014-11-04 02:48:03 UTC


Attachments (Terms of Use)


Links
System ID Priority Status Summary Last Updated
Red Hat Bugzilla 1159292 None None None Never
Red Hat Bugzilla 1159641 None None None Never

Internal Links: 1159292 1159641

Description Martin Kolman 2014-10-20 17:09:30 UTC
+++ This bug was initially created as a clone of Bug #1152220 +++

Description of problem:
The Initial Setup systemd service file[0] contains the TimeoutSec=0 options, but systemd still shuts-down the system after initial setup has been running for about 10-15 minutes.


Version-Release number of selected component (if applicable):
systemd
Version     : 216
Release     : 10.fc22

initial-setup
Version     : 0.3.23
Release     : 2.fc22

How reproducible:
always

Steps to Reproduce:
0a.: install rawhide with kickstart that contains "firstboot --enable"
     and don't configure user - this should make Initial Setup start after
     installation
0b.: some other service that has TimeoutSec=0 and is run during startup might
     also do 
1. leave the given service running for about 10-15 minutes

Actual results:
The system is shutdown by systemd after about 10-15 minutes, regardless
of what's going on (it even once shut down during dnf update, trashing my testing VM...).

Expected results:
The given service will run indefinitely without systemd shutting down the system.


Additional info:
This is in Journal directly before shutdown:

Oct 13 15:38:28 rawinit systemd[1]: Startup timed out.
Oct 13 15:38:28 rawinit systemd[1]: Forcibly powering off as result of failure.
Oct 13 15:38:28 rawinit systemd[1]: Shutting down.


[0] https://git.fedorahosted.org/cgit/initial-setup.git/tree/systemd/initial-setup-graphical.service

--- Additional comment from Zbigniew Jędrzejewski-Szmek on 2014-10-13 18:04:29 CEST ---

I don't know if this is a consolation, but a fix for this is on the todo list [1]:

* apply start timeout during the "initializing" manager state only,
  instead of both "initializing" and "starting". maybe rename the
  timeout to "initialization-timeout" then or so?

[1] http://cgit.freedesktop.org/systemd/systemd/tree/TODO?id=HEAD#n78

--- Additional comment from Martin Kolman on 2014-10-20 18:23:25 CEST ---

Does not happen in the latest F21 nightly with systemd 215-19.

--- Additional comment from Martin Kolman on 2014-10-20 19:09:05 CEST ---

Looks like it got backported to F21 with 216-4.

Comment 1 Fedora Blocker Bugs Application 2014-10-20 17:13:12 UTC
Proposed as a Blocker for 21-alpha by Fedora user m4rtink using the blocker tracking app because:

 If Initial Setup is running, the computer will unconditionally shutdown after 15 minutes after startup. This can be problematic as user input can be lost, important operations as user and group creation being interrupted mid-way or computer shutting down unexpectedly when user expects it to be running after the installation & reboot.

Comment 2 Andre Robatino 2014-10-20 17:16:58 UTC
Possibly a duplicate of my https://bugzilla.redhat.com/show_bug.cgi?id=1154416 ? Also, I think you might need to make this a Beta Blocker, since Alpha is already out (but not 100% sure).

Comment 3 Martin Kolman 2014-10-20 17:21:29 UTC
(In reply to Andre Robatino from comment #2)
> Possibly a duplicate of my
> https://bugzilla.redhat.com/show_bug.cgi?id=1154416 ? Also, I think you
> might need to make this a Beta Blocker, since Alpha is already out (but not
> 100% sure).

Looking at the tool, the 21-alpha is preselected as the default milestone for some reason. :)

Comment 4 Fedora Blocker Bugs Application 2014-10-20 17:22:26 UTC
Proposed as a Blocker for 21-beta by Fedora user m4rtink using the blocker tracking app because:

 If Initial Setup is running, the computer will unconditionally shutdown after 15 minutes after startup. This can be problematic as user input can be lost, important operations as user and group creation being interrupted mid-way or computer shutting down unexpectedly when user expects it to be running after the installation & reboot.

(submitted again with correct milestone)

Comment 5 Andre Robatino 2014-10-20 17:49:05 UTC
(In reply to Andre Robatino from comment #2)
> Possibly a duplicate of my
> https://bugzilla.redhat.com/show_bug.cgi?id=1154416 ?

Actually, this bug is more detailed, so if it's the same bug, then mark bug 1154416 as a duplicate of this one. (This bug was also cloned from bug 1152220 which preceded mine.)

Comment 6 Kamil Páral 2014-10-20 18:23:54 UTC
Discussed in 2014-10-20 Blocker Review meeting [1]. Rejected as a blocker, accepted as a freeze exception.  It isn't clear how easy this bug is to hit. Getting a fix in for Beta would be good. Please repropose with reproduction steps if it's more widespread than currently indicated.

[1] http://meetbot.fedoraproject.org/fedora-blocker-review/2014-10-20/

Comment 7 Zbigniew Jędrzejewski-Szmek 2014-10-26 00:37:32 UTC
Patches sent for review: http://lists.freedesktop.org/archives/systemd-devel/2014-October/024502.html.

Comment 8 Adam Williamson 2014-10-30 21:40:30 UTC
Beta got approved without a fix for this, so no point having it as a Beta FE any more. Re-proposing as Final FE as it seems significant and we'll want to make sure we don't lose it.

Comment 9 Adam Williamson 2014-10-31 19:20:32 UTC
We suspect this is causing https://bugzilla.redhat.com/show_bug.cgi?id=1159292 , which may be a major problem for Beta. The upgrade.img for Beta is baked-in at this point. Our only hope is if fedup can, somehow, work around the problem: is there some way it can disable the shutdown-after-timeout behaviour for the fedup boot, perhaps?

Comment 10 Fedora Update System 2014-11-03 13:24:15 UTC
kmod-18-4.fc21,systemd-216-7.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/kmod-18-4.fc21,systemd-216-7.fc21

Comment 11 Fedora Update System 2014-11-03 19:05:53 UTC
systemd-216-8.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/systemd-216-8.fc21

Comment 12 Fedora Update System 2014-11-04 02:48:03 UTC
systemd-216-8.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 13 Fedora Update System 2014-11-04 14:21:30 UTC
kmod-18-4.fc21,systemd-216-9.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/kmod-18-4.fc21,systemd-216-9.fc21

Comment 14 Fedora Update System 2014-11-05 13:17:22 UTC
kmod-18-4.fc21,systemd-216-10.fc21 has been submitted as an update for Fedora 21.
https://admin.fedoraproject.org/updates/kmod-18-4.fc21,systemd-216-10.fc21

Comment 15 Fedora Update System 2014-11-12 02:38:16 UTC
kmod-18-4.fc21, systemd-216-11.fc21 has been pushed to the Fedora 21 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.