LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat
User Name
Password
Red Hat This forum is for the discussion of Red Hat Linux.

Notices


Reply
  Search this Thread
Old 09-12-2013, 05:12 AM   #1
makupl
LQ Newbie
 
Registered: Sep 2013
Posts: 23

Rep: Reputation: Disabled
(Hello&Help with) logrotate omits specified parameters of particular logs


Hello.
I'm testing logrotate and can't find out why some settings are not taken in in use in my configuration.
I configure logrotation of yum log for testing purposes.
I edidted yum file in /etc/logrotate.d/ directory and put:
/var/log/yum.log {
daily
start 0
rotate 2
compress
create 0600 root root
}
Now. In /var/log is only one log yum.log
I execute logrotate command with -f to not edit /var/lib/logrotate.status all the time and what I see
I see compressed backup of yum.log (yum.log-'today_date'.gz) which looks good at first glance but is not imho.
I exec ommand more time and nothing happens)
I I understand correctly it should create backup with .0 suffix .1 and then rotate when next occurence. Somehow rotate and start is not taken in use while compress is working at least.
Please help me.
BTW in some tutorials rotate means how many (count) rotates will be kept.
While in /etc/logrotate.conf comment says:
# keep 4 weeks worth of backlogs

I'm confused.
Waiting for some good explanation.
Thank you.

Update.
It started work for me when commented - it seems it is not ovewriten by rotate parameter.
# dateext

But the question is stil valid
in some tutorials rotate means how many (count) rotates will be kept.
In /etc/logrotate.conf comment says:
# keep 4 weeks worth of backlogs
but in man for rotate is something different
How this two parameters correspond each other?

Last edited by makupl; 09-12-2013 at 05:27 AM. Reason: more tests
 
Old 09-16-2013, 07:03 AM   #2
makupl
LQ Newbie
 
Registered: Sep 2013
Posts: 23

Original Poster
Rep: Reputation: Disabled
Unhappy

I don't believe. Noone experienced that issue?
 
Old 09-16-2013, 09:28 AM   #3
zhjim
Senior Member
 
Registered: Oct 2004
Distribution: Debian Squeeze x86_64
Posts: 1,748
Blog Entries: 11

Rep: Reputation: 233Reputation: 233Reputation: 233
See what time spec the default logrotate.conf has. Then it does make sense why it has "keeps 4 weeks worth of backlogs"
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
logrotate not compressing logs vonedaddy Linux - Server 1 07-03-2013 11:09 PM
logrotate - How to delete uncompressed logs diamond_D Linux - Newbie 4 11-03-2011 09:57 PM
logrotate for logs that change filenames badkuk Linux - Server 1 11-26-2010 02:57 AM
Logrotate doesn't rotate logs kenneho Linux - Desktop 5 03-23-2010 12:13 PM
Logrotate: Rotate Apache logs, but never delete kenneho Linux - Newbie 2 10-23-2008 06:58 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Red Hat

All times are GMT -5. The time now is 03:45 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration