Project

General

Profile

Actions

Bug #328

closed

(network_linux_sendfile.c.167) sendfile failed: Invalid argument 6

Added by Anonymous over 16 years ago. Updated about 14 years ago.

Status:
Fixed
Priority:
High
Category:
core
Target version:
-
ASK QUESTIONS IN Forums:

Description

Hello,

all static files that should get send out (css, htm, html, ... files) create this error
and dont send any data to the browser.
Dynamic files like php are no problem.

2005-10-12 17:14:34: (network_linux_sendfile.c.167) sendfile failed: Invalid argument 6
2005-10-12 17:14:34: (connections.c.515) connection closed: write failed on fd 6


Files

lighttpd.conf (11.4 KB) lighttpd.conf lighttpd.conf -- gdolley Anonymous, 2005-11-13 23:14
Actions #1

Updated by Anonymous over 16 years ago

  • Status changed from Fixed to Need Feedback
  • Resolution deleted (fixed)

Same error on:
Debian GNU/Linux sarge
Kernel: 2.4.20 i686 GNU/Linux
lighttpd-1.4.6 (ssl)

2005-10-24 23:46:10: (network_linux_sendfile.c.167) sendfile failed: Function not implemented 6
2005-10-24 23:46:10: (connections.c.515) connection closed: write failed on fd 6

-- lighthttpd-thomas

Actions #2

Updated by Anonymous over 16 years ago

Same error on: Red Hat 7.1

Linux cvs.getopal.com 2.4.1-008stab044.15.swsoft-smp #1 SMP Fri Jul 18 16:29:52 MSD 2003 i686 unknown

2005-11-12 04:19:20: (network_linux_sendfile.c.171) sendfile failed: Invalid argument 6
2005-11-12 04:19:20: (connections.c.529) connection closed: write failed on fd 6

No static data can be served.

How I configured lighttpd:

./configure --prefix=/home/garry/sys/ --with-openssl --disable-ipv6 --disable-lfs

Happens w/ versions 1.4.6 and 1.4.7 (haven't tried any others)

Everything else works fine (FastCGI, etc...), but static content doesn't get served.

My lighttpd.conf file is attached.

-- gdolley

Actions #3

Updated by Anonymous over 16 years ago

sweet, that worked perfectly, thank you!!

-- Garry Dolley

Actions #4

Updated by Anonymous over 16 years ago

  • Status changed from Fixed to Need Feedback
  • Resolution deleted (fixed)

the fix doesn't seem to work with lighttpd 1.4.8 on debian sarge; when I start the server, I get the following message:

(server.c.692) WARNING: unknown config-key: server.network-backend (ignored)

-- coriolinus

Actions #5

Updated by jan over 16 years ago

  • Status changed from Need Feedback to Fixed
  • Resolution set to worksforme

are you sure that you use lighttpd 1.4.8 ?

$ lighttpd -v

will tell you. This option works for me nicely.

Actions #6

Updated by Anonymous over 15 years ago

  • Status changed from Fixed to Need Feedback
  • Resolution deleted (worksforme)

Still happens on 1.4.11. Puppy Linux 2.02.
2006-09-04 19:05:11: (network_linux_sendfile.c.171) sendfile failed: Invalid argument 6 2006-09-04 19:05:11: (connections.c.538) connection closed: write failed on fd 6

Yair

-- yair.almog

Actions #7

Updated by Anonymous about 15 years ago

Hi,
this happens in 1.4.13 too:
On a Virtuozzo Virtual Server - Kernel 2.4.20-021stab028.19.777-enterprise #1 SMP Wed Oct 19 13:05:01 MSD 2005 i686 GNU/Linux

Error-Message:

(network_linux_sendfile.c.171) sendfile failed: Function not implemented 6

(connections.c.588) connection closed: write failed on fd 6

  1. lighttpd -v

lighttpd-1.4.13 (ssl) - a light and fast webserver

Build-Date: Oct 26 2006 15:08:49

Greeting,
Waldemar Dick

-- wdick

Actions #8

Updated by Anonymous about 15 years ago

For a workaround see:
http://forum.lighttpd.net/topic/4829

Greetings, Waldemar Dick

-- wdick

Actions #9

Updated by Anonymous almost 15 years ago

I just dicovered similar problem. In error.log, I have bunches of errors like

(network_linux_sendfile.c.171) sendfile failed: Function not implemented 8
(connections.c.588) connection closed: write failed on fd 8

Lighty is serving about 200req/sec and i have about 10 of these errors per second in log, but I cannot find any specific file or script (i am using php fastcgi), which can cause this. All scripts are working, all static files are served.

Lighttpd v.1.4.13, Debian-Sarge

-- flopin

Actions #10

Updated by Anonymous over 14 years ago

I'm seeing the same issue with document on Linux with tmpfs over ext3 via unionfs. Using server.network-backend = "writev" makes the problem go away.

-- forest

Actions #11

Updated by darix over 14 years ago

unionfs might have a broken sendfile implementation.

Actions #12

Updated by Anonymous over 14 years ago

Hello, I was struc by this bug with
lighttpd-1.4.18 (ssl) - a light and fast webserver
Build-Date: Oct 29 2007 17:14:51.

I was using a symlink to a tmpfs directory, the server.network-backend = "writev" workaround made
the problem go silent yet it still didn't serve the static content.

I hope this helps to further solve this issue, I really prefer to use the tmpfs, my work around for now is to use another filesystem on a block device.

-- carlos

Actions #13

Updated by Anonymous about 14 years ago

I have been able to confirm that yes, this does seem to be a bug in the union filesystem (at least on Asus eeePC 701).

Kenrel: 2.6.21.4-eeepc (Not sure what patches have been included by default).

Actions #14

Updated by stbuehler about 14 years ago

  • Status changed from Need Feedback to Fixed
  • Resolution set to duplicate

See #471

Actions

Also available in: Atom