Solved

Apache Log files not Updated

Posted on 2001-07-24
6
195 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
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

NFR key for Veeam Backup for Microsoft Office 365

Veeam is happy to provide a free NFR license (for 1 year, up to 10 users). This license allows for the non‑production use of Veeam Backup for Microsoft Office 365 in your home lab without any feature limitations.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Traceroute command on mac printing * * *** 10 89
How to identify SSH user interactive login? 15 85
Measure data download 2 126
Understanding ping command in Ubuntu 5 30
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…

756 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