#12360 [Csd->Opn]: fsockopen timeout doesn't work

From: Date: Tue, 16 Sep 2003 09:25:22 +0000
Subject: #12360 [Csd->Opn]: fsockopen timeout doesn't work
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-47620@lists.php.net to get a copy of this message
ID: 12360 Updated by: wez@php.net Reported By: hordur at modernus dot is -Status: Closed +Status: Open Bug Type: Sockets related Operating System: RedHat 6.2 PHP Version: 4.3 New Comment: Can you guys that still experience this problem try recompiling PHP using --disable-ipv6 and see if that "solves" the problem? Previous Comments: ------------------------------------------------------------------------ [2003-09-16 04:53:03] uros at sir-mag dot com I'm using PHP 4.3.3 on FreeBSD and also have problems with this fsockopen It seams that no timeout is using, because simple script takes about 1 minute to finish with error. $fp = @fsockopen ('www.damirjosar.com', 80, $errno, $errstr, 1.0); print_r($errno); print_r($errstr); print_r($fp); Error is: 22 Invalid argument And it takes about 1 minute. What about 1.0 second I set. If i use regular system call like dig or nslookup It only takes about 10s for this host. I have same problems with function checkdnsrr and gethostbyname ------------------------------------------------------------------------ [2003-09-15 03:09:35] johannes at zoomposters dot com php 4.3.3, redhat 7.3 still not working! ------------------------------------------------------------------------ [2003-08-26 07:20:43] s dot tijink at snoopmedia dot com the same on PHP 4.3.3 / SuSE 8.0 ------------------------------------------------------------------------ [2003-08-26 05:36:21] s dot tijink at snoopmedia dot com Hi, using PHP 4.3.2 stable on SuSE 8.0 i've still the same problem that I got no timeout on fsockopen or stream_set_timeout. Greetz, Stephan Tijink ------------------------------------------------------------------------ [2002-12-22 09:59:11] msopacua@php.net An additional note: Under BSDi and threaded builds, the timeout isn't respected. Additionally the openssl test, takes much longer, which leads me to believe, this is a BSDi threading issue, to do with time values. This issue doesn't surface, when --with-experimental-zts is removed from the equation and can't be reproduced on FreeBSD. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/12360 -- Edit this bug report at http://bugs.php.net/?id=12360&edit=1

« previous php.bugs (#47620) next »