Logging Out of Linux
After you create a new user account and a new user's password, log out of Linux by using the either the logout or exit command, as follows:
$ exit $ logout
After you enter either of these commands, the display will clear, and the Linux login prompt will be redisplayed.
Rebooting Linux
To reboot your system, always use the shutdown command, which is found under the /sbin directory. Just powering off your computer can cause severe disk errors, and is an unsafe practice. I cannot stress enough the importance of properly shutting down your system. You must be the root operator or use the su command to use the shutdown command.
The shutdown command takes several command-line options. For example, using the -r, or ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access