1830779 Members
12254 Online
110016 Solutions
New Discussion

Login Hostories

 
SOLVED
Go to solution
YOGI_3
Frequent Advisor

Login Hostories

Hi all..
can i know that who were looged into the system and what command they issued...??

Thanks,
Yogesh
There is never a wrong time to do the right things
4 REPLIES 4
Paul_481
Respected Contributor
Solution

Re: Login Hostories

Hi Yogesh,

You can use the "last" command to check the sign on history. Man "last" for details.

As for the command they issue, check the i guess your best shot would be the ~/.sh_history of the users.

Regards,
Paul
Joseph Loo
Honored Contributor

Re: Login Hostories

hi,

unless u have audit turn on. your next best thing would be using last command for who login and thru .sh_history for a history of the user's commands entered.

regards.
what you do not see does not mean you should not believe
Muthukumar_5
Honored Contributor

Re: Login Hostories

You can get the logged user informations detials from wmtp log file. It can be viewed using last command.

last -R

If you want to audit their command execution then it is possible with their history file.

You can get all users history file as,

su - -c "echo $HISTFILE"

hth.
Easy to suggest when don't know about the problem!
Vibhor Kumar Agarwal
Esteemed Contributor

Re: Login Hostories

Last is the best command for seeing logins.

For commands you can add a line to their .profiles

script commands.txt
Now whatever they will do will also come in this file.
Vibhor Kumar Agarwal