V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
AlloVince
V2EX  ›  PHP

使用 xhprof 进行线上 PHP 性能追踪及分析

  •  1
     
  •   AlloVince · Dec 28, 2014 · 5232 views
    This topic created in 4140 days ago, the information mentioned may be changed or developed.

    最近的一些经验总结,欢迎指正

    http://avnpc.com/pages/profiler-php-performance-online-by-xhprof

    11 replies    2015-01-11 21:09:50 +08:00
    wwek
        1
    wwek  
       Dec 28, 2014
    看了这篇文,不错的实践。
    同时也推荐大家用xhprof 做php性能分析。
    anewg
        2
    anewg  
       Dec 29, 2014
    难得看到原创技术贴,支持
    dongbeta
        3
    dongbeta  
       Dec 29, 2014
    请问你们是对所有请求都分析,还是只分析一定比例?
    thankyourtender
        4
    thankyourtender  
       Dec 29, 2014
    你们不知道 blackfire?
    AlloVince
        5
    AlloVince  
    OP
       Dec 29, 2014
    @dongbeta 线上常规都是关闭的,如果发现负载问题,会针对消耗较大的URL单独开启。
    br00k
        6
    br00k  
       Dec 29, 2014
    一直想尝试,有空试试。
    AlloVince
        7
    AlloVince  
    OP
       Dec 29, 2014
    @thankyourtender 对于墙外的需要并且安装php扩展的监控程序我们都持保留态度。前一段时间尝试过线上使用newrelic,估计是因为墙的原因,造成了php-fpm进程阻塞,具体表现为netstat中php-fpm开启的端口始终不回收,墙内环境使用墙外服务器很难保证服务的稳定性
    bdnet
        8
    bdnet  
       Dec 30, 2014
    前段时间折腾了一下 xhprof ,感觉还不错,就 GUI 工具有点乱,也不尽人意。
    AlloVince
        9
    AlloVince  
    OP
       Dec 30, 2014
    AlloVince
        10
    AlloVince  
    OP
       Dec 30, 2014
    Preview

    mingyun
        11
    mingyun  
       Jan 11, 2015
    好赞
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   924 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 39ms · UTC 21:16 · PVG 05:16 · LAX 14:16 · JFK 17:16
    ♥ Do have faith in what you're doing.