This is the contents so it appears to be:
#!/bin/sh

DIRS="/var/log/rrd/ /var/ntop/"

rm /home/httpd/html/graphs/*.png &>/dev/null

find $DIRS -name "*.rrd" | \
    while read F; do
    NOW=$(date "+%s")
    LAST=$(rrdtool last $F)
    if [ "$LAST" -gt "$NOW" ]; then
        echo "rrd file $F contains timestamps in future. Remove the file!"
        rm -f $F
    fi
done

ntop does appear to be the owner also:
[EMAIL PROTECTED]:/var/ntop/rrd # ls -al
total 20
drwxr-xr-x  5 ntop ntop 4096 Nov 15 14:10 .
drwxr-xr-x  4 ntop ntop 4096 Dec  3 10:18 ..
drwx------  8 ntop ntop 4096 Nov 25 23:15 flows
drwx------  2 ntop ntop 4096 Dec  3 09:31 graphics
drwx------  5 ntop ntop 4096 Nov 16 18:50 interfaces


compdoc wrote:
> 
> That should be a fine cpu for ewf.
> 
> I have no files in /var/ntop/rrd/flows/
> 
> Open rrdfix.sh with an editor. Is it the same as mine?
> 
> Try these commands:
> 
> cd /var/ntop/rrd
> ls -al
> 
> total 20
> drwxr-xr-x  5 ntop ntop 4096 Oct 14 08:01 .
> drwxr-xr-x  4 ntop ntop 4096 Nov 27 16:51 ..
> drwx------  2 ntop ntop 4096 Oct 14 08:01 flows
> drwx------  2 ntop ntop 4096 Nov 16 20:12 graphics
> drwx------  3 ntop ntop 4096 Oct 14 08:02 interfaces
> 
> 
> is ntop the user/owner for these directories? Do they have
> the same permissions?
> 
> 
> 
> 
> -----Original Message-----
> From: danodemano [mailto:[EMAIL PROTECTED] 
> Sent: Wednesday, December 03, 2008 9:14 AM
> To: efw-user@lists.sourceforge.net
> Subject: Re: [Efw-user] rrdfix.sh VERY high CPU and memory
> usage EFW 2.2RC3
> 
> 
> I believe it to be a 2GHz (though I'm not sure) dual core
> Pentium so I doubt
> the CPU is the problem.
> 
> Running the script by hand give a few errors and takes about
> 4 minutes:
> [EMAIL PROTECTED]:/usr/local/bin # ./rrdfix.sh
> ERROR: opening '/var/ntop/rrd/flows/Host': No such file or
> directory
> ERROR: opening '/var/ntop/rrd/flows/Host': No such file or
> directory
> 
> Those errors appear almost immediately then the rest of the
> time nothing is
> displayed.
> 
> Running "rm /home/httpd/html/graphs/*.png &>/dev/null"
> finishes instantly.
> 
> 
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's
> challenge
> Build the coolest Linux based applications with Moblin SDK & win great
> prizes
> Grand prize is a trip for two to an Open Source event anywhere in the
> world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> Efw-user mailing list
> Efw-user@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/efw-user
> 
> 

-- 
View this message in context: 
http://www.nabble.com/rrdfix.sh-VERY-high-CPU-and-memory-usage-EFW-2.2RC3-tp20813429p20816429.html
Sent from the efw-user mailing list archive at Nabble.com.


-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Efw-user mailing list
Efw-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/efw-user

Reply via email to