[Puppet Users] "Future" parser and "return value" of resource definition

2013-05-24 Thread Simon Marechal
A simple example :

file { '/tmp/out':
content => [1,2,3,8].each |$v| {
file { "/tmp/$v": content => $v; }
}
}

Should it be valid to use "each" here ? If it is, what is the expected 
behavior (in my test the content of /tmp/out is '3') ?

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




Re: [Puppet Users] puppet apply -- override node name, module path

2013-05-24 Thread Nan Liu
On Fri, May 24, 2013 at 3:39 PM, Martin Langhoff
wrote:

> Hi folks,
>
> testing puppet configs, I have
>
>   /home/martin/mytestingpuppetconfigs/{manifests,modules}
>
> and while working in there, I would like to be able to say something
> along the lines of:
>
>  puppet apply --noop --nodename=foo01 --modulepath=./modules
> manifests/site.pp
>
> which should tell me what puppet wants to do to my system.
>
> Is there any practical way to achieve this? I am not planning on
> having one test VM per "victim" system :-p


I believe you can do:

puppet apply --certname=foo01 ...


HTH,

Nan

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




[Puppet Users] Error: Could not find dependency Yumrepo[puppetlabs-products] for Package[puppet]

2013-05-24 Thread Jagan Kommineni
I have installed puppet from puppet-labs yum repository on OEL familiy 
of Red Hat Enterprise Linux Server release 5.9 (Tikanga)

[root@oel-puppet-master modules]# yum list facter
Loaded plugins: rhnplugin, security
This system is not registered with ULN.
You can use up2date --register to register.
ULN support will be disabled.
Installed Packages
facter.x86_64 1:1.7.1-1.el5  installed 
 
Available Packages
facter.noarch 1.6.6-1.el5   
 puppetlabs-products
[root@oel-puppet-master modules]# yum list puppet
Loaded plugins: rhnplugin, security
This system is not registered with ULN.
You can use up2date --register to register.
ULN support will be disabled.
Installed Packages
puppet.noarch  3.1.1-1.el5   installed 
 
Available Packages
puppet.noarch  3.2.1-1.el5   
puppetlabs-products
[root@oel-puppet-master modules]# 
---
package { "puppet":
ensure  => latest,
require => [ Yumrepo["puppetlabs-products"], 
Package["facter"] ],
notify  => Service["puppet"],
}

package { "facter":
ensure  => latest,
require => Yumrepo["puppetlabs-products"],
notify  => Service["puppet"],
}

Here is the repofile
-
[root@oel-puppet-master modules]# cat /etc/yum.repos.d/puppetlabs.repo 
[puppetlabs-products]
name=Puppet Labs Products El 5 - $basearch
baseurl=http://yum.puppetlabs.com/el/5/products/$basearch
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-puppetlabs
enabled=1
gpgcheck=1
---
 yum repolist | grep puppetlabs-products
This system is not registered with ULN.
You can use up2date --register to register.
ULN support will be disabled.
puppetlabs-products Puppet Labs Products El 5 - x86_64 
  262
[root@oel-puppet-master modules]# 
-
Could you mind to advise where I am going wrong ...
-


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




Re: [Puppet Users] apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Greg Sutcliffe
On 24 May 2013 21:55, Eric Sorenson  wrote:

> Hi Greg, thanks for the info -- I slightly disagree that the docs should
> describe manual installation; IMO they should describe supported/official
> ways to do things, because anything that's documented gets interpreted as
> being supported and official :)
>

Amen to that ;)


> That said, we could punch up the importance of including the deps
> repository. It's been necessary for EL users for a long time, but this was
> the first Puppet release that pulled in a hard dependency for Debian-based
> systems.
>

I'll snip here as I broadly agree with you anyway ;)

I think it would be fine to have an "Advanced" or "Manual APT" section
that's away from the recommended route. I don't object to a recommended
route _at all_ but I do feel the information should be there for those that
want to find it. As of today (I think) one cannot find mention of the
additional repo in the docs.

Greg
freenode: gwmngilfen

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




[Puppet Users] Re: PuppetDb Query Help/Problems

2013-05-24 Thread Worker Bee
Actually, I am getting no results..

[ ]

I assume this means that facts are not being stored but, I cannot figure
out why/how to troubleshoot...


Thanks!


On Fri, May 24, 2013 at 7:23 PM, Worker Bee  wrote:

> Hi All;
>
> I am using the PuppetDD 1.3 docs.  I am attempting to run the following
> query:
>
> curl -H 'Accept: application/json' -X GET
> http://localhost:8080/v2/resources --data-urlencode query@db_look
>
> Contents of db_look:
> ["=", "certname", "puppet-satellite"]
>
> However, I get no results with this...  I also do not get an errors
>
> I do see this in the log file (as indicated by the docs)
>
> 2013-05-24 19:17:26,464 INFO  [command-proc-46] [puppetdb.command]
> [140d6911-3d86-483c-9c00-3e637fc13ea8] [replace catalog] puppet-satellite
>
> But, I am also getting the error
> 2013-05-24 19:17:34,325 WARN  [qtp17805761-41]
> [server.AbstractHttpConnection] /v2/resources
> com.fasterxml.jackson.core.JsonParseException: Unexpected character ('#'
> (code 35)): expected a valid value (number, String, array, object, 'true',
> 'false' or 'null')
>
>
> Any advice would be greatly appreciated!
>
> Bee
>

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




[Puppet Users] PuppetDb Query Help/Problems

2013-05-24 Thread Worker Bee
Hi All;

I am using the PuppetDD 1.3 docs.  I am attempting to run the following
query:

curl -H 'Accept: application/json' -X GET
http://localhost:8080/v2/resources--data-urlencode query@db_look

Contents of db_look:
["=", "certname", "puppet-satellite"]

However, I get no results with this...  I also do not get an errors

I do see this in the log file (as indicated by the docs)

2013-05-24 19:17:26,464 INFO  [command-proc-46] [puppetdb.command]
[140d6911-3d86-483c-9c00-3e637fc13ea8] [replace catalog] puppet-satellite

But, I am also getting the error
2013-05-24 19:17:34,325 WARN  [qtp17805761-41]
[server.AbstractHttpConnection] /v2/resources
com.fasterxml.jackson.core.JsonParseException: Unexpected character ('#'
(code 35)): expected a valid value (number, String, array, object, 'true',
'false' or 'null')


Any advice would be greatly appreciated!

Bee

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




[Puppet Users] puppet apply -- override node name, module path

2013-05-24 Thread Martin Langhoff
Hi folks,

testing puppet configs, I have

  /home/martin/mytestingpuppetconfigs/{manifests,modules}

and while working in there, I would like to be able to say something
along the lines of:

 puppet apply --noop --nodename=foo01 --modulepath=./modules manifests/site.pp

which should tell me what puppet wants to do to my system.

Is there any practical way to achieve this? I am not planning on
having one test VM per "victim" system :-p

cheers,


m
--
 martin.langh...@gmail.com
 -  ask interesting questions
 - don't get distracted with shiny stuff  - working code first
 ~ http://docs.moodle.org/en/User:Martin_Langhoff

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




[Puppet Users] zpool resource fails with incorrect error

2013-05-24 Thread treydock
I'm working to expand / develop on the zpool built-in type, but the zpool 
command is failing and Puppet's returned stderr is not what I get if I 
copy/paste the command given by the debug output.

# cat /etc/puppet/manifests/zpool_raidz2.pp
zpool { 'tank':
  ensure  => present,
  raidz   => [ 'd01 d02 d03 d04', 'd05 d06 d07 d08' ],
  raid_parity => 'raidz2',
  pool=> 'tank',
  log_mirror  => 'd09 d10',
  force   => true,
}

I've put the full trace/debug in pastebin [1].

You'll have to excuse the extra debug lines, as I'm trying to do a few 
things.

* Add logged mirror support
* Figure out and fix the inability to create striped RAIDZ sets
* Add property for cache devices

The main error is this...

Error: /Stage[main]//Zpool[tank]/ensure: change from absent to present 
failed: Execution of '/sbin/zpool create -f tank raidz2 d01 d02 d03 d04 
raidz2 d05 d06 d07 d08 log mirror d09 d10' returned 1: cannot open 'd01 d02 
d03 d04': no such device in /dev
must be a full path or shorthand device name

However if I run that exact command, I receive no error.

# /sbin/zpool create -f tank raidz2 d01 d02 d03 d04 raidz2 d05 d06 d07 d08 
log mirror d09 d10
# echo $?
0
# zpool status
  pool: tank
 state: ONLINE
  scan: none requested
config:

NAMESTATE READ WRITE CKSUM
tankONLINE   0 0 0
  raidz2-0  ONLINE   0 0 0
d01 ONLINE   0 0 0
d02 ONLINE   0 0 0
d03 ONLINE   0 0 0
d04 ONLINE   0 0 0
  raidz2-1  ONLINE   0 0 0
d05 ONLINE   0 0 0
d06 ONLINE   0 0 0
d07 ONLINE   0 0 0
d08 ONLINE   0 0 0
logs
  mirror-2  ONLINE   0 0 0
d09 ONLINE   0 0 0
d10 ONLINE   0 0 0

errors: No known data errors

This is being done in a Vagrant VM as part of my puppet-zfsonlinux module , 
which I've uploaded to github [2].  I don't have much experience in custom 
types and providers so am unsure where to begin on debugging the errors 
when I can't reproduce them via command line.

[1] - http://pastebin.com/Lcy6feyt
[2] 
- https://github.com/treydock/puppet-zfsonlinux/tree/development_zpool_type

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




[Puppet Users] PuppetDB Architecture Questions

2013-05-24 Thread Worker Bee
Hi Everyone;

I am having a bit of challenge understanding the PuppetDB 1.3
Architecture.  When I  installed using the packages in the puppet repo, it
was difficult for me to determine where the postgres database was installed
but, I found that it was installed in /var/lib/puppetdb.

I am a serious newbie to PuppetDb so, please excuse my questions of they
are dumb but, any assistance you are willing to provide will be greatly
appreciated.

1.) Why is pgsql not running on my server even though puppetdb is running?
How is the database being served?
2.)Is it possible to interact with the database via pqsql?

Thanks so much for your time!
Bee

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




Re: [Puppet Users] PuppetDB

2013-05-24 Thread Worker Bee
Thanks!

Sorry for the blackout there I just found it!  That was too easy! :)
Worked perfectly!

Thank you!
Bee


On Fri, May 24, 2013 at 5:36 PM, Ashley Penney  wrote:

> You definitely still need postgres!  If you grab
> http://forge.puppetlabs.com/puppetlabs/puppetdb instead of installing it
> manually, it will help you get postgres and all the other dependencies you
> need installed.
>
>
> On Fri, May 24, 2013 at 5:33 PM, Worker Bee  wrote:
>
>> Hi Everyone;
>>
>> I am sorry to be a pest but, I am very confused here.  I just installed
>> the latest PuppetDB from the repo packages.  However, it does not appear
>> that postgres is installed. I am really lost here... is postgres no longer
>> required?
>>
>> Thanks! Bee
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Puppet Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to puppet-users+unsubscr...@googlegroups.com.
>> To post to this group, send email to puppet-users@googlegroups.com.
>> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: [Puppet Users] PuppetDB

2013-05-24 Thread Ashley Penney
You definitely still need postgres!  If you grab
http://forge.puppetlabs.com/puppetlabs/puppetdb instead of installing it
manually, it will help you get postgres and all the other dependencies you
need installed.


On Fri, May 24, 2013 at 5:33 PM, Worker Bee  wrote:

> Hi Everyone;
>
> I am sorry to be a pest but, I am very confused here.  I just installed
> the latest PuppetDB from the repo packages.  However, it does not appear
> that postgres is installed. I am really lost here... is postgres no longer
> required?
>
> Thanks! Bee
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




[Puppet Users] PuppetDB

2013-05-24 Thread Worker Bee
Hi Everyone;

I am sorry to be a pest but, I am very confused here.  I just installed the
latest PuppetDB from the repo packages.  However, it does not appear that
postgres is installed. I am really lost here... is postgres no longer
required?

Thanks! Bee

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




Re: [Puppet Users] apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Eric Sorenson
On May 24, 2013, at 1:53 AM, Greg Sutcliffe  wrote:

> I've hit this, but it's because I have the main Puppetlabs repo in my preseed 
> file for new virtual machines, so it's available within the installer 
> environment. That's just text, so I only have a line for "deb 
> http://apt.puppetlabs.com  main"
> 
> I think the "install a deb which sets up the repos" is good for most people, 
> but there should always be the docs for the manual apt setup for those going 
> a different route. As of right now, I don't see a "dependencies" repo 
> mentioned anywhere on the page you linked, Eric
> 
> I'll also add a voice the question on the logic behind a separate 
> dependencies repo, although only because you're adding work to your 
> documentation requirements ;)
> 

Hi Greg, thanks for the info -- I slightly disagree that the docs should 
describe manual installation; IMO they should describe supported/official ways 
to do things, because anything that's documented gets interpreted as being 
supported and official :)

That said, we could punch up the importance of including the deps repository. 
It's been necessary for EL users for a long time, but this was the first Puppet 
release that pulled in a hard dependency for Debian-based systems.

There's an administrative reason and a technical reason for the dependencies 
repo:
1. administratively, it indicates which packages are derived from 
puppetlabs-owned repos vs upstream projects
2. technically, those packages can be provided by other sources so the separate 
repo keeps them from cross-polluting your system.

As an extreme but real-world example the EL5 dependencies repo contains an 
updated Ruby package, and it'd be surprising/dangerous to update Ruby on 
everyone's system when they thought they were just getting Puppet.

We'll do a better job in the future of 
(a) pointing out the necessity of the dependencies repo in the release notes
(b) featuring the Upgrading guide ( 
http://docs.puppetlabs.com/guides/upgrading.html ) more prominently, as it has 
best practice for safe upgrading 

(PS I'll note for the record, that page says: "We highly recommend avoiding 
unintentional upgrades." and goes into detail about how to do that.)

Eric Sorenson - eric.soren...@puppetlabs.com
#puppet irc: eric0 

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




Re: [Puppet Users] Re: Puppet 3.0: Not authorized to call find on /file_metadata, more issues?

2013-05-24 Thread Josh Cooper
On Wed, May 22, 2013 at 12:39 AM, Russell Maclean <
hyperthinker1...@gmail.com> wrote:

> Thank you for clearing this up.
> What I am not understanding is why this fails. If anyone could help me
> figure this out would be greatly appreciated.
>
> [files]
> path /etc/puppet/files
> allow_ip 10.0.0.0/8
>
>
The allow_ip directive is not allowed in fileserver.conf, only auth.conf


> But this works,
>
>
> [files]
> path /etc/puppet/files
> allow *
>
>
See http://docs.puppetlabs.com/guides/file_serving.html#ip-addresses for
more information.


> It resulted in much hair loss.
>
> On Tuesday, October 23, 2012 9:55:16 AM UTC+11, Nick Fagerlund wrote:
>>
>> Hi everybody,
>>
>> This is a bug, and we're working on it. I'm about to update the auth.conf
>> docs with info about allow_ip. Additionally, have a complete workaround for
>> anyone being affected by this today. This offers complete equivalence to
>> the fileserver.conf behavior that worked in 2.x and broke in 3.0.0.
>>
>> **In fileserver.conf:**
>>
>> Put the name of your mount point, the path, and an `allow *` directive.
>>
>> [files]
>>   path /etc/puppet/files
>>   allow *
>>
>> **In auth.conf:**
>>
>> Use a regular expression path to match both the `file_metadata` and
>> `file_content` endpoints followed by the name of your custom mount point.
>> Then, use any combination of `allow` and `allow_ip` directives to control
>> access.
>>
>> path ~ ^/file_(metadata|content)/**files/
>> auth yes
>> allow /^(.+\.)?example.com$/
>> allow_ip 192.168.100.0/24
>>
>> **Effect:**
>>
>> This fully re-implements the previous behavior of the following
>> fileserver.conf:
>>
>> [files]
>>   path /etc/puppet/files
>>   allow *.example.com
>>   allow 192.168.100.0/24
>>
>> It does this by:
>>
>> * Allowing any request to fulfill fileserver.conf's requirements...
>> * ...but using auth.conf to ensure that only authorized requests ever
>> reach fileserver.conf.
>>
>> This pattern will be forward-compatible with whatever permanent fix we
>> implement for this bug. It's not very attractive, but it works.
>>
>  --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users+unsubscr...@googlegroups.com.
>
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>



-- 
Josh Cooper
Developer, Puppet Labs

*Join us at PuppetConf 2013, August 22-23 in San Francisco - *
http://bit.ly/pupconf13*
**Register now and take advantage of the Early Bird discount - save 25%!*

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




[Puppet Users] Apache Passenger: Action 'configtest' failed

2013-05-24 Thread valentino
I am running apache for the first time and get this error.

puppet@puppetmastervm:/etc/apache2/mods-available$ sudo service apache2 
restart[sudo] password for puppet: 
Syntax error on line 3 of /etc/apache2/sites-enabled/puppetmaster:
Invalid command 'PassengerHighPerformance', perhaps misspelled or defined 
by a module not included in the server configuration
Action 'configtest' failed.
The Apache error log may have more information.
   ...fail!

My mac client is giving me these error.

http://pastebin.com/cs83riQr

Your help is greatly appreciated.

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




[Puppet Users] Apache Passenger Fail

2013-05-24 Thread valentino
I just setup my puppetmaster with passenger and I get the following error. 
Any help would be appreciated. I'm on Ubuntu 13.04

puppet@puppetmastervm:/etc/apache2/mods-available$ sudo service apache2 
restart[sudo] password for puppet: 
Syntax error on line 3 of /etc/apache2/sites-enabled/puppetmaster:
Invalid command 'PassengerHighPerformance', perhaps misspelled or defined 
by a module not included in the server configuration
Action 'configtest' failed.
The Apache error log may have more information.
   ...fail!

My Mac client is giving me this error when I run the checkin

http://pastebin.com/cs83riQr

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




[Puppet Users] Re: accessing one master via multiple hostnames (internal & external)

2013-05-24 Thread jcbollinger


On Thursday, May 23, 2013 6:01:14 AM UTC-5, Ernest Beinrohr wrote:
>
> Hi, I currently use one puppetmaster for my external and internal servers. 
> For the externals however I have to modify my /etc/hosts for puppet to 
> work. 
>
> Is it possible to use a different hostname for my master without the 
> agents complaining?
>


Yes.  You need to generate a certificate for the server that includes the 
external DNS name as an alternative name (supposing that its sense of its 
own hostname is the internal name).  See here 
http://serverfault.com/questions/320028/how-to-add-multiple-dns-names-to-my-puppetmaster
 
for a fuller description.

Note that that answer claims you can replace the master's certificate (but 
not the CA certificate) without interfering with clients that have already 
been issued certs.  That's plausible -- indeed, it should be the case -- 
but I cannot personally confirm it.


John

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




Re: [Puppet Users] Re: apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Matthaus Owens
Maik, there was an update via the puppetlabs-release package to update
the sources.list file to add the dependencies repo.

2013/5/24 Maik Kulbe :
> I can confirm this too and think the way of installing this via a .deb is
> not very nice to admins with more then 10 servers. Why do I need to install
> a package for installing some sources.list.d file when I want it all
> automated. Automation has to do a lot with simplification IMHO, because the
> simpler something is the less likely it will fail. If you want to build a
> robust mechanism of fast deployment a .deb is just really ugly and awkward
> to handle.
>
> Also I really don't understand why this changed in a way you coudn't upgrade
> anymore. There should have been an update via the repo to at least update
> the sources.list file or create a new one for the dependencies..
>
> I'm also in with the other guys here - I really don't get why you would need
> a second repository for the dependencies.
>
>
> On Thursday, May 23, 2013 5:26:40 PM UTC+2, ma...@marco-scholl.de wrote:
>>
>> i can confirm this
>>
>> ruby-rgen is not found.
>>
>> greets
>>
>> ---
>>
>> Paketlisten werden gelesen... Fertig
>> Abhängigkeitsbaum wird aufgebaut
>> Statusinformationen werden eingelesen... Fertig
>> Einige Pakete konnten nicht installiert werden. Das kann bedeuten, dass
>> Sie eine unmögliche Situation angefordert haben oder, wenn Sie die
>> Unstable-Distribution verwenden, dass einige erforderliche Pakete noch
>> nicht erstellt wurden oder Incoming noch nicht verlassen haben.
>> Die folgenden Informationen helfen Ihnen vielleicht, die Situation zu
>> lösen:
>>
>> Die folgenden Pakete haben unerfüllte Abhängigkeiten:
>>  puppet : Hängt ab von: puppet-common (= 3.2.1-1puppetlabs1) soll aber
>> nicht installiert werden
>> E: Probleme können nicht korrigiert werden, Sie haben zurückgehaltene
>> defekte Pakete.
>> $ sudo apt-get install puppet-common
>> Paketlisten werden gelesen... Fertig
>> Abhängigkeitsbaum wird aufgebaut
>> Statusinformationen werden eingelesen... Fertig
>> Einige Pakete konnten nicht installiert werden. Das kann bedeuten, dass
>> Sie eine unmögliche Situation angefordert haben oder, wenn Sie die
>> Unstable-Distribution verwenden, dass einige erforderliche Pakete noch
>> nicht erstellt wurden oder Incoming noch nicht verlassen haben.
>> Die folgenden Informationen helfen Ihnen vielleicht, die Situation zu
>> lösen:
>>
>> Die folgenden Pakete haben unerfüllte Abhängigkeiten:
>>  puppet-common : Hängt ab von: ruby-rgen ist aber nicht installierbar
>>  Empfiehlt: debconf-utils soll aber nicht installiert
>> werden
>> E: Probleme können nicht korrigiert werden, Sie haben zurückgehaltene
>> defekte Pakete.
>>
>>
>>
>>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>



-- 
Matthaus Owens
Release Manager, Puppet Labs

Join us at PuppetConf 2013, August 22-23 in San Francisco -
http://bit.ly/pupconf13
Register now and take advantage of the Early Bird discount - save 25%!

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




Re: [Puppet Users] Re: apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Matthaus Owens
Peter,
hiera-puppet is built in to puppet 3.x, so you don't need to install
it explicitly.

On Fri, May 24, 2013 at 4:56 AM, Peter  wrote:
> Eric,
>
> Damn forgot to cut message down and include the error messages.
>
> Essentially when I try to install puppet-hiera I get this error message:
>
> root@play apt/sources.list.d# apt-get install hiera-puppet
> Reading package lists... Done
> Building dependency tree
> Reading state information... Done
> Some packages could not be installed. This may mean that you have
> requested an impossible situation or if you are using the unstable
> distribution that some required packages have not yet been created
> or been moved out of Incoming.
> The following information may help to resolve the situation:
>
> The following packages have unmet dependencies:
>  hiera-puppet : Depends: puppet but it is not going to be installed
> E: Unable to correct problems, you have held broken packages.
>
>
> However puppet is already installed:
>
> root@play apt/sources.list.d# dpkg --status puppet
> Package: puppet
> Status: install ok installed
> Priority: optional
> Section: admin
> Installed-Size: 134
> Maintainer: Puppet Labs <>
> Architecture: all
> Version: 3.1.1-1puppetlabs1
> Depends: puppet-common (= 3.1.1-1puppetlabs1), ruby | ruby-interpreter
> Recommends: rdoc
> Suggests: puppet-el, vim-puppet
>
>
> Peter
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>



-- 
Matthaus Owens
Release Manager, Puppet Labs

Join us at PuppetConf 2013, August 22-23 in San Francisco -
http://bit.ly/pupconf13
Register now and take advantage of the Early Bird discount - save 25%!

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




[Puppet Users] Re: Suppress deprecation warnings because of Referencing Variables

2013-05-24 Thread Christopher Rutter
I am in the same boat here. For example there are a few puppetlabs modules 
that currently don't have a stable release that fixes this:

   - https://github.com/puppetlabs/puppetlabs-mysql - tag 0.6.1  (pull 
   request )
   - https://github.com/puppetlabs/puppetlabs-apache - tag 0.6.0 (fixed in 
   master branch)
   - https://github.com/puppetlabs/puppetlabs-apt - tag 1.1.0 (pull 
request
   )

And this isn't even all of them, only the ones that I use...
Sure this issue is addressed in the master branch of these modules (or 
pending pull requests, that I just submitted today) but I don't feel 
comfortable running 'master' in production.

Heck, even the documentation 
("iteration" 
section and below)  breaks down halfway down the page and stops using the 
'@'.
I feel like this new "warning" might have been a bit premature, then again, 
I suppose this will force people to fix the problem. 
-Chris


On Friday, May 24, 2013 12:09:51 AM UTC-4, Nam Nguyen wrote:
>
> Hey guys, 
> after upgrading Puppet to version 3.2.1 I got lots of warning like this: 
>
> Warning: Variable access via 'logroot' is deprecated. Use '@logroot' 
> instead. 
> template[/etc/puppet/modules/apache/templates/vhost-default.conf.erb]:24
>
> I used puppet many modules which don't use @ or $ in front of reference 
> variables, so I will be a pain to fix them all. 
> Is there any way I can suppress (hide | disable) these warnings?
>
> NN.
>
>

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




[Puppet Users] ossec integration

2013-05-24 Thread Björn
Hello,

I recently found this great sample in the wiki to integrate ossec. 

http://projects.puppetlabs.com/projects/1/wiki/OSSEC-HIDS_Patterns

Once you installed openssl-devel on your ossec server while installation, 
the ossec-authd is compilied too and you are able to add clients to  ossec 
server remotely.
Therefore I changed the sample of ossec intergrated with these lines:

exec { "client.keys":
  command => "/var/ossec/bin/agent-auth -m 10.1.2.3  -A $::fqdn -D 
/var/ossec/",
  creates => "/var/ossec/etc/client.keys",
}

In addition the service "ossec" object isn't working for me, because the 
init-script status return always 0. I'm new at puppet and would like to ask 
if I did fine:

service { "ossec":
  enable => true,
  ensure => running,
  hasrestart => true,
  hasstatus  => true,
  status => '/etc/init.d/ossec | grep "ossec-agentd is 
running"',
}


Thanks!

Björn

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




[Puppet Users] Re: Problems installing git for windows using Puppet

2013-05-24 Thread Kevin D
Louis,

Unfortunately, the way that Git for Windows is packaged, it doesn't update 
the registry (HKLM\Software\Microsoft\Windows\CurrentVersion\Uninstall) or 
touch the Windows Installer Database (and update the WMI Win32_Product).  
As a result, no matter how you perform the installation (using either the 
"exec" or "package" types), each subsequent Puppet run will invoke a 
reinstall/repair of the product (and most likely this will be undesirable 
behavior). 
Reference
.

Therefore, you will need to create a method to determine if it is 
installed.  One way of doing this is to write a check file after install.

I tested your manifest on a Windows 2008 R2 SP1 box and it was successful 
(I didn't get a timeout).  You may want to use Microsoft's Process Monitor 
to determine the "command line" call to the exe. 

exec:
file {$pkg:
  ensure => present,
  name   => 'C:\Temp\Git-1.8.1.2-preview20130201.exe',
  #source => 'puppet:///puppetfs/Git-1.8.1.2-preview20130201.exe',
  source => "x:\\Git-1.8.1.2-preview20130201.exe",
  mode   => '0755',
  before => Exec[$pkg],
}

exec {$pkg:
  creates   => 'C:\Program Files (x86)\Git\bin',
  command   => 'C:\Windows\sysnative\cmd.exe /c 
"C:\Temp\Git-1.8.1.2-preview20130201.exe /silent"',
  logoutput => true,
  timeout   => 900,
}

package:
file {$pkg:
  ensure => present,
  name   => 'C:\Temp\Git-1.8.1.2-preview20130201.exe',
  #source => 'puppet:///puppetfs/Git-1.8.1.2-preview20130201.exe',
  source => "x:\\Git-1.8.1.2-preview20130201.exe",
  mode   => '0755',
  before => Package[$pkg],
}

package {$pkg:
  ensure => installed,
  source =>'C:/Temp/Git-1.8.1.2-preview20130201.exe',
  install_options => '/silent',
}

-Kevin

On Thursday, May 23, 2013 8:52:21 AM UTC-6, Louis wrote:
>
> This might not be related to Puppet but it seems that the installation 
> process hangs. I have tried this configuration on an empty w2008r2 VM.
>
> file { $pkg:
>   ensure => present,
>   name   => 'C:\Temp\Git-1.8.1.2-preview20130201.exe',
>   source => 'puppet:///puppetfs/Git-1.8.1.2-preview20130201.exe',
>   mode   => '0755',
>   before => Exec[$pkg]}
> exec { $pkg:
>   creates   => 'C:\Program Files (x86)\Git\bin',
>   command   => 'C:\Windows\sysnative\cmd.exe /c 
> "C:\Temp\Git-1.8.1.2-preview20130201.exe /silent"',
>   logoutput => true,
>   timeout   => 900}
>
>

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




Re: [Puppet Users] Announce: Puppet 3.2.1 Available

2013-05-24 Thread Andreas Ntaflos

On 24/05/13 11:43, Paul Tötterman wrote:

Did something change in the way Puppet outputs messages? Until this

morning we used the following to run Puppet from Cron on all our nodes:

But as of 3.2.1 this produces output on every Puppet agent run and that
output is mailed out, resulting in hundreds of messages which contain
nothing of importance (see below). This had worked fine for almost two
years now, with output only generated on errors and problems (such as
DNS not available).


I'm having the same issue. I couldn't find a bug report about this.
There is --verbose and --debug, but not --silent or --quiet. Should we
maybe use --logdest? Anyway the behaviour has changed from 3.1.1


We have always been using "--logdest syslog", it is only with 3.2.1 that 
log messages now seem to go not only to syslog but also to stdout, which 
is why Cron generates annoying mail messages.


Even more interesting: before 3.2.1 /var/log/syslog would only show the 
"finished catalog run" message when running Puppet from Cron with 
"puppet agent -o --no-daemonize --logdest syslog":


May 21 09:30:01 node01 CRON[14018]: (root) CMD (/usr/bin/puppet agent 
--onetime --no-daemonize --logdest syslog)

May 21 09:30:38 node01 crontab[15379]: (root) LIST (root)
May 21 09:30:38 node01 puppet-agent[14019]: Finished catalog run in 
17.33 seconds


Now it shows everything in /var/log/syslog:

May 24 07:15:01 node01 CRON[23182]: (root) CMD (/usr/bin/puppet agent 
--onetime --no-daemonize --logdest syslog > /dev/null 2>&1)

May 24 07:15:02 node01 puppet-agent[23183]: Retrieving plugin
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/postgres_default_version.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/corosync_mcastaddr.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/pe_version.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/concat_basedir.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/root_home.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/lvm_disk_usage.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/corosync_mcastport.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/libvirt_guests.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/libvirt_used_memory.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/puppet_vardir.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/has_libvirtd.rb
May 24 07:15:03 node01 puppet-agent[23183]: Loading facts in 
/var/lib/puppet/lib/facter/has_group_libvirtd.rb
May 24 07:15:22 node01 puppet-agent[23183]: Caching catalog for 
dbb01.db01.prod.rz01.riseops.at
May 24 07:15:24 node01 puppet-agent[23183]: Applying configuration 
version '1369362429'

May 24 07:15:43 node01 crontab[24545]: (root) LIST (root)
May 24 07:15:43 node01 puppet-agent[23183]: Finished catalog run in 
20.11 seconds


So, I am asking the Puppet devs: is this behaviour intended or a bug? 
Should I open a bug report?


Andreas

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




[Puppet Users] Re: manifest for fusioninventory-agent

2013-05-24 Thread Stan
thanks a lot

i change my manifest with hasstatus false and it's ok!!! 

service { 'fusioninventory-agent':
ensure => running,
hasstatus => false,
hasrestart => false,
enable => true,
require => 
File['/etc/sysconfig/fusioninventory-agent']
}
}


Le jeudi 23 mai 2013 16:32:59 UTC+2, Stan a écrit :
>
> Hi
>
> I create a manifest for fusioninventory-agent on my puppet server
>
> On my puppet client if i modify file /etc/sysconfig/fusioninventory-agent 
> the file fusioninventory-agent replace by puppet server configuration (this 
> is OK)
>
> But if i stop fusioninventory-agent on my puppet client, puppet server not 
> start the service and i don't know why
>
> If you see an error in my configuration, say me
>
> regards
>
>
> class fusioninventory-agent::redhat {
>
> package { 'fusioninventory-agent':
>  ensure => present,
> }
>
> file { '/etc/sysconfig/fusioninventory-agent':
> ensure => present,
> owner => 'root',
> group => 'root',
> mode => 0644,
> content => 
> template("/etc/puppet/modules/fusioninventory-agent/templates/fusioninventory-agent.erb"),
> require => Package["fusioninventory-agent"],
> notify => Service["fusioninventory-agent"]
> }
>
>
> service { 'fusioninventory-agent':
> ensure => running,
> hasstatus => true,
> hasrestart => true,
> enable => true,
> require => 
> File['/etc/sysconfig/fusioninventory-agent']
> }
> }
>

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




[Puppet Users] Re: Suppress deprecation warnings because of Referencing Variables

2013-05-24 Thread Nam Nguyen
John, thanks so much for your notice, yes I thought about this too, and, 
now I think I should spend sometime fixing them rather than suppressing. At 
first I was frustrated because of so many warning, but now I got it, I dont 
think I should stop at version < 3.2. 

NN

On Friday, May 24, 2013 9:10:53 PM UTC+7, jcbollinger wrote:
>
>
>
> On Thursday, May 23, 2013 11:09:51 PM UTC-5, Nam Nguyen wrote:
>>
>> Hey guys, 
>> after upgrading Puppet to version 3.2.1 I got lots of warning like this: 
>>
>> Warning: Variable access via 'logroot' is deprecated. Use '@logroot' 
>> instead. 
>> template[/etc/puppet/modules/apache/templates/vhost-default.conf.erb]:24
>>
>> I used puppet many modules which don't use @ or $ in front of reference 
>> variables, so I will be a pain to fix them all. 
>> Is there any way I can suppress (hide | disable) these warnings?
>>
>>
> I don't know about suppressing the warnings, but unless you intend to stop 
> at Puppet 3.2, you really ought to fix them.  Deprecation is a prelude to 
> feature removal, so you can expect that your templates will no longer work 
> with some future version of Puppet.  You can put off changes until then if 
> you want, but I'd recommend that you do the work now.  That will help you 
> avoid making more future work for yourself, by causing new uses of the 
> deprecated style to stand out.
>
>
> John
>
>

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




Re: [Puppet Users] Puppet/Nagios/PuppetDB slow performance

2013-05-24 Thread Ken Barber
Its probably the nagios resource, its well known for not scaling when
the files contain a lot of entries. That would explain why your
PuppetDB is showing low load - as its probably not the bottleneck.

The most performant work-around I've seen for this is that you can use
the nagios_* resources to export, but then use custom collectors that
query PuppetDB (using Dalen's puppetdbquery for example:
https://github.com/dalen/puppet-puppetdbquery) that generates custom
templates for your nagios_*.cfg files. If nagios_service.cfg is the
main bottleneck, you can focus on this one to start with.

This way you continue to use the model of the nagios_* resources, but
at collection time you improve performance.

ken.

On Fri, May 24, 2013 at 1:53 PM, Jonathan Gazeley
 wrote:
> Hi all,
>
> For months now I've been using Puppet with PuppetDB backend to manage my
> Nagios configs. We now have 1200+ services being checked and including
> servicedependency, host, hostdependency, command and other Nagios resources
> being managed, that's about 3000 resources in total. Unfortunately this
> means the monitoring server takes about 8 minutes to perform a Puppet run.
>
> I'm not exactly sure what the bottleneck is - whether it's doing 3000 calls
> to PuppetDB (although the load on the PuppetDB server and its Postgres
> database are low), or whether it is parsing nagios_service.cfg that causes
> the slowdown. It's about 500kb and 11,000 lines.
>
> I know it is possible to squirt the Nagios config into several smaller files
> when the resources are collected on the monitoring server, but I gather this
> also means that Nagios resources cannot be purged if the default file
> locations are not used. The ability to purge old configs automatically is
> essential to our environment.
>
> So does anyone have any suggestions on how to improve the performance of
> Puppet when handling large Nagios configs?
>
> Cheers,
> Jonathan
>
> --
> You received this message because you are subscribed to the Google Groups
> "Puppet Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

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




[Puppet Users] Re: Exec question: variable expansion to set gconf string

2013-05-24 Thread Kodiak Firesmith
D'oh!

I figured out how to just get it to cat /etc/issue which wins since I'll 
only have to manage the banner in one place.

# Turn on and enforce the contents of the GDM legal banner.
  exec { 'gconftool-2 --set --type=string 
/apps/gdm/simple-greeter/banner_message_text "$(cat /etc/issue)"':
cwd => '/var/lib/puppet',
path=> ['/bin', '/usr/bin', '/sbin', '/usr/sbin'],
unless  => 'gconftool-2 --get 
/apps/gdm/simple-greeter/banner_message_text | grep MYCOMPANY',
user=> 'gdm'
  }

  exec { 'gconftool-2 --set --type=boolean 
/apps/gdm/simple-greeter/banner_message_enable true':
cwd => '/var/lib/puppet',
path=> ['/bin', '/usr/bin', '/sbin', '/usr/sbin'],
unless  => 'gconftool-2 --get 
/apps/gdm/simple-greeter/banner_message_enable | grep true',
user=> 'gdm'
  }



On Friday, May 24, 2013 7:49:53 AM UTC-4, Kodiak Firesmith wrote:
>
> Hi Everybody,
>
> So I'm working on a workstation_policies module that will basically set a 
> ton of gconf keys.
>
> I think I have everything figured out except for a clean way to throw a 
> long legal banner into an exec for gconf.
>
> This should give an idea of what I thought would work per my 
> interpretation of the exec resource type docs:
> (Using single quotes in variable to preserve line breaks, using double 
> quotes in the exec so that the variable is interpreted, etc)
>
> class workstation_policies() {
>
>   $legal_banner = 
> '==
>
> THIS SYSTEM IS OPERATED FOR AUTHORIZED USERS ONLY
>
> Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod 
> tempor incididunt 
> ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud 
> exercitation ullamco 
> laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in 
> reprehenderit in 
> voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur 
> sint occaecat cupidatat 
> non proident, sunt in culpa qui officia deserunt mollit anim id est 
> laborum.
>
> =='
>
> # Turn on and enforce the contents of the GDM legal banner.
>   exec { 'gconftool-2 --set --type=boolean 
> /apps/gdm/simple-greeter/banner_message_enable true':
> cwd => '/var/lib/puppet',
> path=> ['/bin', '/usr/bin', '/sbin', '/usr/sbin'],
> unless  => 'gconftool-2 --get 
> /apps/gdm/simple-greeter/banner_message_enable | grep true',
> user=> 'gdm'
>   }
>
>
>   exec { "gconftool-2 --set --type=string 
> /apps/gdm/simple-greeter/banner_message_text "$legal_banner"":
> cwd => '/var/lib/puppet',
> path=> ['/usr/bin'],
> unless  => 'gconftool-2 --get 
> /apps/gdm/simple-greeter/banner_message_text | grep AUTHORIZED',
> user=> 'gdm'
>   }
>
>
> As it is now, I'll get a catalog compilation error like the one below:
>
> Error: Could not retrieve catalog from remote server: Error 400 on SERVER: 
> Syntax error at 'legal_banner'; expected '}' at 
> /etc/puppet/modules/beta/workstation_policies/manifests/init.pp:65 on node 
> foo
>
>

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




[Puppet Users] Re: Execution order of classes

2013-05-24 Thread jcbollinger


On Friday, May 24, 2013 5:12:33 AM UTC-5, Markus Shorty Uckelmann wrote:
>
> Hi all, 
>
> I'm stuck in the hell of class dependencies and hope that someone here 
> can help me. 
>
> Puppet-Version is 2.7.21 
> It's the Debian Squeeze package from the Puppetlabs Repo. 
>
> I want one class to manage everything database related. So I call it in 
> "site.pp" like this: 
>
>   node client1 { 
> class { 'database': } 
>   } 
>
> It's parameterized and uses default values. The class "database" 
> declares(executes) other classes. 
>
> Now to my problem. I have a "sub"-class "database::packages" which must 
> be executed before every other stuff inside the database class. Here is 
> the code: 
>
> 1 class database { 
> 2   class { 'database::packages': } -> 
> 3   # setup data dirs 
> 4   class { 'database::directories': 
> 5 # require => Class['database::packages'], 
> 6   } 
> 7   # Class['database::packages'] -> Class['database::directories'] 
> 8 } 
>
> I tried three different things. None of them worked. First one is the 
> chaining arrow in line 2. The next two tries I left commented out. In 
> line 5 I tried to require the "packages" class inside the "directories" 
> class declaration. And last in line 7 I tried the chaining again. 
>
> Whenever I run this code on a client, the "directories" class gets 
> executed first



As judged how?

 

> and fails, because it needs a specific user which is 
> setup in the "packages" class. 
>
>
 
All of the methods you tried for declaring the needed relationship are 
valid and appear correct.  I conclude that you have diagnosed the problem 
incorrectly.

To be sure, you do have an order-of-application issue, but I don't think 
it's the relative order of these classes themselves that is the problem.  
It is more likely a containment issue within one or more of those classes' 
implementations.  I suggest you read the documentation on that area 
(http://docs.puppetlabs.com/puppet/3/reference/lang_containment.html) for 
information on that problem and and least one possible solution.


John

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




[Puppet Users] Re: Suppress deprecation warnings because of Referencing Variables

2013-05-24 Thread jcbollinger


On Thursday, May 23, 2013 11:09:51 PM UTC-5, Nam Nguyen wrote:
>
> Hey guys, 
> after upgrading Puppet to version 3.2.1 I got lots of warning like this: 
>
> Warning: Variable access via 'logroot' is deprecated. Use '@logroot' 
> instead. 
> template[/etc/puppet/modules/apache/templates/vhost-default.conf.erb]:24
>
> I used puppet many modules which don't use @ or $ in front of reference 
> variables, so I will be a pain to fix them all. 
> Is there any way I can suppress (hide | disable) these warnings?
>
>
I don't know about suppressing the warnings, but unless you intend to stop 
at Puppet 3.2, you really ought to fix them.  Deprecation is a prelude to 
feature removal, so you can expect that your templates will no longer work 
with some future version of Puppet.  You can put off changes until then if 
you want, but I'd recommend that you do the work now.  That will help you 
avoid making more future work for yourself, by causing new uses of the 
deprecated style to stand out.


John

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




[Puppet Users] Re: Example of a working runinterval + splay configuration?

2013-05-24 Thread Michael O'Dea
Oops nevermind.  The host I sampled in the logs still was running the 
2.7.18 Puppet client.  I re-checked a host running 3.1.1 and it does appear 
to be varying it's runs somewhat.  Need to retire all those puppet 2.7 
hosts!

On Friday, May 24, 2013 9:47:49 AM UTC-4, Michael O'Dea wrote:
>
> I have a substantial number of Windows hosts running puppet 3.1.1 with the 
> following in their puppet.conf:
>
> runinterval = 1800
>> splay = true
>> splaylimit = 900
>
>
> However in checking puppet logs, I'm finding that these hosts are dialing 
> in at 30 minute intervals +/- 5-10 seconds.  Can someone provide me an 
> example puppet.conf that is properly implementing the splay feature on a 
> similar environment (windows, Puppet 3.1.1)?
>
> Thanks in advance.  I've searched quite a bit on this and not found 
> anything that completely explains how to make use of splay to ensure agents 
> don't all dial in at the same time.  I sometimes launch 20+ systems at a 
> time, and staggering the launch is not an option -- I need to figure out 
> how to get Puppet to vary the dial in.  When 100 hosts all dial in at the 
> same time, it absolutely crushes the masters.  
>
>

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




[Puppet Users] Re: Execution order of classes in a node

2013-05-24 Thread jcbollinger


On Thursday, May 23, 2013 1:45:55 PM UTC-5, Bikram Agarwal wrote:
>
> Hi.
>
> I have three modules in my puppet/modules - 
>
>1. jdk_installer
>2. weblogic_installer
>3. wldomain_create
>
> Each of them have one class (same names as modules).
>
> I have a node in site.pp which calls these 3 classes. And these classes 
> need to be executed in a particular order. This is what I have in site.pp - 
>
> node "devdomain.org"{
> $config = hiera('domaincreation')
> class{'jdk_installer':
>  }
> class{'weblogic_installer':
>require => Class["jdk_installer"],
> }
> class{'wldomain_create':
>require => Class["weblogic_installer"],
> }
> }
>
> Execution order that I am trying to implement is first - jdk_installer 
> followed by weblogic_installer and ending at wldomain_create.
>
> When I run the puppet agent --verbose --test from the agent node, in the 
> output it even looks like it is executing in the correct order. But towards 
> the end, when it is running the wldomain_create class, it errors out saying 
> the domain is already created; as if this class was already ran. Here's the 
> last part of the output - 
>
> notice: /Stage[main]/Weblogic_installer/Exec[Delete Existing jar]/returns: 
> executed successfully
> notice: /Stage[main]/Weblogic_installer/File[Copy_weblogic_jar]/ensure: 
> defined content as '{md5}33d45745ff0510381de84427a7536f65'
> notice: /Stage[main]/Weblogic_installer/File[Copy_silent_xml]/ensure: 
> defined content as '{md5}e71e523800541d4cfa6d60a1da0f4e2a'
> notice: /Stage[main]/Weblogic_installer/Exec[install_wls]/returns: 
> Extracting 
> 0%100%
> notice: /Stage[main]/Weblogic_installer/Exec[install_wls]/returns: 
> executed successfully
> notice: /Stage[main]/Wldomain_create/File[Copy domaincreate 
> script]/ensure: defined content as '{md5}9eb3f3645f8fb3be20af4f64116a9861'
> info: /Stage[main]/Wldomain_create/File[Copy domaincreate script]: 
> Scheduling refresh of Exec[Execute domain create script]
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns:
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: 
> CLASSPATH=/opt/oracle/middleware/patch_wls1036/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/oracle/jdk/lib/tools.jar:/opt/oracle/middleware/wlserver_10.3/server/lib/weblogic_sp.jar:/opt/oracle/middleware/wlserver_10.3/server/lib/weblogic.jar:/opt/oracle/middleware/modules/features/weblogic.server.modules_10.3.6.0.jar:/opt/oracle/middleware/wlserver_10.3/server/lib/webservices.jar:/opt/oracle/middleware/modules/org.apache.ant_1.7.1/lib/ant-all.jar:/opt/oracle/middleware/modules/net.sf.antcontrib_1.1.0.0_1-0b2/lib/ant-contrib.jar::/opt/oracle/middleware/utils/config/10.3/config-launch.jar::/opt/oracle/middleware/wlserver_10.3/common/derby/lib/derbynet.jar:/opt/oracle/middleware/wlserver_10.3/common/derby/lib/derbyclient.jar:/opt/oracle/middleware/wlserver_10.3/common/derby/lib/derbytools.jar::
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns:
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: Initializing WebLogic Scripting Tool (WLST) ...
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns:
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: Welcome to WebLogic Server Administration Scripting Shell
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns:
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: Type help() for help on available commands
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns:
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: Length of args:  8 ['create_domain.py', 
> '/opt/oracle/user_projects/domains/domaincreation', '8901', '8902', 
> 'managed_test', '8903', '8904', 'weblogic1']
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: Error: Current path is invalid for creation. cd() to its 
> parent first.
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: Domain Created Successfully!
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: executed successfully
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns:
> notice: /Stage[main]/Wldomain_create/Exec[Execute domain create 
> script]/returns: 
> CLASSPATH=/opt/oracle/middleware/patch_wls1036/profiles/default/sys_manifest_classpath/weblogic_patch.jar:/opt/oracle/jdk/lib/tools.jar:/opt/oracle/middleware/wlserver_10.3/server/lib/weblogic_sp.jar:/opt/oracle/middleware/wlserver_10.3/server/lib/weblogic.jar:/opt/oracle/middleware/modules/features/weblogic.server.modules_10.3.6.0.jar:/opt/oracle/middleware/wlserver_1

[Puppet Users] Example of a working runinterval + splay configuration?

2013-05-24 Thread Michael O'Dea
I have a substantial number of Windows hosts running puppet 3.1.1 with the 
following in their puppet.conf:

runinterval = 1800
> splay = true
> splaylimit = 900


However in checking puppet logs, I'm finding that these hosts are dialing 
in at 30 minute intervals +/- 5-10 seconds.  Can someone provide me an 
example puppet.conf that is properly implementing the splay feature on a 
similar environment (windows, Puppet 3.1.1)?

Thanks in advance.  I've searched quite a bit on this and not found 
anything that completely explains how to make use of splay to ensure agents 
don't all dial in at the same time.  I sometimes launch 20+ systems at a 
time, and staggering the launch is not an option -- I need to figure out 
how to get Puppet to vary the dial in.  When 100 hosts all dial in at the 
same time, it absolutely crushes the masters.  

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




[Puppet Users] Puppet/Nagios/PuppetDB slow performance

2013-05-24 Thread Jonathan Gazeley

Hi all,

For months now I've been using Puppet with PuppetDB backend to manage my 
Nagios configs. We now have 1200+ services being checked and including 
servicedependency, host, hostdependency, command and other Nagios 
resources being managed, that's about 3000 resources in total. 
Unfortunately this means the monitoring server takes about 8 minutes to 
perform a Puppet run.


I'm not exactly sure what the bottleneck is - whether it's doing 3000 
calls to PuppetDB (although the load on the PuppetDB server and its 
Postgres database are low), or whether it is parsing nagios_service.cfg 
that causes the slowdown. It's about 500kb and 11,000 lines.


I know it is possible to squirt the Nagios config into several smaller 
files when the resources are collected on the monitoring server, but I 
gather this also means that Nagios resources cannot be purged if the 
default file locations are not used. The ability to purge old configs 
automatically is essential to our environment.


So does anyone have any suggestions on how to improve the performance of 
Puppet when handling large Nagios configs?


Cheers,
Jonathan

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




Re: [Puppet Users] Execution order of classes

2013-05-24 Thread Markus "Shorty" Uckelmann
Am 24.05.2013 11:35, schrieb Markus Uckelmann:
> Hi all,

Sorry for the double post.

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




Re: [Puppet Users] Re: apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Peter
Eric,

Damn forgot to cut message down and include the error messages.

Essentially when I try to install puppet-hiera I get this error message:

root@play apt/sources.list.d# apt-get install hiera-puppet
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 hiera-puppet : Depends: puppet but it is not going to be installed
E: Unable to correct problems, you have held broken packages.


However puppet is already installed:

root@play apt/sources.list.d# dpkg --status puppet
Package: puppet
Status: install ok installed
Priority: optional
Section: admin
Installed-Size: 134
Maintainer: Puppet Labs <>
Architecture: all
Version: 3.1.1-1puppetlabs1
Depends: puppet-common (= 3.1.1-1puppetlabs1), ruby | ruby-interpreter
Recommends: rdoc
Suggests: puppet-el, vim-puppet


Peter

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




Re: [Puppet Users] Manage config files with Puppet and version control software

2013-05-24 Thread Kodiak Firesmith
Hello,
We are doing something similar to manage our entire Puppet hierarchy with 
Subversion.  Essentially we make changes 'go live' in Puppet by using 
post-hooks that copy the modified files into the normal puppet areas upon 
committing.  

We use svnserve with GSSAPI auth and sub-repository level ACLs to delegate 
access to host & service owners or groups.  

We cobbled this together during the Puppet 2.6 era and have used it since - 
I'm not sure if new functionality has been integrated with Puppet or Puppet 
Enterprise to do version control since then.

Now that we have everything set up just right we love it for the most part.

On Friday, May 24, 2013 6:30:11 AM UTC-4, Dusan Dordevic wrote:
>
> Thanks for feedback once more. I will try it as well then...
>
> Best regards,
> Dušan
>
>
> On Fri, May 24, 2013 at 11:20 AM, Brian Lalor 
> > wrote:
>
>> On May 24, 2013, at 6:14 AM, Dusan Dordevic <
>> dusan.d...@clavistechnology.com > wrote:
>>
>> My problem is following, if I want to manage /etc/mysql/my.cnf and other 
>> config files, that means I would need to make repository in / which I am 
>> not really happy with. Mercurial that we are using do not support 
>> relocating files, so I cannot check out my.cnf from somewhere else and 
>> place it to /etc/mysql/. Only thing that comes to mi mind is to check out 
>> repo somewhere else and then create a copy of file.
>>
>>
>> This is the approach that I'm taking.  It works very well; have vcsrepo 
>> manage the repository, then use a file resource to ensure that a target 
>> file is kept in sync with the one checked out from the remote repo.  Make 
>> the file resource require the vcsrepo resource.  Then you can notify MySQL 
>> to restart when its config file changes.
>>
>> --
>> Brian Lalor
>> bla...@bravo5.org 
>>
>>  
>>  -- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "Puppet Users" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/puppet-users/e3YJSINkNPc/unsubscribe?hl=en
>> .
>> To unsubscribe from this group and all its topics, send an email to 
>> puppet-users...@googlegroups.com .
>> To post to this group, send email to puppet...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>  
>>  
>>
>
>

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




[Puppet Users] Exec question: variable expansion to set gconf string

2013-05-24 Thread Kodiak Firesmith
Hi Everybody,

So I'm working on a workstation_policies module that will basically set a 
ton of gconf keys.

I think I have everything figured out except for a clean way to throw a 
long legal banner into an exec for gconf.

This should give an idea of what I thought would work per my interpretation 
of the exec resource type docs:
(Using single quotes in variable to preserve line breaks, using double 
quotes in the exec so that the variable is interpreted, etc)

class workstation_policies() {

  $legal_banner = 
'==

THIS SYSTEM IS OPERATED FOR AUTHORIZED USERS ONLY

Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod 
tempor incididunt 
ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud 
exercitation ullamco 
laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in 
reprehenderit in 
voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint 
occaecat cupidatat 
non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

=='

# Turn on and enforce the contents of the GDM legal banner.
  exec { 'gconftool-2 --set --type=boolean 
/apps/gdm/simple-greeter/banner_message_enable true':
cwd => '/var/lib/puppet',
path=> ['/bin', '/usr/bin', '/sbin', '/usr/sbin'],
unless  => 'gconftool-2 --get 
/apps/gdm/simple-greeter/banner_message_enable | grep true',
user=> 'gdm'
  }


  exec { "gconftool-2 --set --type=string 
/apps/gdm/simple-greeter/banner_message_text "$legal_banner"":
cwd => '/var/lib/puppet',
path=> ['/usr/bin'],
unless  => 'gconftool-2 --get 
/apps/gdm/simple-greeter/banner_message_text | grep AUTHORIZED',
user=> 'gdm'
  }


As it is now, I'll get a catalog compilation error like the one below:

Error: Could not retrieve catalog from remote server: Error 400 on SERVER: 
Syntax error at 'legal_banner'; expected '}' at 
/etc/puppet/modules/beta/workstation_policies/manifests/init.pp:65 on node 
foo

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




Re: [Puppet Users] Re: apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Peter
Hi Eric,

I was setting up a fresh VM in my dev environment and ran into this same 
issue.  Here is how I setup and install puppet in my VM

#!/bin/bash -x

CODENAME=$(lsb_release -cs | tr '[A-Z]' '[a-z]')

[ -z $CODENAME ] && echo "Codename not set" && exit 1;

 
pkgname="puppetlabs-release-${CODENAME}.deb"
 
url="https://apt.puppetlabs.com/${pkgname}";
 
wget -q $url
dpkg -i $pkgname
 
rm $pkgname
 
apt-get update && apt-get -y install puppet


Hope this helps.

Peter.


On Friday, May 24, 2013 7:25:52 AM UTC+10, Eric Sorenson wrote:
>
> Quick question for those of you affected by this -- what did you to do to 
> add the puppetlabs apt repo? 
>
> Did you do it through the method described here: 
> http://docs.puppetlabs.com/guides/puppetlabs_package_repositories.html#for-debian-and-ubuntu
>
> .. or some other way? I'm trying to suss out whether the docs / packages 
> are messing people up.
>
> thx
> eric0
>
> On Thursday, May 23, 2013 12:38:37 PM UTC-7, Matthew Kennedy wrote:
>>
>> I resolved this by adding the 'dependency' repo. I do wonder what the 
>> purpose of having a separate repo? 
>> On May 23, 2013 12:46 PM, "Chris Prior"  wrote:
>>
>>> I am having the same issue...
>>>
>>> Running on Ubuntu as below:
>>>
>>>
>>> Distributor ID: Ubuntu
>>> Description: Ubuntu 12.04 LTS
>>> Release: 12.04
>>> Codename: precise
>>>
>>>
>>> Managed using Vagrant, puppet master being installed via the puppetlabs 
>>> puppet module from puppet forge:
>>>
>>>
>>> err: /Stage[main]/Puppet/Package[puppet]/ensure: change from purged to 
>>> latest failed: Could not update: Execution of '/usr/bin/apt-get -q -y -o 
>>> DPkg::Options::=--force-confold install puppet' returned 100: Reading 
>>> package lists...
>>> Building dependency tree...
>>> Reading state information...
>>> Some packages could not be installed. This may mean that you have 
>>> requested an impossible situation or if you are using the unstable 
>>> distribution that some required packages have not yet been created or been 
>>> moved out of Incoming.
>>> The following information may help to resolve the situation:
>>>
>>> The following packages have unmet dependencies:
>>> puppet : Depends: puppet-common (= 3.2.1-1puppetlabs1) but it is not 
>>> going to be installed
>>> E: Unable to correct problems, you have held broken packages.
>>> at /tmp/vagrant-puppet/modules-0/puppet/manifests/init.pp:39
>>>
>>>
>>> Chris
>>>
>>> On Wednesday, 22 May 2013 22:53:21 UTC+1, Matthew Kennedy wrote:

 When trying to install puppetmaster-passenger** from puppetlabs apt 
 repo I get... was working 2ish hours ago (before the 3.2 release)

 Some packages could not be installed. This may mean that you have
 requested an impossible situation or if you are using the unstable
 distribution that some required packages have not yet been created
 or been moved out of Incoming.
 The following information may help to resolve the situation:

 The following packages have unmet dependencies:
  puppetmaster-passenger : Depends: puppetmaster-common (= 
 3.2.1-1puppetlabs1) but it is not going to be installed
 E: Unable to correct problems, you have held broken packages.

 Thanks,
 Matt

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

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




[Puppet Users] Re: Manage config files with Puppet and version control software

2013-05-24 Thread Maik Kulbe
You could create a puppet module and clone the repo into a subirectory of 
the files-dir of that module. Then you create a cronjob(on the puppet 
master) that pulls the repo every n minutes.
Then you can use this file now in a puppet manifest. But I would highly 
recommend to add some kind of automated testing(like some continous 
integration environment)  before pulling so you don't pull bad/broken files.

On Friday, May 24, 2013 10:12:22 AM UTC+2, dusan.d...@clavistechnology.com 
wrote:
>
> Hi,
>
> I want to manage some configuration files (let's say my.cnf) using Puppet. 
> I want to keep that file in some version control repository and developers 
> will have access to it. Once they change it, Puppet should pull it, put it 
> in place on server and restart service. 
>
> Is there any general guide what is the best practice how to achieve this ?
>
> Thanks...
>

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




[Puppet Users] Re: apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Maik Kulbe
I can confirm this too and think the way of installing this via a .deb is 
not very nice to admins with more then 10 servers. Why do I need to install 
a package for installing some sources.list.d file when I want it all 
automated. Automation has to do a lot with simplification IMHO, because the 
simpler something is the less likely it will fail. If you want to build a 
robust mechanism of fast deployment a .deb is just really ugly and awkward 
to handle. 

Also I really don't understand why this changed in a way you coudn't 
upgrade anymore. There should have been an update via the repo to at least 
update the sources.list file or create a new one for the dependencies..

I'm also in with the other guys here - I really don't get why you would 
need a second repository for the dependencies. 

On Thursday, May 23, 2013 5:26:40 PM UTC+2, ma...@marco-scholl.de wrote:
>
> i can confirm this
>
> ruby-rgen is not found.
>
> greets
>
> ---
>
> Paketlisten werden gelesen... Fertig
> Abhängigkeitsbaum wird aufgebaut   
> Statusinformationen werden eingelesen... Fertig
> Einige Pakete konnten nicht installiert werden. Das kann bedeuten, dass
> Sie eine unmögliche Situation angefordert haben oder, wenn Sie die
> Unstable-Distribution verwenden, dass einige erforderliche Pakete noch
> nicht erstellt wurden oder Incoming noch nicht verlassen haben.
> Die folgenden Informationen helfen Ihnen vielleicht, die Situation zu 
> lösen:
>
> Die folgenden Pakete haben unerfüllte Abhängigkeiten:
>  puppet : Hängt ab von: puppet-common (= 3.2.1-1puppetlabs1) soll aber 
> nicht installiert werden
> E: Probleme können nicht korrigiert werden, Sie haben zurückgehaltene 
> defekte Pakete.
> $ sudo apt-get install puppet-common
> Paketlisten werden gelesen... Fertig
> Abhängigkeitsbaum wird aufgebaut   
> Statusinformationen werden eingelesen... Fertig
> Einige Pakete konnten nicht installiert werden. Das kann bedeuten, dass
> Sie eine unmögliche Situation angefordert haben oder, wenn Sie die
> Unstable-Distribution verwenden, dass einige erforderliche Pakete noch
> nicht erstellt wurden oder Incoming noch nicht verlassen haben.
> Die folgenden Informationen helfen Ihnen vielleicht, die Situation zu 
> lösen:
>
> Die folgenden Pakete haben unerfüllte Abhängigkeiten:
>  puppet-common : Hängt ab von: ruby-rgen ist aber nicht installierbar
>  Empfiehlt: debconf-utils soll aber nicht installiert 
> werden
> E: Probleme können nicht korrigiert werden, Sie haben zurückgehaltene 
> defekte Pakete.
>
>
>
>
>

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




[Puppet Users] Execution order of classes

2013-05-24 Thread Markus Uckelmann
Hi all,

I'm stuck in the hell of class dependencies and hope that someone here
can help me.

Puppet-Version is 2.7.21
It's the Debian Squeeze package from the Puppetlabs Repo.

I want one class to manage everything database related. So I call it in
"site.pp" like this:

  node client1 {
class { 'database': }
  }

It's parameterized and uses default values. The class "database"
declares(executes) other classes.

Now to my problem. I have a "sub"-class "database::packages" which must
be executed before every other stuff inside the database class. Here is
the code:

1 class database {
2   class { 'database::packages': } ->
3   # setup data dirs
4   class { 'database::directories':
5 # require => Class['database::packages'],
6   }
7   # Class['database::packages'] -> Class['database::directories']
8 }

I tried three different things. None of them worked. First one is the
chaining arrow in line 2. The next two tries I left commented out. In
line 5 I tried to require the "packages" class inside the "directories"
class declaration. And last in line 7 I tried the chaining again.

Whenever I run this code on a client, the "directories" class gets
executed first and fails, because it needs a specific user which is
setup in the "packages" class.

BTW: I also tried to put the code from line 7 inside the "sub"-classes.

Thanks for any help.

Cheers, Markus



signature.asc
Description: OpenPGP digital signature


[Puppet Users] Execution order of classes

2013-05-24 Thread Markus "Shorty" Uckelmann
Hi all,

I'm stuck in the hell of class dependencies and hope that someone here
can help me.

Puppet-Version is 2.7.21
It's the Debian Squeeze package from the Puppetlabs Repo.

I want one class to manage everything database related. So I call it in
"site.pp" like this:

  node client1 {
class { 'database': }
  }

It's parameterized and uses default values. The class "database"
declares(executes) other classes.

Now to my problem. I have a "sub"-class "database::packages" which must
be executed before every other stuff inside the database class. Here is
the code:

1 class database {
2   class { 'database::packages': } ->
3   # setup data dirs
4   class { 'database::directories':
5 # require => Class['database::packages'],
6   }
7   # Class['database::packages'] -> Class['database::directories']
8 }

I tried three different things. None of them worked. First one is the
chaining arrow in line 2. The next two tries I left commented out. In
line 5 I tried to require the "packages" class inside the "directories"
class declaration. And last in line 7 I tried the chaining again.

Whenever I run this code on a client, the "directories" class gets
executed first and fails, because it needs a specific user which is
setup in the "packages" class.

BTW: I also tried to put the code from line 7 inside the "sub"-classes.

Thanks for any help.

Cheers, Shorty


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




Re: [Puppet Users] Manage config files with Puppet and version control software

2013-05-24 Thread Dusan Dordevic
Thanks for feedback once more. I will try it as well then...

Best regards,
Dušan


On Fri, May 24, 2013 at 11:20 AM, Brian Lalor  wrote:

> On May 24, 2013, at 6:14 AM, Dusan Dordevic <
> dusan.dorde...@clavistechnology.com> wrote:
>
> My problem is following, if I want to manage /etc/mysql/my.cnf and other
> config files, that means I would need to make repository in / which I am
> not really happy with. Mercurial that we are using do not support
> relocating files, so I cannot check out my.cnf from somewhere else and
> place it to /etc/mysql/. Only thing that comes to mi mind is to check out
> repo somewhere else and then create a copy of file.
>
>
> This is the approach that I'm taking.  It works very well; have vcsrepo
> manage the repository, then use a file resource to ensure that a target
> file is kept in sync with the one checked out from the remote repo.  Make
> the file resource require the vcsrepo resource.  Then you can notify MySQL
> to restart when its config file changes.
>
> --
> Brian Lalor
> bla...@bravo5.org
>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Puppet Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/puppet-users/e3YJSINkNPc/unsubscribe?hl=en
> .
> To unsubscribe from this group and all its topics, send an email to
> puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: [Puppet Users] Manage config files with Puppet and version control software

2013-05-24 Thread Brian Lalor
On May 24, 2013, at 6:14 AM, Dusan Dordevic 
 wrote:

> My problem is following, if I want to manage /etc/mysql/my.cnf and other 
> config files, that means I would need to make repository in / which I am not 
> really happy with. Mercurial that we are using do not support relocating 
> files, so I cannot check out my.cnf from somewhere else and place it to 
> /etc/mysql/. Only thing that comes to mi mind is to check out repo somewhere 
> else and then create a copy of file.


This is the approach that I'm taking.  It works very well; have vcsrepo manage 
the repository, then use a file resource to ensure that a target file is kept 
in sync with the one checked out from the remote repo.  Make the file resource 
require the vcsrepo resource.  Then you can notify MySQL to restart when its 
config file changes.

--
Brian Lalor
bla...@bravo5.org


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




Re: [Puppet Users] Manage config files with Puppet and version control software

2013-05-24 Thread Dusan Dordevic
Hi,

Yes, I know about vcsrepo module and that part is not a problem. It is
fairly easy to set it up and pull release from repository.

My problem is following, if I want to manage /etc/mysql/my.cnf and other
config files, that means I would need to make repository in / which I am
not really happy with. Mercurial that we are using do not support
relocating files, so I cannot check out my.cnf from somewhere else and
place it to /etc/mysql/. Only thing that comes to mi mind is to check out
repo somewhere else and then create a copy of file.

Is there any better method ?

Best regards,
Dušan


On Fri, May 24, 2013 at 11:10 AM, Brian Lalor  wrote:

> On May 24, 2013, at 4:12 AM, dusan.dorde...@clavistechnology.com wrote:
>
> I want to manage some configuration files (let's say my.cnf) using Puppet.
> I want to keep that file in some version control repository and developers
> will have access to it. Once they change it, Puppet should pull it, put it
> in place on server and restart service.
>
> Is there any general guide what is the best practice how to achieve this ?
>
>
> I'm not sure that's really a best practice, but it does come in handy from
> time to time.  There's a module for that: 
> vcsrepo
> .
>
> --
> Brian Lalor
> bla...@bravo5.org
>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Puppet Users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/puppet-users/e3YJSINkNPc/unsubscribe?hl=en
> .
> To unsubscribe from this group and all its topics, send an email to
> puppet-users+unsubscr...@googlegroups.com.
> To post to this group, send email to puppet-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/puppet-users?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

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




Re: [Puppet Users] Manage config files with Puppet and version control software

2013-05-24 Thread Brian Lalor
On May 24, 2013, at 4:12 AM, dusan.dorde...@clavistechnology.com wrote:

> I want to manage some configuration files (let's say my.cnf) using Puppet. I 
> want to keep that file in some version control repository and developers will 
> have access to it. Once they change it, Puppet should pull it, put it in 
> place on server and restart service. 
> 
> Is there any general guide what is the best practice how to achieve this ?


I'm not sure that's really a best practice, but it does come in handy from time 
to time.  There's a module for that: vcsrepo.

--
Brian Lalor
bla...@bravo5.org


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




Re: [Puppet Users] Announce: Puppet 3.2.1 Available

2013-05-24 Thread Paul Tötterman

>
> Did something change in the way Puppet outputs messages? Until this 

morning we used the following to run Puppet from Cron on all our nodes: 
>
 

But as of 3.2.1 this produces output on every Puppet agent run and that 
> output is mailed out, resulting in hundreds of messages which contain 
> nothing of importance (see below). This had worked fine for almost two 
> years now, with output only generated on errors and problems (such as 
> DNS not available). 
>

I'm having the same issue. I couldn't find a bug report about this. There 
is --verbose and --debug, but not --silent or --quiet. Should we maybe use 
--logdest? Anyway the behaviour has changed from 3.1.1

Cheers,
Paul

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




Re: [Puppet Users] Re: apt repository appears to have dependency issue with latest release (3.2.1)

2013-05-24 Thread Greg Sutcliffe
On 23 May 2013 22:25, Eric Sorenson  wrote:

> Quick question for those of you affected by this -- what did you to do to
> add the puppetlabs apt repo?
>
> Did you do it through the method described here:
> http://docs.puppetlabs.com/guides/puppetlabs_package_repositories.html#for-debian-and-ubuntu
>
> .. or some other way? I'm trying to suss out whether the docs / packages
> are messing people up.
>

I've hit this, but it's because I have the main Puppetlabs repo in my
preseed file for new virtual machines, so it's available within the
installer environment. That's just text, so I only have a line for "deb
http://apt.puppetlabs.com  main"

I think the "install a deb which sets up the repos" is good for most
people, but there should always be the docs for the manual apt setup for
those going a different route. As of right now, I don't see a
"dependencies" repo mentioned anywhere on the page you linked, Eric

I'll also add a voice the question on the logic behind a separate
dependencies repo, although only because you're adding work to your
documentation requirements ;)

Cheers,
Greg

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




[Puppet Users] Manage config files with Puppet and version control software

2013-05-24 Thread dusan . dordevic
Hi,

I want to manage some configuration files (let's say my.cnf) using Puppet. 
I want to keep that file in some version control repository and developers 
will have access to it. Once they change it, Puppet should pull it, put it 
in place on server and restart service. 

Is there any general guide what is the best practice how to achieve this ?

Thanks...

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