How To Clear or Remove Linux Logins History
On Linux systems, there are three standard commands that show information about the most recently connected users: last, lastb and lastlog.
The output of these commands includes: login, time of last connection , IP address, port, etc.
To preserve anonymity, it is necessary to clear the history of recent connections.

CommandLogDescription
last/var/log/wtmpLists successful login/logout history
lastb/var/log/btmpHistory of failed login attempts
lastlogvar/log/lastlogList of the last connected users
Also a popular request is how to clear the lastlog file in linux history.
For removing all the information about the last logged in users, you need to clear the logs:
# echo > /var/log/wtmp
# echo > /var/log/btmp
# echo > /var/log/lastlog