Operating System - HP-UX
1752328 Members
5549 Online
108786 Solutions
New Discussion

create a custom logs script of rm command

 
Aamir14
Regular Advisor

create a custom logs script of rm command

Hi,

 

create a custom logs script of rm command

 

many people log to root user and  delete some files.

 

i want to make a script when any user and root user run the RM command

 

its save a logs to any file.

 who run the RM command   

 

Please give me some advice .

 

Thanks

Aamir

 

5 REPLIES 5
madhucertify
Advisor

Re: create a custom logs script of rm command

Hi Aamir,

 

 enable history file.

 

if you want to have records for each user,you have make changes in root .profile file.

 

regards

 

Madhu

 

 

 

 

Aamir14
Regular Advisor

Re: create a custom logs script of rm command

Hi,

 

I want only rm command logs because many people log in to root user(such as DBA user) and clear 

the history file.

and create a script.and save to some hidden location.

 

Please give me a script or it is a possible.

 

 

Thaks

Aamir

 

 

 

madhucertify
Advisor

Re: create a custom logs script of rm command

Hi

 

>>because many people log in to root user(such as DBA user) and clear the history file.

 

why DBA user is switching to root ,if it so then there is a security issue.

 

if DBA really wants to use root,grant them the sudo access.

 

 

>>create a script.and save to some hidden location.

 

if people has root access,they can even find and edit hidden location.

 

RJHall
Frequent Advisor

Re: create a custom logs script of rm command

A couple of thoughts occur: (1) use HIDS and filter on rm actions; (2) set up auditing and post-process the logs to look for deletions.

Aamir14
Regular Advisor

Re: create a custom logs script of rm command

Hi,

 

Thanks for advice.

 

but my DBA user running software and install Database on /u01 and /u02 mount point.

 

I give the full access of /u02 and /u02 mount point

not to vg00 mount point

 

it is possible DBA users run every single command  on /u02 /u01 mount point.and not to run all mount point.

 

if yes how can give the access.

 

Thanks for advance

aamir