Security

Customizing history file in HP-UX

 
GVUMREDDY
Occasional Visitor

Customizing history file in HP-UX

Hi,

In our HP-UX 11i V3 server, currently we are using the default .sh_history file for all users command history. But, this file maintains the history of very limited commands and each user can edit his own history file. So, for monitoring purpose, we need to maintain the history of at least 10000 commands of each user and user should not have permission to edit this file. could you please help me to setup this for all users in the system.

 

Yours,

G V U M REDDY,

UNIX system administrator,

Bangalore,

India.

1 REPLY 1
Dennis Handly
Acclaimed Contributor

Re: Customizing history file in HP-UX

>we need to maintain the history of at least 10000 commands of each user

 

You need to add this to /etc/profile: export HISTSIZE=10000

 

>user should not have permission to edit this file.

 

You can't do this because users won't be able to write to the file.  If you want this type of auditing, give up on using the history file.