From: boating12345
Subject: Allegro serve too many open files
Date: 
Message-ID: <1163176156.325579.171910@e3g2000cwe.googlegroups.com>
Dear All

LEWIS is running like a dream in SBCL except for sometimes when he gets
a bit ill.

Allegroserve goes bannas up the screen saying "Allegroserve - too many
open files", which I guess means that we've got too many people
accessing the websites??? Who knows can't find any documentation on
this error at all.

Anyone any ideas?

Paul
www.hyperstring.net

From: Pascal Bourguignon
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <87r6wbntvb.fsf@thalassa.informatimago.com>
"boating12345" <············@hyperstring.net> writes:

> Dear All
>
> LEWIS is running like a dream in SBCL except for sometimes when he gets
> a bit ill.
>
> Allegroserve goes bannas up the screen saying "Allegroserve - too many
> open files", which I guess means that we've got too many people
> accessing the websites??? Who knows can't find any documentation on
> this error at all.
>
> Anyone any ideas?

This may be an OS limit.

Check ulimit and check the kernel parameters.


-- 
__Pascal Bourguignon__                     http://www.informatimago.com/
In deep sleep hear sound,
Cat vomit hairball somewhere.
Will find in morning.
From: boating12345
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <1163176564.586219.148480@m7g2000cwm.googlegroups.com>
Pascal Bourguignon wrote:
> "boating12345" <············@hyperstring.net> writes:
>
> > Dear All
> >
> > LEWIS is running like a dream in SBCL except for sometimes when he gets
> > a bit ill.
> >
> > Allegroserve goes bannas up the screen saying "Allegroserve - too many
> > open files", which I guess means that we've got too many people
> > accessing the websites??? Who knows can't find any documentation on
> > this error at all.
> >
> > Anyone any ideas?
>
> This may be an OS limit.
>
> Check ulimit and check the kernel parameters.
>
>
> --
> __Pascal Bourguignon__                     http://www.informatimago.com/
> In deep sleep hear sound,
> Cat vomit hairball somewhere.
> Will find in morning.

Hi Pascal

Thanks so much for your reply!

I did ulimit and it says unlimited

I'm running ubuntu 6.10 SERVER with no GUI! :-) (its a server!)

Paul
http://www.hyperstring.net
From: Pascal Bourguignon
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <87mz6znry1.fsf@thalassa.informatimago.com>
"boating12345" <············@hyperstring.net> writes:
> Pascal Bourguignon wrote:
>> "boating12345" <············@hyperstring.net> writes:
>> > Allegroserve goes bannas up the screen saying "Allegroserve - too many
>> > open files", which I guess means that we've got too many people
>> > accessing the websites??? Who knows can't find any documentation on
>> > this error at all.
>>
>> This may be an OS limit.
>> Check ulimit and check the kernel parameters.
>
> I did ulimit and it says unlimited
> I'm running ubuntu 6.10 SERVER with no GUI! :-) (its a server!)

You can also use lsof to see all the open files.

On linux, you can see the limit of the kernel with:

(defun file-max () 
    (with-open-file (in "/proc/sys/fs/file-max") (read in)))

And you can change it (if run on root account) with:

(defun (setf file-max) (value) 
    (with-open-file (out "/proc/sys/fs/file-max" :direction :output
                     :if-does-not-exist :error :if-exists :overwrite) 
      (prin1 value out) (terpri out)) 
    value)


-- 
__Pascal Bourguignon__                     http://www.informatimago.com/

There is no worse tyranny than to force a man to pay for what he does not
want merely because you think it would be good for him. -- Robert Heinlein
From: boating12345
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <1163183089.701605.296020@b28g2000cwb.googlegroups.com>
HI Pascal

VERY interesting, that seems to have solved it, I suppose that the os
sees streams as open files! So to run allegroserve or any other web
server you need to make sure you can have enough files open!

You know what hits me is just how much we have to change stuff at
operating system level  to make it work under pressure. But there is
something wonderful, the linux servers we build are custom built for
LEWIS rather than just chucking it on some other box.

Thank you so much for your help.
From: Bill Atkins
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <m2zmazi27k.fsf@weedle-24.dynamic.rpi.edu>
"boating12345" <············@hyperstring.net> writes:

> HI Pascal
>
> VERY interesting, that seems to have solved it, I suppose that the os
> sees streams as open files! So to run allegroserve or any other web
> server you need to make sure you can have enough files open!

Yes, each stream has an underlying socket, and sockets need file
descriptors (not technically an open file).

> But there is
> something wonderful, the linux servers we build are custom built for
> LEWIS rather than just chucking it on some other box.

?
From: boating12345
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <1163186464.046734.99740@m7g2000cwm.googlegroups.com>
Bill Atkins wrote:
> "boating12345" <············@hyperstring.net> writes:
>
> > HI Pascal
> >
> > VERY interesting, that seems to have solved it, I suppose that the os
> > sees streams as open files! So to run allegroserve or any other web
> > server you need to make sure you can have enough files open!
>
> Yes, each stream has an underlying socket, and sockets need file
> descriptors (not technically an open file).
>
> > But there is
> > something wonderful, the linux servers we build are custom built for
> > LEWIS rather than just chucking it on some other box.
>
>

Right! (both of you) it's really great when you move from Windows and
VB/Asp/.net to Ubuntu SBCL and build something like this - I'm really
grateful to you guys for the help!

We've moved our business over to Ubuntu and Lisp as our main
development environment and wow it's amazing - you know today one of
our clients wanted to put a lot of little enquiry forms on his site.
Thanks to LISP I wrote 12 lines of code and he was able to add forms
all over his site that emailed him and identified themselves! For a web
developer it's quite a leap but a wonderful one - Lisp is just one
beautiful language.

Thank you again so much!
From: Pascal Bourguignon
Subject: Re: Allegro serve too many open files
Date: 
Message-ID: <87ejsbnohz.fsf@thalassa.informatimago.com>
"boating12345" <············@hyperstring.net> writes:
> VERY interesting, that seems to have solved it, I suppose that the os
> sees streams as open files! So to run allegroserve or any other web
> server you need to make sure you can have enough files open!
>
> You know what hits me is just how much we have to change stuff at
> operating system level  to make it work under pressure. But there is
> something wonderful, the linux servers we build are custom built for
> LEWIS rather than just chucking it on some other box.

Well, you cannot have an OS working from wristwatches up to
supercomputers without doing some tuning from time to time...  And
unix in general and linux in particular really don't need a lot of
such tuning, compared to the other OS.

-- 
__Pascal Bourguignon__                     http://www.informatimago.com/

"Specifications are for the weak and timid!"