PMM Query Analytics Settings and PMM System Summary broken on fresh PMM 1.17.1Docker

I have installed a fresh (non upgraded) PMM Server 1.17.1 running on Docker and am having problems when accessing the _PMM menu options, namely PMM Query Analytics Settings and PMM System Summary. When I browse to these locations I get a spinning wheel and no content, even before I add any monitored hosts (with pmm-admin of pmm-client package).

I am attaching screenshots and technical information to illustrate the problem.
I am looking for a fix or clues on how to troubleshoot. I believe the problem is located somewhere around the javascript code found in /usr/share/percona-qan-app/ .

Symptoms:
https://drive.google.com/file/d/1f8s4sWAk7VJJybRDyBg_TVQiNqI007o_/view?usp=sharing
See also attached screen shots

Here is some technical information, feel free to ask for anything that’s needed:

  1. Tried fresh docker pmm-data container with fresh docker pmm-server but always get spinning wheel right after installation.
  2. Tried Firefox 47.0 and Chrome Version 46.0.2490.86 (64-bit) both under Linux
  3. Runtime information

root@sqlpmm1:~# cat /etc/issue
Ubuntu 16.04.5 LTS \n \l

root@sqlpmm1:~# docker --version
Docker version 18.09.1, build 4c52b90

root@sqlpmm1:~# docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
1b09f3f81f02 percona/pmm-server:1 “/opt/entrypoint.sh” 11 days ago Up 11 days 0.0.0.0:443->443/tcp, 80/tcp, 0.0.0.0:3000->3000/tcp pmm-server
16c24a6ce045 percona/pmm-server:1 “/bin/true” 11 days ago Created pmm-data

  1. Output of https://github.com/Percona-QA/percona-qa/blob/master/pmm-info.sh

root@sqlpmm1:~# sh pmm-info.sh
QA PMM Info Script v0.10
==================== uname -a
Linux sqlpmm1 4.4.0-140-generic #166-Ubuntu SMP Wed Nov 14 20:09:47 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
==================== /proc/version
Linux version 4.4.0-140-generic (buildd@lcy01-amd64-006) (gcc version 5.4.0 20160609 (Ubuntu 5.4.0-6ubuntu1~16.04.10) ) #166-Ubuntu SMP Wed Nov 14 20:09:47 UTC 2018
==================== OS Release (filtered cat /etc/*-release):
DISTRIB_CODENAME=xenial
DISTRIB_DESCRIPTION=“Ubuntu 16.04.5 LTS”
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=16.04
HOME_URL=“http://www.ubuntu.com/
ID_LIKE=debian
ID=ubuntu
NAME=“Ubuntu”
PRETTY_NAME=“Ubuntu 16.04.5 LTS”
SUPPORT_URL=“http://help.ubuntu.com/
UBUNTU_CODENAME=xenial
VERSION=“16.04.5 LTS (Xenial Xerus)”
VERSION_CODENAME=xenial
VERSION_ID=“16.04”
==================== Docker release (docker --version):
Docker version 18.09.1, build 4c52b90
==================== SELinux status if present (sestatus):
pmm-info.sh: 14: pmm-info.sh: sestatus: not found
==================== PMM server images (sudo docker images | grep pmm):
percona/pmm-server 1 deac61541b67 2 months ago 1.08GB
percona/pmm-server latest deac61541b67 2 months ago 1.08GB
==================== PMM server state (sudo docker ps -a | grep pmm):
1b09f3f81f02 percona/pmm-server:1 “/opt/entrypoint.sh” 11 days ago Up 11 days 0.0.0.0:443->443/tcp, 80/tcp, 0.0.0.0:3000->3000/tcp pmm-server
16c24a6ce045 percona/pmm-server:1 “/bin/true” 11 days ago Created pmm-data
b5d3d3aad6f4 izakmarais/grafana-reporter “/usr/local/bin/graf\u2026” 2 weeks ago Up 2 weeks 0.0.0.0:80->8686/tcp pmm-pdf
==================== Exporter status (ps -ef | grep exporter):
root 54056 53954 1 Apr10 ? 03:48:11 /usr/local/percona/pmm-client/node_exporter -web.listen-address=localhost:9100 -collectors.enabled=diskstats,filefd,filesystem,loadavg,meminfo,netdev,netstat,stat,time,uname,vmstat
==================== PMM info (sudo pmm-admin info):
sudo: pmm-admin: command not found
==================== PMM network check (sudo pmm-admin check-network):
pmm-info.sh: 24: pmm-info.sh: function: not found
sudo: pmm-admin: command not found
pmm-info.sh: 27: pmm-info.sh: version: not found
pmm-info.sh: 27: pmm-info.sh: version: not found
pmm-info.sh: 27: [: Illegal number:
sudo: pmm-admin: command not found
==================== PMM list (sudo pmm-admin list):
sudo: pmm-admin: command not found

  1. NGINX relevant section /etc/nginx/conf.d/pmm.conf

QAN App

location /qan {
alias /usr/share/percona-qan-app;
try_files $uri /index.html break;
add_header X-Frame-Options SAMEORIGIN;
}

  1. I think it might be somewhere in the javascript code specified in 5. above:

cat index.html

<!doctype html>

Percona Query Analytics [root@1b09f3f81f02 percona-qan-app]# ls -lah *js -rw-r--r-- 1 root root 2.0M Feb 13 13:11 main.028181dae0e9fde58167.js -rw-r--r-- 1 root root 104K Feb 13 13:11 polyfills.3ba1c7d28a2c5cb87c32.js -rw-r--r-- 1 root root 1.1K Feb 13 13:11 runtime.a66f828dca56eeb90e02.js
  1. I don’t know much about web development with javascript but maybe this is helpful. When I navigate to /qan on the PMM server I get the following nginx logs:

tail -f nginx/*

==> nginx/access.log <==
10.50.15.50 - admin [22/Apr/2019:16:15:51 +0000] “GET /qan/ HTTP/2.0” 200 387 “-” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”
10.50.15.50 - admin [22/Apr/2019:16:15:51 +0000] “GET /qan/styles.ea50374bcbbca38020af.css HTTP/2.0” 304 0 “https://10.3.101.19/qan/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”
10.50.15.50 - admin [22/Apr/2019:16:15:51 +0000] “GET /qan/runtime.a66f828dca56eeb90e02.js HTTP/2.0” 304 0 “https://10.3.101.19/qan/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”
10.50.15.50 - admin [22/Apr/2019:16:15:51 +0000] “GET /qan/polyfills.3ba1c7d28a2c5cb87c32.js HTTP/2.0” 304 0 “https://10.3.101.19/qan/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”
10.50.15.50 - admin [22/Apr/2019:16:15:51 +0000] “GET /qan/main.028181dae0e9fde58167.js HTTP/2.0” 304 0 “https://10.3.101.19/qan/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”
10.50.15.50 - admin [22/Apr/2019:16:15:52 +0000] “GET /qan-api/instances?deleted=no HTTP/2.0” 200 2329 “https://10.3.101.19/qan/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”
10.50.15.50 - admin [22/Apr/2019:16:15:52 +0000] “GET /qan/fontawesome-webfont.af7ae505a9eed503f8b8.woff2?v=4.7.0 HTTP/2.0” 304 0 “https://10.3.101.19/qan/” “Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/46.0.2490.86 Safari/537.36” “-”

  • (nothing in nginx error log)
  • see also attached PMM_qan_js_console.png
    ERROR TypeError: Gs.demoHosts.includes is not a function(\u2026)
    ERROR CONTEXT e {view: Object, nodeIndex: 1, nodeDef: Object, elDef: Object, elView: Object}
    Angular is running in the development mode. Call enableProdMode() to enable the production mode.
    EmptyInstanceGuard.constructor [Object, Object, Object]
    ERROR TypeError: Gs.demoHosts.includes is not a function(\u2026)
    ERROR CONTEXT e {view: Object, nodeIndex: 1, nodeDef: Object, elDef: Object, elView: Object}
    ERROR TypeError: Gs.demoHosts.includes is not a function(\u2026)
    ERROR CONTEXT e {view: Object, nodeIndex: 1, nodeDef: Object, elDef: Object, elView: Object}
    ERROR Error: Uncaught (in promise): TypeError: Gs.demoHosts.includes is not a function(\u2026)

Hi morgado-pythian

We’ve reviewed this error but we can’t tell initially what’s going on to cause the eternal spinning of the wheel. We haven’t seen any other reports of this behaviour. Can we ask that you submit this as a bug so we can get our QA team to reproduce ?

https://jira.percona.com/browse/PMM

Hi Michael,

Thanks for your help. I’ve opened up the following bug report as requested:
https://jira.percona.com/browse/PMM-3939

I’ve managed to get the QAN page to render properly by upgrading my Firefox browser (from v47 -> v57). Feel free to close this issue.