Page MenuHomePhabricator

Decom "xhprof" viewer
Closed, ResolvedPublic

Description

Looking at performance.wikimedia.org Apache config I noticed an entry for /xhprof that proxies to http://tungsten.eqiad.wmnet/xhprof/.

It appears to be some kind of XHProf viewer. Currently at https://performance.wikimedia.org/xhprof/.

It seems to only have one entry, from 2016, and I have no idea how to get things added to it.

As far as I know it's not part of the XHGui application that runs there, but something else. Possibly this might be the "public_html" viewer that came with the php5-xhprof package originally.

Anyhow, I propose we remove it, which will also make T195314 simpler.

Event Timeline

Krinkle triaged this task as Low priority.Jun 4 2018, 9:03 PM
Krinkle created this task.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJun 4 2018, 9:03 PM
Krinkle removed Imarlier as the assignee of this task.Jun 4 2018, 9:03 PM
Krinkle raised the priority of this task from Low to Needs Triage.

/srv/xhprof/xhprof_html is not installed/owned by a package:

imarlier@tungsten:/srv/xhprof$ dpkg -S /srv/xhprof/xhprof_html
dpkg-query: no path found matching pattern /srv/xhprof/xhprof_html
imarlier@tungsten:/srv/xhprof$ dpkg -S /srv/xhprof/xhprof_html/index.php
dpkg-query: no path found matching pattern /srv/xhprof/xhprof_html/index.php
imarlier@tungsten:/srv/xhprof$

It's also not referenced anywhere except in that apache config file:

imarlier@WMF2024 ~/dev/src/puppet (production)$ grep -r 'xhprof_html' *                                                                                                                                              
modules/role/templates/apache/sites/xhgui.erb:    Alias /xhprof /srv/xhprof/xhprof_html
modules/role/templates/apache/sites/xhgui.erb:    <Directory /srv/xhprof/xhprof_html>
grep: modules/admin/files/home/akosiaris/.my.cnf: No such file or directory
imarlier@WMF2024 ~/dev/src/puppet (production)$

Given this, seems safe to remove it.

Imarlier claimed this task.Jun 11 2018, 7:04 PM

Change 439647 had a related patch set uploaded (by Imarlier; owner: Imarlier):
[operations/puppet@production] Remove /xhprof from performance.wikimedia.org apache config

https://gerrit.wikimedia.org/r/439647

Imarlier triaged this task as Normal priority.Jun 11 2018, 7:55 PM
Imarlier moved this task from Inbox to Doing on the Performance-Team board.

Change 439647 merged by Dzahn:
[operations/puppet@production] Remove /xhprof from performance.wikimedia.org apache config

https://gerrit.wikimedia.org/r/439647

Dzahn added a comment.Jun 12 2018, 6:53 AM

Applied on tungsten. Apache config has been changed by puppet. Regarding /srv/xhprof/xhprof_html do you want me to delete it or do we just not care because tungsten will be decom'ed as soon as we are done here?

Imarlier closed this task as Resolved.Jun 12 2018, 4:13 PM
Imarlier removed a project: Patch-For-Review.

@Dzahn We can just leave xhprof_html lying around, it'll be doing away soon enough.

Thanks for merging!

Change 442232 had a related patch set uploaded (by Krinkle; owner: Krinkle):
[operations/puppet@production] webperf: Make performance::site apache config more dynamic

https://gerrit.wikimedia.org/r/442232

Vvjjkkii renamed this task from Decom "xhprof" viewer to lnbaaaaaaa.Jul 1 2018, 1:06 AM
Vvjjkkii reopened this task as Open.
Vvjjkkii removed Imarlier as the assignee of this task.
Vvjjkkii raised the priority of this task from Normal to High.
Vvjjkkii updated the task description. (Show Details)
Vvjjkkii removed subscribers: Aklapper, gerritbot.
CommunityTechBot renamed this task from lnbaaaaaaa to Decom "xhprof" viewer .Jul 2 2018, 4:41 AM
CommunityTechBot closed this task as Resolved.
CommunityTechBot assigned this task to Imarlier.
CommunityTechBot lowered the priority of this task from High to Normal.
CommunityTechBot updated the task description. (Show Details)
CommunityTechBot added subscribers: Aklapper, gerritbot.

Change 442232 merged by Muehlenhoff:
[operations/puppet@production] webperf: Make performance::site apache config more dynamic

https://gerrit.wikimedia.org/r/442232

Krinkle reopened this task as Open.Dec 21 2018, 3:30 AM

Tentatively re-opening, but prepared to be called wrong.

I was looking at the XHGui puppet classes as part of the upgrade (because we may need to puppetize a config.php file soon), and spotted what appears to be source for /srv/xhprof/xhprof_html - in Puppet.

https://github.com/wikimedia/puppet/blob/d489cac509b9921cc948335f76979a68e04178e0/modules/role/manifests/xhgui/app.pp#L73-L83

git::clone { 'operations/software/xhprof':
    ensure    => 'latest',
    directory => '/srv/xhprof',
    branch    => 'wmf_deploy',
}
-> file { '/srv/xhprof/profiles':
    ensure => directory,
    owner  => 'www-data',
    group  => 'www-data',
    mode   => '0755',
}

With the xhprof_html/ web app coming from https://gerrit.wikimedia.org/g/operations/software/xhprof/+/wmf_deploy. I guess we'll want to archive the git repo as read-only and remove the puppet resource.

Dzahn added a comment.EditedDec 22 2018, 12:25 AM

The node using the xhgui::app role which is using this is tungsten. tungsten was installed back in 2015 in T117888 as a test system for InfluxDB. The system uses no other roles so if this is decom'ed the question should be if the entire tungsten host can be decom'ed.

Yeah, but it's gone through decom and since been repurposed for XHGui. And since then, again being decom'ed now as part of T158837. We're mostly done with moving the webperf stuff from old hardware (hafnium and tungsten) onto multi-DC Ganeti VMs.

For hafnium this work is done.. Its services have been refactored and consolidated under the role "webperf::processors_site", running on webperf1001/webperf2001.

For tungsten, this is still in progress (role "webperf::profiling_tools"), but will go to webperf1002/webperf2002. Services being xhgui (T180761) and flame graphs (T195312).

This task is for removing the left-over bits of the "XHProf Viewer" which was the predecessor to XHGui, but it hasn't been accessible or used in any way for a long time. We thought it was just unpuppetised left-over, and that might still be the case, as I haven't tried applying the role elsewhere. But there still appear to be some puppet resources related to it as well.

Krinkle claimed this task.Jan 14 2019, 9:47 PM

Change 484351 had a related patch set uploaded (by Krinkle; owner: Krinkle):
[operations/puppet@production] xhgui: Remove outdated clone of xhprof mirror

https://gerrit.wikimedia.org/r/484351

Change 484351 merged by Dzahn:
[operations/puppet@production] xhgui: Remove outdated clone of xhprof mirror

https://gerrit.wikimedia.org/r/484351

merged. want me to also rm /srv/xhprof/profiles on tungsten? are you doing that?

Mentioned in SAL (#wikimedia-operations) [2019-01-16T23:10:37Z] <Krinkle> krinkle@tungsten:/srv/: rm -rf xhprof; for T196406

Krinkle closed this task as Resolved.Jan 16 2019, 11:11 PM
Krinkle removed a project: Patch-For-Review.

(Done.)