DHCP provides information about the configuration to interworking devices and Internet hosts. This particular protocol consists of two different components which include a specific mechanism that is primarily for allocating network addresses to the device, and the other one is delivering parameters of configuration to a device from a DHCP server.
DHCP is technically built on a client-server model in Cisco Catalyst WS-C2960CX-8PC-L switches where selected DHCP server configuration parameters and locate network addresses to the devices that are dynamically configured. The switch over here cannot only act as a DHCP server but also as a DHCP client.
Your switch on the Cisco DHCP client automatically configures at the startup with a configuration file and an IP address information. This happens during the DHCP-based auto-configuration. You don’t need any DHCP client-side configuration on your switch when you have the DHCP-based auto-configuration. But this is not the same case when you need to configure the DHCP service for different other lease options that are associated with IP addresses. But suppose you are using the DHCP any kind of configuration file location on the network. In that case, you also require to configure a Cisco Domain name system server (DNS) and a Cisco Trivial file transfer protocol server (TFTP).
Same LAN or on a different LAN
The DHCP server for your switch can either be on a different LAN or the same LAN than the switch. But suppose the DHCP server is running on a different LAN the switch then all you need to do is to configure a DHCP relay device between the DHCP server and your switch. Relay device is used when there is a need for forwarding broadcast traffic between two LANs that are directly connected. Most users and customers of the mistake one thing about the DHCP server on the Cisco catalyst 2960 series is at the router forward broadcast packets. This particular piece of information is not right because it only helps to forward packets that are based upon the destination IP address, which is present in the received packet.
Lastly, the BOOTP client functionality on your Cisco Catalyst 2960 switches is replaced by the DHCP-based autoconfiguration.
The DHCP client request
It’s important to understand that when you put off your switch the DHCP requests configuration information because it is invoked from the DHCP server when the configuration file is not available on the switch. Suppose the configuration file is not available on the switch and top of this. In that case, the configuration also includes the IP address DHCP interface configuration commands that is on precise and particular rooted interfaces then that the DHCP client is appealed or otherwise requested to give the Ip information for all of those interfaces.
The process of how all of this happens is mentioned below:
- The Client or otherwise known as switch A tries to send a DHCP Discover message for locating a DHCP server. Upon receiving this request or message, DHCP server provides all the configuration parameters, for example, Subnet Mask, IP address, a lease for the IP address, DNS IP address, and a gateway IP address among many others. This message is sent to the Client in a DHCP of a unicast message.
- When it reaches a DHCP request Broadcast message, a formal request is retired for the configuration information that is offered to the DHCP server by the Client. But this formal request is broadcasted so that all the other DHCP servers who have received the same DHCP Discover Broadcast message from the Client can get the IP addresses which they have all offered to the Client.
- A DHCPack unicast message is sent back to the Client when a DHCP server confirms the specific IP address that has been selected or offered to the Client. This message is only sent as a form of confirmation on the receiving of the particular information that was requested and which was offered upon seeing the request.
- But what happens when the configuration parameters which were officially sent to the Client in the DHCP offer a unicast message turns out to be invalid, or in other terms, an error exists in the configuration? When that happens, the Client returns a DHCP decline Broadcast message to where it got the configuration error from which is the DHCP server.
- The DHCP server in Cisco Catalyst WS-C2960CX-8PC-L switches then, in turn, sends the Client a DHCP Nack Broadcast message which basically means or refers that the configuration parameters which were offered have not been assigned, that the Client was slow to respond to the DHCP offer message, or that there was an error that occurred during the negotiation that was taking the place of the parameters.