rotate_logfiles possibly loss of information
Hello ! I discovered that the script /etc/cron.daily/aaa_base_rotate_logs may loose information in the logfiles. it performs the following steps (a bit simplified) 1. cp "logfile" "logfile".o 2. cp "/dev/null" "logfile" 3. reload the service 4. compress the logfile etc. All data written to the logfile between step 1 and 2 will be lost. I don't know if it's save to cp a file while another process is writing to it, if not, step 1 alone may loose data. I wonder why this script doesn't do it the "normal" (or what I thought the normal way is):(a bit simplified) 1. mv "logfile" "logfile".o 2. touch "logfile" 3. reload the service 4. ... I think the security ml is appropriate, because (in)complete are very relevant for the security of our systems. thank you Nicolas/Severin -- Wiedemann EDV Systeme GmbH Landsbergerstr. 77 80339 München Tel.: 089/5108599-0 Fax.: 089/5108599-99
participants (1)
-
Severin Wiedemann