custom ntp server in phosphor-networkd

Alexander Amelkin a.amelkin at yadro.com
Wed Aug 28 01:14:57 AEST 2019


27.08.2019 13:32, Ratan Gupta wrote:
> On 27/08/19 1:13 PM, Alexander A. Filippov wrote:
>> On Mon, Aug 26, 2019 at 10:23:15AM -0700, Vernon Mauery wrote:
>>> This is pretty common behavior for DHCP settings.
>> On Tue, Aug 27, 2019 at 11:28:36AM +0530, Ratan Gupta wrote:
>>> Why this is wrong,
>> Ok, ok.  I wasn't clear enough. My appologies.
>>
>> I've meant that the impossibility to add a custom ntp server while dhcp is
>> enabled is wrong. Of course, the list of ntp servers received from DHCP-server
>> must be used. And I propose to move only manual settings.
>>
>> I believe that it is a same stuff with DNS-servers, routes. But probably, the
>> BMC is not such kind of devices which is required such deep settings. One of the
>> possible reasons was specified by Vernon quoted below:
>>
>> On Mon, Aug 26, 2019 at 10:23:15AM -0700, Vernon Mauery wrote:
>>> It seems to me that if you are using static settings for your network, 
>>> then you would also have static (or user-supplied) settings for NTP and 
>>> DNS. But if you are using DHCP for the network, it would make sense to 
>>> use the NTP and DNS settings supplied by the DHCP server.
>>>
>>> Now it might also be nice to have some reasonable defaults for NTP 
>>> servers. It is not uncommon to have IP gateways also be NTP servers, so 
>>> it might be reasonable to attempt to use the gateway as an NTP server if 
>>> none was specified in the DHCP response. I don't like the idea of 
>>> setting the default NTP server to be something that is globally 
>>> addressable because that makes the assumption that the BMC can reach 
>>> global networks, which should not be the case.
> I have the following suggestion
>
>
> => By default all the DHCP optional parameters will be set to false(i.e Don't
> ask the optional info from the DHCP server) => If users wants the DHCP
> provided configuration then it has to set the specific optional parameters to
> true(Say NTPEnabled=true).

I'd say that sysadmins won't be happy with this approach. If I were them I'd
prefer this:

1. If DHCP is globally enabled for the BMC and the DHCP server sends any
parameters, then they take precedence
2. If any of the optional parameters are not provided by DHCP server or DHCP is
globally disabled for the BMC, then statically defined settings are used

IMO, that is a very simple and deterministic approach without any
easy-to-overlook settings.

> => User configures the Static NTP => Check if DHCP is enabled then look for
> the DHCP configuration parameters, if "NTP Enabled is true"
> then user wants the NTP server from the DHCP and in that case don't allow the
> static configuration.
> => if DHCP is enabled but in DHCP configuration parameters "NTP Enabled is false"
> then user doesn't want the NTP server from the DHCP and allow the static
> configuration.
>
> Link:
> https://github.com/openbmc/phosphor-dbus-interfaces/blob/master/xyz/openbmc_project/Network/DHCPConfiguration.interface.yaml
>
> Note: It may happen that user has set DHCP Configuration parameters on the BMC
> to take the NTP server details from the
> DHCP server but have not configured the DHCP server to provide the NTP server,
> in that case
> Static NTP server configuration will not be allowed.

With best regards,
Alexander Amelkin,
BIOS/BMC Team Lead, YADRO
https://yadro.com

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20190827/8663571a/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: OpenPGP digital signature
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20190827/8663571a/attachment-0001.sig>


More information about the openbmc mailing list