{"action":"created","issue":{"url":"https://api.github.com/repos/grisha/mod_python/issues/46","labels_url":"https://api.github.com/repos/grisha/mod_python/issues/46/labels{/name}","comments_url":"https://api.github.com/repos/grisha/mod_python/issues/46/comments","events_url":"https://api.github.com/repos/grisha/mod_python/issues/46/events","html_url":"https://github.com/grisha/mod_python/issues/46","id":108752650,"number":46,"title":"PyEval_SaveThread: NULL tstate","user":{"login":"natsuFairytail","id":1108736,"avatar_url":"https://avatars.githubusercontent.com/u/1108736?v=3","gravatar_id":"","url":"https://api.github.com/users/natsuFairytail","html_url":"https://github.com/natsuFairytail","followers_url":"https://api.github.com/users/natsuFairytail/followers","following_url":"https://api.github.com/users/natsuFairytail/following{/other_user}","gists_url":"https://api.github.com/users/natsuFairytail/gists{/gist_id}","starred_url":"https://api.github.com/users/natsuFairytail/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/natsuFairytail/subscriptions","organizations_url":"https://api.github.com/users/natsuFairytail/orgs","repos_url":"https://api.github.com/users/natsuFairytail/repos","events_url":"https://api.github.com/users/natsuFairytail/events{/privacy}","received_events_url":"https://api.github.com/users/natsuFairytail/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":27,"created_at":"2015-09-28T21:41:54Z","updated_at":"2015-11-25T03:47:48Z","closed_at":null,"body":"On apache httpd2 2.2.15 on CentOS release 6.5 (Final)\r\nI am getting \r\n\r\nmod_python: Creating 32 session mutexes based on 256 max processes and 0 max threads.\r\n[Sun Sep 27 03:28:04 2015] [notice] mod_python: using mutex_directory /var/run/mod_python/ \r\nFatal Python error: PyEval_SaveThread: NULL tstate\r\n[Sun Sep 27 03:28:04 2015] [notice] seg fault or similar nasty error detected in the parent process\r\n\r\n\r\nIs there any way to resolve it\r\n"},"comment":{"url":"https://api.github.com/repos/grisha/mod_python/issues/comments/159481965","html_url":"https://github.com/grisha/mod_python/issues/46#issuecomment-159481965","issue_url":"https://api.github.com/repos/grisha/mod_python/issues/46","id":159481965,"user":{"login":"SBBH","id":15910606,"avatar_url":"https://avatars.githubusercontent.com/u/15910606?v=3","gravatar_id":"","url":"https://api.github.com/users/SBBH","html_url":"https://github.com/SBBH","followers_url":"https://api.github.com/users/SBBH/followers","following_url":"https://api.github.com/users/SBBH/following{/other_user}","gists_url":"https://api.github.com/users/SBBH/gists{/gist_id}","starred_url":"https://api.github.com/users/SBBH/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/SBBH/subscriptions","organizations_url":"https://api.github.com/users/SBBH/orgs","repos_url":"https://api.github.com/users/SBBH/repos","events_url":"https://api.github.com/users/SBBH/events{/privacy}","received_events_url":"https://api.github.com/users/SBBH/received_events","type":"User","site_admin":false},"created_at":"2015-11-25T03:47:48Z","updated_at":"2015-11-25T03:47:48Z","body":"I also have this problem on FreeBSD 10.2 x64 running apache 2.4, python 2.7.10, mod_python 3.5.0. Apache will run for a day or so but then crash with the following in the logs:\r\n\r\n```\r\n[:notice] [pid 7108] mod_python: Creating 8 session mutexes based on 256 max processes and 0 max threads.\r\n[:notice] [pid 7108] mod_python: using mutex_directory /tmp Fatal Python error: PyEval_SaveThread: NULL tstate\r\n[core:notice] [pid 7108] AH00060: seg fault or similar nasty error detected in the parent process\r\n```\r\n\r\nI'm not so sure what the steps are for getting a backtrace but \"gdb /usr/local/sbin/httpd /root/httpd.core\" yields the following.\r\n\r\n```\r\nGNU gdb 6.1.1 [FreeBSD]\r\nCopyright 2004 Free Software Foundation, Inc.\r\nGDB is free software, covered by the GNU General Public License, and you are\r\nwelcome to change it and/or distribute copies of it under certain conditions.\r\nType \"show copying\" to see the conditions.\r\nThere is absolutely no warranty for GDB.  Type \"show warranty\" for details.\r\nThis GDB was configured as \"amd64-marcel-freebsd\"...(no debugging symbols found)...\r\nCore was generated by `httpd'.\r\nProgram terminated with signal 6, Aborted.\r\nReading symbols from /usr/local/lib/libpcre.so.1...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libpcre.so.1\r\nReading symbols from /usr/local/lib/libaprutil-1.so.0...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libaprutil-1.so.0\r\nReading symbols from /usr/local/lib/libexpat.so.1...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libexpat.so.1\r\nReading symbols from /usr/local/lib/libapr-1.so.0...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libapr-1.so.0\r\nReading symbols from /lib/libcrypt.so.5...(no debugging symbols found)...done.\r\nLoaded symbols for /lib/libcrypt.so.5\r\nReading symbols from /lib/libthr.so.3...(no debugging symbols found)...done.\r\nLoaded symbols for /lib/libthr.so.3\r\nReading symbols from /lib/libc.so.7...(no debugging symbols found)...done.\r\nLoaded symbols for /lib/libc.so.7\r\nReading symbols from /lib/libm.so.5...(no debugging symbols found)...done.\r\nLoaded symbols for /lib/libm.so.5\r\nReading symbols from /usr/local/lib/libpython2.7.so.1...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libpython2.7.so.1\r\nReading symbols from /usr/local/lib/libintl.so.8...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libintl.so.8\r\nReading symbols from /lib/libutil.so.9...(no debugging symbols found)...done.\r\nLoaded symbols for /lib/libutil.so.9\r\nReading symbols from /usr/local/lib/python2.7/lib-dynload/_locale.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/python2.7/lib-dynload/_locale.so\r\nReading symbols from /usr/local/libexec/apache24/mod_authn_file.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_authn_file.so\r\nReading symbols from /usr/local/libexec/apache24/mod_authn_core.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_authn_core.so\r\nReading symbols from /usr/local/libexec/apache24/mod_authz_host.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_authz_host.so\r\nReading symbols from /usr/local/libexec/apache24/mod_authz_groupfile.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_authz_groupfile.so\r\nReading symbols from /usr/local/libexec/apache24/mod_authz_user.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_authz_user.so\r\nReading symbols from /usr/local/libexec/apache24/mod_authz_core.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_authz_core.so\r\nReading symbols from /usr/local/libexec/apache24/mod_access_compat.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_access_compat.so\r\nReading symbols from /usr/local/libexec/apache24/mod_auth_basic.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_auth_basic.so\r\nReading symbols from /usr/local/libexec/apache24/mod_reqtimeout.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_reqtimeout.so\r\nReading symbols from /usr/local/libexec/apache24/mod_filter.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_filter.so\r\nReading symbols from /usr/local/libexec/apache24/mod_mime.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_mime.so\r\nReading symbols from /usr/local/libexec/apache24/mod_log_config.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_log_config.so\r\nReading symbols from /usr/local/libexec/apache24/mod_env.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_env.so\r\nReading symbols from /usr/local/libexec/apache24/mod_headers.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_headers.so\r\nReading symbols from /usr/local/libexec/apache24/mod_setenvif.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_setenvif.so\r\nReading symbols from /usr/local/libexec/apache24/mod_version.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_version.so\r\nReading symbols from /usr/local/libexec/apache24/mod_unixd.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_unixd.so\r\nReading symbols from /usr/local/libexec/apache24/mod_status.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_status.so\r\nReading symbols from /usr/local/libexec/apache24/mod_autoindex.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_autoindex.so\r\nReading symbols from /usr/local/libexec/apache24/mod_cgi.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_cgi.so\r\nReading symbols from /usr/local/libexec/apache24/mod_dir.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_dir.so\r\nReading symbols from /usr/local/libexec/apache24/mod_alias.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_alias.so\r\nReading symbols from /usr/local/libexec/apache24/libphp5.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/libphp5.so\r\nReading symbols from /usr/local/lib/libxml2.so.2...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/libxml2.so.2\r\nReading symbols from /lib/libz.so.6...(no debugging symbols found)...done.\r\nLoaded symbols for /lib/libz.so.6\r\nReading symbols from /usr/lib/liblzma.so.5...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/lib/liblzma.so.5\r\nReading symbols from /usr/local/libexec/apache24/mod_python.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_python.so\r\nReading symbols from /usr/local/libexec/apache24/mod_auth_digest.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/libexec/apache24/mod_auth_digest.so\r\nReading symbols from /usr/local/lib/php/20131226/xml.so...(no debugging symbols found)...done.\r\nLoaded symbols for /usr/local/lib/php/20131226/xml.so\r\nReading symbols from /libexec/ld-elf.so.1...(no debugging symbols found)...done.\r\nLoaded symbols for /libexec/ld-elf.so.1\r\n#0  0x000000080169d64a in thr_kill () from /lib/libc.so.7\r\n[New Thread 802006400 (LWP 100948/<unknown>)]\r\n```\r\n\r\nLet me know if there's anything else that would be helpful.\r\n\r\nI've also posted this to [FreeBSD Bugzilla](https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=204793)."}}