Public bug reported:

Description:    Ubuntu 12.04 LTS
Release:        12.04

ntp:
  Installed: 1:4.2.6.p3+dfsg-1ubuntu3.1
  Candidate: 1:4.2.6.p3+dfsg-1ubuntu3.1
  Version table:
 *** 1:4.2.6.p3+dfsg-1ubuntu3.1 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise-updates/main amd64 
Packages
        100 /var/lib/dpkg/status
     1:4.2.6.p3+dfsg-1ubuntu3 0
        500 http://us.archive.ubuntu.com/ubuntu/ precise/main amd64 Packages
f
I had a need to set a custom config file for ntp. I looked about and found that 
I could pass a '-c' option and that options for ntp are set in /etc/default/ntp 
in NTPD_OPTS. So I put it in there: NTPD_OPTS='-g -c /path/to/custom/ntp.conf'. 
It worked. Until I deployed to another box that was receiving NTP settings via 
DHCP. On that box, ntpd exited with an error because it had received two config 
files in its arguments. Not good.

After reading through the init script, I opted to add a new variable to
/etc/default/ntp specifically for holding a custom config file. Attached
is a patch that will use that value if DHCP has not created its own
ntp.conf. If NTP settings were passed via DCHP, then those settings will
override the custom config file.

** Affects: ntp (Ubuntu)
     Importance: Undecided
         Status: New

** Patch added: "Patch for /etc/init.d/ntp"
   https://bugs.launchpad.net/bugs/1129696/+attachment/3535713/+files/ntp.diff

-- 
You received this bug notification because you are a member of Ubuntu
Server Team, which is subscribed to ntp in Ubuntu.
https://bugs.launchpad.net/bugs/1129696

Title:
  Cannot set config file in /etc/default/ntp

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/ntp/+bug/1129696/+subscriptions

-- 
Ubuntu-server-bugs mailing list
Ubuntu-server-bugs@lists.ubuntu.com
Modify settings or unsubscribe at: 
https://lists.ubuntu.com/mailman/listinfo/ubuntu-server-bugs

Reply via email to