LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 06-13-2003, 08:42 AM   #1
TruckStuff
Member
 
Registered: Apr 2002
Posts: 498

Rep: Reputation: 30
Logrotate conf: unexpted text


I recently added another conf file to /etc/logrotate.d to rotate some logs I keep for work. Problem is that every time it runs the script, I recieve the following error:
Code:
error: customlogs:3 unexpected text
I've read through the man pages and everything looks to be in order to me. Can someone point me in the right direction?
Code:
[root@localhost root]# cat /etc/logrotate.d/customlogs
/home/php/logs/log1 /home/php/logs/log2 /home/php/logs/log3 /home/php/logs/log4 {
     missingok
     errors root
     rotate 6
     weekly
     nocompress
     postrotate
          /usr/bin/killall -HUP syslogd
     endscript
}

Last edited by TruckStuff; 06-13-2003 at 08:43 AM.
 
Old 06-13-2003, 09:31 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Looks OK to me.
What's the output running "logrotate -d -v /etc/logrotate.d/customlogs"?
 
Old 06-16-2003, 11:25 AM   #3
TruckStuff
Member
 
Registered: Apr 2002
Posts: 498

Original Poster
Rep: Reputation: 30
Code:
[root@localhost root]# logrotate -d -v /etc/logrotate.d/customlogs
reading config file /etc/logrotate.d/customlogs
reading config info for /home/php/logs/log1 /home/php/logs/log2 /home/php/logs/log3 /home/php/logs/log4
/etc/logrotate.d/customlogs: 3: the errors directive is deprecated and no longer used.
error: /etc/logrotate.d/customlogs:3 unexpected text

Handling 1 logs

rotating pattern: /home/php/logs/log1 /home/php/logs/log2 /home/php/logs/log3 /home/php/logs/log4  weekly (6 rotations)
empty log files are rotated, old logs are removed
considering log /home/php/logs/log1
  log does not need rotating
considering log /home/php/logs/log2
  log does not need rotating
considering log /home/php/logs/log3
  log does not need rotating
considering log /home/php/logs/log4
  log /home/php/logs/log4 does not exist -- skipping
 
Old 06-17-2003, 08:00 PM   #4
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Since you posted only the output and no comments, line 3 says "the errors directive is deprecated and no longer used.", so comment out the "errors root" line.
 
Old 06-18-2003, 08:55 AM   #5
TruckStuff
Member
 
Registered: Apr 2002
Posts: 498

Original Poster
Rep: Reputation: 30
That did the trick. Odd since I pulled that directive from the man page. Guess its an old man page. Thanks for your help.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Logrotate Help! MaverickApollo Linux - Software 3 02-19-2004 12:09 PM
logrotate dominant Linux - Newbie 1 02-13-2004 09:28 AM
logrotate Rig24 Linux - Newbie 2 07-11-2003 05:08 AM
logrotate MrJoshua Linux - General 2 09-25-2002 09:55 AM
Logrotate errors.! Stingreen Linux - Networking 1 03-14-2002 02:22 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:25 PM.

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