Contact Info
43 Street 3, Hiep Binh Chanh Ward
Thu Duc District, HCM City, Vietnam
[email protected]
+84 866.09.02.09
Support

How should we call you?

    Follow Us

    Zodinet Technology Co.,Ltd

    LINUX common monitor commands & tools

    I. Common Commands & Tools

    1. PHP Performance debugger

    Strace is good tool to debug PHP performance. Firstly, you need to install it via

    CentOS

    yum install strace

    Ubuntu

    apt-get install strace

    For detect all PHP-FPM we can use following command

     strace -c -f $(pgrep php-fpm | sed 's/\([0-9]*\)/\-p \1/g')

    lstat + fstat + stat  is system call into file information

    2. IP Monitor

    netstat -ant | grep -v LISTEN | awk '{print $5}' | cut -d":" -f1 | sort | uniq -c | sort -rn

    3. Disk application I/O monitor

    iotop

    4. Process monitor tools

    htop
    atop
    top 

    II. References

    https://blog.sleeplessbeastie.eu/2019/10/14/how-to-strace-php-fpm-processes/

    Post a Comment