Giter Site home page Giter Site logo

Comments (6)

avishefi avatar avishefi commented on July 29, 2024

Try using: -mongodb.uri mongodb://root:example@mongo:27017

from mongodb_exporter.

pauldintel avatar pauldintel commented on July 29, 2024

@mostafaghadimi - have you been able to make this work . ! I still have issue not getting full spectrum of mongo metrics through exporter .

from mongodb_exporter.

mostafaghadimi avatar mostafaghadimi commented on July 29, 2024

@pauldintel Yes, I did. Please share the details about how you deploy your applications. In case of using Docker, there might be network related issues.

from mongodb_exporter.

pauldintel avatar pauldintel commented on July 29, 2024

hi @mostafaghadimi thanks for offering the help . I am using mongo7.0.5, prometheus , nodeexporter , grafana and mongodb exporter in docker container (all inside same network bridge) .
Below is the docker specification :

mongodb-exporter:
hostname: mongodb-exporter
container_name: mongodb-exporter
image: mongoexport:prom
command: ./mongodb_exporter-linux-amd64 -logtostderr -mongodb.uri mongodb://admin1:password@mongo1:27017/mydb -groups.enabled 'asserts,durability,background_flusshing,connections,extra_info,global_lock,index_counters,network,op_counters,op_counters_repl,memory,locks,metrics'
restart: always
ports:
- 9001:9001
networks:
mongo_network:

Please note above mongo1 is the container name and mydb is the db name . the exporter linux utility is used in command line.
the issue with the above is I am getting Authentication failed error : the prometheus portal shows mongo exporter is up and running on 9001 port and no issue . But just shows couple of http# metrics and nothing on mongo metrics shown . So my gut feeling is this is because mongo authentication failure.

image

Generally at this moment my thought is those user/password needs to be preexisting on the database. Once I create them in database with admin roles I started getting Panic error plus mongo exporter shows down in prometheus ..

image

So at this moment it is being very strange ! I want to use Grafana dashboard comes pre-shipped with mongo metrics that works on exporter and stuck on implementing that solution.

from mongodb_exporter.

mostafaghadimi avatar mostafaghadimi commented on July 29, 2024

@pauldintel you're welcome. I think you can create user with environment variables and would you please also share your mongodb service in docker-compose file details?

from mongodb_exporter.

avishefi avatar avishefi commented on July 29, 2024

@pauldintel take a look if this is relevant: #110

I had the same message: panic: runtime error: invalid memory address or nil pointer dereference

I patched according to this comment and it worked.

from mongodb_exporter.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    šŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. šŸ“ŠšŸ“ˆšŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ā¤ļø Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.