Bug 736879 - chrony dies on systemd startup
Summary: chrony dies on systemd startup
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: chrony
Version: 15
Hardware: x86_64
OS: Linux
unspecified
high
Target Milestone: ---
Assignee: Miroslav Lichvar
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-09-08 23:25 UTC by Wolfgang Rupprecht
Modified: 2011-09-25 03:52 UTC (History)
2 users (show)

Fixed In Version: chrony-1.26-3.20110831gitb088b7.fc15
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-09-25 03:52:15 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
chrony conf file. (2.51 KB, application/octet-stream)
2011-09-08 23:25 UTC, Wolfgang Rupprecht
no flags Details

Description Wolfgang Rupprecht 2011-09-08 23:25:20 UTC
Created attachment 522215 [details]
chrony conf file.

Description of problem:

Chrony works fine when started by hand, but dies without even printing the initial output to syslog when started by systemd at boot time.

Version-Release number of selected component (if applicable):
chrony.x86_64                    1.26-1.fc15       

How reproducible:
always

Steps to Reproduce:
1. shutdown -r now
2.
3.
  
Actual results:

Sep  8 03:54:57 arbol chronyd[827]: Fatal error : Possible infinite loop in scheduling

Expected results:

Sep  8 15:56:40 arbol chronyd[25350]: chronyd version 1.26 starting
Sep  8 15:56:40 arbol chronyd[25350]: Linux kernel major=2 minor=6 patch=40
Sep  8 15:56:40 arbol chronyd[25350]: hz=100 shift_hz=7 freq_scale=1.00000000 nominal_tick=10000 slew_delta_tick=833 max_tick_bias=1000
Sep  8 15:56:40 arbol chronyd[25350]: Frequency 20.893 +- 0.063 ppm read from /var/lib/chrony/drift

Additional info:

The host this is observed on runs its own named.  Perhaps there is a timing issue with hostnames not resolving when chrony expects them to.

This host also has ipv6 connections.  I don't think that should be an issue here.

Comment 1 Wolfgang Rupprecht 2011-09-08 23:45:10 UTC
This appears to be related to named.  When I add the ipv4 and ipv6 addresses of the chrony servers to /etc/hosts then things work fine.

There appear to be two bugs here. 1) chrony is started before named is ready.  This didn't happen in Fedora-14 so I assume systemd is implicated.  2) chrony needs to be more mellow about name lookup failures.  Waiting a few seconds and retrying seems to be a much better idea than exiting.

Comment 2 Miroslav Lichvar 2011-09-09 10:05:01 UTC
Yes, this is related to name resolving. When it fails on start, it retries couple seconds later, but if that takes too long (perhaps 200 ms or more per server), it will crash.

It's a bug in the code which should prevent chrony from flooding the network.

It should be fixed in the latest f16 update, I will submit it for f15 too.

Comment 3 Fedora Update System 2011-09-09 10:13:57 UTC
chrony-1.26-3.20110831gitb088b7.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/chrony-1.26-3.20110831gitb088b7.fc15

Comment 4 Fedora Update System 2011-09-10 00:28:25 UTC
Package chrony-1.26-3.20110831gitb088b7.fc15:
* should fix your issue,
* was pushed to the Fedora 15 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing chrony-1.26-3.20110831gitb088b7.fc15'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/chrony-1.26-3.20110831gitb088b7.fc15
then log in and leave karma (feedback).

Comment 5 Wolfgang Rupprecht 2011-09-10 18:04:45 UTC
confirmed fixed in chrony-1.26-3.20110831gitb088b7.fc15

thanks!

Comment 6 Fedora Update System 2011-09-25 03:52:04 UTC
chrony-1.26-3.20110831gitb088b7.fc15 has been pushed to the Fedora 15 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.