FAQ
Hello,
I'm trying to build a custom report processor so that I can get puppet
metrics into Zabbix.
I found one here: https://github.com/thomasvandoren/puppet-zabbix which
basically works.

The problem I have is that report processor mostly use self.host as
hostname. But it represent certname in "puppet world".
I tried @hostname, but still get certname instead of hostname.

Is there any way to get the real hostname into report processor ?

Regards,
Jean-Baptiste Favre

--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.

Search Discussions

  • James Turnbull at Nov 26, 2012 at 4:43 am

    Jean Baptiste Favre wrote:
    Hello,
    I'm trying to build a custom report processor so that I can get puppet
    metrics into Zabbix.
    I found one here: https://github.com/thomasvandoren/puppet-zabbix which
    basically works.

    The problem I have is that report processor mostly use self.host as
    hostname. But it represent certname in "puppet world".
    I tried @hostname, but still get certname instead of hostname.

    Is there any way to get the real hostname into report processor ?
    As you're located on the master and all that gets passed to the report
    processor is the the contents of the report this is a little tricky. Off
    the top of my head you could use the self.host value to lookup the fact
    values from the node, i.e. if you're using PuppetBD
    (http://docs.puppetlabs.com/puppetdb/1/index.html) or the Inventory
    Service (http://docs.puppetlabs.com/guides/inventory_service.html).

    Hope that helps!

    Regards

    James Turnbull

    --
    James Turnbull
    1-503-734-8571
    To schedule a meeting with me: http://doodle.com/jamtur01
    We are moving! New address: Puppet Labs, Inc., 926 NW 13th Ave., Suite
    210, Portland, OR 97209.

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Jean Baptiste Favre at Nov 28, 2012 at 10:13 am
    Hello James,
    Yes, this help.
    I just felt confused that 'host' report variable represents in fact
    'certname' value.

    That said, I'll have a look on PuppetDB, which I do not use for now.

    Thanks,
    Jean Baptiste
    On 11/26/12 5:43 AM, James Turnbull wrote:
    Jean Baptiste Favre wrote:
    Hello,
    I'm trying to build a custom report processor so that I can get puppet
    metrics into Zabbix.
    I found one here: https://github.com/thomasvandoren/puppet-zabbix which
    basically works.

    The problem I have is that report processor mostly use self.host as
    hostname. But it represent certname in "puppet world".
    I tried @hostname, but still get certname instead of hostname.

    Is there any way to get the real hostname into report processor ?
    As you're located on the master and all that gets passed to the report
    processor is the the contents of the report this is a little tricky. Off
    the top of my head you could use the self.host value to lookup the fact
    values from the node, i.e. if you're using PuppetBD
    (http://docs.puppetlabs.com/puppetdb/1/index.html) or the Inventory
    Service (http://docs.puppetlabs.com/guides/inventory_service.html).

    Hope that helps!

    Regards

    James Turnbull
    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppuppet-users @
categoriespuppet
postedNov 23, '12 at 9:52a
activeNov 28, '12 at 10:13a
posts3
users2
websitepuppetlabs.com

People

Translate

site design / logo © 2022 Grokbase