kern/138999: Lighttpd/php-cgi with freebsd-sendfile enabled causing kernel to not reenter userland

Jacob Myers jacob at whotookspaz.org
Mon Sep 21 01:20:02 UTC 2009


>Number:         138999
>Category:       kern
>Synopsis:       Lighttpd/php-cgi with freebsd-sendfile enabled causing kernel to not reenter userland
>Confidential:   no
>Severity:       critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Mon Sep 21 01:20:01 UTC 2009
>Closed-Date:
>Last-Modified:
>Originator:     Jacob Myers
>Release:        7.2-RELEASE-p3
>Organization:
Wilcox Technologies
>Environment:
FreeBSD IND-Serv003.Wilcox-Tech.com 7.2-RELEASE-p3 FreeBSD 7.2-RELEASE-p3 #1: Wed Aug 26 23:16:03 EDT 2009     root at IND-Serv003.Wilcox-Tech.com:/usr/obj/usr/src/sys/IND-SERV003  i386
>Description:
There is some sort of odd issue involving FreeBSD and lighttpd with respect to lighttpd's use of sendfile(2) causing the kernel to not return to userland (or so we suspect). The kernel responds to ping (and even rate limits ping floods), but all SSH and other connections stop, and all login attempts at the console hang.

I have investigated this problem with a friend of mine, and have been unable to draw any conclusions. Testing this problem with debugging symbols compiled in has caused the bug to manifest itself in a new way, in that sendfile(2) continuously returns EAGAIN without end.
>How-To-Repeat:
0) Make sure the kernel has no debugging enabled (e.g., witness, etc.)
1) Run lighttpd with php-cgi
2) Set server.network-backend = freebsd-sendfile in lighttpd.conf
3) Attempt to upload a file > 2 MB in length or so using a simple PHP script
4) The machine should then be locked from new logins, but will respond to ping
>Fix:
None known.

>Release-Note:
>Audit-Trail:
>Unformatted:


More information about the freebsd-bugs mailing list