Home > Backend Development > PHP Problem > How to enable slow log query in PHP

How to enable slow log query in PHP

藏色散人
Release: 2023-03-02 22:42:02
Original
3537 people have browsed it

How to enable slow query in PHP: first find the "php-fpm" file; then remove the semicolon in front of "request_slowlog_timeout" and set the time; then remove the semicolon in front of slowlog and set the log path; finally Just restart PHP.

How to enable slow log query in PHP

PHP enables slow log query

Recommended: "PHP Tutorial"

1. Find the php-fpm file

2. Remove the semicolon in front of request_slowlog_timeout and set the time. For example: request_slowlog_timeout=5 means more than 5 seconds

3. Remove the semicolon in front of slowlog and set the log path. For example, slowlog=/usr/local/php71/log

4, restart PHP

The above is the detailed content of How to enable slow log query in PHP. 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
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template