Reports not updating

Hi Guys, im having some troubles updating the reports.

Its simple, the only way to get reports are importing them manually.

I followed the setup instructions, but no luck. I having the same
issue with puppet-dashboard, so it might be something with
puppetmaster. Reports get generated and stored, but looks like they
are to forwarded to foreman/puppet-dashboard.

Any hint on debugin this?

Let me know if you want to see any config file.

thanks!

does going over
https://groups.google.com/group/foreman-users/browse_thread/thread/48e562f56455afb0?hl=en
helps?

Ohad

··· On Thu, Nov 25, 2010 at 4:18 PM, Nicolas Arias wrote:

Hi Guys, im having some troubles updating the reports.

Its simple, the only way to get reports are importing them manually.

I followed the setup instructions, but no luck. I having the same
issue with puppet-dashboard, so it might be something with
puppetmaster. Reports get generated and stored, but looks like they
are to forwarded to foreman/puppet-dashboard.

Any hint on debugin this?

Let me know if you want to see any config file.

thanks!


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

Didnt help.

i only see:

Processing FactValuesController#create (for 172.31.201.164 at
2010-11-25 13:15:03) [POST]
Parameters: {"facts"=>"[FILTERED]", "action"=>"create",
"controller"=>"fact_values"}
Completed in 194ms (View: 0, DB: 40) | 200 OK
[http://#######/fact_values/create]

Processing FactValuesController#create (for 172.31.201.164 at
2010-11-25 13:15:03) [POST]
Parameters: {"facts"=>"[FILTERED]", "action"=>"create",
"controller"=>"fact_values"}
Completed in 227ms (View: 0, DB: 31) | 200 OK
[http://#######/fact_values/create]

reports = store, foreman
reportdir = $vardir/reports/

ruby report files:

[root@puppet #######]# ls -l /usr/lib/ruby/site_ruby/1.8/puppet/reports
total 36
-rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb
-rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb
-rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb
-rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb
-rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb
-rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb

Reports are generated and stored by puppet. They are not forwarded to foreman.

Thanks.

··· from my puppetmaster conf:

On Thu, Nov 25, 2010 at 11:39 AM, Ohad Levy ohadlevy@gmail.com wrote:

does going
over https://groups.google.com/group/foreman-users/browse_thread/thread/48e562f56455afb0?hl=en helps?
Ohad

On Thu, Nov 25, 2010 at 4:18 PM, Nicolas Arias nicoarias@gmail.com wrote:

Hi Guys, im having some troubles updating the reports.

Its simple, the only way to get reports are importing them manually.

I followed the setup instructions, but no luck. I having the same
issue with puppet-dashboard, so it might be something with
puppetmaster. Reports get generated and stored, but looks like they
are to forwarded to foreman/puppet-dashboard.

Any hint on debugin this?

Let me know if you want to see any config file.

thanks!


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


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

> Didnt help.
>
> i only see:
>
> Processing FactValuesController#create (for 172.31.201.164 at
> 2010-11-25 13:15:03) [POST]
> Parameters: {"facts"=>"[FILTERED]", "action"=>"create",
> "controller"=>"fact_values"}
> Completed in 194ms (View: 0, DB: 40) | 200 OK
> [http://#######/fact_values/create]
>
>
> Processing FactValuesController#create (for 172.31.201.164 at
> 2010-11-25 13:15:03) [POST]
> Parameters: {"facts"=>"[FILTERED]", "action"=>"create",
> "controller"=>"fact_values"}
> Completed in 227ms (View: 0, DB: 31) | 200 OK
> [http://#######/fact_values/create]
>
>
> from my puppetmaster conf:
>
> reports = store, foreman
>
You dont really need the store option (as it just keeps it as plain file)

> reportdir = $vardir/reports/
>
>
> ruby report files:
>
> [root@puppet #######]# ls -l /usr/lib/ruby/site_ruby/1.8/puppet/reports
> total 36
> -rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb
> -rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb
> -rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb
> -rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb
> -rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb
> -rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb
>
>
> That probably means you dont have the right url in foreman.rb (or you didnt
restart your master).
if the master is failing to send the message to foreman, you should see the
error in your syslog.

Ohad

··· On Thu, Nov 25, 2010 at 6:22 PM, Nicolas Arias wrote:

[root@puppet foreman]# cat
/usr/lib/ruby/site_ruby/1.8/puppet/reports/foreman.rb

copy this file to your report dir - e.g. /usr/lib/ruby/1.8/puppet/reports/

add this report in your puppetmaster reports - e.g, in your puppet.conf add:

reports=log, foreman # (or any other reports you want)

URL of your Foreman installation

$foreman_url="http://puppet.cs.#####:3001"

(foreman is listening on port 3001)

puppetmasterd in debug mode:

notice: Starting Puppet server version 0.25.5
debug: Finishing transaction -609036108 with 0 changes
info: mount[files]: allowing *.globant.com access
debug: No modules mount given; autocreating with default permissions
debug: No plugins mount given; autocreating with default permissions
debug: Creating interpreter
debug: Finishing transaction -609043938 with 0 changes
info: access[^/catalog/([^/]+)$]: allowing 'method' find
info: access[^/catalog/([^/]+)$]: allowing $1 access
info: access[/certificate_revocation_list/ca]: allowing 'method' find
info: access[/certificate_revocation_list/ca]: allowing * access
info: access[/report]: allowing 'method' save
info: access[/report]: allowing * access
info: access[/file]: allowing * access
info: access[/certificate/ca]: adding authentication no
info: access[/certificate/ca]: allowing 'method' find
info: access[/certificate/ca]: allowing * access
info: access[/certificate/]: adding authentication no
info: access[/certificate/]: allowing 'method' find
info: access[/certificate/]: allowing * access
info: access[/certificate_request]: adding authentication no
info: access[/certificate_request]: allowing 'method' find
info: access[/certificate_request]: allowing 'method' save
info: access[/certificate_request]: allowing * access
info: access[/]: adding authentication any
info: Expiring the node cache of puppet.cs.globant.com
info: Not using expired node for puppet.cs.globant.com from cache;
expired at Thu Nov 25 13:36:36 -0300 2010
info: Caching node for puppet.cs.globant.com
debug: importing '/etc/puppet/modules/classes/users.pp'
debug: importing '/etc/puppet/modules/classes/yum.pp'
debug: importing '/etc/puppet/modules/classes/resolvconf.pp'
debug: importing '/etc/puppet/modules/classes/ldap_auth.pp'
debug: importing '/etc/puppet/modules/classes/mysql.pp'
debug: importing '/etc/puppet/modules/classes/syslog.pp'
debug: importing '/etc/puppet/modules/utils.pp'
debug: importing '/etc/puppet/modules/classes/sendmail.pp'
debug: importing '/etc/puppet/modules/classes/tcpwrappers.pp'
debug: importing '/etc/puppet/modules/classes/groups.pp'
debug: importing '/etc/puppet/modules/classes/ntp.pp'
debug: importing '/etc/puppet/modules/classes/ssh.pp'
debug: importing '/etc/puppet/modules/classes/puppet.pp'
debug: importing '/etc/puppet/modules/classes/sudoers.pp'
debug: importing '/etc/puppet/modules/classes/initd.pp'
notice: Compiled catalog for puppet.cs.##### in 0.51 seconds

This is for reports = foreman.

Looks like puppetmasted is ignoring reports = foreman.

··· On Thu, Nov 25, 2010 at 1:36 PM, Ohad Levy wrote: > > > On Thu, Nov 25, 2010 at 6:22 PM, Nicolas Arias wrote: >> >> Didnt help. >> >> i only see: >> >> Processing FactValuesController#create (for 172.31.201.164 at >> 2010-11-25 13:15:03) [POST] >> Parameters: {"facts"=>"[FILTERED]", "action"=>"create", >> "controller"=>"fact_values"} >> Completed in 194ms (View: 0, DB: 40) | 200 OK >> [http://#######/fact_values/create] >> >> >> Processing FactValuesController#create (for 172.31.201.164 at >> 2010-11-25 13:15:03) [POST] >> Parameters: {"facts"=>"[FILTERED]", "action"=>"create", >> "controller"=>"fact_values"} >> Completed in 227ms (View: 0, DB: 31) | 200 OK >> [http://#######/fact_values/create] >> >> >> from my puppetmaster conf: >> >> reports = store, foreman > > You dont really need the store option (as it just keeps it as plain file) >> >> reportdir = $vardir/reports/ >> >> >> ruby report files: >> >> [root@puppet #######]# ls -l /usr/lib/ruby/site_ruby/1.8/puppet/reports >> total 36 >> -rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb >> -rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb >> -rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb >> -rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb >> -rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb >> -rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb >> >> > That probably means you dont have the right url in foreman.rb (or you didnt > restart your master). > if the master is failing to send the message to foreman, you should see the > error in your syslog. > Ohad > > -- > You received this message because you are subscribed to the Google Groups > "Foreman users" group. > To post to this group, send email to foreman-users@googlegroups.com. > To unsubscribe from this group, send email to > foreman-users+unsubscribe@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/foreman-users?hl=en. >

can you confirm that:
a. puppet really send a report to the master? (can see a post request going
to the master)
b. the reports setting is under the [puppetmaster] section

Ohad

··· On Thu, Nov 25, 2010 at 6:41 PM, Nicolas Arias wrote:

[root@puppet foreman]# cat
/usr/lib/ruby/site_ruby/1.8/puppet/reports/foreman.rb

copy this file to your report dir - e.g.

/usr/lib/ruby/1.8/puppet/reports/

add this report in your puppetmaster reports - e.g, in your puppet.conf

add:

reports=log, foreman # (or any other reports you want)

URL of your Foreman installation

$foreman_url=“http://puppet.cs.#####:3001

(foreman is listening on port 3001)

puppetmasterd in debug mode:

notice: Starting Puppet server version 0.25.5
debug: Finishing transaction -609036108 with 0 changes
info: mount[files]: allowing *.globant.com access
debug: No modules mount given; autocreating with default permissions
debug: No plugins mount given; autocreating with default permissions
debug: Creating interpreter
debug: Finishing transaction -609043938 with 0 changes
info: access[^/catalog/([^/]+)$]: allowing ‘method’ find
info: access[^/catalog/([^/]+)$]: allowing $1 access
info: access[/certificate_revocation_list/ca]: allowing ‘method’ find
info: access[/certificate_revocation_list/ca]: allowing * access
info: access[/report]: allowing ‘method’ save
info: access[/report]: allowing * access
info: access[/file]: allowing * access
info: access[/certificate/ca]: adding authentication no
info: access[/certificate/ca]: allowing ‘method’ find
info: access[/certificate/ca]: allowing * access
info: access[/certificate/]: adding authentication no
info: access[/certificate/]: allowing ‘method’ find
info: access[/certificate/]: allowing * access
info: access[/certificate_request]: adding authentication no
info: access[/certificate_request]: allowing ‘method’ find
info: access[/certificate_request]: allowing ‘method’ save
info: access[/certificate_request]: allowing * access
info: access[/]: adding authentication any
info: Expiring the node cache of puppet.cs.globant.com
info: Not using expired node for puppet.cs.globant.com from cache;
expired at Thu Nov 25 13:36:36 -0300 2010
info: Caching node for puppet.cs.globant.com
debug: importing '/etc/puppet/modules/classes/users.pp’
debug: importing '/etc/puppet/modules/classes/yum.pp’
debug: importing '/etc/puppet/modules/classes/resolvconf.pp’
debug: importing '/etc/puppet/modules/classes/ldap_auth.pp’
debug: importing '/etc/puppet/modules/classes/mysql.pp’
debug: importing '/etc/puppet/modules/classes/syslog.pp’
debug: importing '/etc/puppet/modules/utils.pp’
debug: importing '/etc/puppet/modules/classes/sendmail.pp’
debug: importing '/etc/puppet/modules/classes/tcpwrappers.pp’
debug: importing '/etc/puppet/modules/classes/groups.pp’
debug: importing '/etc/puppet/modules/classes/ntp.pp’
debug: importing '/etc/puppet/modules/classes/ssh.pp’
debug: importing '/etc/puppet/modules/classes/puppet.pp’
debug: importing '/etc/puppet/modules/classes/sudoers.pp’
debug: importing '/etc/puppet/modules/classes/initd.pp’
notice: Compiled catalog for puppet.cs.##### in 0.51 seconds

This is for reports = foreman.

Looks like puppetmasted is ignoring reports = foreman.

On Thu, Nov 25, 2010 at 1:36 PM, Ohad Levy ohadlevy@gmail.com wrote:

On Thu, Nov 25, 2010 at 6:22 PM, Nicolas Arias nicoarias@gmail.com > wrote:

Didnt help.

i only see:

Processing FactValuesController#create (for 172.31.201.164 at
2010-11-25 13:15:03) [POST]
Parameters: {“facts”=>"[FILTERED]", “action”=>“create”,
“controller”=>“fact_values”}
Completed in 194ms (View: 0, DB: 40) | 200 OK
[http://#######/fact_values/create]

Processing FactValuesController#create (for 172.31.201.164 at
2010-11-25 13:15:03) [POST]
Parameters: {“facts”=>"[FILTERED]", “action”=>“create”,
“controller”=>“fact_values”}
Completed in 227ms (View: 0, DB: 31) | 200 OK
[http://#######/fact_values/create]

from my puppetmaster conf:

reports = store, foreman

You dont really need the store option (as it just keeps it as plain file)

reportdir = $vardir/reports/

ruby report files:

[root@puppet #######]# ls -l /usr/lib/ruby/site_ruby/1.8/puppet/reports
total 36
-rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb
-rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb
-rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb
-rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb
-rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb
-rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb

That probably means you dont have the right url in foreman.rb (or you
didnt
restart your master).
if the master is failing to send the message to foreman, you should see
the
error in your syslog.
Ohad


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


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

> can you confirm that:
> a. puppet really send a report to the master? (can see a post request going to the master)
reports are generated on puppetmaster
> b. the reports setting is under the [puppetmaster] section
its configured. The reports get stored, but not sent to foreman.

··· On Thu, Nov 25, 2010 at 1:48 PM, Ohad Levy wrote: > Ohad > > On Thu, Nov 25, 2010 at 6:41 PM, Nicolas Arias wrote: >> >> [root@puppet foreman]# cat >> /usr/lib/ruby/site_ruby/1.8/puppet/reports/foreman.rb >> # copy this file to your report dir - e.g. >> /usr/lib/ruby/1.8/puppet/reports/ >> # add this report in your puppetmaster reports - e.g, in your puppet.conf >> add: >> # reports=log, foreman # (or any other reports you want) >> >> # URL of your Foreman installation >> $foreman_url="http://puppet.cs.#####:3001" >> >> (foreman is listening on port 3001) >> >> >> puppetmasterd in debug mode: >> >> notice: Starting Puppet server version 0.25.5 >> debug: Finishing transaction -609036108 with 0 changes >> info: mount[files]: allowing *.globant.com access >> debug: No modules mount given; autocreating with default permissions >> debug: No plugins mount given; autocreating with default permissions >> debug: Creating interpreter >> debug: Finishing transaction -609043938 with 0 changes >> info: access[^/catalog/([^/]+)$]: allowing 'method' find >> info: access[^/catalog/([^/]+)$]: allowing $1 access >> info: access[/certificate_revocation_list/ca]: allowing 'method' find >> info: access[/certificate_revocation_list/ca]: allowing * access >> info: access[/report]: allowing 'method' save >> info: access[/report]: allowing * access >> info: access[/file]: allowing * access >> info: access[/certificate/ca]: adding authentication no >> info: access[/certificate/ca]: allowing 'method' find >> info: access[/certificate/ca]: allowing * access >> info: access[/certificate/]: adding authentication no >> info: access[/certificate/]: allowing 'method' find >> info: access[/certificate/]: allowing * access >> info: access[/certificate_request]: adding authentication no >> info: access[/certificate_request]: allowing 'method' find >> info: access[/certificate_request]: allowing 'method' save >> info: access[/certificate_request]: allowing * access >> info: access[/]: adding authentication any >> info: Expiring the node cache of puppet.cs.globant.com >> info: Not using expired node for puppet.cs.globant.com from cache; >> expired at Thu Nov 25 13:36:36 -0300 2010 >> info: Caching node for puppet.cs.globant.com >> debug: importing '/etc/puppet/modules/classes/users.pp' >> debug: importing '/etc/puppet/modules/classes/yum.pp' >> debug: importing '/etc/puppet/modules/classes/resolvconf.pp' >> debug: importing '/etc/puppet/modules/classes/ldap_auth.pp' >> debug: importing '/etc/puppet/modules/classes/mysql.pp' >> debug: importing '/etc/puppet/modules/classes/syslog.pp' >> debug: importing '/etc/puppet/modules/utils.pp' >> debug: importing '/etc/puppet/modules/classes/sendmail.pp' >> debug: importing '/etc/puppet/modules/classes/tcpwrappers.pp' >> debug: importing '/etc/puppet/modules/classes/groups.pp' >> debug: importing '/etc/puppet/modules/classes/ntp.pp' >> debug: importing '/etc/puppet/modules/classes/ssh.pp' >> debug: importing '/etc/puppet/modules/classes/puppet.pp' >> debug: importing '/etc/puppet/modules/classes/sudoers.pp' >> debug: importing '/etc/puppet/modules/classes/initd.pp' >> notice: Compiled catalog for puppet.cs.##### in 0.51 seconds >> >> >> This is for reports = foreman. >> >> Looks like puppetmasted is ignoring reports = foreman. >> >> >> >> >> On Thu, Nov 25, 2010 at 1:36 PM, Ohad Levy wrote: >> > >> > >> > On Thu, Nov 25, 2010 at 6:22 PM, Nicolas Arias >> > wrote: >> >> >> >> Didnt help. >> >> >> >> i only see: >> >> >> >> Processing FactValuesController#create (for 172.31.201.164 at >> >> 2010-11-25 13:15:03) [POST] >> >> Parameters: {"facts"=>"[FILTERED]", "action"=>"create", >> >> "controller"=>"fact_values"} >> >> Completed in 194ms (View: 0, DB: 40) | 200 OK >> >> [http://#######/fact_values/create] >> >> >> >> >> >> Processing FactValuesController#create (for 172.31.201.164 at >> >> 2010-11-25 13:15:03) [POST] >> >> Parameters: {"facts"=>"[FILTERED]", "action"=>"create", >> >> "controller"=>"fact_values"} >> >> Completed in 227ms (View: 0, DB: 31) | 200 OK >> >> [http://#######/fact_values/create] >> >> >> >> >> >> from my puppetmaster conf: >> >> >> >> reports = store, foreman >> > >> > You dont really need the store option (as it just keeps it as plain >> > file) >> >> >> >> reportdir = $vardir/reports/ >> >> >> >> >> >> ruby report files: >> >> >> >> [root@puppet #######]# ls -l /usr/lib/ruby/site_ruby/1.8/puppet/reports >> >> total 36 >> >> -rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb >> >> -rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb >> >> -rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb >> >> -rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb >> >> -rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb >> >> -rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb >> >> >> >> >> > That probably means you dont have the right url in foreman.rb (or you >> > didnt >> > restart your master). >> > if the master is failing to send the message to foreman, you should see >> > the >> > error in your syslog. >> > Ohad >> > >> > -- >> > You received this message because you are subscribed to the Google >> > Groups >> > "Foreman users" group. >> > To post to this group, send email to foreman-users@googlegroups.com. >> > To unsubscribe from this group, send email to >> > foreman-users+unsubscribe@googlegroups.com. >> > For more options, visit this group at >> > http://groups.google.com/group/foreman-users?hl=en. >> > >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Foreman users" group. >> To post to this group, send email to foreman-users@googlegroups.com. >> To unsubscribe from this group, send email to >> foreman-users+unsubscribe@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/foreman-users?hl=en. >> > > -- > You received this message because you are subscribed to the Google Groups > "Foreman users" group. > To post to this group, send email to foreman-users@googlegroups.com. > To unsubscribe from this group, send email to > foreman-users+unsubscribe@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/foreman-users?hl=en. >

perhaps join us at #theforeman on irc (freenode), it would probably make it
a whole lot faster :slight_smile:

Ohad

··· On Thu, Nov 25, 2010 at 6:51 PM, Nicolas Arias wrote:

On Thu, Nov 25, 2010 at 1:48 PM, Ohad Levy ohadlevy@gmail.com wrote:

can you confirm that:
a. puppet really send a report to the master? (can see a post request
going to the master)
reports are generated on puppetmaster
b. the reports setting is under the [puppetmaster] section
its configured. The reports get stored, but not sent to foreman.
Ohad

On Thu, Nov 25, 2010 at 6:41 PM, Nicolas Arias nicoarias@gmail.com > wrote:

[root@puppet foreman]# cat
/usr/lib/ruby/site_ruby/1.8/puppet/reports/foreman.rb

copy this file to your report dir - e.g.

/usr/lib/ruby/1.8/puppet/reports/

add this report in your puppetmaster reports - e.g, in your

puppet.conf

add:

reports=log, foreman # (or any other reports you want)

URL of your Foreman installation

$foreman_url=“http://puppet.cs.#####:3001

(foreman is listening on port 3001)

puppetmasterd in debug mode:

notice: Starting Puppet server version 0.25.5
debug: Finishing transaction -609036108 with 0 changes
info: mount[files]: allowing *.globant.com access
debug: No modules mount given; autocreating with default permissions
debug: No plugins mount given; autocreating with default permissions
debug: Creating interpreter
debug: Finishing transaction -609043938 with 0 changes
info: access[^/catalog/([^/]+)$]: allowing ‘method’ find
info: access[^/catalog/([^/]+)$]: allowing $1 access
info: access[/certificate_revocation_list/ca]: allowing ‘method’ find
info: access[/certificate_revocation_list/ca]: allowing * access
info: access[/report]: allowing ‘method’ save
info: access[/report]: allowing * access
info: access[/file]: allowing * access
info: access[/certificate/ca]: adding authentication no
info: access[/certificate/ca]: allowing ‘method’ find
info: access[/certificate/ca]: allowing * access
info: access[/certificate/]: adding authentication no
info: access[/certificate/]: allowing ‘method’ find
info: access[/certificate/]: allowing * access
info: access[/certificate_request]: adding authentication no
info: access[/certificate_request]: allowing ‘method’ find
info: access[/certificate_request]: allowing ‘method’ save
info: access[/certificate_request]: allowing * access
info: access[/]: adding authentication any
info: Expiring the node cache of puppet.cs.globant.com
info: Not using expired node for puppet.cs.globant.com from cache;
expired at Thu Nov 25 13:36:36 -0300 2010
info: Caching node for puppet.cs.globant.com
debug: importing '/etc/puppet/modules/classes/users.pp’
debug: importing '/etc/puppet/modules/classes/yum.pp’
debug: importing '/etc/puppet/modules/classes/resolvconf.pp’
debug: importing '/etc/puppet/modules/classes/ldap_auth.pp’
debug: importing '/etc/puppet/modules/classes/mysql.pp’
debug: importing '/etc/puppet/modules/classes/syslog.pp’
debug: importing '/etc/puppet/modules/utils.pp’
debug: importing '/etc/puppet/modules/classes/sendmail.pp’
debug: importing '/etc/puppet/modules/classes/tcpwrappers.pp’
debug: importing '/etc/puppet/modules/classes/groups.pp’
debug: importing '/etc/puppet/modules/classes/ntp.pp’
debug: importing '/etc/puppet/modules/classes/ssh.pp’
debug: importing '/etc/puppet/modules/classes/puppet.pp’
debug: importing '/etc/puppet/modules/classes/sudoers.pp’
debug: importing '/etc/puppet/modules/classes/initd.pp’
notice: Compiled catalog for puppet.cs.##### in 0.51 seconds

This is for reports = foreman.

Looks like puppetmasted is ignoring reports = foreman.

On Thu, Nov 25, 2010 at 1:36 PM, Ohad Levy ohadlevy@gmail.com wrote:

On Thu, Nov 25, 2010 at 6:22 PM, Nicolas Arias nicoarias@gmail.com > >> > wrote:

Didnt help.

i only see:

Processing FactValuesController#create (for 172.31.201.164 at
2010-11-25 13:15:03) [POST]
Parameters: {“facts”=>"[FILTERED]", “action”=>“create”,
“controller”=>“fact_values”}
Completed in 194ms (View: 0, DB: 40) | 200 OK
[http://#######/fact_values/create]

Processing FactValuesController#create (for 172.31.201.164 at
2010-11-25 13:15:03) [POST]
Parameters: {“facts”=>"[FILTERED]", “action”=>“create”,
“controller”=>“fact_values”}
Completed in 227ms (View: 0, DB: 31) | 200 OK
[http://#######/fact_values/create]

from my puppetmaster conf:

reports = store, foreman

You dont really need the store option (as it just keeps it as plain
file)

reportdir = $vardir/reports/

ruby report files:

[root@puppet #######]# ls -l
/usr/lib/ruby/site_ruby/1.8/puppet/reports

total 36
-rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb
-rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb
-rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb
-rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb
-rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb
-rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb

That probably means you dont have the right url in foreman.rb (or you
didnt
restart your master).
if the master is failing to send the message to foreman, you should
see

the
error in your syslog.
Ohad


You received this message because you are subscribed to the Google
Groups
"Foreman users" group.
To post to this group, send email to foreman-users@googlegroups.com.
To unsubscribe from this group, send email to
foreman-users+unsubscribe@googlegroups.comforeman-users%2Bunsubscribe@googlegroups.com
.

For more options, visit this group at
http://groups.google.com/group/foreman-users?hl=en.


You received this message because you are subscribed to the Google
Groups

“Foreman users” group.
To post to this group, send email to foreman-users@googlegroups.com.
To unsubscribe from this group, send email to
foreman-users+unsubscribe@googlegroups.comforeman-users%2Bunsubscribe@googlegroups.com
.

For more options, visit this group at
http://groups.google.com/group/foreman-users?hl=en.


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


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

Sorry for the delay. Looking closer to the logs i see that im having
lots of error with ruby and stuff like that.
So, im going to rebuild the box and start from scratch, so i can have
a clean environment.

thanks.

··· On Thu, Nov 25, 2010 at 1:59 PM, Ohad Levy wrote: > perhaps join us at #theforeman on irc (freenode), it would probably make it > a whole lot faster :) > Ohad > > On Thu, Nov 25, 2010 at 6:51 PM, Nicolas Arias wrote: >> >> On Thu, Nov 25, 2010 at 1:48 PM, Ohad Levy wrote: >> > can you confirm that: >> > a. puppet really send a report to the master? (can see a post request >> > going to the master) >> reports are generated on puppetmaster >> > b. the reports setting is under the [puppetmaster] section >> its configured. The reports get stored, but not sent to foreman. >> > Ohad >> > >> > On Thu, Nov 25, 2010 at 6:41 PM, Nicolas Arias >> > wrote: >> >> >> >> [root@puppet foreman]# cat >> >> /usr/lib/ruby/site_ruby/1.8/puppet/reports/foreman.rb >> >> # copy this file to your report dir - e.g. >> >> /usr/lib/ruby/1.8/puppet/reports/ >> >> # add this report in your puppetmaster reports - e.g, in your >> >> puppet.conf >> >> add: >> >> # reports=log, foreman # (or any other reports you want) >> >> >> >> # URL of your Foreman installation >> >> $foreman_url="http://puppet.cs.#####:3001" >> >> >> >> (foreman is listening on port 3001) >> >> >> >> >> >> puppetmasterd in debug mode: >> >> >> >> notice: Starting Puppet server version 0.25.5 >> >> debug: Finishing transaction -609036108 with 0 changes >> >> info: mount[files]: allowing *.globant.com access >> >> debug: No modules mount given; autocreating with default permissions >> >> debug: No plugins mount given; autocreating with default permissions >> >> debug: Creating interpreter >> >> debug: Finishing transaction -609043938 with 0 changes >> >> info: access[^/catalog/([^/]+)$]: allowing 'method' find >> >> info: access[^/catalog/([^/]+)$]: allowing $1 access >> >> info: access[/certificate_revocation_list/ca]: allowing 'method' find >> >> info: access[/certificate_revocation_list/ca]: allowing * access >> >> info: access[/report]: allowing 'method' save >> >> info: access[/report]: allowing * access >> >> info: access[/file]: allowing * access >> >> info: access[/certificate/ca]: adding authentication no >> >> info: access[/certificate/ca]: allowing 'method' find >> >> info: access[/certificate/ca]: allowing * access >> >> info: access[/certificate/]: adding authentication no >> >> info: access[/certificate/]: allowing 'method' find >> >> info: access[/certificate/]: allowing * access >> >> info: access[/certificate_request]: adding authentication no >> >> info: access[/certificate_request]: allowing 'method' find >> >> info: access[/certificate_request]: allowing 'method' save >> >> info: access[/certificate_request]: allowing * access >> >> info: access[/]: adding authentication any >> >> info: Expiring the node cache of puppet.cs.globant.com >> >> info: Not using expired node for puppet.cs.globant.com from cache; >> >> expired at Thu Nov 25 13:36:36 -0300 2010 >> >> info: Caching node for puppet.cs.globant.com >> >> debug: importing '/etc/puppet/modules/classes/users.pp' >> >> debug: importing '/etc/puppet/modules/classes/yum.pp' >> >> debug: importing '/etc/puppet/modules/classes/resolvconf.pp' >> >> debug: importing '/etc/puppet/modules/classes/ldap_auth.pp' >> >> debug: importing '/etc/puppet/modules/classes/mysql.pp' >> >> debug: importing '/etc/puppet/modules/classes/syslog.pp' >> >> debug: importing '/etc/puppet/modules/utils.pp' >> >> debug: importing '/etc/puppet/modules/classes/sendmail.pp' >> >> debug: importing '/etc/puppet/modules/classes/tcpwrappers.pp' >> >> debug: importing '/etc/puppet/modules/classes/groups.pp' >> >> debug: importing '/etc/puppet/modules/classes/ntp.pp' >> >> debug: importing '/etc/puppet/modules/classes/ssh.pp' >> >> debug: importing '/etc/puppet/modules/classes/puppet.pp' >> >> debug: importing '/etc/puppet/modules/classes/sudoers.pp' >> >> debug: importing '/etc/puppet/modules/classes/initd.pp' >> >> notice: Compiled catalog for puppet.cs.##### in 0.51 seconds >> >> >> >> >> >> This is for reports = foreman. >> >> >> >> Looks like puppetmasted is ignoring reports = foreman. >> >> >> >> >> >> >> >> >> >> On Thu, Nov 25, 2010 at 1:36 PM, Ohad Levy wrote: >> >> > >> >> > >> >> > On Thu, Nov 25, 2010 at 6:22 PM, Nicolas Arias >> >> > wrote: >> >> >> >> >> >> Didnt help. >> >> >> >> >> >> i only see: >> >> >> >> >> >> Processing FactValuesController#create (for 172.31.201.164 at >> >> >> 2010-11-25 13:15:03) [POST] >> >> >> Parameters: {"facts"=>"[FILTERED]", "action"=>"create", >> >> >> "controller"=>"fact_values"} >> >> >> Completed in 194ms (View: 0, DB: 40) | 200 OK >> >> >> [http://#######/fact_values/create] >> >> >> >> >> >> >> >> >> Processing FactValuesController#create (for 172.31.201.164 at >> >> >> 2010-11-25 13:15:03) [POST] >> >> >> Parameters: {"facts"=>"[FILTERED]", "action"=>"create", >> >> >> "controller"=>"fact_values"} >> >> >> Completed in 227ms (View: 0, DB: 31) | 200 OK >> >> >> [http://#######/fact_values/create] >> >> >> >> >> >> >> >> >> from my puppetmaster conf: >> >> >> >> >> >> reports = store, foreman >> >> > >> >> > You dont really need the store option (as it just keeps it as plain >> >> > file) >> >> >> >> >> >> reportdir = $vardir/reports/ >> >> >> >> >> >> >> >> >> ruby report files: >> >> >> >> >> >> [root@puppet #######]# ls -l >> >> >> /usr/lib/ruby/site_ruby/1.8/puppet/reports >> >> >> total 36 >> >> >> -rwxr-xr-x 1 root root 1042 Nov 25 13:14 foreman.rb >> >> >> -rwxr-xr-x 1 root puppet 300 May 20 2010 log.rb >> >> >> -rwxr-xr-x 1 root puppet 309 Nov 25 10:48 puppet_dashboard.rb >> >> >> -rwxr-xr-x 1 root puppet 4961 May 20 2010 rrdgraph.rb >> >> >> -rwxr-xr-x 1 root puppet 1907 May 20 2010 store.rb >> >> >> -rwxr-xr-x 1 root puppet 6404 May 20 2010 tagmail.rb >> >> >> >> >> >> >> >> > That probably means you dont have the right url in foreman.rb (or you >> >> > didnt >> >> > restart your master). >> >> > if the master is failing to send the message to foreman, you should >> >> > see >> >> > the >> >> > error in your syslog. >> >> > Ohad >> >> > >> >> > -- >> >> > You received this message because you are subscribed to the Google >> >> > Groups >> >> > "Foreman users" group. >> >> > To post to this group, send email to foreman-users@googlegroups.com. >> >> > To unsubscribe from this group, send email to >> >> > foreman-users+unsubscribe@googlegroups.com. >> >> > For more options, visit this group at >> >> > http://groups.google.com/group/foreman-users?hl=en. >> >> > >> >> >> >> -- >> >> You received this message because you are subscribed to the Google >> >> Groups >> >> "Foreman users" group. >> >> To post to this group, send email to foreman-users@googlegroups.com. >> >> To unsubscribe from this group, send email to >> >> foreman-users+unsubscribe@googlegroups.com. >> >> For more options, visit this group at >> >> http://groups.google.com/group/foreman-users?hl=en. >> >> >> > >> > -- >> > You received this message because you are subscribed to the Google >> > Groups >> > "Foreman users" group. >> > To post to this group, send email to foreman-users@googlegroups.com. >> > To unsubscribe from this group, send email to >> > foreman-users+unsubscribe@googlegroups.com. >> > For more options, visit this group at >> > http://groups.google.com/group/foreman-users?hl=en. >> > >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Foreman users" group. >> To post to this group, send email to foreman-users@googlegroups.com. >> To unsubscribe from this group, send email to >> foreman-users+unsubscribe@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/foreman-users?hl=en. >> > > -- > You received this message because you are subscribed to the Google Groups > "Foreman users" group. > To post to this group, send email to foreman-users@googlegroups.com. > To unsubscribe from this group, send email to > foreman-users+unsubscribe@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/foreman-users?hl=en. >