4.4 Your Computer on the Network (Weight: 2)
📘Linux Essentials (LPI 010-160)
1. What is a Network?
A network is a group of computers and devices connected together to share data and resources like files, printers, or internet access.
- Local Area Network (LAN): A network within a building or office. Example: Multiple computers in a small office connected to a shared printer.
- Wide Area Network (WAN): A network that covers a large geographic area, like connecting multiple offices in different cities.
- Internet: The largest WAN, connecting millions of networks globally.
2. Network Devices
These are devices that help computers connect and communicate:
- Router: Directs traffic between different networks. Example: Connects your office LAN to the internet.
- Switch: Connects multiple devices in the same network (LAN) and forwards data to the correct device.
- Access Point (AP): Provides wireless (Wi-Fi) connectivity to devices.
- Network Interface Card (NIC): The hardware inside a computer that allows it to connect to a network.
3. IP Addresses
An IP (Internet Protocol) address is like a digital address that identifies a device on a network.
- IPv4: Most common, 32-bit address, written as four numbers separated by dots (e.g.,
192.168.1.10). - IPv6: Newer, 128-bit address, written in hexadecimal (e.g.,
2001:0db8:85a3::8a2e:0370:7334).
Example in IT: A server in a data center might have IP 192.168.100.50, allowing other servers to connect and access its services.
4. Subnets and Masks
Networks can be divided into smaller parts called subnets.
- Subnet mask: Determines which part of the IP is the network and which part is the device.
Example: IP192.168.1.10with subnet mask255.255.255.0→ Network is192.168.1.0and devices are1–254.
IT example: In a corporate LAN, the subnet ensures departments like HR, IT, and Sales have separate IP ranges.
5. Default Gateway
- The default gateway is the router that connects your network to other networks or the internet.
- Example: Your office LAN computers use the gateway
192.168.1.1to access cloud services.
6. DNS (Domain Name System)
- Converts human-friendly names (like
www.example.com) into IP addresses (93.184.216.34). - IT usage: When employees type
intranet.company.com, DNS resolves it to the internal server IP automatically.
7. Ports and Protocols
- Protocols are rules for how data moves across a network.
- Common protocols in Linux/IT:
| Protocol | Port | Purpose |
|---|---|---|
| HTTP | 80 | Accessing websites |
| HTTPS | 443 | Secure web access |
| SSH | 22 | Remote server login |
| FTP | 21 | File transfer |
| SMTP | 25 | Sending emails |
IT example: A Linux admin uses SSH (port 22) to securely manage a server from home.
8. Network Commands in Linux
Linux has commands to check and manage networks:
ifconfig/ip addr→ Shows your IP addresses and network interfaces.ping <IP>→ Tests if another device is reachable.traceroute <IP>→ Shows the path packets take to reach a device.netstat/ss→ Shows active connections and listening ports.nslookup <domain>ordig <domain>→ Checks DNS resolution.
Example: A sysadmin might run ping 192.168.1.1 to see if the office router is working.
9. Static vs Dynamic IP
- Static IP: Manually assigned; does not change. Used for servers.
- Dynamic IP: Assigned automatically by a DHCP server. Common for desktops and laptops.
IT example: Web servers usually have static IPs so clients always know where to connect.
10. MAC Address
- Every network interface has a MAC (Media Access Control) address, a unique hardware identifier.
- Format:
00:1A:2B:3C:4D:5E - IT use: Network security can restrict access to certain MAC addresses.
11. Firewalls
- A firewall controls incoming and outgoing traffic based on rules.
- Linux often uses
iptablesorfirewalldto secure servers. - Example: Only allow SSH (port 22) and block all other unused ports.
Summary: Key Points for the Exam
- Network basics: LAN, WAN, Internet.
- Devices: Router, switch, access point, NIC.
- IP addressing: IPv4/IPv6, subnet, gateway.
- DNS resolves names to IPs.
- Ports and protocols for communication.
- Linux network commands:
ping,ifconfig/ip,traceroute,netstat,dig/nslookup. - Static vs dynamic IPs.
- MAC address is unique per device.
- Firewalls secure traffic.
These are the essentials for basic networking concepts in the Linux Essentials exam. Understanding them helps you work with Linux servers, desktops, and cloud services efficiently in real IT environments.
