Page 1 of 1

access_log - löschen/neuanlegen

Posted: 2005-01-22 23:59
by weally
Hallo,

meine access_log Datei ist inwzischen über 7 GB gross, kann ich Datei löschen bzw. eine neue anlegen oder gibt es dann Probleme zwecks Webalizer bzw. den Confixx-Stats?

Danke

Re: access_log - löschen/neuanlegen

Posted: 2005-01-23 00:03
by chris76
Du solltest dir mal die Konfiguration von logrotate zu Gemüte führen.

Re: access_log - löschen/neuanlegen

Posted: 2005-01-23 08:20
by weally
hmm hier mal der Inhalt der logrotate.conf:

Code: Select all

# see "man logrotate" for details
# rotate log files weekly
weekly

# keep 4 weeks worth of backlogs
rotate 4

# create new (empty) log files after rotating old ones
create

# uncomment this if you want your log files compressed
#compress

# uncomment these to switch compression to bzip2
#compresscmd /usr/bin/bzip2
#uncompresscmd /usr/bin/bunzip2

# RPM packages drop log rotation information into this directory
include /etc/logrotate.d

# no packages own wtmp -- we'll rotate them here
#/var/log/wtmp {
#    monthly
#    create 0664 root utmp
#    rotate 1
#}

# system-specific logs may be also be configured here.


In der /etc/logrotate.d/:

/var/log/apache2/access_log {
    compress
    dateext
    maxage 365
    rotate 99
    size=+4096k
    notifempty
    missingok
    create 644 root root
    postrotate
     /etc/init.d/apache2 reload
    endscript
}

/var/log/apache2/error_log {
    compress
    dateext
    maxage 365
    rotate 99
    size=+1024k
    notifempty
    missingok
    create 644 root root
    postrotate
     /etc/init.d/apache2 reload
    endscript
}


Soll ich hier was umstellen?

Re: access_log - löschen/neuanlegen

Posted: 2005-01-25 01:09
by forest
Moin

Mach mal aus dem rotate 99 ein rotate 1 ;)

Greetz
Forest

Re: access_log - löschen/neuanlegen

Posted: 2005-08-11 12:04
by jojo8897
ich habe ein ähnliche problem, bis zum 30 juli lief alles problemlos, seit dem werden die lodfiles nicht mehr geschlossen und archiviert sondern das access_log file wird immer größer.

@Forest
wenn ich aus rotate 99 ein rotate 1 mache wird die datei doch nach einmalrotieren gelöscht und nicht nach 99 mal rotieren, was sollte das bringen? sie müsste ja erstmal rotieren.

kann mir wer helfen

@weally

wie hast du dein problem gelöst?[/quote]

Re: access_log - löschen/neuanlegen

Posted: 2005-08-11 12:58
by Roger Wilco
jojo8897 wrote:ich habe ein ähnliche problem, bis zum 30 juli lief alles problemlos, seit dem werden die lodfiles nicht mehr geschlossen und archiviert sondern das access_log file wird immer größer.
Confixx-Lizenz gültig?

Re: access_log - löschen/neuanlegen

Posted: 2005-08-12 15:35
by jojo8897
:lol: mega thx
darauf musste erstmal kommen, ok die lizenz war abgelaufen