diff --git a/dhcp.spec b/dhcp.spec index 0f79d10..557eb9e 100644 --- a/dhcp.spec +++ b/dhcp.spec @@ -10,7 +10,7 @@ Summary: DHCP (Dynamic Host Configuration Protocol) server and relay agent Name: dhcp Version: 3.0.5 -Release: 38%{?dist} +Release: 39%{?dist} Epoch: 12 License: ISC Group: System Environment/Daemons @@ -434,6 +434,9 @@ fi %{_libdir}/libdhcp4client.a %changelog +* Tue Sep 04 2007 David Cantrell - 12:3.0.5-39 +- Do not override manually configured NTP servers in /etc/ntp.conf (#274761) + * Mon Jul 09 2007 David Cantrell - 12:3.0.5-38 - Remove -TERM option from killproc command (#245317) diff --git a/linux b/linux index 81b5bd5..7d54e5c 100755 --- a/linux +++ b/linux @@ -410,15 +410,10 @@ function dhconfig() : elif [ -n "$new_ntp_servers" ] && [ -e /etc/ntp.conf ]; then save_previous /etc/ntp.conf - /bin/egrep -v '(^[\ \ ]*(server|fudge))|(generated by /sbin/dhclient-script)'< /etc/ntp.conf.predhclient > /etc/ntp.conf - echo '# servers generated by /sbin/dhclient-script' >> /etc/ntp.conf - localClocks=(`/bin/egrep '^[\ \ ]*server[\ \ ]+127\.127' /etc/ntp.conf.predhclient | while read s addr rest; do echo $addr; done`) - localClockFudge="`/bin/egrep '^[\ \ ]*fudge[\ \ ]+127\.127' /etc/ntp.conf.predhclient`"; - for s in $new_ntp_servers ${localClocks[@]}; - do - echo 'server '$s >> /etc/ntp.conf; + /bin/egrep -v '^server .* # added by /sbin/dhclient-script$'< /etc/ntp.conf.predhclient > /etc/ntp.conf + for s in $new_ntp_servers; do + echo "server $s # added by /sbin/dhclient-script" >> /etc/ntp.conf; done - echo "$localClockFudge" >> /etc/ntp.conf; if [ -x /usr/bin/diff ] && /usr/bin/diff -q /etc/ntp.conf /etc/ntp.conf.predhclient >/dev/null 2>&1; then : ; else