Help to create audit log while firing 'rm' command


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting Help to create audit log while firing 'rm' command
# 1  
Old 07-08-2013
Help to create audit log while firing 'rm' command

Hi,

I would like to get the audit log with username, directory and the date whenever user fires 'rm' command anywhere in the file locations.

Is there any possibility to capture the 'rm' command and its parameters from any environment by the single function ?

Please advise me.

Thanks,
Joviac
# 2  
Old 07-08-2013
What system are you using?
# 3  
Old 07-08-2013
It is SunOS 5.9
# 4  
Old 07-08-2013
Too bad you are not using at least Solaris 10. DTrace would make your request trivial... For Solaris 9 you can use BSM auditing: http://docs.oracle.com/cd/E19604-01/...ing/index.html
# 5  
Old 07-08-2013
I am aware that by using 'lastcomm' command, we can able to get the details such as user, execution time etc, but we couldn't capture the filenames and their paths. Do we have any such alternative way to find out the details together ?

Thanks in advance
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Parse audit log

I am trying to parse the audit log to find a particular date that associated with a user record. The Date and the context of the record that I need to extract from the audit.log are 11-07-2015, the username and the activity he or she performed that day. Here is my code: grep -c date -d... (3 Replies)
Discussion started by: dellanicholson
3 Replies

2. SuSE

Alert for Audit log

Dear users, I have SLES 11 and SLES 10 servers. I'd like to receive an alert when audit log files reach certain percentage of full. 1. Is '/etc/audit/auditd.conf' the right file to modify? 2. I'd like to receive email alert. Can I specify my email in this parameter 'action_mail_acct... (1 Reply)
Discussion started by: JDBA
1 Replies

3. Red Hat

Audit.log Management

Hi, I'm fairly new to administering RedHat (or any Linux system for that matter), and was wondering if someone could help me work out how to best manage audit logs. In a nutshell, this is what I need to do: - Compress audit.log file(s) once a month and delete the originals - The... (0 Replies)
Discussion started by: Seonix
0 Replies

4. AIX

When AIX audit start, How to set the /audit/stream.out file size ?

Dear All When I start the AIX(6100-06)audit subsystem. the log will save in /audit/stream.out (or /audit/trail), but in default when /audit/stream.out to grow up to 150MB. It will replace the original /audit/stream.out (or /audit/trail). Then the /audit/stream.out become empty and... (2 Replies)
Discussion started by: nnnnnnine
2 Replies

5. Solaris

delete audit old log

hi all, i enabled audit in my server it is working fine, now i want to delete old logs from audit file ,plz find a solution for it, Regards spandan (2 Replies)
Discussion started by: spandhan
2 Replies

6. AIX

Need to audit LV's - need some command help

I need to run a DC wide audit of some oracle filesystems to ensure their all on SAN. In linux its pretty easy since its LVM device structure includes the VG for which that lv is part of (/dev/VGFOO/lv-bar). As such I can just run mount and do some greping to get the needed info. SO my question... (2 Replies)
Discussion started by: Mattchewie
2 Replies

7. Solaris

Solaris BSM audit log

I got a lot of this message in my /var/audit log how can I exclude this message? header,127,2,invalid event number,fe,hostsol1.com.sg,2007-12-21 00:10:01.001 +08:00,argument,1,0x5,processor ID,argument ,2,0x3,flag,text,P_STATUS,subject,zhang1,root,root,root,root,18228,576129155,291 131094... (1 Reply)
Discussion started by: geoffry
1 Replies

8. Shell Programming and Scripting

Awk Script Is Not Firing

Why is my awk script not firing and how can I confirm? #!/usr/bin/ksh # LU 5 FEB 2007 12:35 OLDDATE=`cat TIMEFILE` for FILE in `find /home/Upload -prune -type f -newer TIMEFILE` do gawk -f convert_sun.awk "/home/Upload/$FILE" done date > TIMEFILE (5 Replies)
Discussion started by: goodmis
5 Replies

9. Shell Programming and Scripting

Is it possible to create audit trail on remote server using FTP

Hi, I'm automatically FTPing few files daily as a cron job to a remote server. I wanted to know if there is a way to log the successful transfer in a log on the remote server? The log on the remote server should look something like this. 10/30/2006 00:00:02 - File 1 transferred... (0 Replies)
Discussion started by: dayanand
0 Replies

10. Programming

Event firing

I am writing a program in C. It is kind of a daemon process. In this program, at the end of every 2 hours, i need to fire an event. How can i achieve this timer effect in my program? (1 Reply)
Discussion started by: Nadeem Mistry
1 Replies
Login or Register to Ask a Question