Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Prometheus Startup Error #1981

Closed
tesla747 opened this Issue Sep 12, 2016 · 3 comments

Comments

Projects
None yet
2 participants
@tesla747
Copy link

tesla747 commented Sep 12, 2016

Trying to start Prometheus?

What did you expect to see?

I'm trying to start prometheus, im getting the below error

INFO[0000] Starting prometheus (version=1.1.2, branch=master, revision=36fbdcc30fd13ad796381dc934742c559feeb1b5) source=main.go:73
INFO[0000] Build context (go=go1.6.3, user=root@a74d279a0d22, date=20160908-13:12:43) source=main.go:74
INFO[0000] Loading configuration file prometheus.yml source=main.go:221
ERRO[0000] Error loading config: couldn't load configuration (-config.file=prometheus.yml): yaml: line 6: found character that cannot start any token source=main.go:126

RHEL 6

  • System information:

Linux 2.6.32-573.12.1.el6.x86_64 x86_64

  • Prometheus version:

prometheus, version 1.1.2 (branch: master, revision: 36fbdcc)
build user: root@a74d279a0d22
build date: 20160908-13:12:43
go version: go1.6.3

  • Alertmanager version:

NA

  • Prometheus configuration file:
global:
  scrape_interval:     5s
  evaluation_interval: 5s
scrape_configs:
- job_name: linux
target_groups:
        -targets: ['192.17.36.189:3306']
          labels:
            alias: db1
  • Alertmanager configuration file:
NA
  • Logs:
insert Prometheus and Alertmanager logs relevant to the issue here
@fabxc

This comment has been minimized.

Copy link
Member

fabxc commented Sep 12, 2016

You have to put a space after the - in -targets. Please use a YAML linter for future YAML syntax errors: http://www.yamllint.com/

Also make sure that you use the correct indentation levels. These are not valid.
target_groups is deprecated for a while now.

global:
  scrape_interval:     5s
  evaluation_interval: 5s
scrape_configs:
- job_name: linux
  static_configs:
  - targets: 
    - '192.17.36.189:3306'
    labels:
      alias: db1

Configuration documentation: https://prometheus.io/docs/operating/configuration

@fabxc fabxc closed this Sep 12, 2016

@tesla747

This comment has been minimized.

Copy link
Author

tesla747 commented Sep 12, 2016

Thanks fabxc. I have started it, but i'm unable to open the prometheus link in my browser. It says site can't be reached. I know these doubts are silly. Would be glad if you could help me. Does it have to do with proxy or anything?

@lock

This comment has been minimized.

Copy link

lock bot commented Mar 24, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked and limited conversation to collaborators Mar 24, 2019

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
You can’t perform that action at this time.