Exercícios de laboratório, conteúdo muito similar ao cobrado no exame prático da certificação RHCSA, em inglês.
Lab Manual-Basic Commands
Linux basic commands
Print the system uptime, number of logged on users and average load to the system.
Print the currently working directory
Change the current directory to /etc directory
# cd /etc/
See, network interfaces and their configurations
# ip addr show
To clear the terminal
Listing Files & Directories
# ls –l
# ls –al
# ls –lt
# ls –ltr
# ls -R
Read contents of file in the Bash Terminal
# cat /etc/passwd
Verify and change hostname
# hostnamectl set-hostname server.example.com
Verify and change time, date and time-zone
Print full date and time
To see the time, time zone, clock status,
# timedatectl set-timezone and press ‘tab’ key twice. It will display all the timezones. Find your timezone > Here, for this demonstration, I assume my timezone as Asia/Bankok > copy it > press ‘escape’ key and paste.
Again, you need to authenticate. Enter the password > click on authenticate. Clearing the screen, verify.
# date +%
# date +%R
# cal 08 2019
See what commands you’ve run so far
To study or know in detail about any command, the available options and arguments, open manual page of the command. For example, to read the manual page of ls command
# man ls.
Press, space bar to go to other pages. Press ‘q’ to quit from here.
To know details of any command, just type man and the name of the command.