Coder Social home page Coder Social logo

factbeat's People

Contributors

jarpy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

ruflin

factbeat's Issues

factbeat not sending anything.

This may be due to running it on a very old server, so please bear with me. I'm running a SLES 11.3 which I can unfortunately not update, with facter 2.4, and I would like to ship facter data to logstash.

My yaml file:
input:
period: 300
facter: "/usr/bin/facter"
output:
logstash:
hosts: ["http://hostname:5044"]

Running factbeat provides no output, when I quit it, this is the output:
(No data is ever shipped to logstash.)

`/opt/factbeat # ./factbeat
^Cpanic: close of nil channel

goroutine 1 [running]:
github.com/jarpy/factbeat/beat.(_Factbeat).Stop(0xc820010800)
/go/src/github.com/jarpy/factbeat/beat/factbeat.go:118 +0x25
github.com/elastic/beats/libbeat/beat.(_Beat).Stop(0xc820016240)
/go/src/github.com/elastic/beats/libbeat/beat/beat.go:278 +0xa2
github.com/elastic/beats/libbeat/beat.Run(0x8f6150, 0x8, 0x8e22b8, 0x5, 0x7f68ed5c7a08, 0xc820010800, 0x0, 0x0)
/go/src/github.com/elastic/beats/libbeat/beat/beat.go:138 +0xd0
main.main()
/go/src/github.com/jarpy/factbeat/main.go:12 +0xad

goroutine 17 [syscall, locked to thread]:
runtime.goexit()
/usr/local/go/src/runtime/asm_amd64.s:1721 +0x1

goroutine 5 [syscall]:
os/signal.loop()
/usr/local/go/src/os/signal/signal_unix.go:22 +0x18
created by os/signal.init.1
/usr/local/go/src/os/signal/signal_unix.go:28 +0x37

goroutine 7 [sleep]:
time.Sleep(0x3b9aca00)
/usr/local/go/src/runtime/time.go:59 +0xf9
github.com/jarpy/factbeat/beat.(_Factbeat).Run(0xc820010800, 0xc820016240, 0x0, 0x0)
/go/src/github.com/jarpy/factbeat/beat/factbeat.go:109 +0x8e2
github.com/elastic/beats/libbeat/beat.(_Beat).Run(0xc820016240, 0x0, 0x0)
/go/src/github.com/elastic/beats/libbeat/beat/beat.go:264 +0x361
github.com/elastic/beats/libbeat/beat.(*Beat).Start(0xc820016240, 0x0, 0x0)
/go/src/github.com/elastic/beats/libbeat/beat/beat.go:174 +0x126
github.com/elastic/beats/libbeat/beat.Run.func1(0xc820016240)
/go/src/github.com/elastic/beats/libbeat/beat/beat.go:121 +0x3c
created by github.com/elastic/beats/libbeat/beat.Run
/go/src/github.com/elastic/beats/libbeat/beat/beat.go:133 +0x8d

goroutine 8 [sleep]:
time.Sleep(0x3b9aca00)
/usr/local/go/src/runtime/time.go:59 +0xf9
github.com/elastic/beats/libbeat/outputs/mode.(_SingleConnectionMode).publish(0xc820010980, 0x0, 0x0, 0xc82009b300, 0xc82005dae0, 0x0, 0x0)
/go/src/github.com/elastic/beats/libbeat/outputs/mode/single.go:160 +0x42b
github.com/elastic/beats/libbeat/outputs/mode.(_SingleConnectionMode).PublishEvents(0xc820010980, 0x0, 0x0, 0xc820048b00, 0xc8202a4000, 0x1, 0x800, 0x0, 0x0)
/go/src/github.com/elastic/beats/libbeat/outputs/mode/single.go:84 +0x75
github.com/elastic/beats/libbeat/outputs/logstash.(_logstash).BulkPublish(0xc82000f3a0, 0x0, 0x0, 0x0, 0xc8202a4000, 0x1, 0x800, 0x0, 0x0)
/go/src/github.com/elastic/beats/libbeat/outputs/logstash/logstash.go:185 +0x39d
github.com/elastic/beats/libbeat/publisher.(_outputWorker).sendBulk(0xc8200816c0, 0xc82005dd88, 0xc8202a4000, 0x1, 0x800)
/go/src/github.com/elastic/beats/libbeat/publisher/output.go:89 +0x190
github.com/elastic/beats/libbeat/publisher.(_outputWorker).onBulk(0xc8200816c0, 0xc82005dd88, 0xc8202a4000, 0x1, 0x800)
/go/src/github.com/elastic/beats/libbeat/publisher/output.go:66 +0x3ac
github.com/elastic/beats/libbeat/publisher.(_outputWorker).onMessage(0xc8200816c0, 0xffffffffffff0000, 0x0, 0x0, 0x0, 0xc8202a4000, 0x1, 0x800)
/go/src/github.com/elastic/beats/libbeat/publisher/output.go:49 +0x79
github.com/elastic/beats/libbeat/publisher.(_messageWorker).run(0xc8200816c0)
/go/src/github.com/elastic/beats/libbeat/publisher/worker.go:69 +0x424
created by github.com/elastic/beats/libbeat/publisher.(_messageWorker).init
/go/src/github.com/elastic/beats/libbeat/publisher/worker.go:55 +0x11e

goroutine 10 [select]:
github.com/elastic/beats/libbeat/publisher.(*bulkWorker).run(0xc8200692d0)
/go/src/github.com/elastic/beats/libbeat/publisher/bulk.go:57 +0x3ca
created by github.com/elastic/beats/libbeat/publisher.newBulkWorker
/go/src/github.com/elastic/beats/libbeat/publisher/bulk.go:41 +0x20a

goroutine 11 [select, locked to thread]:
runtime.gopark(0x9b5040, 0xc820034728, 0x8e9eb8, 0x6, 0x42db18, 0x2)
/usr/local/go/src/runtime/proc.go:185 +0x163
runtime.selectgoImpl(0xc820034728, 0x0, 0x18)
/usr/local/go/src/runtime/select.go:392 +0xa64
runtime.selectgo(0xc820034728)
/usr/local/go/src/runtime/select.go:212 +0x12
runtime.ensureSigM.func1()
/usr/local/go/src/runtime/signal1_unix.go:227 +0x353
runtime.goexit()
/usr/local/go/src/runtime/asm_amd64.s:1721 +0x1
`

This may be a very dumb question, but is go required to be installed to run the binary? I assume not since filebeat works fine for me. However, my server's version of glibc is too old to install Go.

Unable to run factbeat on ubuntu 12.x

Here's what i've done on Ubuntu 12.x with fresh docker/docker-compose

  • Add 'elasticsearch' to /etc/hosts for the target ES cluster I want to use
  • git clone ...
  • cd factbeat
  • Populate the template into the cluster
  • make
  • make unit-test
  • make acceptance-test

And that fails with these errors a couple of times:
E FactbeatError: Factbeat is not populating Elasticsearch.

Even going around the acceptance tests, I'm finding I can't get very far:

[...~/src/factbeat]$ ./factbeat -c factbeat.yml -e -v -d "*"
2016/03/04 17:52:29.565697 beat.go:221: DBG  Initializing output plugins
2016/03/04 17:52:29.565777 geolite.go:24: INFO GeoIP disabled: No paths were set under shipper.geoip.paths
2016/03/04 17:52:29.565876 client.go:431: DBG  ES Ping(url=http://elasticsearch:9200, timeout=1m30s)
2016/03/04 17:52:29.570664 client.go:440: DBG  Ping status code: 200
2016/03/04 17:52:29.570701 outputs.go:89: INFO Activated elasticsearch as output plugin.
2016/03/04 17:52:29.570717 publish.go:235: DBG  Create output worker
2016/03/04 17:52:29.570818 publish.go:277: DBG  No output is defined to store the topology. The server fields might not be filled.
2016/03/04 17:52:29.570876 publish.go:291: INFO Publisher name: myhost
2016/03/04 17:52:29.571158 async.go:70: INFO Flush Interval set to: 1s
2016/03/04 17:52:29.571195 async.go:71: INFO Max Bulk Size set to: 50
2016/03/04 17:52:29.571211 async.go:79: DBG  create bulk processing worker (interval=1s, bulk size=50)
2016/03/04 17:52:29.571272 beat.go:238: INFO Init Beat: factbeat; Version: 0.1.2
2016/03/04 17:52:29.571544 beat.go:267: INFO factbeat sucessfully setup. Start running.

Can you validate the current master runs for you or give me some hints?

Feature: support ohai as alternative to facter

Facter is common in the puppet universe, ohai (ruby gem) by Chef does almost the same for the chef ecosphere.

Given that ohai by default outputs JSON, it would be nice to be able switch factor for ohai if someone is a chef-shop and has already installed it by default.

A simple way to get ohai on your system (macOS) is installing chef-dk (cask will be installed to /opt/chefdk)

brew cask install chefdk

Actually, It might work out of the box using custom configuration if the parameters for facter were configurable, e.g. no hard coded --json. Ohai users may have a custom options as well.

facter 2.x has different location

I think the linux part should support multiple paths to try.
For example with facter 2.4.4 installed from the puppetlabs apt package its installed in /usr/bin/facter

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.