Catalog / FreeBSD Command Line Cheatsheet
FreeBSD Command Line Cheatsheet
A quick reference for navigating and managing FreeBSD systems from the command line. Includes essential commands and shortcuts for system administration and general usage.
Basic Commands
System Information
|
Display kernel information (kernel name, hostname, kernel release, version, machine hardware name). |
|
Show the FreeBSD version running. |
|
Display boot-time messages from the kernel. Useful for hardware info. |
|
Show hardware information. |
|
Display and update sorted information about processes. |
|
Show all processes running on the system. |
File System Navigation
|
List directory contents. |
|
Change directory. |
|
Print working directory. |
|
Create a new directory. |
|
Remove an empty directory. |
|
Find files by name in the current directory. |
Package Management
pkg Commands
|
Update the package repository. |
|
Upgrade installed packages to the latest versions. |
|
Install a new package. |
|
Remove an installed package. |
|
Search for packages matching a keyword. |
|
List all installed packages. |
|
Remove automatically installed packages no longer required. |
|
Clean the package cache. |
User and Permissions
User Management
|
Add a new user. |
|
Remove an existing user. |
|
Change a user’s password. |
|
Switch to another user. |
|
Display the current user’s username. |
|
Display the groups a user belongs to. |
File Permissions
|
Change file permissions. |
|
Change file owner. |
|
Change file group. |
|
List files with detailed permissions. |
|
Show or set the file creation mask. |
Networking
Network Configuration
|
Display network interface configuration. |
|
Display the routing table. |
|
Test network connectivity to a host. |
|
Trace the route packets take to a host. |
|
Securely connect to a remote host. |
|
Securely copy files to/from a remote host. |
Hostname and DNS
|
Display the system’s hostname. |
|
Query DNS for information about a hostname. |
|
View DNS resolver configuration. |