httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Giuliano Catrambone (CatraSoftware)" <>
Subject [users@httpd] memory leak (?) when a copy of the ErrorLog is done
Date Tue, 20 Apr 2010 12:33:17 GMT
    I'm using the httpd apache server and inside the httpd.conf I have
the ErrorLog set as:

        ErrorLog "/logs/SystemLogs.trace"

    I'm using also a custom module writing a lot of trace in the
ErrorLog using the API like:
        ap_log_error (__FILE__, __LINE__, APLOG_ERR, 0, prrRequestRec ->
server, "%s", ".......");
        ap_log_error (__FILE__, __LINE__, APLOG_WARNING, 0,
prrRequestRec -> server, "%s", ".......");

    I have also a crontab job that periodically copy
the /logs/SystemLogs.trace in a repository
        cp /logs/SystemLogs.trace /Repository/SystemLogs.trace
    and reset the current log using the command:
        echo "" > /logs/SystemLogs.trace

    So, the issue is that:
    - every time the copy is done we saw the memory usage is decreased a
lot and
    - if we remove the copied log file (rm /Repository/SystemLogs.trace)
the memory usage is again increased

    Why the memory usage is impacted when the copy of the log file is
done or the copied log file is removed?

    Thanks in advance for your help

View raw message