Suchen
Aktuell
- Aktuell
- Kommentare
- TagCloud
- Windows Phone 7: Silverlight und XNA
- 1267769400 1267769400 - Keine Kommentare
- Empfehlung: Microsoft Arc Keyboard
- 1266747660 1266747660 - 2 Kommentare
- C#: Outlook like Pop-up Alert
- 1264008720 1264008720 - Keine Kommentare
- Windows Mobile 7 - Verschiedene Versionen geplant
- 1264007340 1264007340 - Keine Kommentare
- Windows Media Center: Pixelfehler am rechten Rand
- 1260208800 1260208800 - Keine Kommentare
- Das Outlook Fenster kann nicht geöffnet werden #2
- 1259409180 1259409180 - 13 Kommentare
- Bis jetzt sind noch keine Kommentare geschrieben worden
Randnotiz
W3C
- Keine Kommentare
Lighttpd mit Mono: Error 500 Problem
Hier habe ich berichtet, wie man Mono mit Lighttpd zum laufen bringt. Leider gab es immer noch ein kleines Problem: die Sockets wurden nicht richtig beendet, so dass nach einer gewissen zeit Lighttpd immer einen Fehler 500 gebracht hat. Nur ein Neustart des Webservers hat das Problem behoben. Auf Anfrage im offiziellen Mono-Forum wurde nun bestätigt, dass es in XSP einen kleinen Fehler gibt, welcher die Sockets nicht richtig schließt:
mbasil77: "Basically the Close method of this UnmanagedSocket class does a shutdown on the socket, but does not close it. This leaves a file handle open. I'm not sure if mono/fastcgi thinks that the webserver is responsible for actually closing the socket, but typically when you close a socket you do a shutdown, then a close."
Um das Problem zu lösen, hat mbasil77 auch einen Fix gepostet. Zum einem muss inder src/Mono/FastCgi/UnmanagedSocket.cs folgendes hinzugefügt werden:
[DllImport ("libc", SetLastError=true, EntryPoint="close")]
unsafe extern static int close (IntPtr s);
Sowie die Methode close folgendermaßen abgeändert:
public override void Close ()
{
connected = false;
if (shutdown (socket, (int) sock.SocketShutdown.Both) != 0)
throw GetException ();
close(socket);
}
Anschließend natürlich XSP neu kompilieren und installieren, sowie Lighttpd neustarten. Danach sollte das Problem eigentlich behoben sein.
- Links:
- Thread im Mono-Forum
Kommentare
- Bis jetzt sind noch keine Kommentare geschrieben worden



