Discovering a New Linux Machine
Essential commands to gather important information about a Linux machine:
hostname # Display the hostname of the machine
uname -a # Display all kernel information
uname -r # Kernel release
uname -m # Machine hardware name
lsb_release -a # Display LSB information, including the distribution name and release
cat /etc/os-release # Display the operating system name and version
cat /etc/issue # Display the operating system name, version, and other info
lscpu # Display CPU information
free -h # Display memory information
df -h # Display disk space information
ifconfig # Check network configuration
ip a # Display IP addresses and network interfaces
netstat -tuln # Check network connections
ps aux # Check running processes
lsof # Check open files
who # Check logged in users
w # Display who is logged on and what they are doing
last # Check last logged in users
mount # Display list of mounted file systems
uptime # Display system load and uptime
lsusb # List USB devices (Universal Serial Bus)
lspci # List PCI devices (Peripheral Component Interconnect)
lsscsi # List SCSI devices (Small Computer System Interface)
cat /etc/passwd # List users
systemctl list-units --type=service # List all systemd services
References
Linked from
- my workflows — [[Discovering a New Linux Machine]]
External links
Read next
- Cloudflare Images CLI with Python Jul 2025
- Set VS Code Debugger for Stepping Through External Modules Feb 2025
- Setup reverse ssh on Ubuntu Feb 2025
- Sync, Build & Deploy at One Action Feb 2025
- Unix & Linux Commands Cookbook Feb 2025
Listen
Alpha. Uses your browser's Speech API; voice quality is low.