Linuxlastb command details

Source: Internet
Author: User
Note: execute the lastb command separately. it will read the text named btmp in the/var/log directory.

Lastb

Function description: lists information about users who failed to log on to the system.

Syntax: last [-adRx] [-f] [-n] [account name] [terminal number]

Note: execute the lastb command separately. it will read the text named btmp in the/var/log directory.

And display all the user names that failed to log on to the system.

You can specify the account name or terminal number to list only the specified range.

Parameter:-a displays the host name or IP address from which to log on to the system in the last row;

-D. convert the IP address to the host name. When a user logs on to the system from a remote host instead of a local host

Not only the host name, but also the IP address of the remote host. Default

The IP address is used to display the remote host. you can use this parameter to replace it with the host.

Name;

-F specifies the record file. The default last command reads the/var/log directory.

Btmp file;

-N: set the number of columns displayed in the list. if you only want to query the last logon system

10-bit user name. you can set the number of columns to "10 ".

The last 30 users are set to "30" and so on;

-R does not display the host name or IP address used to log on to the system;

-X displays information such as system shutdown, reboot, and change of execution level.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.