Plug in and it just works
A new laptop joins the college Wi-Fi. Nobody types an address. Nobody types a server name. A minute later it can open the intranet.
Two services made that happen. Each does one small job.
Key words
| Word | What it means |
|---|---|
| Network | computers joined together so they can share data |
| IP address | a number that identifies a device on a network |
| DHCP | a service that hands out addresses and settings automatically |
| Lease | the time a device may keep the address it was given |
| DNS | a service that turns a name into an IP address |
| Hostname | the name of a device, such as fileserver |
| Router | a device that passes data between networks |
| Server | a computer that provides a service to others |
The cells students fill in are left blank in this preview.
By the end of this lesson
Note
I can explain what DHCP and DNS do in a domain, and check a simple configuration for each.
Starter
Have a go
Starter
3 questionsYour answers are marked here and are not kept. A college account keeps every student’s marks.
DHCP gives each device what it needs
A new device has no address. It shouts, "Is there a DHCP server?" The server answers with an IP address for a set time, called a lease. It also tells the device the router to use and the DNS server to ask.
So one service sets up a whole network, and nobody types a number by hand.
What a DHCP server hands out
| Item | What it is for | Example |
|---|---|---|
| IP address | Identifies this device | 10.0.0.101 |
| Router | The way out to other networks | 10.0.0.1 |
| DNS server | Where to ask for names | 10.0.0.2 |
| Lease time | How long to keep the address | 12 hours |
The cells students fill in are left blank in this preview.
Write a small DHCP setting
printf 'dhcp-range=10.0.0.100,10.0.0.150,12h\ndhcp-option=option:router,10.0.0.1\ndhcp-option=option:dns-server,10.0.0.2\n' > dhcp.conf && cat dhcp.confA command for the lesson’s lab terminal. It is shown here and not run.
Check that the setting is correct
dnsmasq --test --conf-file=dhcp.confA command for the lesson’s lab terminal. It is shown here and not run.
Check: DHCP
Have a go
Check: DHCP
4 questionsYour answers are marked here and are not kept. A college account keeps every student’s marks.