# Apache2 frequently stops with a python error (SLES 12 SP 1)

**URL:** <https://forums.suse.com/t/apache2-frequently-stops-with-a-python-error-sles-12-sp-1/28056>\
**Category:** SLES Networking\
**Created:** [April 6, 2016, 1:11am UTC](https://forums.suse.com/t/apache2-frequently-stops-with-a-python-error-sles-12-sp-1/28056 "2016-04-06T01:11:33Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![jwookyoo](https://avatars.discourse-cdn.com/v4/letter/j/8491ac/32.png) [@jwookyoo](https://forums.suse.com/u/jwookyoo)\
**Post date:** [April 6, 2016, 1:11am UTC](https://forums.suse.com/t/apache2-frequently-stops-with-a-python-error-sles-12-sp-1/28056/1 "2016-04-06T01:11:33Z")

</div>

Hello,

The apache2 server frequently stops with the error below. (When I manually (re)start the apache2 server, it starts okay.)

The error messages in the apache2 log:  
[mpm\_prefork:notice] [pid 19521] AH00171: Graceful restart requested, doing restart  
[:notice] [pid 19521] mod\_python: Creating 8 session mutexes based on 150 max processes and 0 max threads.  
[:notice] [pid 19521] mod\_python: using mutex\_directory /tmp  
Fatal Python error: PyEval\_SaveThread: NULL tstate  
[core:notice] [pid 19521] AH00060: seg fault or similar nasty error detected in the parent process

Does anyone know how I can fix this?

Thank you!  
Jae

---

<div class="post-metadata">

**Author:** ![Jens-U](https://avatars.discourse-cdn.com/v4/letter/j/d78d45/32.png) [@Jens-U](https://forums.suse.com/u/Jens-U)\
**Post date:** [April 6, 2016, 5:26pm UTC](https://forums.suse.com/t/apache2-frequently-stops-with-a-python-error-sles-12-sp-1/28056/2 "2016-04-06T17:26:56Z")

</div>

Hi Jae,

> [core:notice] [pid 19521] AH00060: seg fault or similar nasty error detected in the parent process

do you have any entries in the request log that might help you reproduce the error under controlled conditions? My gut feeling points at a problem in some lib that accessed via Python code (executed upon an HTTP request), causing that segmentation violation.

You may additionally want to enable core dumps for your httpd, so that you have a chance to look at the segv location post-mortem.

Regards,  
Jens

---

<div class="post-metadata">

**Author:** ![jwookyoo](https://avatars.discourse-cdn.com/v4/letter/j/8491ac/32.png) [@jwookyoo](https://forums.suse.com/u/jwookyoo)\
**Post date:** [April 19, 2016, 12:35am UTC](https://forums.suse.com/t/apache2-frequently-stops-with-a-python-error-sles-12-sp-1/28056/3 "2016-04-19T00:35:47Z")

</div>

Hi Jens,

Thank you for the kind advice.

I found that the problem was because of the bug with mod\_python in apache2 ([https://github.com/grisha/mod\_python/issues/46](https://github.com/grisha/mod_python/issues/46)). The bug was fixed with the latest check-in (Dec 1, 2015) in the github project ([https://github.com/grisha/mod\_python](https://github.com/grisha/mod_python)). The check-in version is not updated in the RPM package group yet.

Sincerely,  
Jaewook
