[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: user History File.



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Sun, Feb 28, 2016 at 01:52:25PM +0500, Muhammad Yousuf Khan wrote:
> Thanks Alot for your input Tomas.
> 
> I don't know exactly what your problem is, but take into account that bash
> > only appends its (in-memory) history to .bash_history at exit (so while
> > the shell is active you won't see any changes)
> 
> 
> Actually i never worked on multi user environment. this is the first time
> that i am dealing with multiple users. i  want to monitor what hey are
> doing. so i thought history is the best option to do.but when i try to scan
> their history i see nothing. so my Question is why i can not see any thing
> new in their history file.
> so how can i track user activity.

Well, you should be able to see the history in their home's .bash_history
files, but it gets only added to when they end the respective shell session.

Yo can see it happening by opening two terminals (same user). In the one,
you do "tail -f ~/.bash_history", in the other you enter some commands
and terminate the shell (e.g. by entering CTRL-D or "exit", or even perhaps
by closing the terminal). You should see all those commands appear at
once at this moment.

Regards
- -- t
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)

iEYEARECAAYFAlbS0CsACgkQBcgs9XrR2kYkwwCfZ5AZ43+n+ORanXKg/oMMycUn
/B8An04BeiMtXqxHAGFo7SB9FAvdAwE+
=PE8Q
-----END PGP SIGNATURE-----


Reply to: