Skip to main content

Command Palette

Search for a command to run...

Cloud Girl Logs — Week 5: Computer Networking Fundamentals & Linux File Permissions

Updated
8 min readView as Markdown
Cloud Girl Logs — Week 5: Computer Networking Fundamentals & Linux File Permissions
A
I am a computer applications student actively preparing for a career in cloud and system administration. My technical journey began with full-stack web development, which gave me a strong understanding of how applications are built from the ground up. Now, I am focused on how they are hosted, secured, and scaled. I am currently pursuing my Red Hat Certified System Administrator (RHCSA) certification and gaining hands-on experience with AWS infrastructure.

Week 5 is different. Instead of AWS, this week is networking — my exam syllabus covers it thoroughly and networking is just as foundational for DevOps as cloud is. Understanding how data actually moves across networks is what makes everything in AWS make sense. So this one doubles as exam prep and career prep at the same time.


Networking

Overview of Networks

A network is simply a collection of devices connected together to share resources and communicate. Every time you open a browser, send a file, or SSH into a server — that's a network doing its job.

Key terms that come up everywhere:

  • Node — any device on a network (PC, server, router, switch)

  • Link — the connection between nodes (wired or wireless)

  • Bandwidth — how much data can be transferred per second

  • Latency — delay between sending and receiving data

  • Protocol — agreed-upon rules for how devices communicate


Circuit Switching vs Packet Switching

Circuit Switching — a dedicated path is established before communication begins and held for the entire duration. Traditional telephone networks. The path is reserved even when no data is being sent — consistent but wasteful.

Packet Switching — data is broken into packets, each routed independently, reassembled at the destination. The internet uses this. Efficient because bandwidth is only used when data is actually sent, but packets can arrive out of order.


Reference Models — OSI vs TCP/IP

OSI Model (7 layers):

Layer Name What it does
7 Application User-facing protocols (HTTP, FTP, SMTP)
6 Presentation Data formatting, encryption, compression
5 Session Managing sessions between applications
4 Transport End-to-end delivery, TCP/UDP
3 Network Routing and IP addressing
2 Data Link Node-to-node delivery, MAC addresses
1 Physical Raw bits over physical medium

TCP/IP Model (4 layers):

Layer Equivalent OSI Layers
Application Application + Presentation + Session
Transport Transport
Internet Network
Network Access Data Link + Physical

OSI is theoretical and used for understanding. TCP/IP is what the internet actually runs on.


Network Topology

  • Bus — all nodes share one cable. Simple but one failure affects everyone

  • Star — all nodes connect to a central switch. Most common in LANs, single point of failure is the center

  • Ring — nodes in a circle, data travels in one direction. One break breaks the network

  • Mesh — every node connects to every other. Highly reliable, very expensive

  • Hybrid — combination, most real networks


Physical Layer

Transmission Media

Guided (wired):

  • Twisted Pair — two copper wires twisted together. Cheapest, used in most ethernet

  • Coaxial Cable — inner conductor with metal shield. Better noise resistance. Used in cable TV

  • Fiber Optic — transmits light pulses. Immune to electromagnetic interference, fastest, longest distances. Expensive

Unguided (wireless):

  • Microwave — line-of-sight transmission between towers

  • Satellite — high latency due to distance

  • Radio Waves — omnidirectional, used in WiFi and mobile networks

  • Infrared — very short range, TV remotes

Transmission Modes

  • Simplex — one direction only. TV broadcast

  • Half Duplex — both directions but not simultaneously. Walkie-talkie

  • Full Duplex — both directions simultaneously. Phone call, most network communication


Flow Control

Stop and Wait — send one frame, wait for ACK, repeat. Simple but slow.

Sliding Window — send multiple frames before needing an ACK. The window is how many unacknowledged frames can be in flight at once. Much more efficient.

Error Control — ARQ Protocols

Stop and Wait ARQ — send one, wait for ACK. If ACK doesn't arrive, resend.

Go-Back-N ARQ — if one frame is lost, retransmit that frame AND all frames sent after it, even correctly received ones. Simple receiver, wasteful retransmission.

Selective Reject ARQ — only the specific damaged frame is retransmitted. More efficient, but receiver must buffer out-of-order frames.

Error Detection

Parity Check — adds one bit so total 1s are always even or odd. Detects single-bit errors only.

CRC (Cyclic Redundancy Check) — divides data by a polynomial, appends the remainder. Much stronger than parity. Used in Ethernet.

Checksum — sum of all data segments. Simple, used in UDP and IP headers.

Encoding Schemes

  • NRZ — high voltage = 1, low voltage = 0. Simple but synchronization problems with long runs

  • Manchester — transition in the middle of each bit period. Self-synchronizing, used in Ethernet

  • 4B/5B — maps 4-bit data to 5-bit codes to ensure synchronization transitions


Network Layer

IPv4 and IPv6

IPv4 — 32-bit addresses (192.168.1.1). About 4.3 billion unique addresses. We've run out.

IPv6 — 128-bit addresses in hexadecimal. 340 undecillion addresses. Built-in security, no broadcast.

Ethernet and CSMA/CD

CSMA/CD is how early shared Ethernet handled collisions:

  1. Listen before transmitting — if busy, wait

  2. If free, transmit

  3. If collision detected, stop, send jam signal, wait random backoff, retry

Modern switched Ethernet is full duplex — switches eliminate collisions entirely.

Routing

Distance Vector — routers tell neighbors what destinations they know and the cost. Simple, slow to converge. Used by RIP.

Link State — each router broadcasts its link states to the whole network. Everyone builds a complete map, runs Dijkstra's shortest path. Faster convergence. Used by OSPF.


Transport and Application Layers

TCP vs UDP

TCP:

  • Connection-oriented — three-way handshake (SYN, SYN-ACK, ACK)

  • Reliable, ordered delivery

  • Flow and congestion control

  • Use for: HTTP, email, file transfer

UDP:

  • Connectionless — just sends packets

  • No reliability or ordering guarantees

  • Much faster, lower overhead

  • Use for: DNS, video streaming, gaming

Application Layer Protocols

Protocol Port Use
HTTP 80 Web browsing
HTTPS 443 Secure web
FTP 20/21 File transfer
SMTP 25 Sending email
POP3 110 Receiving email
DNS 53 Domain resolution
SNMP 161 Network management

DNS, Firewalls, Gateways

DNS — translates domain names to IPs through a hierarchy: root servers, TLD servers, authoritative servers.

Firewall — filters traffic based on rules. Stateless checks each packet independently, stateful tracks connection state.

Gateway — connects networks using different protocols. Your home router is a gateway between your LAN and the internet.


Linux Side

Group Management

Groups let you apply permissions to multiple users at once.

groupadd groupname              # create group
groupmod -n newname oldname     # rename group
groupdel groupname              # delete group
gpasswd -a username groupname   # add user to group
gpasswd -d username groupname   # remove user from group
groups username                 # see all groups a user belongs to
cat /etc/group                  # all group info stored here

Every user has one primary group (set at creation) and can have many supplementary groups. Files created by a user get assigned to their primary group by default.

id username    # shows UID, primary GID, all supplementary groups

File Permissions

Every file has three permission sets — owner, group, others.

ls -l filename
# -rwxr-xr-- 1 anousheh devops 1024 Jul 10 script.sh

Breaking down -rwxr-xr--:

  • First character: file type (- = file, d = directory, l = symlink)

  • Next 3: owner permissions (rwx)

  • Next 3: group permissions (r-x)

  • Last 3: others permissions (r--)

Permission File Directory
read (r) View contents List contents
write (w) Modify file Create/delete files inside
execute (x) Run as program Enter the directory

chmod

Symbolic mode:

chmod u+x file       # add execute for owner
chmod g-w file       # remove write for group
chmod o=r file       # set others to read only
chmod a+r file       # add read for everyone

Octal mode: read = 4, write = 2, execute = 1

chmod 755 file    # rwxr-xr-x  (standard for scripts)
chmod 644 file    # rw-r--r--  (standard for files)
chmod 700 file    # rwx------  (owner only, nothing for anyone else)
chmod 777 file    # rwxrwxrwx  (everyone full access — avoid this)

chown

chown username file              # change owner
chown username:groupname file    # change owner and group
chown :groupname file            # change group only
chown -R username directory/     # change recursively

Only root can change file ownership. A regular user can change a file's group but only to a group they already belong to.


What's next?

Next week will mostly focus on revision alongside a few new AWS topics. After a month of uni exams, I have a lot of ground to cover to get back up to speed.

Full notes on GitHub: https://github.com/anousheh-hussain/cloud-devops-notes
(Will updates the notes soon. Sorry for the delay as I got really busy with exams.)