Sponsored Content
Operating Systems Solaris How to logrotate a file after X days with logadm? Post 302866969 by DukeNuke2 on Wednesday 23rd of October 2013 05:23:52 AM
Old 10-23-2013
Have you tried to read the logadm man page?
This User Gave Thanks to DukeNuke2 For This Post:
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

logrotate with /etc/logrotate.conf file

Hi there, I want to rotate the logfiles which are located in /var/log/jboss/tomcat* so I have created a file named as 'tomat' in /etc/logrotate.d/tomcat with the following content. # cat /etc/logrotate.d/tomcat /var/log/jboss/tomcat_access_log*.log { daily nocreate ... (2 Replies)
Discussion started by: skmdu
2 Replies

2. Shell Programming and Scripting

logrotate irrespective of the size of a file/directory

hi, How to logrotate irrespective of the size of a file/directory...? Please help me in this regard... (4 Replies)
Discussion started by: Dedeepthi
4 Replies

3. Shell Programming and Scripting

How to give the zip file name in logrotate?

Hi, How to give file name for the zip file while compressing in logrotate... Should we need to give it in the logrotate.conf file or in the spec file...? (2 Replies)
Discussion started by: Dedeepthi
2 Replies

4. UNIX for Dummies Questions & Answers

Explain this logrotate file

Very silly question .. I deleted it .. Please delete this thread too . (0 Replies)
Discussion started by: stunn3r
0 Replies

5. Red Hat

File is missing after logrotate!!

I am having a requirement to rotate the my application logs dailay as it is keep on writiing to single file and below is the logrotate function which I am using, cat /apps/bmc/bmtm/QPasa_logrotate.conf /apps/bmc/bmtm/all_events.log /apps/bmc/bmtm/history_association.log { missingok ... (1 Reply)
Discussion started by: sandyrajh
1 Replies

6. Shell Programming and Scripting

Logrotate - I am not able to rotate files using logrotate

I have written script which is working in Home directory perfectly and also compressing log files and rotating correctly. But, when i try to run script for /var/log/ i am able to get compressed log files but not able to get rotation of compressed log files. Please suggest. I am using below command... (5 Replies)
Discussion started by: VSom007
5 Replies

7. Red Hat

Logrotate to delete file which has date stamp

Hello, can someone please suggest how to create an logrotate for this scenario. Need to delete all log file which are created more than 30 days ago, and all the log file have date stamp on it. I dont want to create a cron job for this task. here is the example -rw-r--r-- 1 tomcat tomcat ... (2 Replies)
Discussion started by: bobby320
2 Replies

8. AIX

Logrotate - /etc/logrotate.conf does't exist

Hi Admins. I have installed logrotate rpm on Aix 6.1. After the installation of rpm, I don't find /etc/logrotate.conf file and /etc/logrotate.d dir . The config file is located in /opt/freeware/etc/logrotate.conf. When I ran logrotate -v /opt/freeware/etc/logrotate.conf I get below... (2 Replies)
Discussion started by: snchaudhari2
2 Replies

9. UNIX for Beginners Questions & Answers

Logrotate exclude log file

Hi all ! I've an issue to exclude a log file from logrotate, I tried this below: /var/log/apache2/*.log { olddir /var/log/apache2/old missingok rotate 50 compress copytruncate notifempty create 644 root root } I tried also:... (0 Replies)
Discussion started by: Arnaudh78
0 Replies

10. UNIX for Beginners Questions & Answers

Logrotate 0 byte file

Hello, For various reasons I decided to rebuild my log server on a new microSD. To simplify matters I restored a backed up copy of the appropriate config files and uploaded them to the new log server once syslog-ng was setup. The issue I am running into now is when logrotate compresses the log... (3 Replies)
Discussion started by: MyUserName7000
3 Replies
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)
All times are GMT -4. The time now is 10:33 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy