[BUG] 'WARNING Dhcp client is not running' on RHEL 8.0
- Dominant language
- Python
- Stars
- 581
- Forks
- 397
- Avg merge
- 2d 15h
- Merged PRs (30d)
- 9
Description
## Description
The version of NetworkManager installed on RHEL 8.0 use the internal dhcp client by default:
```
NetworkManager[831]: [1570363540.7012] dhcp-init: Using DHCP client 'internal'
NetworkManager[827]: [1570413842.0257] dhcp-init: Using DHCP client 'internal'
NetworkManager[832]: [1571104032.7495] dhcp-init: Using DHCP client 'internal'
```
However **WALinuxAgent** is only checking for `dhclient`: https://github.com/Azure/WALinuxAgent/blob/e3ecde432c0fd6968bdb6d2774e316a61b3289d2/azurelinuxagent/common/osutil/redhat.py#L74-L75
Because of this we are getting this warning in *waagent.log*:
```
WARNING ExtHandler Dhcp client is not running.
WARNING ExtHandler Dhcp client is not running.
WARNING ExtHandler Dhcp client is not running.
```
## Version
```
# cat /etc/redhat-release
Red Hat Enterprise Linux release 8.0 (Ootpa)
# waagent --version
WALinuxAgent-2.2.32.2 running on redhat 8.0
Python: 3.6.8
Goal state agent: 2.2.42
```
Contributor guide
Research direction
Start with azurelinuxagent/common/osutil/redhat.py at the linked lines 74-75 and review how the agent checks for dhclient. Compare that check with the RHEL 8.0 logs showing NetworkManager's internal DHCP client, then verify that the resulting waagent.log no longer reports a false DHCP warning when the supported client is running.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- linux, python
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100