DragonFly BSD
DragonFly commits List (threaded) for 2005-06
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: cvs commit: src/sys/sys filedesc.h


From: Joerg Sonnenberger <joerg@xxxxxxxxxxxxxxxxx>
Date: Tue, 21 Jun 2005 22:29:42 +0200
Mail-followup-to: commits@crater.dragonflybsd.org

On Tue, Jun 21, 2005 at 01:00:15PM -0700, Matthew Dillon wrote:
> 
> :On Tue, Jun 21, 2005 at 10:59:47AM -0700, Matthew Dillon wrote:
> :>   Bump fd_lastfile, freefile, and refcnt to 32 bit ints.  Also bump cmask
> :>   (though that doesn't fix any particular bug).  lastfile and freefile were
> :>   previously unsigned shorts which caused the system to become very confused
> :>   when any single user process had more then 65535 open file descriptors.
> :
> :I don't think it can happen with a single process having 64k open file
> :descriptors. It should hit resource limits much earlier. But it is
> :certainly possible for multiple processes to reach this limit. On the
> :other hand, that makes error handling kind of difficult, since e.g.
> :fork() should be able to trigger it.
> :
> :Joerg
> 
>     This can happen trivially because Jeff sent me a program that blows
>     the kernel up.  Resource limits are not hard-limited to 65535 so there
>     is nothing preventing you from bumping them up.

But kern.maxfilesperproc is an upper limit on the number of descriptors?
If not, that's a bigger bug.

Joerg



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]