Linux Force to kick out the USER command: 1, enter the w command to view the logged in user information [root@KW_S01_192.168.1.106 _ A ~] # W19: 22: 31up2: 11,3 users, loadaverage: 0.00, 0.00, 0.00USERTTYFROMLOGIN@IDLEJCPUPCPUWHATrootpts0192.168.1.17818: 410.00s0.16s0.01s
Force users out of linuxCommand:
I. InputW commandView logged-on user information
Root@KW_S01_192.168.1.106 _ A ~ # W
19:22:31 up, 3 users, load average: 0.00, 0.00, 0.00
User tty from login @ IDLE JCPU PCPU WHAT
Root pts/0 192.168.1.178 0.00 s 0.16 s 0.01 s w
Root pts/1 192.168.1.178 4.00 s 0.14 s 0.05 s ssh localhost
Root pts/2 localhost. locald 4.00 s 0.07 s 0.07 s-bash
2. Run the command pKill-Kill-t User tty
Root@KW_S01_192.168.1.106 _ A ~ # Pkill-kill-t pts/2
Iii. verify whether the operation is successful
Root@KW_S01_192.168.1.106 _ A ~ # W
19:24:25 up, 2 users, load average: 0.00, 0.00, 0.00
User tty from login @ IDLE JCPU PCPU WHAT
Root pts/0 192.168.1.178 0.00 s 0.18 s 0.02 s w
Root pts/1 192.168.1.178 0.09 s 0.09 s-bash
Description of login user information:
USER: displays the login USER account name. The user logs in again, and the account will appear again.
TTY: the terminal used for user login.
FROM: displays where the user logs on to the system.
LOGIN @: indicates the time when LOGIN is logged on to the system.
IDLE: the user's free time, from the user's last task after the end of the meeting notes.
JCPU: indicates the CPU time consumed by all process tasks related to the terminal within the touch period.
PCPU: the CPU time consumed by tasks in WHAT domains after execution.
WHAT: indicates the current task.