where to enable php slow log in ispconfig + nginx + ubuntu 18.04?

Discussion in 'Installation/Configuration' started by skysky, Apr 17, 2022.

  1. skysky

    skysky Member

    I am running multi ver php with ispconfig, and I have an api that calls to DB to returns json data for mobile app. but the api is running very slow somehow. I run the sql directly in mysql, it takes 400ms. but get the same sql data from the php api (running php 7.4) takes 6 seconds. running the same api and data on another server without ispconfig takes 1 second to return the json.

    I am trying to troubleshoot this issue, and wonder where to enable php slow log in ispconfig environment.
    I google, and found below,
    edit the PHP-FPM pool configuration, e.g. /etc/php-fpm.d/example.com.conf and add directives specifying the desired location of the slow log file and the time it takes for a script to run for it to be logged:
    slowlog = /srv/www/example.com/logs/slow.log
    request_slowlog_timeout = 3s

    but it does not match my server. there is no /etc/php-fpm.d, and there is something like this

  2. Jesse Norell

    Jesse Norell ISPConfig Developer Staff Member ISPConfig Developer

    Add the config lines to "Custom php.ini settings" under the website Options tab.

Share This Page