clocker1996
01-02-2002, 04:31 AM
Where does the history get saved to? for bash its .bash_history
What if a user is using /bin/csh for his/her shell
How can you see what he/she has done (his history)
priyadi
01-02-2002, 06:08 AM
Originally posted by clocker1996
What if a user is using /bin/csh for his/her shell
How can you see what he/she has done (his history)
What vendor of csh? On tcsh (RedHat Linux) it is .history.
clocker1996
01-02-2002, 06:21 AM
Its rh 7.1 seawolf
using /bin/csh
Noldar
01-02-2002, 09:44 AM
The special files for the C shell should be:
.cshrc Executed at each instance of shell.
.history History list saved from previous login.
.login Executed by login shell after .cshrc at login.
.logout Executed by login shell at logout.
You can control the history buffer with the follwing commands:
set history=nnn Sets the length of the history buffer for the session.
set savehist=nnn Sets the number of commands to be saved when you logout.
You can place these set commands in your .cshrc.
This is from HP-UX, but should be them same on any *nix.
Richard
bobcares
01-02-2002, 12:08 PM
Hi!
Actually Linux uses tcsh which is an enhanced form of csh...
In tcsh you have to specify the history file..
I have pasted below a part of the man file of tcsh.. I hope this helps.
With -L, the shell appends filename, which is presumably a history list saved by the
-S option or the savehist mechanism, to the history list. -M is like -L, but the contents of filename are merged into the history list and sorted by timestamp. In either case, histfile is used if filename is not given and ~/.history is used if histfile is unset. `history -L' is exactly like 'source -h' except that it does not require a filename.
I hope this was useful.
Have a great day :)
regards
amar
I believe you can use "ls -a" from command line to see any file with a "." in front of it. Like .history Also those files are usually stored in your users home directory. Try this from command line.
# cd ~
# ls -a