How to solve php script segfault problem

藏色散人
Release: 2023-03-06 10:20:01
Original
1829 people have browsed it

The solution to the php script segmentation error: first check the php code; then execute the command "ulimit -c unlimited"; finally recompile php and add "--debug" when compiling.

How to solve php script segfault problem

Recommended: "PHP Video Tutorial"

A php script has a segmentation fault (Segment fault) My experience

Today I ran a php script on cli on a new server, and a Segment fault error occurred. The first impression was that there was a problem with the installation of an extension.

This php code calls the soap interface. There is no problem with the soap extension. I don’t know the reason for the moment.

I thought that I could use gdb to debug the core file, so I installed gdb and executed the following command: ulimit -c unlimited

Executed again and the core.PID file was generated, using the gdb php path core.PID prompts no debugging information.

I asked Sanjinguo and it turns out that --debug is required when compiling PHP.

So I recompiled php and used gdb. I found that it was a problem with the curl module and solved it.

The above is the detailed content of How to solve php script segfault problem. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
php
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!