access_log - löschen/neuanlegen

Apache, Lighttpd, nginx, Cherokee
Post Reply
weally
Posts: 32
Joined: 2004-09-13 19:25
 

access_log - löschen/neuanlegen

Post 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
chris76
Posts: 1878
Joined: 2003-06-27 14:37
Location: Germering
 

Re: access_log - löschen/neuanlegen

Post by chris76 »

Du solltest dir mal die Konfiguration von logrotate zu Gemüte führen.
Gruß Christian

BofH excuses: YOU HAVE AN I/O ERROR -> Incompetent Operator error
weally
Posts: 32
Joined: 2004-09-13 19:25
 

Re: access_log - löschen/neuanlegen

Post 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?
forest
Posts: 14
Joined: 2004-05-09 23:24
 

Re: access_log - löschen/neuanlegen

Post by forest »

Moin

Mach mal aus dem rotate 99 ein rotate 1 ;)

Greetz
Forest
jojo8897
Posts: 79
Joined: 2004-01-19 14:08
 

Re: access_log - löschen/neuanlegen

Post 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]
Roger Wilco
Posts: 5923
Joined: 2004-05-23 12:53
 

Re: access_log - löschen/neuanlegen

Post 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?
jojo8897
Posts: 79
Joined: 2004-01-19 14:08
 

Re: access_log - löschen/neuanlegen

Post by jojo8897 »

:lol: mega thx
darauf musste erstmal kommen, ok die lizenz war abgelaufen
Post Reply