Am Montag, 7. Januar 2019, 18:25:50 CET schrieb Dave Howorth:
OK, another silly question. Does anybody use
Yes. However in "production" I use the upstream build as the SUSE package
sadly is not available vor ARMv7. (Yes, I run it on a Raspberry PI 2.)
To look at your issue I installed it on my workstation.
I just installed it but I'm not having much luck
getting started with
I assume you did `zypper in golang-github-prometheus-prometheus` .
prometheus, version 2.1.0 (branch: non-git, revision:
build user: abuild@lamb69
build date: 20180513-03:46:03
go version: go1.9.4
Yep, can reproduce.
so at least it runs. I can't find any opensuse
docs to tell me about
anything specific (no man page in particular) so I'm relying on the
'Starting' section in
which is not
brilliant. I first tried running as my own user and failed with lack of
permission to create /var/lib/prometheus/metrics so then I tried as
root, which seemed to work but seems a bit weird, so then I tried user
prometheus and that worked too, so is probably right, but it would be
nice if there was opensuse docs to say so, and/or something on the web
page to indicate it.
There is nothing special about the SUSE package. When running as a user you
will have to give it a configuration file so that it will find a proper place
to store its data and know what to scrape.
I suggest to run it via the Systemd unit contained in the package:
systemctl start prometheus.service
This will run the service as the Prometheus service which will have write
access to /var/lib/prometheus/metrics.
It will use the config file from the default location at /etc/prometheus/
prometheus.yml. The package provides a working basic configuration.
Anyway, I then fired up a browser and pointed it at
and got a display. But it doesn't seem to
work like https://prometheus.io/docs/introduction/first_steps/
should. I assume it means 'choose the "Console" view alongside the
"Graph" tab' as opposed to what it does say. But it just says 'no
data'. I assume that 'the expression console' is the text box at the
top of the screen but nothing happens when I put the recommended string
into it, and if I hit Execute, it says 'No datapoints found'
It sometimes takes a couple seconds until Prometheus has the first data
collection (it usually samples every 60s). On the Graph view you will see a
dropdown with all available metrics next to the execute button. Selecting one
there will insert it into the query editor. Pressing execute should give you
data. This works for me with the freshly installed package and started Systemd
The IMHO most helpful debugging screen of Prometheus is http://localhost:9090/
targets. This will show you wether anything has been configured to be scraped,
when it was last scraped, and wether it was up. In addition, http://localhost
9090/config will give you the current configuration, allowing you to verify
that Prometheus is actually using the config file you expect it to use.
The version in Leap is not the latest one, but should be recent enough not to
differ from the upstream documentation too much. I hope this could help you
Dr. Matthias Bach
„Der einzige Weg, die Grenzen des Möglichen zu finden, ist ein klein wenig
über diese hinaus in das Unmögliche vorzustoßen.“ - Arthur C. Clarke