tty1 under linux means "virtual terminal"; in the Linux system, the computer monitor is usually called the console terminal, which emulates a terminal type of Linux and has some device special files with it Related, such as tty0, tty1, tty2, etc.; when you log in on the console, you use tty1.
#The operating environment of this tutorial: linux5.9.8 system, Dell G3 computer.
What is tty1 under Linux?
tty1, tty2 in Linux represent virtual terminals.
In Linux systems, the computer monitor is usually called the console terminal (Console). It emulates a terminal of type Linux (TERM=Linux), and has some device special files associated with it: tty0, tty1, tty2, etc. When you log in at the console, tty1 is used.
When using the Alt [F1-F6] key combination, we can switch to tty2, tty3, etc. tty1–tty6 and so on are called virtual terminals, and tty0 is an alias of the currently used virtual terminal. Information generated by the system will be sent to the terminal (also called a console terminal at this time).
Extended information:
How to view the current virtual terminal
1. tty only views the current terminal
2. The w command w has the most comprehensive functions. It can display the user login name, terminal logo, login day of the week and specific login time, idle time, programs being executed by the user, occupied CPU time, system running time and average load
3. The function of the command who is relatively simple. It only displays the user login name, terminal logo, and login date and time
Related recommendations: " Linux video tutorial》
The above is the detailed content of What is tty1 under linux. For more information, please follow other related articles on the PHP Chinese website!