IT Course Directory: VMware, Linux, Networking, and Raspberry Pi

Raspberry Pi Beginner Course: Setup, Raspberry Pi OS, Linux Commands, Multimedia, and Remote Access

Learn Raspberry Pi setup from scratch: install Raspberry Pi OS, configure networking, use Linux commands and APT, work with cameras and multimedia, and connect remotely with SSH and SFTP.

Course overview

This beginner course takes you from an unused Raspberry Pi to a working Linux computer. You will prepare boot storage, install Raspberry Pi OS, configure the system, connect it to a network, use the terminal, install software, work with multimedia and cameras, and administer the Pi remotely.

No Linux or programming experience is required. You need basic computer skills, a Raspberry Pi, a compatible power supply, boot storage, and an internet connection.

1. What is a Raspberry Pi?

A Raspberry Pi is a compact single-board computer: the processor, memory, connectors, and supporting electronics are mounted on one circuit board. It can run an operating system, applications, servers, scripts, and hardware projects much like a desktop computer, but in a small and energy-efficient format.

Common uses include learning Linux and programming, teaching computer science, playing local media, building camera projects, controlling electronics through GPIO pins, automating tasks, hosting small services, and experimenting with sensors and networks.

Main board elements

  • Processor: executes operating-system and application instructions.
  • Memory: working space used by running programs. It is different from storage.
  • GPIO header: general-purpose input/output pins used with LEDs, buttons, sensors, and other electronics.
  • USB ports: connect keyboards, mice, storage devices, cameras, controllers, and other peripherals.
  • Video output: connects to a monitor or television. The connector and supported resolutions depend on the model.
  • Audio output: may be provided through a combined audio/video connector, HDMI, USB, Bluetooth, or another model-specific method.
  • Storage interface: commonly a microSD slot; some models also support alternative boot devices.
  • Ethernet and wireless networking: provide wired or Wi-Fi connectivity when available.
  • Camera and display connectors: ribbon-cable interfaces for compatible modules. Their connector type and support vary by generation.
  • Power input: supplies regulated power through the connector specified for the model.

Do not assume that a guide for one board applies exactly to another. Port layout, memory size, boot firmware, wireless features, camera support, configuration menus, and power requirements vary by generation.

Setup checklist

ItemPurposeCompatibility considerationsBeginner recommendation
Power supplyProvides stable powerMust match the model and connectorUse a reputable, model-compatible supply
microSD cardStores the operating system and dataCapacity, speed, and reliability matterUse a quality card with enough space for your projects
Display or headless methodProvides first accessDisplay connectors and cables varyUse a monitor, or preconfigure SSH for headless setup
Keyboard and mouseSupports local desktop or console useUSB and Bluetooth support varyUse simple USB devices for initial setup
Network connectionProvides updates and remote accessEthernet and Wi-Fi features varyUse Ethernet during troubleshooting when possible
Case and coolingProtects the board and manages heatMust fit the exact modelUse a ventilated case appropriate to the workload
Camera moduleCaptures images and videoConnector, adapter, and software support varyCheck model and operating-system compatibility first

Never remove power while the Pi is writing to storage. Use the desktop shutdown control or run sudo shutdown -h now. Abrupt power loss can corrupt the filesystem and damage files. Wait until shutdown has completed before disconnecting power.

2. Prepare and install Raspberry Pi OS

The operating system is normally stored on a microSD card. A disk image is a prepared copy of an operating system and its partitions that an imaging program writes to bootable storage. Back up any files on the card before imaging: writing an image normally erases existing contents.

Choose an operating system

OptionBest forDesktop includedArchitecture considerationsNotes
Raspberry Pi OS DesktopBeginners, graphical applications, multimediaYesChoose 32-bit or 64-bit according to model and software needsBest starting point for this course
Raspberry Pi OS LiteServers, scripting, headless systemsNoUses fewer resources; confirm application supportAdministration is primarily through SSH and the shell
32-bit Raspberry Pi OSBroad compatibility with older softwareMay be included in desktop or Lite editionsCan address less memory per process in some situationsUseful when a package or application requires 32-bit support
64-bit Raspberry Pi OSModern models and 64-bit applicationsMay be included in desktop or Lite editionsRequires a compatible processor and softwareCan improve compatibility with some modern workloads
Specialized distributionMedia centers, security tools, or dedicated appliancesDepends on distributionHardware and package support differUse when its focused purpose outweighs general flexibility

Raspberry Pi OS is the current name of the Raspberry Pi-focused Linux distribution formerly called Raspbian. Older tutorials may use the old name or mention packages and commands from an earlier release. Check commands against the release installed on your Pi rather than assuming historical instructions are still valid.

Older termCurrent term or contextWhat learners should do
RaspbianRaspberry Pi OSInterpret it as the older operating-system name when reading older documentation
raspistill and raspividlibcamera and rpicam toolsUse the camera tools supplied by the installed release
Legacy camera enable menuModern camera stack detectionDo not expect a legacy camera switch on every current system

Write the image

  1. Back up the microSD card if it contains anything important.
  2. Install and open Raspberry Pi Imager or an equivalent imaging utility on another computer.
  3. Select the desired Raspberry Pi OS edition.
  4. Select the correct removable storage device. Verify its identity and capacity carefully.
  5. When supported, open the customization settings before writing. Set a unique username, strong password, hostname, locale, time zone, keyboard layout, Wi-Fi country, Wi-Fi credentials, and SSH enablement.
  6. Start the write operation and allow the tool to create the required partitions.
  7. Let the tool validate the write. Do not remove the card until validation and writing have finished.
  8. Insert the card into the powered-off Pi, connect the display and input devices if using them, and apply power.

Imaging tools generally format or erase the selected card and create the partitions needed by the operating system. You usually do not need to manually create Linux partitions first. If you manually erase a card, use the operating system's disk utility carefully and select the removable device, not your computer's internal drive.

First boot and verification

The first boot may resize storage, generate system files, and apply regional or network settings. A desktop edition presents a graphical login or desktop; Lite normally presents a console login. Confirm the keyboard layout, hostname, date and time, network connection, storage capacity, and attached USB or display hardware.

After connecting to the internet, update the system:

sudo apt update
sudo apt full-upgrade

apt update downloads current package metadata. It does not upgrade installed programs. apt full-upgrade installs available upgrades and may handle dependency changes. Use a stable power supply, close unnecessary applications, and allow the process to finish.

3. Raspberry Pi OS desktop, networking, and software

The desktop typically includes an application menu, taskbar, network indicator, file manager, terminal, and shutdown controls. Use the graphical interface for visual file management and applications. Use the command line for repeatable administration, remote work, diagnostics, and automation.

Connect to the network

For Ethernet, connect the cable before or during boot. For Wi-Fi, choose the network from the network menu, enter its credentials, and ensure the correct Wi-Fi country is configured. A local IP address identifies the Pi inside your home or office network. A public IP address identifies a connection on the wider internet; it is not normally the address you should expose for beginner remote administration.

ip addr
hostname -I
ip route
ping -c 4 example.local

ip addr shows interfaces and assigned addresses. hostname -I gives the Pi's local addresses. ip route shows routes and the default gateway. ping tests reachability, although some networks block it. DHCP commonly assigns local addresses automatically, so an address can change after reconnecting or rebooting. Use the hostname, a router client list, or a reserved DHCP lease when a stable local identity is useful.

Install software safely

A repository is a configured source of packages. Package metadata describes available versions. APT resolves dependencies, which are other libraries or programs required by a package.

GoalAPT commandGraphical alternativeExpected result
Refresh package listssudo apt updatePackage manager refreshAvailable-package metadata is current
Upgrade installed softwaresudo apt full-upgradeMark upgrades and applyInstalled packages are upgraded
Searchapt search keywordSearch software toolMatching packages are listed
Inspectapt show packagePackage propertiesDescription, version, and dependencies are shown
Installsudo apt install packageMark for installationPackage and required dependencies are installed
Removesudo apt remove packageMark for removalPackage is removed while some configuration may remain
Remove unused dependenciessudo apt autoremoveRemove automatically installed itemsUnneeded dependencies are removed

Graphical software stores differ between Raspberry Pi OS releases and editions, so they are not the only installation method. A tool such as Synaptic, where available, lets you search, inspect, mark packages for installation or removal, and apply changes. Manually installed software may use a downloaded package, source code, or its own installer; understand its origin, update process, and compatibility before using it. Avoid adding unrelated third-party repositories casually.

4. System configuration with raspi-config

raspi-config is a terminal-based configuration utility. Its menu names and available options depend on the operating-system release and Raspberry Pi model. Launch it with administrator privileges:

sudo raspi-config

Use the arrow keys and prompts, record each change, and reboot when requested. Change one setting at a time when troubleshooting so you know which change affected the result.

Setting areaPurposeWhen to change itReboot requiredVersion or model caveat
Password and system optionsChange credentials and basic system behaviorImmediately after installation or when access changesUsually not for a password changeAccount and menu names vary
Boot behaviorSelect console or desktop and automatic login behaviorWhen switching between headless and graphical useOftenChoices depend on installed edition
LocalizationSet locale, time zone, keyboard, and Wi-Fi countryWhen regional settings are incorrectSometimesWi-Fi country affects regulatory operation
HostnameGives the device a network-readable nameBefore using several Pis or remote accessOftenName resolution depends on the local network
InterfacesEnable SSH and applicable hardware interfacesBefore headless administration or camera workOftenModern cameras may not use a legacy enable item
Filesystem expansionUses remaining storage capacityWhen df -h shows less space than expectedYesMany current images expand automatically
Memory or performanceAdjust applicable GPU memory or performance settingsOnly for a specific workloadUsuallyOptions differ by model and modern memory design

Use strong, unique passwords and avoid relying on an assumed default account. A hostname helps local discovery but is not a security control. If storage is smaller than expected, check df -h, use the applicable filesystem-expansion option, reboot, and check again.

GPU memory split means reserving part of system memory for graphics-related work on applicable systems. It may matter for a graphical or camera workload, but modern models and software can manage memory differently. Do not change it without a reason.

Overclocking runs hardware above standard clock settings. Treat it as optional advanced work: use model-specific support, adequate cooling and power, test stability, monitor temperatures, back up data, and understand the possibility of crashes, corruption, and support or warranty implications. Reverse the setting if the Pi becomes unreliable.

5. Optional discovery and registration services

Some community services have allowed users to register devices or projects on a public map. This is optional and is not part of installing or operating Raspberry Pi OS.

Before sharing, consider whether the device name, approximate location, IP-related information, project description, or photographs could identify your home, school, workplace, or network. Share only non-sensitive information, use a project label rather than a personal address, and skip registration if the privacy benefit is unclear.

6. Multimedia projects

Audio and video

Audio can come from local files through HDMI, a combined audio/video connector where available, USB, or Bluetooth. Select the intended output device in the desktop sound controls or the relevant player settings. Check volume, mute state, file permissions, supported formats, and whether the chosen player has the required codec support.

Video performance depends on the Pi model, codec, resolution, frame rate, display connection, storage speed, and player configuration. If playback is choppy, reduce resolution or bitrate, use a suitable codec, check storage capacity, and inspect heat or CPU load.

Games and emulation are graphical workloads. They require compatible software, controller configuration, adequate storage, and realistic expectations about the model's performance. Acquire games and ROMs responsibly and use software you are legally permitted to use.

Camera capture

A compatible camera module connects through a camera ribbon connector, while a USB camera uses a USB port. Power down before inserting or reseating a ribbon cable. Check cable orientation, connector seating, focus, lighting, permissions, and available storage.

Current Raspberry Pi OS releases commonly use the libcamera stack and rpicam command names. Older systems may use raspistill and raspivid. These are legacy commands, not interchangeable assumptions.

TaskCurrent tool familyLegacy tool familyCompatibility note
Test camerarpicam-helloOlder preview toolsUse the command supplied by the installed release
Still imagerpicam-stillraspistillOptions and availability differ
Videorpicam-vidraspividUse current documentation for current camera stacks
rpicam-hello
rpicam-still -o image.jpg
rpicam-vid -o video.h264 -t 10000

Timestamped image script

Create a file named capture-photo.sh with a text editor:

#!/bin/bash
mkdir -p "$HOME/photos"
rpicam-still -o "$HOME/photos/photo-$(date +%Y%m%d-%H%M%S).jpg"

Make it executable and run it:

chmod +x capture-photo.sh
./capture-photo.sh

The command substitution inserts the current date and time into the filename. If capture fails, check the camera connection, tool family, permissions, lighting, and whether another process is using the camera.

Slow motion

Slow motion is created by capturing more frames per second than the playback frame rate. For example, recording at 90 frames per second and presenting those frames at 30 frames per second makes ten seconds of real action occupy approximately thirty seconds of playback, assuming the player handles the timing correctly.

rpicam-vid --framerate 90 -o highfps.h264 -t 10000

High frame rates can require lower resolution, faster storage, more light, and more processing. Playback software may need explicit frame-rate handling.

Motion detection

Motion detection compares successive camera frames and triggers an action when visual change exceeds a threshold. A basic workflow needs a camera, detection software or script logic, an output directory, and controlled tests.

  1. Place the camera so the intended test area is visible and well lit.
  2. Capture a baseline frame or allow the detection program to establish one.
  3. Compare new frames with the baseline or previous frame.
  4. Trigger an image or video when the difference exceeds the chosen threshold.
  5. Store timestamped output and review false positives.
  6. Test changes in lighting, shadows, moving plants, and camera vibration.

Obtain consent before recording people, avoid private spaces, protect captured files, and delete footage that is no longer needed.

7. Terminal fundamentals

The terminal is an application for entering text commands. A shell interprets those commands. A typical command has a program name, options, and arguments. A path may be absolute, beginning at the filesystem root such as /home/user/project, or relative, interpreted from the current working directory.

  • pwd prints the current directory.
  • ls -la lists files, including hidden files, with details.
  • cd directory changes directory; cd .. moves to the parent.
  • mkdir directory creates a directory; mkdir -p path/to/directory creates missing parents.
  • touch file creates an empty file or updates its timestamp.
  • cat file prints a small file; less file views a larger file page by page.
  • nano file opens a simple text editor.
  • cp source destination copies; mv source destination moves or renames.
  • rm file deletes a file. rm -r directory recursively deletes a directory and needs careful path verification.

Spaces separate arguments, so quote filenames containing spaces: cat "my notes.txt". Wildcards such as *.log match multiple names before the command runs. Pipes send one command's output to another, while redirection writes output to a file:

grep -Rin 'error' "$HOME/project" | less
sort -n scores.txt > sorted-scores.txt

Use the up-arrow for command history. Use man command for built-in manuals and command --help for a concise option summary:

man find
find --help

sudo runs a command with administrator privileges. Use it only when required. It does not make a dangerous command safe; it increases the damage a mistake can cause.

Text processing and file discovery

sort names.txt
sort -n numbers.txt
sort -r names.txt
sort -u names.txt
grep 'pattern' file.txt
grep -Rin 'pattern' project/
find "$HOME" -name '*.jpg'
find /var/log -type f
tail logfile
tail -f logfile

sort orders lines alphabetically by default; -n uses numeric comparison, -r reverses the order, and -u removes duplicate output lines. grep searches text; -R searches recursively, -i ignores case, and -n shows line numbers. find can filter by name, type, path, and modification attributes. locate, where installed, is faster for name searches but depends on a database that may not include newly created files. tail -f follows a file as new lines are added, which is useful for logs.

Processes, archives, and storage

A process is a running instance of a program. Common fields include PID, user, CPU percentage, memory percentage, and command.

ps aux
top
htop

ps aux provides a snapshot. top provides an interactive view; htop is a more visual alternative that may need installation.

A tar archive bundles files. Compression reduces its size but is separate from bundling:

tar -czf project.tar.gz project/
tar -tf project.tar.gz
tar -xzf project.tar.gz

The first command creates a gzip-compressed archive, the second lists its contents without extracting, and the third extracts it. Inspect an archive before extracting it into an important directory.

df -h
du -sh "$HOME/project"
du -ah "$HOME/project" | sort -h

df -h reports filesystem capacity and free space. du reports space used by directories and files. A disk can have free bytes but run out of inodes, which limit the number of filesystem objects; investigate inode usage if many tiny files cause unexpected “no space” errors.

8. SSH and SFTP remote access

Headless operation means using the Pi without a permanently attached monitor, keyboard, or mouse. It is useful for servers, cameras, and installations in inconvenient locations.

SSH is an encrypted protocol for remote command-line access. Enable it during imaging, through the operating-system settings, or with raspi-config. On a running system, the service can be enabled and checked with:

sudo systemctl enable --now ssh
sudo systemctl status ssh
ssh username@hostname-or-ip

Find the Pi using its configured hostname, your router's connected-client list, or local network discovery. From Linux, macOS, and modern Windows systems, the ssh command is commonly available. Windows can also use a graphical SSH client.

On first connection, SSH displays a host-key fingerprint. Verify that you are connecting to the intended device before accepting it. Password authentication is convenient for initial access, but use a unique username and strong password, then prefer SSH keys for regular administration. If a host-key warning appears after re-imaging, do not blindly bypass it: confirm that the device was intentionally re-imaged before removing or replacing the old key.

SFTP is secure file transfer over SSH. It is not the same as FTP: SFTP uses the SSH service and encrypted connection, while traditional FTP is a separate protocol with different security properties.

sftp username@hostname-or-ip
put localfile
get remotefile
scp localfile username@hostname-or-ip:/home/username/

In an SFTP session, select the correct local and remote paths, upload to the user's home directory first, and then move files locally if administrative ownership is required. A successful login does not grant permission to write protected directories. Check ownership, permissions, and free space; SFTP itself does not elevate with sudo.

Keep SSH on the local network when possible. Exposing SSH directly to the public internet is unsafe without strong controls. Prefer local access or a VPN-based connection; if public remote administration is unavoidable, use key authentication, updates, firewall and access controls, rate limiting, monitoring, and a carefully reviewed configuration.

9. Troubleshooting guide

SymptomLikely causesDiagnostic stepsResolution
Pi does not bootBad image, failing card, insufficient power, display issueCheck indicators and supply; re-image and validate; check display input and cableUse compatible power and quality storage; verify model-specific display requirements
No Wi-FiWrong credentials or country, weak signal, unsupported band, captive portalCheck regional setting and ip addr; test EthernetCorrect credentials, move closer, use a supported band or Ethernet
APT errorsNo internet, stale metadata, interrupted update, wrong package, low spaceRun sudo apt update; check df -h; read the exact errorRestore connectivity, free space, and avoid unrelated repositories
Filesystem too smallImage did not expandCheck df -hUse applicable expansion setting in raspi-config, reboot, and verify
SSH failsDisabled service, wrong name or IP, different network, wrong account, changed keyCheck service, router client list, local IP, username, and host-key warningEnable SSH, use the configured account, and investigate key changes safely
SFTP upload failsProtected path, wrong path, full disk, permission mismatchTry the home directory; check space and permissionsUpload to an owned directory and correct local ownership when necessary
Camera failsLoose cable, incompatible camera, stack mismatch, busy device, legacy commandPower down and reseat; use current detection tools; check processesMatch camera, connector, OS release, and tool family
Video is choppyExcessive resolution or codec load, slow storage, high frame rate, heatReduce settings; check storage, temperature, and CPU loadUse suitable resolution, cooling, storage, and playback frame rate
Freeze or reboot under loadWeak power, overheating, overclocking, failing storageReturn clocks to default; check cooling, logs, and storageUse proper power and cooling; back up and test another card
Wrong files changedIncorrect path, wildcard expansion, unquoted spaces, unnecessary sudoRun pwd and ls before destructive commandsUse explicit quoted paths, backups, and supported dry-run options

10. Capstone practice

  1. Identify your exact Raspberry Pi model and choose a compatible power supply, microSD card, and network method.
  2. Use Raspberry Pi Imager to select Raspberry Pi OS, select the correct storage device, configure a unique username, hostname, locale, Wi-Fi settings, and SSH, then write and validate the image.
  3. Boot the Pi and verify the desktop or console, storage size, date, network connection, and hardware.
  4. Run sudo apt update and sudo apt full-upgrade. Install a small utility, verify it runs, and remove it if it is no longer needed.
  5. Use raspi-config to review localization, hostname, boot behavior, and SSH. Reboot when requested.
  6. Discover the Pi through its hostname or local IP address. Connect with ssh username@hostname-or-ip.
  7. On the Pi, create a project directory and a text or image file. If a camera is attached, use the timestamped script to capture an image.
  8. Use SFTP to retrieve the file to the client computer.
  9. Document the model, OS version, hostname and IP-discovery method, configuration changes, commands used, and any troubleshooting steps.

Knowledge check

  1. What is the difference between a Raspberry Pi OS disk image and a normal file copied onto a card?
  2. Why should existing microSD data be backed up before imaging?
  3. What is the difference between apt update and apt full-upgrade?
  4. Why might a hostname work on one local network but not another?
  5. When should sudo be used, and why is it risky?
  6. What is the difference between an absolute and relative path?
  7. What do pipes and output redirection do in the shell?
  8. How would you find large files and check overall filesystem capacity?
  9. Why are current rpicam commands not always interchangeable with older camera commands?
  10. Why does capturing at a high frame rate produce slow motion when played at a lower frame rate?
  11. How does SFTP differ from FTP?
  12. What should you verify before accepting an SSH host key or responding to a changed-key warning?
  13. Why is direct public exposure of SSH discouraged?
  14. What privacy questions should you ask before registering a Pi or camera project on a public service?

Continue learning

After completing this course, consider studying Linux fundamentals, the Raspberry Pi course activity, Python programming, GPIO electronics, camera projects, backups, scheduled tasks, and SSH key management.