Solved

Apache Log files not Updated

Posted on 2001-07-24
6
192 Views
Last Modified: 2010-03-18

Dear Experts,

I have apache with some virtual web pages.  I noticed that some of these web pages log files don't get updated somtimes.  I'm not when and how.

Your help is appreciated.
0
Comment
Question by:u4
6 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 6312190
how do you know that they are not updated?
0
 

Author Comment

by:u4
ID: 6313025

I was going into some of these files to see who is visiting my web pages and asking for which files, and I noticed once that it should have logged myself since I just viewed the page and it did not do so.  Then I on purpose browsed the page again and then no logging.  As if the logging stopped at certain time while the web server is up and running.  at other times I would find that it is logging and sometimes it stops logging, then it goes back to logging at certain point, I'm not sure when, why and/or how.

I know this sounds strange but it is what I'm getting.
0
 
LVL 3

Expert Comment

by:interiot
ID: 6313155
I've gotten the same thing before.  They way I knew is I was had tcpdump running, logging all incoming SYN packets and all outgoing SYN.ack packets.  Tcpdump was reporting www connections being made, but apache was not.

(This was on the evening of the Code Red Worm attacks, BTW)
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 
LVL 3

Accepted Solution

by:
tdaoud earned 300 total points
ID: 6313275

Do you edit the logfiles by hand?  Do you save if you edit your log files in an editor say "vi"?

If you edit any of your logfiles by hand and save afterwards, Apache will stop logging to that file (I'm not sure why....it maybe a security related feature that I don't know about).

I found out that since I moved to RedHat 7.1 that comes with it Apache 1.3.19

In the past I sometimes would edit my logfiles to remove certain logs that I made while testing my web page.  It used to continue logging afterwards, but now with apache 1.3.19, it is not doing the same anymore, and I have to restart httpd everytime I do edit a logfile...but I stopped editing such logfiles for the sake of it.  If I ever do, I will remember to restart httpd.

Hope that helps explain your problem if it is similar to what I faced.

Good Luck,

Tarik
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 6313689
logging is delayed, usually. Means that the file will be flushed to disk every 8kb or so. So you do not see the messages immedeately, but if the (8k) buffer is flushed.
(the size of the buffer depends on kernel settings)
0
 

Author Comment

by:u4
ID: 6316136

Thanks a lot.

After several testing, that is exactly what I'm doing wrong.  I noticed on several tests that if I edit one of the logfiles and do a save in the editor, it stops logging to that file while other logfiles are still updated.

Abe
0

Featured Post

Enabling OSINT in Activity Based Intelligence

Activity based intelligence (ABI) requires access to all available sources of data. Recorded Future allows analysts to observe structured data on the open, deep, and dark web.

Join & Write a Comment

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

705 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now