ID: 41350 Comment by: paul at orac dot clara dot co dot uk Reported By: graham at directhostinguk dot com Status: Feedback Bug Type: MySQL related Operating System: Windows 2003 PHP Version: 5.2.6 Assigned To: scottmac New Comment:
At last, someone seems to have a clue: http://bugs.mysql.com/bug.php?id=25621 http://bugs.mysql.com/bug.php?id=37226 Previous Comments: ------------------------------------------------------------------------ [2008-06-11 21:20:31] paul at orac dot clara dot co dot uk Brand new install of Win XP, with IIS (5.1). Installed PHP 5.2.6 (IIS set to use PHP in CGI mode not ISAPI). MySQL is NOT installed on the machine. The only version of libmysql.dll anywhere is the one supplied with php (version 5.00.51a). With either or both of "extension=php_mysql.dll" or "extension=php_mysqli.dll" enabled, running "php-cgi -v" results in the 5 second delay about 25% of the time (5 times out of 20 - very repeatable). The same happens running a browser to a local web page containing just a call to phpinfo(). With both the extension lines commented, the problem does not occur, ever. Running "php -v" I never see the problem occur, ever, even with the extensions enabled. Replacing libmysql.dll with the one from php 5.2.1 (version 5.00.22) causes the above 5 second delay to disappear in ALL cases. The first version of libmysql.dll that caused the problem was that supplied with php 5.2.2. Surely it can't be too hard to start back with those two versions and work out what changed between them? ------------------------------------------------------------------------ [2008-06-09 11:47:13] Computer dot Pers at gmail dot com OK. I've upgraded PHP to latest 5.2.6 Message: "Error in my_thread_global_end(): 1 threads didn't exit" is disappeared. but delay of 5 seconds is here. I've disabled ALL plugins and there's no any delay. 1. Then i've enabled "extension=php_mysql.dll" 2. i've created script, which shows curent time before and after "php -v" commnad and launched it several times here is result: 1. No delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:16 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:16 2. Delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:18 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:23 3. No delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:26 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:26 4. No delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:28 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:28 5. No delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:29 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:29 6. No delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:30 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:30 7. Delay C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>phpinfo.bat 09.06.2008 14:33:31 PHP 5.2.6 (cli) (built: May 2 2008 18:02:07) Copyright (c) 1997-2008 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2008 Zend Technologies 09.06.2008 14:33:36 ......... 1 of 3 or 4 times i see a delay of 5 secs. and this is on a machine Intel Xeon E5335 @2Ghz 4Gb Ram at Idle state MySql for test reason was STOPPED. ------------------------------------------------------------------------ [2008-06-09 10:55:35] [EMAIL PROTECTED] First you need 5.2.6 and secondly you need to check for old libmysql.dll files lurking around in your path, I can't reproduce this with MySQL 5.0.51. Can you reproduce this when you disable all extensions and just enable MySQL? If you start enabling extensions which one causes the problem? On phpinfo() what version of libmysql does it show? If you don't have PHP 5.2.6 and MySQL 5.0.51 or newer then please upgrade before you consider replying. ------------------------------------------------------------------------ [2008-06-09 10:12:06] Computer dot Pers at gmail dot com So... Is there's any solution??? C:\Program Files\SWsoft\Plesk\Additional\PleskPHP5>php -v PHP 5.2.5 (cli) (built: Nov 8 2007 23:18:51) Copyright (c) 1997-2007 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies Error in my_thread_global_end(): 1 threads didn't exit ------------------------------------------------------------------------ [2008-06-09 02:33:33] kneekoo at yahoo dot com As indicated in some of the above messages, I tried some advices but nothing changed on my setup. 1. Commenting ;[PHP_MYSQL] ;extension=php_mysql.dll and de-commenting extension=php_mysql.dll didn't help. 2. Switching mysql.allow_persistent to Off didn't help as well. I downloaded PHP 5.2.6, installed it on a WinXP SP2 system and that's it. There is a delay (more than 5 seconds to me - about 7) and this message: Error in my_thread_global_end(): 1 threads didn't exit It's shocking to find out there isn't an official fix for this after one whole year. Lucky me I can work with my scripts but I hope this won't interfere with my development further on. Please, guys, fix this. Thanks! ------------------------------------------------------------------------ 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/41350 -- Edit this bug report at http://bugs.php.net/?id=41350&edit=1