logadm.conf(4) File Formats logadm.conf(4)NAME
logadm.conf - configuration file for logadm command
SYNOPSIS
/etc/logadm.conf
DESCRIPTION
/etc/logadm.conf is the default configuration file for the log management tool logadm(1M). Comments are allowed using the pound character
(#) and extend to the end of line. Each non-comment line has the form:
logname options
where logname is the name of the entry and options are the default command line options for the logadm command. The name of the entry may
be the same as the name of the log file, or a log file name may be given in the options section of the entry. Long lines may be folded
using a backslash followed by a newline to continue an entry on the next line. Single or double quotes may be used to protect spaces or
alternate-style quotes in strings.
The preferred method for changing /etc/logadm.conf is to use the -V, -w, and -r options to the logadm(1M) command, which allow you to
lookup an entry, write an entry, or remove an entry from /etc/logadm.conf.
A full description of how and when /etc/logadm.conf is used and sample entries are found in logadm(1M).
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsr |
+-----------------------------+-----------------------------+
SEE ALSO logadm(1M), attributes(5)SunOS 5.10 6 Dec 2001 logadm.conf(4)
Check Out this Related Man Page
logadm.conf(4) File Formats logadm.conf(4)NAME
logadm.conf - configuration file for logadm command
SYNOPSIS
/etc/logadm.conf
DESCRIPTION
/etc/logadm.conf is the default configuration file for the log management tool logadm(1M). Comments are allowed using the pound character
(#) and extend to the end of line. Each non-comment line has the form:
logname options
where logname is the name of the entry and options are the default command line options for the logadm command. The name of the entry may
be the same as the name of the log file, or a log file name may be given in the options section of the entry. Long lines may be folded
using a backslash followed by a newline to continue an entry on the next line. Single or double quotes may be used to protect spaces or
alternate-style quotes in strings.
The preferred method for changing /etc/logadm.conf is to use the -V, -w, and -r options to the logadm(1M) command, which allow you to
lookup an entry, write an entry, or remove an entry from /etc/logadm.conf.
A full description of how and when /etc/logadm.conf is used and sample entries are found in logadm(1M).
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWcsr |
+-----------------------------+-----------------------------+
SEE ALSO logadm(1M), attributes(5)SunOS 5.10 6 Dec 2001 logadm.conf(4)
Can someone suggest on this script :
let's say the logs files are available for Jan 07, Dec 06, Nov 06, Oct 06
the script should identify the latest months logs, i.e Jan 07
it should then delete anything older than 2 months, which will be logs for Nov 06 & Oct 06. (40 Replies)
set filename $logDir/PyLog/$logname
echo $filename >> logname.txt
I am trying to write to write the varibale filename into a file logname.txt,it is not working could any one suggest y (2 Replies)
Hello folks,
I've been making some changes to logadm.conf, but I'm not getting quite the results that I'm expecting
/var/log/pool/poold -a 'pkill -HUP poold; true' -N -s 512k
/var/svc/log/*.log -C 8 -N -s 1m
/var/adm/messages -a 'pkill -HUP `cat /var/run/syslog.pid`' -C 8 -s 10m... (10 Replies)
How would i do this in python
In bash i would do below and this would add the users logname to a file
This write the logname ie James to test.txt
But how would i do it in python this doesnt work below and ive tried different ways but cannot find an answer
But this just writes $(logname) to... (4 Replies)
My logadm.conf is below. Is there a way to match a log file that appends the time/date stamp after the log file? Also, a 0 is being appended onto the files I'm compressing and having rotated. Is there a way to fix that?
/var/apache/tomcat55/logs/catalina.out -C 30 -P 'Fri Jun 18 16:48:55... (5 Replies)
Hi,
Recently i received a request to rotate logs of catalina.out (tomcat). The file size was about 807 MB. I used logadm to truncate the log ( -c ) and zip (-z 0) it.
Everything worked fine, catalina.out.0.gz was created (22 MB) and the size of original catalina.out became 0kb.
After... (2 Replies)
Dear experts.
I was wondering if logadm preserves ACL setuped on for instance, /var/log/authlog.
From man :
...by creating an
empty file whose owner, group ID, and permissions match the
original file....
Is this ACL inclusive or i need to use -a option (run cmd after... (1 Reply)
Hey Guys,
I am looking for a sed one liner to replace an entire line in a file with a certain pattern found. For example.
In logadm.conf.. replace the entire line containing '/var/adm/messages' with '/var/adm/messages -A 90d -C 0 -S 2g -p 1d -s 100m'
I have searched and found stuff about... (3 Replies)
hi folk,
need advise regarding the log rotation, i have the logadm set at
30 2 * * * /usr/sbin/logadm
so it supposed to rotate once per day, but now it rotated twice!
but someone my log will rotate at 2:30 AM, but then another 2 hours later, it creates a new and rotate a new log again,... (2 Replies)
Hi,
I want to check if the given line from a text file has a spaces in between. if it does, then I want to add '"' double quotes at the beginning and end of the line. Otherwise leave the line as it is.
For example, below is the sample content from my file.
$cat file.txt
test1
test2... (6 Replies)
I have a file and some records may contain double quotes at beginning and at end of line. So how do I strip them?
For Example, file is somethings like this
Field1;Field2;Field3
01;'Test';'Test Field3'
"01;'This is 2nd field';This is 3rd field' "
Desired Output is:
... (6 Replies)
Hi
i have following sample entry--Each entry has 7-9 lines. Below entry has 7 lines.
I have a file it contains 1000's of such entries and each entry has 7-9 lines.
Input:
dn:cn=aci,cn=index,cn=example,cn=ldbm database, cn=plugins,cn=config
objectClass: top
objectClass:... (2 Replies)
Hi. Is there a way to:
1) produce a listing of .log files
2) older than 5 years of age
3) that includes the full path and filename together with one file per line
Any help producing such a script would be very helpful. Thanks. (7 Replies)
Hello,
I am trying to rotate my logs using logadm, so I did the following
logadm -w /traces/mylogs.out -C 5 -p 1d -o user -g group -m 644 -c -t '/traces/mylogs.out.$n' -z 1
and then tried to test it by logadm -v and it gets stuck at truncation step
# processing logname: /traces/mylogs.out... (5 Replies)