Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Xhprof installation

2025-01-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

1. First, create a folder dedicated to managing xhprofcd /tmpmkdir xhprof && cd xhprof2. Install xhprofwget http://pecl.php.net/get/xhprof-0.9.4.tgztar-xvf xhprof-0.9.4.tgzcd xhprof-0.9.4/extension/phpize

When I went through this step, I was prompted that I did not install phpize. The next step is to install phpize. If phpize is already installed, you can skip the next step.

phpize is content belonging to php-devel, so just run

yum install php-devel is fine.

Command: yum install php-devel -y

Location: /usr/bin/phpize

Next is the source code installation trilogy:

whereis php-config/* See where your php-config is located, and then put it in the path-to-php-config, usually/usr/bin/php-config */./ configure --with-php-config=makemake installmkdir -p /var/tmp/xhprof(used to store the result file generated by xhprof)3. The module file xhprof.so has just been generated. Now you need to load the module xhprof.so generated in php.ini to take effect: [xhprof]extension=xhprof.so;xhprof.output_dir=/var/tmp/xhprof The folder just created ensures that the folder has permissions on all users, otherwise an error will be reported after switching users 4. Reload php.ini file ps aux smoothly| grep php.fpm Find master process number kill -USR2 How do I view phpinfo ()? In your own website directory, create a php file, write the following code to save, and then visit the page in the browser, you will see the detailed php configuration information, the php.ini file location you are looking for has also been shown to you.

Configuration File (php.ini) Path: /usr/local/php/lib

But what if php.ini is not found in this directory?

whereis php.ini Find the location of php.ini and copy it to the address above

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report