Bug 717532 - Disable NTP setting when DHCP is selected
Summary: Disable NTP setting when DHCP is selected
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: ovirt-node
Version: 6.2
Hardware: All
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Joey Boggs
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-06-29 07:08 UTC by Guohua Ouyang
Modified: 2011-12-06 19:16 UTC (History)
6 users (show)

Fixed In Version: ovirt-node-2.0.2-0.1.git5dce5f9.el6
Doc Type: Bug Fix
Doc Text:
When DHCP is selected in RHEV Hypervisor Network configuration, NTP and DNS server information is retrieved from DHCP options and cannot be manually selected.
Clone Of:
Environment:
Last Closed: 2011-12-06 19:16:47 UTC
Target Upstream Version:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2011:1783 0 normal SHIPPED_LIVE rhev-hypervisor6 bug fix and enhancement update 2011-12-06 15:10:54 UTC

Description Guohua Ouyang 2011-06-29 07:08:36 UTC
Description of problem:
NTP server info cannot save to /etc/ntp.conf if configure IP with dhcp.

Version-Release number of selected component (if applicable):
rhev-hypervisor-5.7-20110622

How reproducible:
Always.

Steps to Reproduce:
1. Configure network.
2. Configure networking device eth0 with dhcp.
3. Configure ntp server (10.66.72.203).
4. apply, can see below info on screen:
 testing ntp configuration
 verified ntp server: 10.66.72.203
 ntpd: synchronizing with time server
 starting ntpd
5. return to shell and cat /etc/ntp.conf


Actual results:
The configured ntp server isn't in /etc/ntp.conf.

Expected results:
NTP server is saved to file /etc/ntp.conf.

In additional info:
1. If configure ip with static way, the ntp server can save to file correctly.
2. dns have no such problem

Comment 1 Guohua Ouyang 2011-06-29 08:54:10 UTC
on RHEL, add ntp server to /etc/ntp.conf and restart network service, the ntp server obtained by dhcp is appended to the one added by manual.

on RHEV-H node, the ntp server obtained by dhcp just replaced the one added by manual.

Comment 2 Alan Pevec 2011-06-29 09:03:01 UTC
That's by design, when dhcp is selected, NTP info should come from dhcp option 42.
In 6.x new UI we could make this visible by disabling NTP when DHCP is selected.

Comment 3 Guohua Ouyang 2011-06-29 09:11:40 UTC
(In reply to comment #2)
> That's by design, when dhcp is selected, NTP info should come from dhcp option
> 42.
manual add dns entry can saved, why not ntp?

> In 6.x new UI we could make this visible by disabling NTP when DHCP is
> selected.
This is nice to disable NTP when DHCP is selected.

Comment 4 Alan Pevec 2011-06-29 10:32:58 UTC
(In reply to comment #3)
> manual add dns entry can saved, why not ntp?

DNS info is stored as DNS1/DNS2 in ifcfg-* and seems that dhclient-script prefers them.

NTP goes directly to ntp.conf and AFAICT dhclient-script removes all server entries before adding what it received from DHCP server.

> on RHEL, add ntp server to /etc/ntp.conf and restart network service, the ntp
> server obtained by dhcp is appended to the one added by manual.

Was that RHEL 5.7 ? Looking at dhclient-script, I can't see how can that happen.

Comment 5 Guohua Ouyang 2011-06-30 01:39:28 UTC
(In reply to comment #4)
> (In reply to comment #3)
> > manual add dns entry can saved, why not ntp?
> 
> DNS info is stored as DNS1/DNS2 in ifcfg-* and seems that dhclient-script
> prefers them.
> 
> NTP goes directly to ntp.conf and AFAICT dhclient-script removes all server
> entries before adding what it received from DHCP server.
> 
> > on RHEL, add ntp server to /etc/ntp.conf and restart network service, the ntp
> > server obtained by dhcp is appended to the one added by manual.
> 
> Was that RHEL 5.7 ? Looking at dhclient-script, I can't see how can that
> happen.

It's RHEL6.0 (I didn't have RHEL5.7 at hand yesterday), dhclient-script just append new ntp entry to ntp.conf.

Tested it on RHEL5.7 today, dhclient-script simply overwrite existed entries.

Since RHEL5.7 do the same, so it's by design.


so modify the title and I will test this in 6.2.

Comment 8 Guohua Ouyang 2011-08-26 07:54:22 UTC
Verified on 6.2-0.14:
1. when dhcp is selected, ntp server is disabled.
2. when static is selected, ntp server is enabled.

Comment 9 Alan Pevec 2011-10-25 10:38:38 UTC
    Technical note added. If any revisions are required, please edit the "Technical Notes" field
    accordingly. All revisions will be proofread by the Engineering Content Services team.
    
    New Contents:
When DHCP is selected in RHEV Hypervisor Network configuration, NTP and DNS server information is retrieved from DHCP options and cannot be manually selected.

Comment 10 errata-xmlrpc 2011-12-06 19:16:47 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2011-1783.html


Note You need to log in before you can comment on or make changes to this bug.