PMDANGINX(1)

πŸ“¦
version 7.2.2 Β· 3 versions
, in arch rolling, centos-stream 10, centos-stream 9, debian trixie, fedora 43, fedora 44, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ PMDANGINX ✨

okay so bestie, welcome to the pmdanginx page β€” that's section 1 of the General Commands Manual, iykyk πŸ’…


πŸ’– NAME πŸ’–

pmdanginx β€” it's the nginx performance metrics domain agent, aka the PMDA. Say it with me: Performance Metrics Domain Agent. Slay.


🌸 DESCRIPTION 🌸

So pmdanginx is a Performance Metrics Domain Agent (PMDA), and what it does is literally export performance metrics straight out of nginx(8) πŸ¦‹

And what even is nginx(8)? Bestie. It's an HTTP and reverse proxy server, a mail proxy server, and a generic TCP proxy server. Main character energy fr fr πŸ‘‘


πŸŽ€ INSTALLATION πŸŽ€

Okay so this PMDA has one requirement, and it's non-negotiable: the nginx stub_status module has to be active and available at http://localhost/nginx_status. No stub_status, no vibes. 😭

To enable that module, the "server" section of your nginx.conf configuration file should contain exactly this:

location /nginx_status {
    stub_status on;
    access_log off;
    allow 127.0.0.1;
    allow ::1;
    deny all;
}

✨ Now let's verify the instrumentation is actually available. There are two checks β€” compile-time, then run-time:

# nginx -V 2>&1 | grep -o with-http_stub_status_module
# curl http://localhost/nginx_status

Then install the nginx PMDA by running the Install script as root:

# cd $PCP_PMDAS_DIR/nginx
# ./Install

And to uninstall, the following must be done as root too:

# cd $PCP_PMDAS_DIR/nginx
# ./Remove
🫢 Heads up bestie: pmdanginx is launched by pmcd(1) and should never be executed directly. Like, ever. The Install and Remove scripts are the ones that notify pmcd(1) when the agent is installed or removed, so let them do their job. πŸ’…

🌈 FILES 🌈

  • $PCP_PMDAS_DIR/nginx/nginx.conf β€” optional configuration file for pmdanginx
  • $PCP_PMDAS_DIR/nginx/Install β€” installation script for the pmdanginx agent
  • $PCP_PMDAS_DIR/nginx/Remove β€” undo installation script for the pmdanginx agent
  • $PCP_LOG_DIR/pmcd/nginx.log β€” default log file for error messages from pmdanginx

🧚 PCP ENVIRONMENT 🧚

Environment variables with the prefix PCP_ are used to parameterize the file and directory names used by PCP. On each installation, the file /etc/pcp.conf contains the local values for these variables. And the $PCP_CONF variable may be used to specify an alternative configuration file, as described in pcp.conf(5). Periodt. πŸ’œ


⭐ SEE ALSO ⭐

PCPIntro(1), pmcd(1) and nginx(8) β€” go read those next, bestie, they're iconic πŸ¦‹


This whole thing is brought to you by Performance Co-Pilot β€” that's PCP, the source, and it's the PMDANGINX(1) page, mwah πŸ’– bye bestie, go watch your metrics ✨

πŸ“¦ where this page comes from