Linux administration Flashcards
What command is used to check the system’s uptime?
uptime
How do you view the currently logged in users?
who or w
What is the purpose of the ‘top’ command in Linux?
displays system processes and their resource usage
How do you check the system’s load average?
uptime or w command.
What command is used to view the system’s hardware information?
lshw or lspci command.
How do you add a new user in Linux?
adduser or useradd command.
What is the purpose of the ‘sudo’ command?
Allows users to execute commands with superuser privileges.
How do you change the password for a user in Linux?
passwd [username] command.
What is the purpose of the ‘passwd’ command?
Changes user password.
How do you give a user administrative privileges in Linux?
sudo usermod -aG sudo [username].
How do you configure a static IP address in Linux?
Edit the network configuration file or use ip command.
What command is used to view the system’s IP address configuration?
ifconfig or ip addr show command.
What is the purpose of the ‘ifconfig’ command?
Displays network interface information.
What command is used to view the system’s disk space usage?
df command.
How do you restart a network service in Linux?
sudo systemctl restart [service] or sudo service [service] restart.