PLEASE NOTE: Native Lighttpd Windows builds are available at http://en.wlmp-project.net/
The last available Lighttpd for Windows build that I created using Cygwin was Lighttpd for Windows 1.4.17. Updated September 29, 2009.
This version incorporates patches from lighttpd.net and fixes file uploads, since it was looking for /var/tmp which does not exist on windows.
If you download 1.4.10a, Please DIGG it, thanks.
Did you enjoy this article? Please subscribe to my feed to receive FREE updates via RSS or Email.


{ 51 comments }
← Previous Comments
Next Comments →
reg.exe is located in %SYSTEMROOT%\system32 which on most machines would be C:\WINDOWS\system32
I noticed on my machine at home that it wasn’t in my path and if thats the case, you will not have the extra keys and values in the registry. Try copying reg.exe into sbin or adding c:\windows\system32 to your path. If that doesn’t help, feel free to mail me with the any error output of the batch file.
I copied reg.exe to c:\lighttpd\sbin. Then I ran the batch file again. After the ‘completed successfully’ portion of the output, I get:
I think this is due to the ‘goto end’ line, and that makes sense since there’s nothing labelled ‘end’.
Suggestions?
> The LighttpdServer service on Local Computer started and then stopped
Try deleting the log files.
I had the same problems, because i initially launched lighty under my account, and it created log files, and then when i tried to launch it as a service it crashed when opening the logs because it was trying to open them under the system account, when they were owned by my user account.
I get the same thing after deleting the log files.
Maybe it is being cached for a certain amount of time and then discarded. Maybe that’s the obvious, but unfortunately I don’t know how to speed it up and increase its performance. Try the forum on lighttpd.net
Sorry, can’t help you then.
But something that *does* strike me – when i’m using my rails web application, it usually runs really snappy. But occasionally, if i leave it for 10 minutes and don’t access it, the next page i access is really slow, and after that its all snappy again.
Any ideas?
Ran into a problem. Tried running it, and nothing happened. Checked the logs, nothing. Rebooted, started, nothing.
I edited the batch start file, removed the exit, then ran it again. Got this error:
C:\lighttpd\sbin>start-lighttpd.bat
8 [main] ? (2416) C:\lighttpd\sbin\lighttpd.exe: *** fatal error – system
shared memory version mismatch detected – 0x75BE0074/0x75BE0096.
This problem is probably due to using incompatible versions of the cygwin DLL.
Search for cygwin1.dll using the Windows Start->Find/Search facility
and delete all but the most recent version. The most recent version *should*
reside in x:\cygwin\bin, where ‘x’ is the drive on which you have
installed the cygwin distribution. Rebooting is also suggested if you
are unable to find another cygwin DLL.
Fixing it is easy enough, but the error is never apparent unless you remove the EXIT from the batch script.
Just an FYI. Thanks for the port!
Yes, this is a known problem. It’s the first thing I ask people to check when lighttpd won’t start for them – if another cygwin1.dll exists anywhere else on the system…
Thanks for the explanation though. And you’re welcome for the port.
I figured out my problem – frigging windows xp (not lighty or scgi or rails) defaults to having its ethernet port go into power-saving mode (ie turn off) if its not used for 15 minutes.
Lighty’s logs weren’t even showing that it had any idea of the requests coming its way – because the requests weren’t even getting past XP.
Grr, at least its fixed now.
Does anyone have any benchmarks or comparisons running lighttpd+SCGI+rails vs. webrick on production applications?
I’ve found that comparatively pages that take handle around 5-10 requests per second now handle between 10-20 requests per second.
chris hulbert: how did you modify the ethernet port so that it does not go into power saving mode?
Graham: I don’t have experience with this. Anybody else…?
What about fastcgi and perl (i use ActivePerl)? Please help me make config for simple script:
—-
#!c:/home/perl/bin/perl.exe
use CGI::Fast qw(:standard);
$COUNTER = 0;
while (new CGI::Fast) {
print header;
print
h1(“Fast CGI Test”),
“Invocation number “, b($COUNTER++),
hr;
print end_html;
}
—-
#!c:/home/perl/bin/perl.exe
thanks
alex: FastCGI is known not to work on lighttpd/win32 right now.
@Kev: You can set the power saving mode options in the device manager.
This is just a heads-up to anybody following this thread: lighttpd 1.4.11 for windows has been released. Read about it and download it here.
1.does Lighttpd 1.4.10a For Windows support those php script encode by zend?
2.does it support mod_bandwidth,if it does not,then where can i get mod_bandwidth.dll
Voaneos: First, as of this writing, the latest version of Lighttpd for Windows is 1.4.11, which you can grab here:
Lighttpd for Windows 1.4.11.
To answer your questions:
1. Assuming that you use a cgi enabled version of PHP, yes, this should work.
2. I don’t see mod_bandwidth included in this release. I would have to compile that option in, but I currently do not have the time. I will do my best to include it in the next version, most likely 1.4.12.
I installed Lighttpd for Windows 1.4.11. But when i start lighttpd, it will close soon… I have no another cygwindll.
henry: try copying the following into an MS-DOS prompt (Start–>Run…–>cmd):
C:\lighttpd\sbinlighttpd.exe -f C:\lighttpd\etc\lighttpd.conf
report the output back here if you can’t figure out the problem.
output is empty. The logs are also empty(0k)
henry: if there is not an error, lighttpd should be running…
But I cannot found the process in task manager.
And cannot connect http://127.0.0.1
henry: have you tried uninstalling and then re-installing lighttpd? Have you tried searching for “cygwin1.dll” on your whole system, to be 100% positive that another file is not present? Can you reproduce lighttpd not working on another Windows system (if you access to another)? Also please indicate which version of Windows you are running.
1. yes, uninstall/re-install, still failed
2. yes, no another cygwin1.dll, but I had installed cygwin, but uninstalled
3. I installed it in another windows xp, it can run…
4. my os is XP pro, sp1
henry: I’m not really sure what the problem could be. Maybe you could try to upgrade to SP2. Also, do you have a firewall running, such as ZoneAlarm or Kerio? If you do have a firewall, it might be blocking port 80.
← Previous Comments
Next Comments →
Comments on this entry are closed.
{ 1 trackback }