Understanding Operating Systems and the Internet

Sep 21, 2024

Computer Science 1JC3: Introduction to Computational Thinking - Lecture on Operating Systems and the Internet

Files

  • Definition: A file is a finite sequence of data stored on a persistent storage device.
    • Data types: Characters or bits (values like true/false, yes/no, 0/1)
  • Types of Files:
    • Text Files: ASCII or Unicode
    • Binary Files
    • File names often have extensions (e.g., .exe, .txt), but extensions can be incorrect or unnecessary.
  • Importance:
    • Files allow sharing of data between programs, users, and storage devices.
    • Can be very large, sometimes only partially loaded into memory (e.g., video files).
  • Functionality:
    • Used for input and output in programs, especially with large data amounts.

File Systems

  • Set up by the operating system, organized as a tree with files and directories (also called folders).
  • Directories: Hold files or other directories.
  • Path Names:
    • Used to access files and directories.
    • Top level is "root" (e.g., in UNIX starts with a slash /).
    • Full and relative path names.
  • File Operations: Creation, deletion, moving, copying, renaming, modification.

Processes

  • Definition: An executing application program.
    • A program becomes a process when executed.
    • Multiple processes can execute the same program.
  • Execution:
    • Processes run on CPU cores; modern computers have multiple cores.
    • Utilize time-sharing to run more processes than there are cores.
    • Time Slice: Short period of CPU time allocated to a process.
  • Process States:
    • Executing, blocked (waiting for an event), ready (waiting for CPU), finished.
  • Virtual Address Space:
    • Processes are given a virtual address space for memory, mapped to RAM or disk storage depending on execution.

Program Execution

  • Parallel Execution: Appears parallel due to rapid switching of processes, but physically one process at a time on a single CPU.

Internet and Networks

  • Physical Networks:
    • Computers exchange digital information via a physical medium.
    • Connected through network interfaces.
    • Types include wired, wireless, local area networks (LAN), wide area networks (WAN).
    • Topologies: Bus, ring, star, point-to-point.
    • Technologies: Ethernet, Wi-Fi, ATM, FDDI.

Internet Architecture

  • Problem: Different physical networks needing communication.
  • Solution: Universal virtual network built on top of physical networks.
    • Governed by TCP/IP protocol suite.
    • Internet architecture consists of interconnected physical networks via routers.
  • Structure:
    • Two layers: heterogeneous physical networks and a homogeneous virtual network.
    • Addresses:
      • Physical network layer uses physical addresses.
      • Virtual network layer uses IP addresses.
      • Mapping of physical to virtual addresses is necessary.

Next Steps

  • Next lecture will cover protocols that enable Internet functionality.