>_ MacLinUnix.

AN INTERACTIVE TECHNICAL FIELD GUIDE

MacLinUnix

Exploring macOS, Unix, and Linux

macOS, Unix, and Linux have different histories, but spend some time in their terminals and you’ll encounter familiar ideas. MacLinUnix explores where they came from, what they share, and where they differ.

An illustrated guide to Unix-style environments, with command comparisons and examples you can experiment with.

~/maclinunix⌘

➜ ~ # notes: macos / unix / linux

Three environments, at a glance

⌘
macOSDarwin: Mach + BSD technologies
CERTIFIED*
>_
UnixThe foundation · Since 1969
ORIGIN
λ
LinuxIndependent kernel · Unix-like
UNIX-LIKE
* UNIX certification covers specific macOS
releases and hardware configurations.

➜ ~ _

01 — HISTORY

The Unix family tree

Unix started a way of thinking about computing.
Its ideas grew in more than one direction.

1969 · BELL LABSUnixThe original foundation
↓ DESCENT & EVOLUTION
BSDBerkeley Software Distribution
↘ +
NeXT → Darwin → macOSMach + BSD + Apple technologies
⇢ INFLUENCE & IDEAS
Linux 1991Independently developed kernel
↓
Linux distributionsKernel + tools + applications

Simplified connections · The Apple branch combines BSD technologies with Mach, NeXT, and Apple development. Modern BSD systems and System V have their own branches.

01

Unix is the starting point

A multi-user system with small tools, a hierarchical filesystem, and a powerful shell. Its design shaped generations of operating systems.

02

macOS has Unix roots

Under the Apple interface is Darwin, combining Mach, BSD components, and Apple technologies through the NeXT and Apple lineage. macOS releases have achieved UNIX certification; certification applies to specific versions and hardware.

03

Linux is Unix-like

Linux was independently written, inspired by Unix concepts. It shares the approach, but is not a direct descendant of the original Unix source code.

Read the full history →

02 — SHARED CONCEPTS

How Unix concepts fit together

These ideas work together across macOS,
BSD systems, and Linux distributions.

  1. Filesystem

    Files live in a hierarchy, starting at /. Paths connect directories and files; many tools use text-based configuration stored within that tree.

    Directory comparison ↓
  2. Users and permissions

    Multi-user design gives files owners and groups. Permissions determine who can read, change, or execute them.

    Permission examples ↓
  3. Shells and command-line tools

    A shell interprets commands. Environment variables provide context; pipes and input/output redirection connect small utilities into useful workflows.

    Shell examples ↓
  4. Processes

    Running programs become processes with identities and owners. Commands such as ps, top, and kill help inspect and manage them.

    Command reference ↓
  5. Networking

    SSH provides secure remote access. Networking tools inspect addresses, routes, and connections, whether you are working locally or on another machine.

    Networking comparison ↓
  6. Development and automation

    Editors, compilers, and command-line utilities form familiar development environments. Shell scripts combine these concepts into repeatable tasks.

    Scripting notes ↓

Read this as a set of connected ideas, rather than a strict dependency chain. A script, for example, can work with files, processes, and remote systems together.

03 — COMMANDS

Command explorer

Compare everyday commands and the options
that differ between implementations.

COMMAND / PURPOSEEXAMPLECOMPATIBILITY
Examples are for learning; review paths before running.

Same name ≠ same options. Use man command on your own system to check its local manual.

04 — TOOLS

System tasks and their tools

Package managers, services, and storage tools
vary even when the underlying task is similar.

macOS and Linux tools for common system tasks
THE JOB⌘ macOSλ Linux
Install softwareHomebrew · MacPortsThird-party package managersapt · dnf · pacman · zypperDepends on the distribution
Manage serviceslaunchd · launchctlsystemd · systemctlCommon; alternatives exist
Store filesAPFSext4 · Btrfs · XFS · ZFSZFS usually requires additional support
Run everyday commandsOften BSD-derived utilitiesOften GNU utilitiesSome systems use alternatives, such as BusyBox
Monitor the systemActivity Monitor · toptop · htop · btophtop and btop may need installing

05 — FILESYSTEM

Directories and filesystem conventions

Unix-style paths begin at /.
Each system adds its own conventions.

/ ← root directory

├── etcSystem configuration

├── usrUtilities & shared resources

├── varLogs & changing data

├── tmpTemporary files

├── binEssential commands

└── sbinSystem administration tools

On macOS, some paths link into /private. Many Linux systems merge /bin and /sbin into /usr.

⌘ macOS directories

/Users
User home directories
/Applications
Application bundles
/Library
Shared support files & settings
/System
Protected operating-system files

λ Linux directories

/home
Ordinary users’ home directories
/boot
Boot files, often including the kernel
/opt
Additional application software

06 — PERMISSIONS

Understanding file permissions

Read, write, and execute permissions apply
to the owner, group, and others.

INTERACTIVE EXAMPLE / chmod

Toggle a permission. Watch the number and command change.

Owner
7rwx
Group
5r-x
Others
5r-x
4 read2 write1 execute
chmod 755 script.sh

FILE MODE -rwxr-xr-x

Owner: read, write, execute. Group: read, execute. Others: read, execute.

Each digit adds the selected values for that group. This demo describes a regular file and only generates a command.

Reading a permission mode

chmod 755 script.sh lets the owner read, write, and execute. The group and everyone else can read and execute.

chmod 644 notes.txt lets the owner read and write. Everyone else can only read.

chmodChange permissions

chownChange owner

chgrpChange group

For directories, execute means the ability to traverse them. ACLs and system protections can add further rules.

07 — SHELLS

Shells, scripts, and composition

A shell interprets your commands.
A script makes them repeatable.

zsh Modern macOS defaultbash Common on Linuxsh Portable scripting baselinefish Friendly, distinct syntax
PIPES
ls | grep ".txt"

A pipe sends one command’s output into another. This filters listing lines; use find for reliable filename processing.

REDIRECTION
echo "Hello" > file.txt

Write output to a file. > overwrites; >> appends.

VARIABLES
echo "$HOME"

Read your home path from an environment variable. name="Ada" sets a shell variable; export name passes it to child processes.

SUBSTITUTION & CHAINING
today=$(date +%F) && echo "$today"

$(command) captures output. && runs the next step only if the first succeeds.

For portable scripts, use a #!/bin/sh shebang and POSIX syntax. Bash, zsh, and fish features are not interchangeable; tool options still vary.

08 — NETWORKING

Connecting and inspecting networks

Remote connections use familiar protocols.
Local inspection tools differ by platform.

↗

Remote access and file transfers

ssh opens a secure remote session. scp copies files; rsync synchronizes them. curl transfers data from URLs.

$ ssh user@hostname
◎

Interfaces and addresses

macOSifconfig
Linuxip addr

Both help inspect network interfaces and addresses. Linux commonly favors ip over older ifconfig.

⇄

Connections and reachability

macOS / older systemsnetstat
Modern Linuxss

ping checks reachability and traceroute traces routes. Availability and options vary by system.

09 — WHY SKILLS TRANSFER

Different systems. Familiar ideas.

Learning Linux makes the macOS terminal more familiar. Learning macOS command-line tools makes Linux less foreign. Paths, permissions, shells, pipes, processes, and SSH continue to connect these environments decades after Unix first appeared.

Much of that knowledge carries over when working on a remote system, too. Scripts often need only small adjustments, but shell syntax, command options, and system-specific tools are always worth checking.