My proposed solution:
To be honest, if you are running the script once a day or week, then:
or even:
would be more than sufficient.
But I have to admit the statement:
Quote:
Originally Posted by lookinginfo
Are there any disc space issues?
[me] no disc space issue.
bothers me. There are always disk space issues -- disks may be cheap, but no one has infinite disk space. IMHO, rotating the logfiles is "better", for it limits the total size of the logs to the number of rotations times 5M (plus or minus). Change the body of the while loop to:
Run this version of the script once a week, and you will retain a minimum of ten weeks of logs.
I'm looking to create a Korn Shell script that, if given a directory as an arg, will calc bytes used by all files in the given directory and display that info. If no command line arg is given the program is to calc and display the bytes used by all the files in the pwd.
Example output:
... (3 Replies)
Hi all,
Does anybody know or guide me on how to remove the first N bytes and the last N bytes from a binary file? Is there any AWK or SED or any command that I can use to achieve this?
Your help is greatly appreciated!!
Best Regards,
Naveen. (1 Reply)
Compete noob question....
I need a script to search through a directory and find files containing text string abcde1234 for example and then copy that file with that text string to another directory
help please :eek: (9 Replies)
Hi All,
OS:AIX 64 bits.
Requirement is to convert file_size from bytes to megabytes through shell script as below:
export DBALIST="xyz@rediffmail.com"
ls -ltr abcd.txt > file_size.result
export file_size=`awk -F" " '{ print $5 }' file_size.result`
if ]
then
mailx -s "File abcd.txt... (3 Replies)
Hi everyone,
the problem is quite simple, yet I can't find an easy solution using awk.
I need to search for a string in $3, then if I find this string, copy the line,modify $3, and copy the next 9 lines to the same file.
My problem is in the copying of the lines... Finding and modifying... (5 Replies)
Hi,
I want to copy some files from a Folder say, /usr/X at random intervals to another location.
Basically, new files will be dumped at random intervals to location /usr/X and I have to copy those new files to some other location (after copying, I cannot delete those files from source... (2 Replies)
Dear all,
I have a database with thousands of files with the structure of name is:
Filename_hour_year.abc
Filename_hour_year_1.abc
..............
So what I need is how to write a script that all file with contain the character "_1" will copy to "_2"
For example: file name:... (7 Replies)
I have a text file which got 6th coloumn as date and 7th coloumn as time. The text contains data for last one week. I need to remove all the data whose date & time is after 03/08/2011 06:00:00 and save it on another file
TEXT FILE
========
6 dbclstr-b IXT_Web Memphis_Prod_SQL_Diff... (4 Replies)
How can i remove a file using shell script when its size exceeds 10MB. Given that file is located in different location to the shell script where it is running? (4 Replies)
hello,
suppose, entered input is of 1-40 bytes, i need it to be converted to 40 bytes exactly.
example: if i have entered my name anywhere between 1-40 i want it to be stored with 40 bytes exactly.
enter your name:
donald duck (this is of 11 bytes)
expected is as below - display 11... (3 Replies)
Discussion started by: shravan.300
3 Replies
LEARN ABOUT SUNOS
audit_binfile
audit_binfile(5) Standards, Environments, and Macros audit_binfile(5)NAME
audit_binfile - generation of Solaris audit logs
SYNOPSIS
/usr/lib/security/audit_binfile.so
DESCRIPTION
The audit_binfile plugin module for Solaris audit, /usr/lib/security/audit_binfile.so, writes binary audit data to files as configured in
audit_control(4); it is the default plugin for the Solaris audit daemon auditd(1M). Its output is described by audit.log(4).
The audit_binfile plugin is loaded by auditd if audit_control contains one or more lines defining audit directories by means of the dir:
specification or if audit_control has a plugin: specification of name=audit_binfile.so.
OBJECT ATTRIBUTES
The p_dir and p_minfree attributes are equivalent to the dir: and minfree: lines described in audit_control. If both the dir: line and the
p_dir attribute are used, the plugin combines all directories into a single list with those specified by means of dir: at the front of the
list. If both the minfree and the p_minfree attributes are given, the p_minfree value is used.
EXAMPLES
The following directives cause audit_binfile.so to be loaded, specify the directories for writing audit logs, and specify the percentage of
required free space per directory.
flags: lo,ad,-fm
naflags: lo,ad
plugin: name=audit_binfile.so;
p_minfree=20;
p_dir=/etc/security/jedgar/eggplant,
/etc/security/jedgar.aux/eggplant,
/etc/security/global/eggplant
ATTRIBUTES
See attributes(5) for a description of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|MT Level |MT-Safe |
+-----------------------------+-----------------------------+
|Interface Stability |Evolving |
+-----------------------------+-----------------------------+
SEE ALSO auditd(1M), audit_control(4), syslog.conf(4), attributes(5)SunOS 5.10 20 May 2003 audit_binfile(5)