Here is a Red Hat Linux cheat sheet with some useful commands and tips:
System Information Commands:
uname -a
: Display system informationhostname
: Display the hostname of the systemtop
: Display real-time system information including processes and memory usagefree -h
: Display memory usage in a human-readable formatdf -h
: Display disk usage in a human-readable formatlsb_release -a
: Display Linux distribution information
File and Directory Commands:
ls
: List files and directoriescd
: Change directorymkdir
: Create a directoryrm
: Remove a file or directorycp
: Copy a file or directorymv
: Move or rename a file or directorychmod
: Change file or directory permissionschown
: Change file or directory ownershipgrep
: Search for a pattern in a file
Network Commands:
ping
: Test network connectivityifconfig
: Display network interface configurationnetstat
: Display network connections and statisticstraceroute
: Trace the path to a network hostssh
: Connect to a remote system over SSHscp
: Securely copy files to and from a remote system over SSH
Package Management Commands:
yum
: Install, update, and remove packagesrpm
: Query and manage installed packagesdnf
: Modern package manager for newer versions of Red Hat Linux
System Administration Commands:
systemctl
: Control system servicesjournalctl
: View system logsfirewall-cmd
: Configure the firewalluseradd
: Create a new userpasswd
: Change a user’s passwordsu
: Switch to another usersudo
: Run a command as another user with elevated privileges