Start dhclient using systemd on CentOS 7 - eitan-j/tech-journal GitHub Wiki

source

  • Create /etc/systemd/system/dhclient.sevice with the following
    • Path to dhclient can be found with whereis dhclient
[Unit]
Description=Service to start dhclient on boot

[Service]
ExecStart=/usr/sbin/dhclient

[Install]
WantedBy=multi-user.target
  • systemctl enable dhclient.service
  • Reboot
    • If it's working, you should be able to connect to access your server before you even log on