Migrate ntp from SystemV to Upstart

Bug #913379 reported by Lars Noodén
This bug report is a duplicate of:  Bug #604717: Please convert init script to upstart. Edit Remove
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
ntp (Ubuntu)
New
Wishlist
Unassigned

Bug Description

If upstart is indeed where Ubuntu is heading then ntp ought to be migrated over to it before 12.04.

Below is a guess at what /etc/init/ntp.conf could contain. Some other changes are needed for it to work properly.

# ntp - Network Time Protoco client and server
#
# The Network Time Protocol client and server synchronizes
# system clocks over the network

description "NTP server"

start on filesystem or runlevel [2345]
stop on runlevel [!2345]

respawn
respawn limit 10 5
umask 022

pre-start script
    test -x /usr/sbin/ntpd || { stop; exit 0; }
    test -f /etc/ntp.conf || { stop; exit 0; }

    mkdir -p -m0755 /var/run/ntp
end script

exec /usr/sbin/ntpd

Revision history for this message
Jamie Strandboge (jdstrand) wrote :

ntp also ships an enforcing apparmor profile. As such, the upstart script should include the following in the pre-start script:
pre-start script
    ...
    /lib/init/apparmor-profile-load usr.sbin.ntpd
end script

Dave Walker (davewalker)
Changed in ntp (Ubuntu):
importance: Undecided → Wishlist
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.