Many NULL request in apache

u4xlol

Verified User
Joined
Nov 12, 2009
Messages
60
hello

i see many NULL request in my server apache!
VHost Request
localhost NULL

the requests server load increases ! i want filter NULL request !
please help me

Server version: Apache/2.2.20 (Unix)

thank you
 
hello

screenshot attached

thanks
 

Attachments

  • 555.jpg
    555.jpg
    101.2 KB · Views: 3,116
i see many NULL request in my server apache!
VHost Request
localhost NULL

I think it is normal. I have the same. I think it started around Apache version 2.2.18, but not sure I remember correct version. Anyway, this all started after a previous Apache upgrade. So I think they maade some changes that cause this, and that it is normal, and nothing to do about it.

But it is too bad, because "localhost null" don't provide any useful information at all! I hope Apache devs change it back regarding this. In meantime, I think everybode have the same with several localhost null in Apache server status page.

Edit: I searched my own old post in this forum, and found this: http://www.directadmin.com/forum/showpost.php?p=203347&postcount=7 Here is the thread http://www.directadmin.com/forum/showthread.php?t=40345 - so, I remembered correct - "localhost null" started with Apache version 2.2.18, before that version, I never had those.
 
Last edited:
hello

but my server is overload!
cpu load is over 40~50 !

may filter null request ??

thanks
 
hi

no , just this information!

may i filter NULL requests in server status?
 
You didn't answer the first question, did you?

And is Client IP local or remote there?

Server status shows the real data, if you want and of course if it's possible you need to filter it in Apache (for now I have no ready solution how to do it). I've done some Googling, and two ideas I've met: it's either (D)DoS or searching bots. That is why I've asked you about IPs.

Anyway I hardly go further with guessing. So you'd better refer the question to Apache's community or/and their mailing lists. Or of course you might want to hire somebody from these forums, as there are some guys ready to give you a commerce service (including me).
 
I don't think it would be a good idea to filter "localhost null" shown in Apache server status page, because they are not only boots and spiders, but also legitimate visits - so if you filter those, then you don't know who you are blocking, and you will then also block legitimate visits.

I can see both my own personal computer ip and plenty of other external ips in Apache server status page for "localhost null".
 
@ditto,

So what can it be? A browser that does not send proper request to a web-server? A plugin for a browser?
 
I don't know. But the "localhost null" started to appear after I upgraded to Apache version 2.2.18 as I have described in post above:
http://directadmin.com/forum/showpost.php?p=212194&postcount=4

I never see "localhost null" before Apache 2.2.18. Today I am running 2.2.21, and alot of the trafic shown in Apache server status still show "localhost null". It seems to be random wich shows "localhost null", and wich shows with proper info. I suspect it is a bug or at least some changes in Apache that is causing this. I would believe that everybody else sees this?

Some day I might try to spend time on asking this questions on Apache maliing list or forums, but I don't think it is important enough, so I have not done it yet.
 
I hardly remember I've ever seen it before. That is caused by the fact I'm using nginx as a frontend to Apache, I guess.
 
hello

i want downgrade from Apache/2.2.20 to 2.2.18
1)Whether this is useful?
2)How do I do?
 
on the 2.2.20 version displayed very NULL request , the previous versions did not exist!
this null request ,Server loads have increased ! Sites on the server are constantly interrupted:(
What solution would you suggest?
 
The null requests happen to everyone since apache 2.2x. Just ignore them. They are definitely not the reason for your problem.
 
Hello,

To clairfy, the NULL requests on the "localhost" VirtualHost are requests from browsers like Chrome.
They're pre-connections made by the browser for clients who have already downloaded a webpage from your server.
Basically, the browsers will know that there are links in the webpage that the client may click, so to save time, the browser connects to apache in anticipation of a link being clicked.
However, a request is not yet made, so the browser will simply idle on that connection until the request is made (link is clicked).
During that idle time, apache doesn't know which VirtualHost the connection is for (since the browser has not yet said anything), thus it defaults to the first VH in the list.. which has a ServerName of "localhost".. .. and since no request has been made, the request is NULL.

So you can ignore these entries. They're normal.
No need to change your Apache version.

John
 
Hello,

To clairfy, the NULL requests on the "localhost" VirtualHost are requests from browsers like Chrome.
They're pre-connections made by the browser for clients who have already downloaded a webpage from your server.
Basically, the browsers will know that there are links in the webpage that the client may click, so to save time, the browser connects to apache in anticipation of a link being clicked.
However, a request is not yet made, so the browser will simply idle on that connection until the request is made (link is clicked).
During that idle time, apache doesn't know which VirtualHost the connection is for (since the browser has not yet said anything), thus it defaults to the first VH in the list.. which has a ServerName of "localhost".. .. and since no request has been made, the request is NULL.

So you can ignore these entries. They're normal.
No need to change your Apache version.

John

John I believe there may be a bigger issue here... while NULL are normal and nothing to worry about... I'm seeing many apache servers sitting idle not being closed for very long periods of time... thus resulting in a crash of apache... with too many clients... happening two machines. I have sent in an email with all the details, I would greatly appreciate it if you would take a look.
 
Indeed it's "rude" for a browser to do that. What you can do is lower the timeout to kick them out sooner.
Edit /etc/httpd/conf/extra/httpd-default.conf and change:
Code:
Timeout 60
to a much lower value. Using 5 seconds should be enough time for any browser to make a request.

In addition, you can limit the number of connections from an IP:
http://help.directadmin.com/item.php?id=339
or http://help.directadmin.com/item.php?id=302

John
 
Back
Top