An operating system (OS) is the system software that manages the hardware and lets other programs run. It sits between the user and the machine. Learn what it does, the types, how a program becomes a process, and the tools and commands you will see in questions.
What an OS does
Function
Meaning
Process management
Decides which program gets the CPU and when
Memory management
Tracks free and used RAM and gives it to programs
File management
Creates, names, stores and protects files and folders
Device management
Controls input, output and storage devices through drivers
Security
Passwords, user accounts and permissions
User interface
Command-line (CLI) or graphical (GUI)
Layers: hardware, then operating system, then applications, then the user.
Types of operating system
Batch: similar jobs are grouped and run one after another with no user interaction.
Multiprogramming: several programs sit in memory so the CPU is never idle.
Time-sharing (multitasking): each user or program gets a short CPU time slice in turn.
Multiprocessing: two or more CPUs work together.
Real-time: the answer must arrive within a fixed deadline (aircraft control, medical equipment).
Distributed: many networked computers behave like one system.
Network OS: a server shares files and printers with client computers.
Embedded: built into a device with a fixed job (ATM, washing machine, smart TV).
Mobile: Android and iOS.
Single-user, single-task: MS-DOS. Multi-user: UNIX and Linux.
Process and memory
A program is stored instructions; a process is a program being executed. A thread is a smaller unit inside a process.
Process states: new, ready, running, waiting (blocked), terminated.
Scheduling: first come first served, shortest job first, round robin (a fixed time slice for each in turn).
Deadlock: processes wait in a circle for resources held by each other, so none can move.
Virtual memory: part of the disk used as extra RAM (page file, swap space). Paging divides memory into equal pages and frames. Thrashing is too much swapping, which makes the system slow.
Spooling: print jobs wait in a queue on disk (Simultaneous Peripheral Operations On-Line).
Kernel and shell: the kernel is the core controlling memory, processes and devices; the shell takes the user's commands and passes them to the kernel.
Booting
Cold boot starts from power-off; warm boot is a restart. Order: power-on self-test (UEFI firmware), boot loader, OS loaded into RAM. Dual boot keeps two operating systems and asks which to start. Safe Mode starts Windows with basic drivers only to fix problems.
Linux was created by Linus Torvalds (1991). It is open source (GNU GPL). A distribution such as Ubuntu bundles the kernel with tools. Android is built on a modified Linux kernel.
The Linux file system starts at the root /; ~ is the home directory; common file system: ext4.
Permissions: r read, w write, x execute.
Linux
DOS / Command Prompt
Job
ls
dir
List files
cd
cd
Change directory
pwd
Show current directory
mkdir
mkdir
Make directory
cp
copy
Copy
mv
ren / move
Move or rename
rm
del
Remove file
clear
cls
Clear screen
chmod
Change permissions
ps, kill
List and end processes
cat, grep
type, find
Show text, search text
man
help
Manual
DOS commands in detail
DOS commands: the internal commands built into COMMAND.COM and the external commands that are separate program files, with wildcards and DIR switches
Internal command: built into COMMAND.COM and always in memory (DIR, COPY, DEL, REN, TYPE, CLS, MD, CD, RD, DATE, TIME, VER, VOL, PATH, PROMPT). External command: a separate file on the disk (FORMAT, CHKDSK, XCOPY, DISKCOPY, FDISK, ATTRIB, TREE, LABEL, SYS, DOSKEY, EDIT, MEM). External commands need the file to be found on the PATH.
Wildcards: `*` any number of characters, `?` exactly one. `DIR *.TXT` lists the text files; `DEL .` asks "Are you sure (Y/N)?" and deletes all files of the directory.
DIR switches: `/P` one screen at a time, `/W` wide list, `/S` includes the subdirectories. Redirection: `DIR > LIST.TXT` sends the listing to a file; `DIR | MORE` pages it.
Files and directories: `COPY A.TXT B.TXT` keeps A.TXT. `COPY CON FILE.TXT` makes a file from the keyboard (end with Ctrl+Z). `MD STUDY\NOTES` makes NOTES inside STUDY. `RD` removes only an empty directory. `CD ..` goes up one level; `CD` alone shows the current directory. `D:` changes the current drive.
Disks: `FORMAT` prepares a disk; `FORMAT A: /S` also adds the system files; `SYS A:` adds them to a formatted disk. `FDISK` partitions a hard disk. `DISKCOPY` copies a whole floppy; `XCOPY` copies directories too. `LABEL` sets the volume label that `VOL` shows. `ATTRIB +R FILE` makes a file read-only. `DOSKEY` recalls typed commands.
Booting and the DOS start-up files
The DOS boot order: power on, the start-up self-test, IO.SYS, MSDOS.SYS, CONFIG.SYS, COMMAND.COM, AUTOEXEC.BAT and the prompt, with cold boot and warm boot
Cold boot: start from switched off (power button). Warm boot: restart while on (Restart or Ctrl+Alt+Del), with no power cut.
Order: the start-up self-test (POST), IO.SYS, MSDOS.SYS (hidden system files), CONFIG.SYS (device drivers and settings), COMMAND.COM (command interpreter), AUTOEXEC.BAT (commands run at start-up), then the prompt `C:\>`.
What are a file and a folder?
A file is a named collection of data stored on a disk, such as a document, a picture or a program. A folder (directory) is a container that holds files and other folders so that they stay organised.
The Windows desktop, Control Panel and files
Start menu: programs, settings and the Power button (Shut down, Restart, Sleep). Wallpaper is the desktop background. Right-click opens the context menu. Restore Down returns a maximised window to its smaller size. Lock the taskbar stops it from being moved.
Control Panel / Settings:Programs and Features uninstalls programs; Display sets resolution; Personalization sets theme, background and lock screen; Power Options sets sleep; Date and Time; Devices and Printers; Windows Update installs fixes. A Standard user needs an administrator to install software or change system settings.
Recycle Bin:Restore returns a file to its folder. Shift+Delete deletes for good. Files deleted from a pen drive or network drive skip the Recycle Bin.
File Explorer:This PC shows the drives. Properties (Alt+Enter) shows type, size, dates and attributes. A Hidden file is shown only if hidden items are turned on. View > File name extensions shows .docx and .jpg. Libraries gather files of several folders. Ctrl+Shift+N makes a new folder. The Details view shows name, date, type and size. A zipped folder is made with Send to > Compressed folder.
FAT32 cannot hold a single file bigger than 4 GB; NTFS and exFAT can.
Windows and Mac shortcut keys, macOS
The same jobs in Windows and macOS with their shortcut keys
macOS (by Apple, UNIX-based): Finder is the file manager, the Dock holds app icons, Spotlight (Command+Space) searches, Launchpad shows apps in a grid, Mission Control shows windows and desktops, Time Machine backs up, the Trash holds deleted files, Terminal types UNIX commands, APFS is the file system. Command+Q quits an app; Command+Tab switches apps.
Android apps come as .apk files, usually from the Google Play Store.
Utilities and safety
Device driver: lets the OS talk to a device. Plug and Play: the OS finds and sets up a new device itself.
Antivirus removes malware; a firewall controls network traffic. A worm spreads by itself; a virus needs a host file.
Patch: small fix. Update: improvement. Keep the OS updated; never share the administrator password.
Hibernate saves work to disk and powers off; Sleep keeps it in RAM at low power.
Removing a USB drive: use Safely Remove Hardware first.
Quick tricks
1. Kernel is inside, shell is outside. 2. Real-time means deadline; time-sharing means fair turns. 3. ls is Linux, dir is DOS; rm is Linux, del is DOS. 4. cut moves, copy keeps the original. 5. Format erases a disk; restart does not.
Operating Systems Set 01
25 questions
Operating Systems Set 02
25 questions
Operating Systems Set 03
25 questions
Operating Systems Set 04
25 questions
Operating Systems Set 05
25 questions
Operating Systems Set 06
25 questions
Operating Systems Set 07
25 questions
Operating Systems Set 08
25 questions
Operating Systems Set 09
25 questions
Sample questions from this set
A preview with answers and explanations. Start the full set above for all questions, instant scoring and negative marking.
1.An operating system is best described as ______.
A.a program used only to type and print documents
B.a chip fitted on the motherboard to store the BIOS
C.system software that manages the hardware and runs other programs✓
D.a device that connects the computer to the Internet
Explanation: Concept: An operating system (OS) is system software that controls the hardware and provides services to other programs.
Why: Typing and printing are jobs of application software; the BIOS chip and an Internet device are hardware.
Answer: system software that manages the hardware and runs other programs → option C
Trap: Because the OS is stored on a disk, some learners call it a hardware part. It is software.
2.Which of the following is an operating system?
A.Linux✓
B.Google Chrome
C.Microsoft Excel
D.Adobe Photoshop
Explanation: Concept: Linux is an operating system; the other three are application programs that run on an operating system.
Why: Chrome browses the web, Excel handles spreadsheets and Photoshop edits pictures.
Answer: Linux → option A
Trap: Chrome is installed like a system tool but it is still an application, not an OS.
3.Which of the following is NOT an operating system?
A.Windows
B.macOS
C.Android
D.Microsoft Word✓
Explanation: Concept: Microsoft Word is a word processor, which is application software.
Why: Windows, macOS and Android all manage hardware and run other programs.
Answer: Microsoft Word → option D
Trap: Word and Windows are both made by Microsoft, so the names can look alike, but only Windows is an OS.