[Raw Msg Headers][Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scheduler dumps core; problem with sfio?

On Fri, Aug 18, 2006 at 06:02:19PM +0100, Darryl Miles wrote:
> Linux FD_SET/select implementation can only deal with 1024 fds by default.
> Even if you raise the limit you need to audit all your dependant 
> libraries for FD_SET usage as well, and fix them use poll().
> A quick grep of scheduler/*.c shows select() is used in there.
> One possible reason for the crash is that calling FD_SET(1025, 
> &fdsetfoobar)  will compile without warning and appear to execute 
> without crashing on that line, but it actually scribbles over memory, 
> exacly 1 byte over the end of the 'fd_set fdsetfoobar' structure.

Good point..   I have been modifying code to use  poll() -- which
in this case would be The Solution.

> I would guess this is the cause of your SEGV.
> Darryl
> Dawid Kuroczko wrote:
> >Recently I was trying to raise the limit of simultatneous TAs
> >run by scheduler (from aroung 1000 processes to around 3000).
> >
> >So, I raised the limit of open fds (ulimit -n 32767), and also
> >increased the number of open files as seen by the kernel:
> >echo 512000 > /proc/sys/fs/file-max
> >
> >Then I tried to run scheduler.  Scheduler already had a load of
> >messages to deliver (around 1 milion files), so it started forking
> >new children, when suddenly... SEGV.  100% reproducable.

/Matti Aarnio	<mea@nic.funet.fi>
To unsubscribe from this list: send the line "unsubscribe zmailer" in
the body of a message to majordomo@nic.funet.fi