Generally Linux history
command is powerful to can store per user based command history with respective time stamps. But in real world it happens like, with same user login, multiple people try to login from different hosts.
Is there any way to store the host-name/IP
along with the time-stamp in history ?
You can do that by using PROMPT_COMMAND variable.
Add the following lines in
/etc/profile
You can customize the above PROMPT_COMMAND as you need.
Create a script which can fetch the info of server which user logged in.