#41350 [Com]: Error in my_thread_global_end()
ID: 41350 Comment by: daniel dot gaddis at tlc dot state dot tx dot us Reported By: graham at directhostinguk dot com Status: Feedback Bug Type: MySQL related Operating System: Windows 2003 PHP Version: 5.2.3 Assigned To: scottmac New Comment: php -v returned the error using PHP 5.2.5-dev (cli) (built: Sep 9 2007 12:04:32). See mysql and apache version info below. F:\php>php -v PHP 5.2.5-dev (cli) (built: Sep 9 2007 12:04:32) 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 F:\MySQL\bin>mysqladmin --user= --password= version mysqladmin Ver 8.41 Distrib 5.0.45, for Win32 on ia32 Copyright (C) 2000-2006 MySQL AB This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL license Server version 5.0.45-community-nt-log Protocol version10 Connection localhost via TCP/IP TCP port3306 Uptime: 9 min 57 sec Threads: 1 Questions: 4 Slow queries: 0 Opens: 12 Flush tables: 1 Open tabl es: 6 Queries per second avg: 0.007 F:\Program Files\Apache Group\Apache>apache.exe -v Server version: Apache/1.3.37 (Win32) Server built: Jul 27 2006 15:23:00 Previous Comments: [2007-09-25 17:54:52] daniel dot gaddis at tlc dot state dot tx dot us php -v returned the error using PHP 5.2.5-dev (cli) (built: Sep 9 2007 12:04:32). See mysql and apache version info below. F:\php>php -v PHP 5.2.5-dev (cli) (built: Sep 9 2007 12:04:32) 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 F:\MySQL\bin>mysqladmin --user= --password= version mysqladmin Ver 8.41 Distrib 5.0.45, for Win32 on ia32 Copyright (C) 2000-2006 MySQL AB This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL license Server version 5.0.45-community-nt-log Protocol version10 Connection localhost via TCP/IP TCP port3306 Uptime: 9 min 57 sec Threads: 1 Questions: 4 Slow queries: 0 Opens: 12 Flush tables: 1 Open tabl es: 6 Queries per second avg: 0.007 F:\Program Files\Apache Group\Apache>apache.exe -v Server version: Apache/1.3.37 (Win32) Server built: Jul 27 2006 15:23:00 [2007-09-19 21:27:36] [EMAIL PROTECTED] ctrl+c causes a SIGINT which isn't handled by PHP so the module shutdown isn't run and we can't clean up. So that would be expected behaviour. libmysql for 6.0 doesn't work yet as far as I know. Those seeing the error on CGI / FCGI should try a 5.2.5 snapshot as there was another bug that caused module shutdown now to be executed for -v and -i. I need a consistent reproduce case to look further at this. I can't reproduce this with 5.2.5-dev with MySQL 5.0.45 with MySQL, MySQLi and pdo_mysql loaded. Test cases if you please. [2007-09-19 19:45:15] phpbug at povaddict dot com dot ar I forgot to mention: MySQL Ver 14.12 Distrib 5.0.45, for Win32 (ia32) I tried renaming the libmysql.dll inside PHP folder and replacing it with the one from MySQL folder, didn't help. I also read somewhere that 5.0.42 should have the fix; obviously that's not the case. Also, derick said on another PHP bug that "We don't call my_thread_init, or anything starting with my_thread." A reply from mysql bug comments: "my_thread_init() is called indirectly from mysql_init()". [2007-09-19 19:36:03] phpbug at povaddict dot com dot ar I'm running: PHP 5.2.4 (cli) (built: Aug 30 2007 07:06:31) Copyright (c) 1997-2007 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies with mysqli enabled, on a Windows XP machine. A simple way to reproduce it is running php -r "sleep(60);" and pressing Ctrl-C before it quits on its own. It takes over 5 seconds to actually quit, and then displays "Error in my_thread_global_end(): 1 threads didn't exit". Of course, you need some MySQL library enabled in php.ini... [2007-09-18 18:58:25] chadworsham at hotmail dot com Error in my_thread_global_end(): 3 threads didn't exit D:\>ver Microsoft Windows XP [Version 5.1.2600] C:\php5>php.exe -v PHP 5.2.4 (cli) (built: Aug 30 2007 07:06:31) Copyright (c) 1997-2007 The PHP Group Ze
#41350 [Com]: Error in my_thread_global_end()
ID: 41350 Comment by: daniel dot gaddis at tlc dot state dot tx dot us Reported By: graham at directhostinguk dot com Status: Feedback Bug Type: MySQL related Operating System: Windows 2003 PHP Version: 5.2.3 Assigned To: scottmac New Comment: php -v returned the error using PHP 5.2.5-dev (cli) (built: Sep 9 2007 12:04:32). See mysql and apache version info below. F:\php>php -v PHP 5.2.5-dev (cli) (built: Sep 9 2007 12:04:32) 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 F:\MySQL\bin>mysqladmin --user= --password= version mysqladmin Ver 8.41 Distrib 5.0.45, for Win32 on ia32 Copyright (C) 2000-2006 MySQL AB This software comes with ABSOLUTELY NO WARRANTY. This is free software, and you are welcome to modify and redistribute it under the GPL license Server version 5.0.45-community-nt-log Protocol version10 Connection localhost via TCP/IP TCP port3306 Uptime: 9 min 57 sec Threads: 1 Questions: 4 Slow queries: 0 Opens: 12 Flush tables: 1 Open tabl es: 6 Queries per second avg: 0.007 F:\Program Files\Apache Group\Apache>apache.exe -v Server version: Apache/1.3.37 (Win32) Server built: Jul 27 2006 15:23:00 Previous Comments: [2007-09-19 21:27:36] [EMAIL PROTECTED] ctrl+c causes a SIGINT which isn't handled by PHP so the module shutdown isn't run and we can't clean up. So that would be expected behaviour. libmysql for 6.0 doesn't work yet as far as I know. Those seeing the error on CGI / FCGI should try a 5.2.5 snapshot as there was another bug that caused module shutdown now to be executed for -v and -i. I need a consistent reproduce case to look further at this. I can't reproduce this with 5.2.5-dev with MySQL 5.0.45 with MySQL, MySQLi and pdo_mysql loaded. Test cases if you please. [2007-09-19 19:45:15] phpbug at povaddict dot com dot ar I forgot to mention: MySQL Ver 14.12 Distrib 5.0.45, for Win32 (ia32) I tried renaming the libmysql.dll inside PHP folder and replacing it with the one from MySQL folder, didn't help. I also read somewhere that 5.0.42 should have the fix; obviously that's not the case. Also, derick said on another PHP bug that "We don't call my_thread_init, or anything starting with my_thread." A reply from mysql bug comments: "my_thread_init() is called indirectly from mysql_init()". [2007-09-19 19:36:03] phpbug at povaddict dot com dot ar I'm running: PHP 5.2.4 (cli) (built: Aug 30 2007 07:06:31) Copyright (c) 1997-2007 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies with mysqli enabled, on a Windows XP machine. A simple way to reproduce it is running php -r "sleep(60);" and pressing Ctrl-C before it quits on its own. It takes over 5 seconds to actually quit, and then displays "Error in my_thread_global_end(): 1 threads didn't exit". Of course, you need some MySQL library enabled in php.ini... [2007-09-18 18:58:25] chadworsham at hotmail dot com Error in my_thread_global_end(): 3 threads didn't exit D:\>ver Microsoft Windows XP [Version 5.1.2600] C:\php5>php.exe -v PHP 5.2.4 (cli) (built: Aug 30 2007 07:06:31) Copyright (c) 1997-2007 The PHP Group Zend Engine v2.2.0, Copyright (c) 1998-2007 Zend Technologies Error in my_thread_global_end(): 3 threads didn't exit mysql> status -- mysql Ver 14.13 Distrib 6.0.2-alpha, for Win32 (ia32) Does anyone know of a REAL fix? [2007-09-18 06:13:54] wangyi6854 at sohu dot com I got the problem on Win2k3, IIS6, php5.2.4 PHP Version 5.2.4 System Windows NT BANDAO-17 5.2 build 3790 Build Date Aug 30 2007 07:05:48 Configure Command cscript /nologo configure.js "--enable-snapshot-build" "--with-gd=shared" Server API CGI/FastCGI Virtual Directory Support enabled Configuration File (php.ini) Path C:\WINDOWS Loaded Configuration File F:\PHP5\php.ini PHP API 20041225 PHP Extension 20060613 Zend Extension 220060519 Debug Build no Thread Safety enabled Zend Memory Manager enabled IPv6 Support enabled Registered PHP Streams php, file, data, http, ftp, compress.zlib Registered Stream Socket Transports tcp, udp Registered Stream Filters convert.iconv.*, string.rot13, string.toupper, string.tolower, string.strip_tags, convert.*, consumed, zlib.* mysql MySQL Support enabled
#30031 [Bgs]: win32 safe_mode=on, safe_mode_exec_dir, and exec function
ID: 30031 User updated by: daniel dot gaddis at tlc dot state dot tx dot us Reported By: daniel dot gaddis at tlc dot state dot tx dot us Status: Bogus Bug Type: Filesystem function related Operating System: windows 2000 service pack 4 PHP Version: 4.3.9RC2 New Comment: how about changing this to a document change request instead? How about adding a comment/example to chapter on Safe Mode where it talks about safe_mode_exec_dir? You could add that if using windows use the following syntax: safe_mode_exec_dir=c:/winnt/system32/ what about open_basedir? Does it now require the use of / instead of \ thanks, Daniel Previous Comments: [2004-10-19 09:06:14] [EMAIL PROTECTED] Marking as "bogus" then, as this was not a bug in PHP but a misconfiguration. [2004-10-18 18:01:43] daniel dot gaddis at tlc dot state dot tx dot us That fixed the problem as posted. However, when I made that change to my real code it still has issues. It looks like I have some more debugging to do. Thanks for the help! Daniel [2004-10-15 18:55:10] [EMAIL PROTECTED] Try changing c:\winnt\system32\ to c:/winnt/system32 [2004-09-08 20:54:35] daniel dot gaddis at tlc dot state dot tx dot us Description: code on a on windows 2000 service pack 4 system using php 4.3.4 command line with safe_mode=on, safe_mode_exec_dir, and exec function works successfully but fails using php 4.3.9RC2 command line. I did not test all versions since 4.3.4 but other php command line versions since 4.3.4 also fail. As you can see from example below I am using php.ini-dist and overriding with: -d safe_mode=on -d safe_mode_gid=On -d safe_mode_exec_dir=c:\winnt\system32\ I also... cd /d C:\WINNT\system32 ...and then run the command line php from the directory shown below: Reproduce code: --- C:\WINNT\system32>D:\PHP\php-4.3.9RC2\php -c D:\PHP\php-4.3.9RC2\php.ini-dist -d safe_mode=on -d safe_mode_gid=On -d safe_mode_exec_dir=c:\winnt\system32\ -r "exec('ping 127.0.0.1',$output,$error); var_dump($output); print ('error code returned: ' . $error);" Expected result: array(12) { [0]=> string(0) "" [1]=> string(40) "Pinging 127.0.0.1 with 32 bytes of data:"; [2]=> string(0) "" [3]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [4]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [5]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [6]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [7]=> string(0) "" [8]=> string(30) "Ping statistics for 127.0.0.1:" [9]=> string(56) "Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)," [10]=> string(46) "Approximate round trip times in milli-seconds:" [11]=> string(49) "Minimum = 0ms, Maximum = 0ms, Average = 0ms" } error code returned: 0 Actual result: -- array(0) { } error code returned: 0 -- Edit this bug report at http://bugs.php.net/?id=30031&edit=1
#30031 [Fbk->Opn]: win32 safe_mode=on, safe_mode_exec_dir, and exec function
ID: 30031 User updated by: daniel dot gaddis at tlc dot state dot tx dot us Reported By: daniel dot gaddis at tlc dot state dot tx dot us -Status: Feedback +Status: Open Bug Type: Filesystem function related Operating System: windows 2000 service pack 4 PHP Version: 4.3.9RC2 New Comment: That fixed the problem as posted. However, when I made that change to my real code it still has issues. It looks like I have some more debugging to do. Thanks for the help! Daniel Previous Comments: [2004-10-15 18:55:10] [EMAIL PROTECTED] Try changing c:\winnt\system32\ to c:/winnt/system32 [2004-09-08 20:54:35] daniel dot gaddis at tlc dot state dot tx dot us Description: code on a on windows 2000 service pack 4 system using php 4.3.4 command line with safe_mode=on, safe_mode_exec_dir, and exec function works successfully but fails using php 4.3.9RC2 command line. I did not test all versions since 4.3.4 but other php command line versions since 4.3.4 also fail. As you can see from example below I am using php.ini-dist and overriding with: -d safe_mode=on -d safe_mode_gid=On -d safe_mode_exec_dir=c:\winnt\system32\ I also... cd /d C:\WINNT\system32 ...and then run the command line php from the directory shown below: Reproduce code: --- C:\WINNT\system32>D:\PHP\php-4.3.9RC2\php -c D:\PHP\php-4.3.9RC2\php.ini-dist -d safe_mode=on -d safe_mode_gid=On -d safe_mode_exec_dir=c:\winnt\system32\ -r "exec('ping 127.0.0.1',$output,$error); var_dump($output); print ('error code returned: ' . $error);" Expected result: array(12) { [0]=> string(0) "" [1]=> string(40) "Pinging 127.0.0.1 with 32 bytes of data:"; [2]=> string(0) "" [3]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [4]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [5]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [6]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [7]=> string(0) "" [8]=> string(30) "Ping statistics for 127.0.0.1:" [9]=> string(56) "Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)," [10]=> string(46) "Approximate round trip times in milli-seconds:" [11]=> string(49) "Minimum = 0ms, Maximum = 0ms, Average = 0ms" } error code returned: 0 Actual result: -- array(0) { } error code returned: 0 -- Edit this bug report at http://bugs.php.net/?id=30031&edit=1
#30031 [NEW]: win32 safe_mode=on, safe_mode_exec_dir, and exec function
From: daniel dot gaddis at tlc dot state dot tx dot us Operating system: windows 2000 service pack 4 PHP version: 4.3.9RC2 PHP Bug Type: Filesystem function related Bug description: win32 safe_mode=on, safe_mode_exec_dir, and exec function Description: code on a on windows 2000 service pack 4 system using php 4.3.4 command line with safe_mode=on, safe_mode_exec_dir, and exec function works successfully but fails using php 4.3.9RC2 command line. I did not test all versions since 4.3.4 but other php command line versions since 4.3.4 also fail. As you can see from example below I am using php.ini-dist and overriding with: -d safe_mode=on -d safe_mode_gid=On -d safe_mode_exec_dir=c:\winnt\system32\ I also... cd /d C:\WINNT\system32 ...and then run the command line php from the directory shown below: Reproduce code: --- C:\WINNT\system32>D:\PHP\php-4.3.9RC2\php -c D:\PHP\php-4.3.9RC2\php.ini-dist -d safe_mode=on -d safe_mode_gid=On -d safe_mode_exec_dir=c:\winnt\system32\ -r "exec('ping 127.0.0.1',$output,$error); var_dump($output); print ('error code returned: ' . $error);" Expected result: array(12) { [0]=> string(0) "" [1]=> string(40) "Pinging 127.0.0.1 with 32 bytes of data:"; [2]=> string(0) "" [3]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [4]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [5]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [6]=> string(48) "Reply from 127.0.0.1: bytes=32 time<10ms TTL=128" [7]=> string(0) "" [8]=> string(30) "Ping statistics for 127.0.0.1:" [9]=> string(56) "Packets: Sent = 4, Received = 4, Lost = 0 (0% loss)," [10]=> string(46) "Approximate round trip times in milli-seconds:" [11]=> string(49) "Minimum = 0ms, Maximum = 0ms, Average = 0ms" } error code returned: 0 Actual result: -- array(0) { } error code returned: 0 -- Edit bug report at http://bugs.php.net/?id=30031&edit=1 -- Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=30031&r=trysnapshot4 Try a CVS snapshot (php5.0): http://bugs.php.net/fix.php?id=30031&r=trysnapshot50 Try a CVS snapshot (php5.1): http://bugs.php.net/fix.php?id=30031&r=trysnapshot51 Fixed in CVS:http://bugs.php.net/fix.php?id=30031&r=fixedcvs Fixed in release:http://bugs.php.net/fix.php?id=30031&r=alreadyfixed Need backtrace: http://bugs.php.net/fix.php?id=30031&r=needtrace Need Reproduce Script: http://bugs.php.net/fix.php?id=30031&r=needscript Try newer version: http://bugs.php.net/fix.php?id=30031&r=oldversion Not developer issue: http://bugs.php.net/fix.php?id=30031&r=support Expected behavior: http://bugs.php.net/fix.php?id=30031&r=notwrong Not enough info: http://bugs.php.net/fix.php?id=30031&r=notenoughinfo Submitted twice: http://bugs.php.net/fix.php?id=30031&r=submittedtwice register_globals:http://bugs.php.net/fix.php?id=30031&r=globals PHP 3 support discontinued: http://bugs.php.net/fix.php?id=30031&r=php3 Daylight Savings:http://bugs.php.net/fix.php?id=30031&r=dst IIS Stability: http://bugs.php.net/fix.php?id=30031&r=isapi Install GNU Sed: http://bugs.php.net/fix.php?id=30031&r=gnused Floating point limitations: http://bugs.php.net/fix.php?id=30031&r=float MySQL Configuration Error: http://bugs.php.net/fix.php?id=30031&r=mysqlcfg