Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 13 Oct 2004 09:36:03 -0600
From:      "Stephane Raimbault" <segr@hotmail.com>
To:        gnn@FreeBSD.org
Cc:        net@FreeBSD.org
Subject:   Re: Error 49, socket problem?
Message-ID:  <BAY24-F31XehYSoOZzH00010fba@hotmail.com>

next in thread | raw e-mail | index | archive | help
I doubt it's a DoS attack, however it could very well be.

In this particular setup, apache runs on port 80 and 81.  A slimed down 
version of apache handles basic http requests on port 80 and on port 81, we 
have a beefier version of apache with php running applications.  We proxy 
the request from port 80 to port 81 so the client only ever sees connections 
to port 80.

What I find strange is other applications on the server freak out when this 
is happening in the same manner.  such as php not able to make mysql 
connections with a similar error.  The errors aren't limited to 127.0.0.1 
either, it seems to be an overall problem with the box, not specifically the 
loopback or apache.

PHP Warning:  mysql_connect(): Can't connect to MySQL server on 
'dbm.xxx.xxx.com' (49) in /www/index.php on line 4060

In this case the above dbm.xxx.xxx.com resolves to 10.0.12.22 which is one 
of the MySQL server's in the cluster.

I've ruled out that it's a problem with the MySQL server in this case, 
because I have 4 other web servers (running apache) able to connect to that 
MySQL server during the same time.  All web servers in this cluster seem to 
exhibit the error randomly at diffrent times.  Not only during high peak 
traffic times as previously thought.

Are there buffers I could be running out of?  What should I be checking?  
Perhaps something in sysctl...  If I know what I should probably be looking 
at, I can probably monitor and have certain variables logged / graphed for a 
better idea of what is going on.

Thanks,
Stephane.

>From: gnn@FreeBSD.org
>To: "Stephane Raimbault" <segr@hotmail.com>
>CC: net@FreeBSD.org
>Subject: Re: Error 49, socket problem?
>Date: Wed, 13 Oct 2004 12:04:48 +0900
>
>At Tue, 12 Oct 2004 12:52:15 -0600,
>Stephane Raimbault wrote:
> >
> > I have some busy boxes part of a cluster which seems to occassionaly get 
>an
> > Error 49 on various network based applications at the same time.
> >
> > Here is from an apache proxy log
> >
> > [Fri Oct 08 11:26:45 2004] [error] (49)Can't assign requested address:
> > proxy: HTTP: attempt to connect to 127.0.0.1:81 (127.0.0.1) failed
> > [Fri Oct 08 11:26:45 2004] [error] (49)Can't assign requested address:
> > proxy: HTTP: attempt to connect to 127.0.0.1:81 (127.0.0.1) failed
> > [Fri Oct 08 11:26:45 2004] [error] (49)Can't assign requested address:
> > proxy: HTTP: attempt to connect to 127.0.0.1:81 (127.0.0.1) failed
> > [Fri Oct 08 11:26:46 2004] [error] (49)Can't assign requested address:
> > proxy: HTTP: attempt to connect to 127.0.0.1:81 (127.0.0.1) failed
> > [Fri Oct 08 11:26:46 2004] [error] (49)Can't assign requested address:
> > proxy: HTTP: attempt to connect to 127.0.0.1:81 (127.0.0.1) failed
> >
> >
> > Various other things at the same time give a similar error.  Am I 
>running
> > out of sockets on the system?  What is the best way to diagnose this
> > problem.  It seems pretty intermitent, however it seems to occur when 
>the
> > boxes are at some of the busiest moments in it's day.
>
>That's the loopback address (127.0.0.1) and the error you're getting
>is "Address Not Available" (/usr/include/sys/errno.h shows this).  I
>have no idea what apahce is trying to do in that case, but you should
>attempt to figure that out.
>
>One theory is that this is some sort of external attack which puts the
>loopback address into a URL to try and get apache to do something
>"bad".  But, I'm not an apache expert.
>
>Later,
>George
>

_________________________________________________________________
MSNŽ Calendar keeps you organized and takes the effort out of scheduling 
get-togethers. 
http://join.msn.com/?pgmarket=en-ca&page=byoa/prem&xAPID=1994&DI=1034&SU=http://hotmail.com/enca&HL=Market_MSNIS_Taglines 
  Start enjoying all the benefits of MSNŽ Premium right now and get the 
first two months FREE*.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?BAY24-F31XehYSoOZzH00010fba>