Sub topic 3
Layer 1: Physical, bits on the medium
This chapter assumes you know what a network, an IP address, and a router are. It also assumes you can run simple commands in a Linux terminal. Layer 1 is the bottom of the OSI model. Every higher layer depends on it.
What Layer 1 does
The Physical layer moves raw bits from one device to another. A bit is a single 0 or 1. Layer 1 does not know about addresses, frames, or packets. It only turns bits into a signal on a medium, such as electricity, light, or radio waves, and turns the signal back into bits at the other end.
Layer 1 defines these things:
- Medium: the material that carries the signal, such as copper cable, fiber, or air.
- Signaling: how a 0 or 1 is represented, for example as a voltage level, a pulse of light, or a radio phase shift.
- Connectors and pinouts: the shape of the plug and which wire carries which signal, such as RJ-45 for Ethernet.
- Timing and speed: how long each bit lasts, which sets the bit rate, such as 1 Gbit/s.
- Topology and direction: whether devices link point to point or share a medium, and whether traffic flows one way at a time (half duplex) or both ways at once (full duplex).
Common media
| Medium | Signal | Typical use | Main limit |
|---|---|---|---|
| Twisted-pair copper (Cat5e, Cat6) | Electrical voltage | Office and home Ethernet | About 100 m per segment |
| Multimode fiber | Light from LEDs or lasers | Within a building or campus | Hundreds of meters |
| Single-mode fiber | Laser light | Long links between sites | Tens of kilometers or more |
| Wi-Fi and other radio | Radio waves | Mobile and wireless access | Shared air, interference |
Copper is cheap and easy to terminate, but it picks up electrical noise and loses signal strength over distance. Fiber is immune to electrical interference and goes much farther, but it costs more and needs different tools. Radio needs no cable, but all devices share the same air, so they must take turns and tolerate interference.
From bits to signals
A device cannot send a bare 0 or 1 and expect the receiver to stay in step. The sender uses a line code, which is a rule for turning bits into signal changes. Many line codes also carry timing information, so the receiver can recover the clock from the signal itself. Without a shared clock, a long run of identical bits would look like silence, and the receiver would lose count.
Higher speeds use more complex encodings. Gigabit Ethernet over copper uses several wire pairs at once and sends multiple voltage levels per symbol. You do not need to memorize these schemes. The point is that bit rate and signal rate are different things, and Layer 1 handles the conversion.
Devices at Layer 1
Devices that work only at Layer 1 repeat or convert signals without reading their contents.
- Cables and connectors carry the signal.
- Repeaters regenerate a weakened signal so it can travel farther.
- Hubs are multiport repeaters. They copy every incoming signal to all other ports, so all connected devices share one collision domain. Switches have largely replaced them.
- Media converters change one medium to another, for example copper to fiber.
- Network interface hardware (the transceiver part of a NIC) does the actual signaling.
Common Layer 1 problems
Most physical faults come from the cable, the connector, or the environment. Typical causes:
- A cable that is unplugged, damaged, or longer than the standard allows.
- A bad connector or a dirty or bent fiber end.
- Electrical interference from nearby power lines or motors.
- A speed or duplex mismatch between two ends, which causes errors and slow transfers.
- Weak or congested radio signal on wireless links.
You can inspect Layer 1 state on Linux. The ip link command shows whether the interface is up and whether it detects a carrier signal. ethtool shows the negotiated speed and duplex.
ip link show eth0 # look for "state UP" and no NO-CARRIER flag
ethtool eth0 # check Speed, Duplex, and "Link detected"
ip -s link show eth0 # error and dropped countersThe flag NO-CARRIER means the interface is enabled but sees no signal. That points to the cable, the port on the other end, or the far device being off. Rising error counters on a link that is up often point to a bad cable or a duplex mismatch.
Check your understanding
Exercise
A server's interface shows NO-CARRIER in ip link show, and you have confirmed the interface is administratively enabled. Which layer should you investigate first, and name two likely causes.
Show answer
Layer 1, the Physical layer. NO-CARRIER means no signal is detected on the medium. Likely causes include an unplugged or damaged cable, a faulty port or transceiver, or the device at the other end being powered off. Check these before examining IP addresses or routing.
Exercise
Why is a hub described as a Layer 1 device, and what is a consequence of using one?
Show answer
A hub only repeats incoming electrical signals to all other ports and does not read addresses or frames. Because every device sees every signal, all ports share one collision domain, so simultaneous transmissions collide and performance drops as more devices are added.