This is the mail archive of the
mailing list for the Cygwin project.
- From: ZHAO Wei <zw at netspeed-tech dot com>
- To: cygwin at cygwin dot com
- Date: Mon, 10 Feb 2003 23:23:03 +0800
- Subject: PHP problem
I think this is a bug somewhere, but I'm not sure. Please help!
Please Cc: me! I'm not on the list. Thank you!
1. Get netcat for Windows from @Stake, this is a neat tool. We will
use it below. This is Cygwin, so you will want the winnt version of
2. Start apache with: $ apachectl start. Remember to enable PHP4 in
your Cygwin setup.
3. Put a simple php script under /var/www/htdocs, say, $ echo "<?php
echo \"hello\"; ?>" > echo.php
4. Watch the apache access log in another console window: $ tail -f
5. Call on netcat: $ while true; do echo -e "GET /echo.php
HTTP/1.1\nHost: 127.0.0.1\n\n" | nc 127.0.0.1 80; done
6. Now see the symptom: telnet 127.0.0.1 80, at the prompt, make a
random HTTP request, say, GET / HTTP/1.0, remember to type CR/LF
twice at the end of your request, now the cymptom comes out, the
HTTP request just hangs, no response from apache.
Watch our log now, we can't see the new request at all. Only after
we terminate the while loop for the netcat, can we see the new
request coming to the log.
Some more experiments let me believe that it's not a Cygwin Socket
Impl. problem, neither Apache's problem, but a PHP problem or a
combo. Or, my misunderstanding somewhere. Any suggestions?
I'm doing a very simple web chat room for use by only two persons,
and I use the <meta> tag to automatically refresh every 5 seconds.
And I saw the above problem, when one browser is in the chat room
doing refresh, no other requests appeared in the access_log. Only
when that browser left the chatroom, no refresh anymore, can the
requests made previouslly appear in the access_log.
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html