From Fedora Project Wiki
Description
This test case ensures that the dhcp-client
package is working as expected. It verifies that a client machine can request, receive, and use an IP address from a DHCP server.
Setup
- Install the version of Fedora that is to be tested on a bare metal or virtual system.
- Install the
dhcp-client
package using the command:sudo dnf install dhcp-client
.
How to test
- Connect the client machine to a network with a functioning DHCP server.
- Open a terminal window.
- Run the command
sudo dhclient <network-interface>
to request a DHCP lease, where<network-interface>
is your network interface name (e.g., eth0, ens33). - Run the command
ip a
orifconfig
to verify that the client machine has received an IP address from the DHCP server.
Expected Results
- The
dhclient
command completes without error. - The client machine successfully receives an IP address from the DHCP server.
- The client machine can communicate with other machines on the network using the assigned IP address.
- The DHCP lease information is correctly stored (usually in
/var/lib/dhclient
or similar directory).
Optional
- Test the DHCP lease renewal process by observing the client machine over an extended period and ensuring it maintains network connectivity.
- Test the behavior when the DHCP server is unreachable or not responding to requests.
- Test the behavior with different DHCP server configurations (e.g., static leases, different subnets).