Current time: 12-23-2024, 05:36 PM Hello There, Guest! (LoginRegister)


Post Reply 
[Resuelto] error en logrotate
Author Message
morgan Offline
Junior Member
*

Posts: 63
Joined: Dec 2007
Reputation: 0
Post: #1
[Resuelto] error en logrotate
buenas tarde uso al version 1.07
y tengo este error:

error: ispcp:65 duplicate log entry for /var/log/apache2/access.log


alguna idea?

Un saludo y gracias
(This post was last modified: 12-24-2010 08:24 PM by kurgans.)
12-15-2010 03:01 AM
Find all posts by this user Quote this message in a reply
kilburn Offline
Development Team
*****
Dev Team

Posts: 2,182
Joined: Feb 2007
Reputation: 34
Post: #2
RE: error en logrotate
Puedes pegarnos lo que tienes en los ficheros /etc/logrotate.d/apache2 y /etc/logrotate.d/ispcp por favor? Qué OS/Distro/Versión usas?
12-15-2010 03:59 AM
Visit this user's website Find all posts by this user Quote this message in a reply
morgan Offline
Junior Member
*

Posts: 63
Joined: Dec 2007
Reputation: 0
Post: #3
RE: error en logrotate
Aqui va Debian Lenny ispcp 1.07 instalada de cero,

/etc/logrotate.d/apache2:

/var/log/apache2/*.log {
weekly
missingok
rotate 52
compress
delaycompress
notifempty
create 640 root adm
sharedscripts
prerotate
/var/www/ispcp/engine/awstats/awstats_updateall.pl now -awstatsprog=/usr/lib/cgi-bin/awstats.pl &> /dev/null
endscript
postrotate
if [ -f "`. /etc/apache2/envvars ; echo ${APACHE_PID_FILE:-/var/run/apache2.pid}`" ]; then
/etc/init.d/apache2 reload > /dev/null
fi
endscript
}

/etc/logrotate.d/ispcp:

/var/log/apache2/users/*.log {
weekly
missingok
rotate 52
compress
delaycompress
notifempty
create 640 root adm
sharedscripts
prerotate
/var/www/ispcp/engine/traffic/ispcp-vrl-traff >/var/log/ispcp/ispcp-vrl-traff.log 2>&1
endscript
postrotate
if [ -f "`. /etc/apache2/envvars ; echo ${APACHE_PID_FILE:-/var/run/apache2.pid}`" ]; then
/etc/init.d/apache2 reload > /dev/null
fi
endscript
}
# Rotation for user traffic prevs
#
/var/log/apache2/backup/*.log.prev {
size 5M
missingok
rotate 5
compress
delaycompress
notifempty
create 640 root adm
}
# Rotation for apache2, launching general statistics if awstats is installed
#
/var/log/apache2/*.log {
weekly
rotate 52
missingok
compress
delaycompress
notifempty
create 640 root adm
sharedscripts
prerotate
if [ `cat /etc/ispcp/ispcp.conf | grep -c 'AWSTATS_ACTIVE *= *yes'` = 1 ]; then
perl /var/www/ispcp/engine/awstats/awstats_updateall.pl now -awstatsprog=/usr/lib/cgi-bin/awstats.pl >/dev/null 2>&1
fi
endscript
postrotate
if [ -f "`. /etc/apache2/envvars ; echo ${APACHE_PID_FILE:-/var/run/apache2.pid}`" ]; then
/etc/init.d/apache2 reload > /dev/null
fi
endscript
}
# Rotation for ispcp-apache-logger logfiles
#
"/var/log/ispcp/ispcp-apache-logger.stderr" /var/log/ispcp/ispcp-apache-logger.stdout {
weekly
rotate 2
size 10M
missingok
compress
delaycompress
notifempty
create 640 root adm
}

# ProFTPd traffic rotation for ispCP traffic count
#
/var/log/proftpd/ftp_traff.log {
daily
rotate 7
missingok
compress
delaycompress
prerotate
/var/www/ispcp/engine/traffic/ispcp-vrl-traff >/var/log/ispcp/ispcp-vrl-traff.log 2>&1
endscript
postrotate
if [ -e /var/run/syslogd.pid ]; then
/usr/bin/killall -HUP syslogd
elif [ -e /var/run/rsyslogd.pid ]; then
/usr/bin/killall -HUP rsyslogd
fi
endscript
}


# ProFTPd traffic rotation for ispCP traffic count
#
/var/log/proftpd/ftp_traff.log {
daily
rotate 7
missingok
compress
delaycompress
prerotate
/var/www/ispcp/engine/traffic/ispcp-vrl-traff >/var/log/ispcp/ispcp-vrl-traff.log 2>&1
endscript
postrotate
if [ -e /var/run/syslogd.pid ]; then
/usr/bin/killall -HUP syslogd
elif [ -e /var/run/rsyslogd.pid ]; then
/usr/bin/killall -HUP rsyslogd
fi
endscript
}

es un error de la instalacion que repite el logrotate del apache pero no cual quitar.

Gracias de antemano

Un saludo desde el sur
12-15-2010 04:46 AM
Find all posts by this user Quote this message in a reply
kilburn Offline
Development Team
*****
Dev Team

Posts: 2,182
Joined: Feb 2007
Reputation: 34
Post: #4
RE: error en logrotate
Quita este archivo: /etc/logrotate.d/apache2
12-15-2010 10:15 PM
Visit this user's website Find all posts by this user Quote this message in a reply
morgan Offline
Junior Member
*

Posts: 63
Joined: Dec 2007
Reputation: 0
Post: #5
RE: error en logrotate
(12-15-2010 10:15 PM)kilburn Wrote:  Quita este archivo: /etc/logrotate.d/apache2

Gracias Kilburn lo raro es que se haya creado no, es un error de la isntalacion de la 1.07?

Un saludote
12-16-2010 03:17 AM
Find all posts by this user Quote this message in a reply
kilburn Offline
Development Team
*****
Dev Team

Posts: 2,182
Joined: Feb 2007
Reputation: 34
Post: #6
RE: error en logrotate
Pues parece que sí es un error. La cosa es que como la instalación misma ya modifica el fichero "/etc/logrotate.d/apache2", el nuevo fichero "/etc/logrotate.d/ispcp" no debería especificar ninguna rotación para los archivos "/var/log/apache2/*.log", pero si lo hace.

Abre un ticket si te animas Wink
12-17-2010 09:35 AM
Visit this user's website Find all posts by this user Quote this message in a reply
sfera Offline
Junior Member
*

Posts: 129
Joined: Oct 2008
Reputation: 0
Post: #7
RE: [Resuelto] error en logrotate
Pero para que sirve exactamente el log rotate???
He activado esta opcion y me han desaparecido la mayoria de logs el servidor de cocupar 700 gb ha pasado a 74gb, He perdido lso logs acumulados durante el ultimo año?
(This post was last modified: 12-31-2011 08:27 AM by sfera.)
12-31-2011 08:21 AM
Find all posts by this user Quote this message in a reply
kurgans Offline
Moderator
*****
Moderators

Posts: 1,565
Joined: Feb 2008
Reputation: 23
Post: #8
RE: [Resuelto] error en logrotate
Si, debes mirar los parametros del rotate de manera que lo pones como quieras, en cuantos debe mantener, <<<rotate 10>>(.tar.gz), si rota semanalmente conserva 10

tiempos para su rotacion, tamaños maximos etc...

No creo que te sirva de mucho un log con mas de entre 2 y 4 semanas por lo menos para mi forma de trababar ya claro como en todo hay un tiesto para cada maceta

Para ver todas las posibilidades y como ponerlo a tus necesidades

man logrotate
(This post was last modified: 12-31-2011 08:15 PM by kurgans.)
12-31-2011 08:11 PM
Visit this user's website Find all posts by this user Quote this message in a reply
Post Reply 


Forum Jump:


User(s) browsing this thread: 1 Guest(s)