File size limit exceeded...

Post support questions that directly relate to Linux/Unix operating systems.

Moderators: Developers, Moderators

Post Reply
edgonz
Posts: 19
Joined: Tue Sep 25, 2007 8:50 am

File size limit exceeded...

Post by edgonz »

I had cacti-0.8.6j working fine for two weeks.

My graphs are not displaying any data anymore and when I run:

Code: Select all

/usr/bin/php /usr/share/cacti/poller.php
as cactiuser I get this:
.
.
.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
Waiting on 3/3 pollers.
File size limit exceeded

Also, here's something else I've found:

Code: Select all

/usr/bin/php /usr/share/cacti/cmd.php 3
File size limit exceeded
/usr/bin/php /usr/share/cacti/cmd.php 4
File size limit exceeded
/usr/bin/php /usr/share/cacti/cmd.php 5
File size limit exceeded

As far as I know, no changes were made to the system, other than adding hosts and labels to the graphs.
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

You cacti.log file is to large. Fix it.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
edgonz
Posts: 19
Joined: Tue Sep 25, 2007 8:50 am

Post by edgonz »

Yup, that fixed it.

I created a logrotate on this file.

Thanks! :)
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Logrotate description was added to http://docs.cacti.net recently
Reinhard
edgonz
Posts: 19
Joined: Tue Sep 25, 2007 8:50 am

Post by edgonz »

gandalf wrote:Logrotate description was added to http://docs.cacti.net recently
Reinhard
I followed the instructions about setting up logrotate, with some minor changes to suit my system.

Code: Select all

/var/log/cacti/cacti.log {
# keep 7 versions online
        rotate 7
# rotate each day
        daily
# file should only be up to 5 MegaBytes
        size 5M
# don't compress, but
# if disk space is an issue, change to
        compress
#       nocompress
# create new file with    attributes
        create 644 cactiuser cacti
# add a YYYYMMDD extension instead of a number
        dateext
}
But this is not creating the log rotation as it should. I ran the following command, but it appears that something's not working properly:

Code: Select all

logrotate -fd /etc/logrotate.d/cacti
reading config file /etc/logrotate.d/cacti
reading config info for /var/log/cacti/cacti.log

Handling 1 logs

rotating pattern: /var/log/cacti/cacti.log  forced from command line (7 rotations)
empty log files are rotated, old logs are removed
considering log /var/log/cacti/cacti.log
  log needs rotating
rotating log /var/log/cacti/cacti.log, log->rotateCount is 7
glob finding old rotated logs failed
renaming /var/log/cacti/cacti.log to /var/log/cacti/cacti.log-20071016
creating new log mode = 0644 uid = 502 gid = 101
compressing log with: /bin/gzip
[root@somebox logrotate.d]# ls -al /var/log/cacti/
total 1520
drwxrwxr-x  2 cactiuser cacti    4096 Oct 15 13:30 .
drwxr-xr-x 10 root      root     4096 Oct 15 16:14 ..
-rw-rw-r--  1 cactiuser cacti 1540044 Oct 16 09:20 cacti.log
I've been over the logrotate config and it seems ok; is there something I missed?

Thanks.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

As long as you're using the "-d" option, logrotate will not perform ANY changes
Reinhard
edgonz
Posts: 19
Joined: Tue Sep 25, 2007 8:50 am

Post by edgonz »

Well, I meant they're not rotating at their 5MB intervals as they're supposed to. They keep growing over 10MB, and not rotating. I'm wondering if I'm missing something else on my logrotate config.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Is a time option along with a filesize allowed?
Reinhard
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests