php5.3 xhprof Performance Test

Source: Internet
Author: User
Tags phpinfo

{Xhprof}

xhprof is a layered PHP performance analysis tool that can be Span style= "line-height:normal;border-collapse:separate;font-size:medium;font-family:arial, ' Microsoft Yahei ', SimSun, sans-serif;border-spacing:0px; " >

[condition]

[Procedure]

  • Downloaded the xhprof for Windows version from the foreign language site and downloaded the relevant XHPROF code and related build page documentation from the Facebook original publishing station. Since Xhprof is compiled based on php5.3.3, it is also necessary to prepare php5.3.3 and go directly to Php.net to pull a VC6 thread-safe version down.

  • Apache has a ready-made, So directly modified the original http.conf, the php5.3.3 to the CGI introduced into Apache, debugging a bit, smooth integration, phpinfo all normal, xdebug is all normal, and now began to join the XHPROF preparation work is done.

[Step]

650) this.width=650; "title=" "Name=" image_operate_7631321243832595 "src=" http://image66.360doc.com/DownloadImg/ 2013/11/0123/36400478_1 "alt=" Windows version apache+php xhprof application __[1] "style=" margin:0px;padding:0px;border:0px; List-style:none; "/>

Figure 1

    • And then to the Xhprof two contains debug output page subdirectory placement, here I chose to directly placed in the root of their website publishing location, that is, Apache default Htdocs directory inside, I here htdocs is transferred to another development on the U disk, Easy to code in different places, 2, shown here is a total of 3 folders, respectively, xhprof_html, Xhprof_lib, Xprof_log, of which xhprof_html and xhprof_ Lib is from the downloaded xhprof source code file package, the package is located at the site: http://pecl.php.net/package/xhprof,xhprof:http://pecl.php.net/get/ Xhprof-0.9.2.tgz, and then create your own Xprof_log folder in the Htdocs, which is used to store page analysis data.

650) this.width=650; "title=" "Name=" image_operate_83191321243834221 "src=" http://image66.360doc.com/DownloadImg/ 2013/11/0123/36400478_2 "alt=" Windows version apache+php xhprof application __[1] "style=" margin:0px;padding:0px;border:0px; List-style:none; "/>
Figure 2

    • because my apache+php has been fully debugged, So to deal with only the php.ini file, the Open method is very simple, at the end of the file, add the following code:

[xhprof]
Extension=php_xhprof.dll
; Directory used by default implementation of the Ixhprofruns
; interface (namely, the Xhprofruns_default Class) for Stor ING
; Xhprof runs.
xhprof.output_dir= "M:/htdocs/xhprof_log"

"hint: xhprof.output_dir= This is used to set the location of profiling data, I shall be htdocs in M-disk, so set to Span style= "LINE-HEIGHT:19PX;FONT-SIZE:2PX;" >m:/htdocs/xhprof_log, which is the above directory location "

    • After adding the success, you can restart Apache to see if the phpinfo () message contains the XHPROF segment, if so, then the installation succeeded, prompted: the CGI run PHP modified php.ini, you can directly run Phpinfo () to view the results, Without restarting Apache. As a result, 3 shows:

650) this.width=650; "title=" "Name=" image_operate_92381321244419749 "src=" http://image66.360doc.com/DownloadImg/ 2013/11/0123/36400478_3 "alt=" Windows version apache+php xhprof application __[1] "style=" margin:0px;padding:0px;border:0px; List-style:none; "/>

Figure 3

    • Well, so far, the xhprof has been properly installed.


This article is from the "Rosy Clouds Fly" blog, please be sure to keep this source http://caixia.blog.51cto.com/2266345/1675266

php5.3 xhprof Performance Test

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.