Network Engineer Interview Question

Explain how DHCP works, including what a relay agent does.

What the interviewer is probing, how to structure your answer, and a spoken example you can adapt.

Quick answer

A client with no address broadcasts a discover message. A server replies with an offer, the client broadcasts a request for that offer, and the server confirms with an acknowledgement, often remembered as DORA. The lease includes the address, mask, gateway and DNS servers. Because broadcasts do not cross routers, a relay agent on the client's gateway forwards requests to a central server as unicast, adding its own address so the right scope is used.

Why interviewers ask this

DHCP failures stop users working, and on routed networks the relay is a frequent point of failure, especially when new VLANs are added. The interviewer wants to know that you understand the exchange, why broadcasts are a problem across subnets, and how the relay agent tells the server which scope to use. Linking this to common faults, such as a missing relay or an exhausted scope, shows practical experience.

How to structure your answer

  • Walk through discover, offer, request and acknowledge.
  • Explain what the lease contains and how renewal works.
  • Explain why a relay agent is needed and how it works.
  • List common DHCP faults.

Example answer

Spoken example, first person

A client joining the network has no address, so it broadcasts a discover message. Any server that hears it replies with an offer. The client broadcasts a request for the offer it chose, and the server confirms with an acknowledgement. The lease includes the IP address, subnet mask, default gateway, DNS servers and lease time, and the client tries to renew with the same server at around half the lease. The catch is that broadcasts stop at the router, and most organisations run a few central DHCP servers rather than one per VLAN. So the gateway interface for each VLAN is configured as a relay agent pointing at the servers. It picks up the client's broadcast, forwards it to the server as unicast, and adds its own interface address, so the server knows which subnet the client is on and picks the matching scope. Common faults are a new VLAN with no relay configured, an exhausted scope, a firewall blocking UDP ports 67 and 68, or a rogue DHCP server, which DHCP snooping on the switches prevents.

Walking into this interview soon? GhostPilot listens to your live call, spots the question the moment it is asked, and puts a structured answer on your screen in real time. Try it on your next mock, or grab a $29 Session Pass, no subscription, for the real thing.

See how it works

Follow-up questions to expect

  • What does DHCP snooping protect against, and how?
  • What happens when a client cannot renew its lease?
  • Why would you use DHCP reservations instead of static addresses?

Related network engineer questions

Your interviewer will ask their own version of this. Paste your actual job description into the free Question Predictor and get the 20 questions that role is most likely to ask, with what each one is really probing.

Predict my questions

Rehearse the hard questions before they are asked

Practise with a live copilot, then walk in ready. A $29 Session Pass gets you through the interview with no subscription and no lock-in.

Get GhostPilot