www.smartbusinesschoices.com

Leading Business and Technology,
News and information


Part of the Identityscape.com network...

getxfactor.com jmoodmusic.com smartbusinesschoices.com mintdepot.com lowfaresalways.com evangelicalview.com shoppingpodder.com soproudlywehail.com webnews.ws currenthumor.com

 

 

Ulimit and Inittab
   Smart Linux Business Choices! - the Best of UseNet Postings! Forum Index -> Linux Security  
View previous topic :: View next topic  
Author Message
fritz-bayer@web.de
Guest






PostPosted: Fri Sep 26, 2008 12:06 pm    Post subject: Ulimit and Inittab Reply with quote

Hi,

I'm starting a transparent proxy via the /etc/inittab like this

myproxy:23:respawn:/usr/local/bin/simpleproxy -L SOURCE -R DESTINATION

and run into the file lilmit of 1024 simultaneous network connections.

To increase the limit, I ran ulimit, but that did not help. I guess
because it's scope is limited to the current shell.

Then I increased the file limits by editing /etc/security/limits.conf
to like this
root soft nofile 2024
root hard nofile 2024

However, I still run into the same problem. Now I was wondering,
whether or not the limits defined in /etc/security/limits.conf also
apply to processes started via the inittab?

Fritz
Back to top
Tim Greer
Guest






PostPosted: Fri Sep 26, 2008 10:33 pm    Post subject: Re: Ulimit and Inittab Reply with quote

fritz-bayer@web.de wrote:

Quote:
Hi,

I'm starting a transparent proxy via the /etc/inittab like this

myproxy:23:respawn:/usr/local/bin/simpleproxy -L SOURCE -R DESTINATION

and run into the file lilmit of 1024 simultaneous network connections.


....

Did you run into the limit at start up, without usage, or when you
started getting connections or you had otherwise initiated connections?
I'm not familiar with the proxy you're running, but it doesn't seem
like a very good design to either be suggested to be put in inittab or
especially if it doesn't properly multiplex/thread where you are maxing
out that many connections. I suppose it depends on the design of it,
but I'm curious when you hit the limit?
--
Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc.
Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers
and Custom Hosting. 24/7 support, 30 day guarantee, secure servers.
Industry's most experienced staff! -- Web Hosting With Muscle!
Back to top
Tim Greer
Guest






PostPosted: Fri Sep 26, 2008 11:05 pm    Post subject: Re: Ulimit and Inittab Reply with quote

fritz-bayer@web.de wrote:

Quote:
Hi,

I'm starting a transparent proxy via the /etc/inittab like this

myproxy:23:respawn:/usr/local/bin/simpleproxy -L SOURCE -R DESTINATION

and run into the file lilmit of 1024 simultaneous network connections.



....

Did you run into the limit at start up, without usage, or when you
started getting connections or you had otherwise initiated connections?
I'm not familiar with the proxy you're running, but it doesn't seem
like a very good design to either be suggested to be put in inittab or
especially if it doesn't properly multiplex/thread where you are maxing
out that many connections.  I suppose it depends on the design of it,
but I'm curious when you hit the limit?
--
Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc.
Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers
and Custom Hosting. 24/7 support, 30 day guarantee, secure servers.
Industry's most experienced staff! -- Web Hosting With Muscle!
Back to top
fritz-bayer@web.de
Guest






PostPosted: Sat Sep 27, 2008 7:04 am    Post subject: Re: Ulimit and Inittab Reply with quote

On 26 Sep., 20:33, Tim Greer <t...@burlyhost.com> wrote:
Quote:
fritz-ba...@web.de wrote:
Hi,

I'm starting a transparent proxy via the /etc/inittab like this

myproxy:23:respawn:/usr/local/bin/simpleproxy -L SOURCE -R DESTINATION

and run into the file lilmit of 1024 simultaneous network connections.

...

Did you run into the limit at start up, without usage, or when you
started getting connections or you had otherwise initiated connections?
I'm not familiar with the proxy you're running, but it doesn't seem
like a very good design to either be suggested to be put in inittab or
especially if it doesn't properly multiplex/thread where you are maxing
out that many connections. I suppose it depends on the design of it,
but I'm curious when you hit the limit?
--
Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc.
Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers
and Custom Hosting. 24/7 support, 30 day guarantee, secure servers.
Industry's most experienced staff! -- Web Hosting With Muscle!

I got the error not at startup but after a long time running. The
reason is that the proxy is connecting to some old webserver, which
does not close the connections fast enough. So after a certain time
there are 1024 open and when the proxy tries to get number 1025 I run
into this exception.

However, my original question is: Do limits which I define for root in
limits.conf also count for "non logins" like processes started via
inittab?

Fritz
Back to top
C.
Guest






PostPosted: Wed Oct 01, 2008 11:43 am    Post subject: Re: Ulimit and Inittab Reply with quote

On 27 Sep, 08:04, "fritz-ba...@web.de" <fritz-ba...@web.de> wrote:
Quote:
On 26 Sep., 20:33, Tim Greer <t...@burlyhost.com> wrote:



fritz-ba...@web.de wrote:
Hi,

I'm starting a transparent proxy via the /etc/inittab like this

myproxy:23:respawn:/usr/local/bin/simpleproxy -L SOURCE -R DESTINATION

and run into the file lilmit of 1024 simultaneous network connections.

...

Did you run into the limit at start up, without usage, or when you
started getting connections or you had otherwise initiated connections?
I'm not familiar with the proxy you're running, but it doesn't seem
like a very good design to either be suggested to be put in inittab or
especially if it doesn't properly multiplex/thread where you are maxing
out that many connections. I suppose it depends on the design of it,
but I'm curious when you hit the limit?
--
Tim Greer, CEO/Founder/CTO, BurlyHost.com, Inc.
Shared Hosting, Reseller Hosting, Dedicated & Semi-Dedicated servers
and Custom Hosting. 24/7 support, 30 day guarantee, secure servers.
Industry's most experienced staff! -- Web Hosting With Muscle!

I got the error not at startup but after a long time running. The
reason is that the proxy is connecting to some old webserver, which
does not close the connections fast enough. So after a certain time
there are 1024 open and when the proxy tries to get number 1025 I run
into this exception.

However, my original question is: Do limits which I define for root in
limits.conf also count for "non logins" like processes started via
inittab?

Fritz

The limits.conf settnig is bounded by the settings in the kernel -
what does
cat /proc/sys/fs/file-max

say?
(AIR this is writable to change)

Also, check the number of file handles:
cat /proc/sys/fs/file-nr
(first number is the handles open and in use, last number is max)

C.
Back to top
Display posts from previous:   
   Smart Linux Business Choices! - the Best of UseNet Postings! Forum Index -> Linux Security  
Page 1 of 1
All times are GMT

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum