Chrony initscript always sets chrony offline even with Internet connectivity
Bug #1034420 reported by
xor
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
chrony (Ubuntu) |
Expired
|
Undecided
|
Unassigned |
Bug Description
Using Ubuntu 12.04 server.
The initscript /etc/init.d/chrony should set chrony to online-mode if Internet connectivity is detected.
However, it always sets chrony to offline mode even when the machine is online. resulting in the machine's clock never being synchronized!
I have copy-pasted some of the "if" in the script to see which one fails, and this one is it:
"if timelimit -q -s9 -t5 -- netstat -rn 2>/dev/null | grep UG | cut -f 1 -d ' ' | grep -q '0\.0\.0\.0'"
(FYI: The machine is online via a DSL-connection configured by "pppoeconf".)
To post a comment you must log in.
Notice that there is also a script /etc/ppp/ip-up.d which set chrony to online mode as soon as ppp dialup happens. This hides the bug which I have reported.
So to reproduce this bug, first dialup the machine, then restart the chrony service. It will be offline then.