{"action":"opened","issue":{"url":"https://api.github.com/repos/rancher/os/issues/909","repository_url":"https://api.github.com/repos/rancher/os","labels_url":"https://api.github.com/repos/rancher/os/issues/909/labels{/name}","comments_url":"https://api.github.com/repos/rancher/os/issues/909/comments","events_url":"https://api.github.com/repos/rancher/os/issues/909/events","html_url":"https://github.com/rancher/os/issues/909","id":153015881,"number":909,"title":"dhcpcd duid configuration prevents static dhcp leases","user":{"login":"segfly","id":3300476,"avatar_url":"https://avatars.githubusercontent.com/u/3300476?v=3","gravatar_id":"","url":"https://api.github.com/users/segfly","html_url":"https://github.com/segfly","followers_url":"https://api.github.com/users/segfly/followers","following_url":"https://api.github.com/users/segfly/following{/other_user}","gists_url":"https://api.github.com/users/segfly/gists{/gist_id}","starred_url":"https://api.github.com/users/segfly/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/segfly/subscriptions","organizations_url":"https://api.github.com/users/segfly/orgs","repos_url":"https://api.github.com/users/segfly/repos","events_url":"https://api.github.com/users/segfly/events{/privacy}","received_events_url":"https://api.github.com/users/segfly/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-05-04T13:46:41Z","updated_at":"2016-05-04T13:46:41Z","closed_at":null,"body":"Hello,\r\n\r\nI have an on-premise installation where I want to boot the host off ISO and manage their IPs via static DHCP leases. However, at least in v0.4.4 the `dhcpcd.conf` has commented out `clientid` and is using `duid`:\r\n```\r\n[rancher@rancher ~]$ cat /etc/dhcpcd.conf                                                                          \r\n# A sample configuration for dhcpcd.                                                                         \r\n# See dhcpcd.conf(5) for details.                                                                             \r\n                                                                                                              \r\n# Allow users of this group to interact with dhcpcd via the control socket.                                    \r\n#controlgroup wheel                                                                                             \r\n                                                                                                                \r\n# Inform the DHCP server of our hostname for DDNS.                                                               \r\nhostname                                                                                                         \r\n                                                                                                                  \r\n# Use the hardware address of the interface for the Client ID.                                                     \r\n#clientid                                                                                                           \r\n# or                                                                                                                \r\n# Use the same DUID + IAID as set in DHCPv6 for DHCPv4 ClientID as per RFC4361.\r\n# Some non-RFC compliant DHCP servers do not reply with this set.\r\n# In this case, comment out duid and enable clientid above.\r\nduid\r\n```\r\n\r\nI'm no expert on setting up DHCP servers (and in my environment, I was not the one who configured the static leases per MAC), so maybe there is a way to assign a static lease to an IAID. But IAID seems to be ignored as the default DHCP server configuration in every environment I try.\r\n\r\nIt boils down to the issue that the DUIDs are not persisted when booting off of ISO. As DUIDs have a random component, the result is a different DUID, and then an different DHCP IP lease on every boot and the inability to assign a static lease.\r\n\r\nI can't find where this `dhcpcd.conf` file is coming from in the rancher source repos, so I can't even build a custom ISO to use `clientid` (which I would rather not have to maintain).\r\n\r\nThere is at at least one other person who saw the same thing when `dhcpcd` was added and replaced `dhclient`:\r\nhttps://github.com/rancher/os-base/pull/5#issuecomment-119595791\r\n\r\nMy 2 cents, is that when rancher runs from ram it needs to use the `clientip` configuration in `dhcpcd.conf` and when installed to disk, it can use `duid` (if that is really needed by anyone)."}}