Re: [Puppet Users] Re: A Question about mixing Puppet with other things

2011-07-13 Thread Peter Meier
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/12/2011 05:26 PM, Dan White wrote: > This tells me RedHat picked Foreman over Cobbler. It does not tell > me WHY. > > Their reasons may not apply to my situation. > > I am not trying to be difficult, but I find that I cannot accept an > opinio

Re: [Puppet Users] Seemingly random failures after 2.7.1 upgrade

2011-07-13 Thread Peter Meier
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 > Is using an empty class in init.pp problematic ? All of these modules > worked just fine before going from 2.6.8 to 2.7.1. I have no idea, whether this is the problem. But why do you do: > # manifests/init.pp > import "classes/*.pp" > > class kv

Re: [Puppet Users] Re: how to write classes to install package from source

2011-07-13 Thread Peter Meier
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/12/2011 12:19 PM, Al @ Lab42 wrote: > You might find this define useful ( > https://github.com/example42/puppet-modules/blob/master/common/manifests/defines/netinstall.pp > > ): > or as a general best practice you might want to build your ow

Re: [Puppet Users] Best way to create a repo, looking for advice and tips

2011-07-13 Thread Denmat
Hi, Not sure I completely understand what you're after but i'll try to give an answer (from a red hat perspective). Yes you can set up a repo that you point puppet clients at. yumrepo allows you to describe that. Yes you can use the yum tool createrepo to create a yum repo from a bunch of rp

Re: [Puppet Users] Testing if a puppet class is going to be installed

2011-07-13 Thread Alan Barrett
On Thu, 07 Jul 2011, Keith Minkler wrote: For example, for setting up the proper nagios monitors, you'd want to say something like "if this machine has the apache class, then configure apache monitoring" It's not feasible I think to put this logic in the "apache" class, since you'd have to hav

Re: [Puppet Users] Re: How to avoid the use of defined

2011-07-13 Thread Arnaud Gomes-do-Vale
Hi, First, thanks for your help. However I still have some issues with your solution. jcbollinger writes: > few bad ones. Here's a good rule of thumb: never use Puppet's > "defined()" function in your manifests. Ever. It is brittle, and it > will cause you grief, increasing exponentially wit

[Puppet Users] puppet manifest execution orders

2011-07-13 Thread Roni
I created manifest for our webserver. manifest included git clone, database creation and restore database etc How to order the installation and exec exactly Roni -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send em

Re: [Puppet Users] puppet manifest execution orders

2011-07-13 Thread Peter Meier
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/13/2011 08:51 AM, Roni wrote: > I created manifest for our webserver. manifest included git clone, > database creation and restore database etc How to order the > installation and exec exactly by using require, before, notify, subscribe...

Re: [Puppet Users] Re: A Question about mixing Puppet with other things

2011-07-13 Thread Dan White
Thank you, Ohad. This is the sort of info I am looking for. “Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us.” Bill Waterson (Calvin & Hobbes) - Ohad Levy wrote: > On Tue, Jul 12, 2011 at 6:26 PM, Dan White

Re: [Puppet Users] Re: A Question about mixing Puppet with other things

2011-07-13 Thread Dan White
Thank you, Peter. This is the type of response I wanted. “Sometimes I think the surest sign that intelligent life exists elsewhere in the universe is that none of it has tried to contact us.” Bill Waterson (Calvin & Hobbes) - Peter Meier wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash:

Re: [Puppet Users] puppet manifest execution orders

2011-07-13 Thread Nigel Kersten
On Tue, Jul 12, 2011 at 11:51 PM, Roni wrote: > I created manifest for our webserver. manifest included git clone, > database creation and restore database etc How to order the > installation and exec exactly > > Roni, you really should have a run through our Learning Puppet series. http://d

Re: [Puppet Users] Seemingly random failures after 2.7.1 upgrade

2011-07-13 Thread Nigel Kersten
On Tue, Jul 12, 2011 at 11:29 PM, Peter Meier wrote: > > Puppet has quite a powerfull autoloading feature of classes and I think > it can be seen as a general best practice to have one class in a file in > its corresponding path on the filesystem. > > What he said. :) Life really does become a lo

[Puppet Users] Re: How to avoid the use of defined

2011-07-13 Thread jcbollinger
On Jul 13, 5:34 am, Arnaud Gomes-do-Vale wrote: > Hi, > > First, thanks for your help. However I still have some issues with your > solution. > > > > jcbollinger writes: > > few bad ones.  Here's a good rule of thumb: never use Puppet's > > "defined()" function in your manifests.  Ever.  It is

Re: [Puppet Users] Re: How to avoid the use of defined

2011-07-13 Thread Nigel Kersten
On Wed, Jul 13, 2011 at 3:34 AM, Arnaud Gomes-do-Vale wrote: > > > # Resource defaults for Packages in this class > > Package { > > ensure => installed, > > require => Package['php'], > > notify => Service['httpd'] > > } > > This creates a dependency loop: An option here is to

[Puppet Users] Re: puppet never finishing when there are thousands of resources

2011-07-13 Thread jcbollinger
On Jul 12, 9:53 pm, Rich Rauenzahn wrote: > We are using puppet to export nagios resources (now we're using file > resources to represent them) and the number of resources is probably > in the thousands -- our puppet runs take 6GB (on the client side) and > then just sort of spin forever (it's b

Re: [Puppet Users] Re: puppet never finishing when there are thousands of resources

2011-07-13 Thread Nigel Kersten
On Wed, Jul 13, 2011 at 8:27 AM, jcbollinger wrote: > > Relationships involving whole classes, especially of one whole class > on another, tend to add a lot of edges that are not strictly > necessary, because they are reduced to multiple inter-resource > dependencies. That is, given Class['a'] ->

Re: [Puppet Users] Moving config to an ENC

2011-07-13 Thread Justin Lambert
Thanks for the response Dan, that was an easy fix. Here is a trace: # puppet agent -t --trace /usr/lib/ruby/site_ruby/1.8/puppet/indirector/rest.rb:56:in `deserialize' /usr/lib/ruby/site_ruby/1.8/puppet/indirector/rest.rb:75:in `find' /usr/lib/ruby/site_ruby/1.8/puppet/indirector/indirection.rb:1

[Puppet Users] Exported Resources with --noop

2011-07-13 Thread Andrew Thompson
When I puppet with the noop flag resources are being exported to the db. Is this expected or a bug? I would expect it to simulate the transaction with the db... -Andrew -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, se

Re: [Puppet Users] Re: What is the best practice to clean up installed components on a node?

2011-07-13 Thread Darrell Fuhriman
I've always thought there should be an implicit X::disabled class that gets included for every host where X isn't included. Then if I create said class, it gets automatically executed on all hosts that don't include X. As it is now, one still has to go through and add X::disabled to every host

[Puppet Users] wrong nodes.pp being accessed by the client

2011-07-13 Thread newguy
I have two development environments, main and development and my puppet.conf looks like this: [main] logdir=/var/log/puppet vardir=/var/lib/puppet ssldir=/var/lib/puppet/ssl rundir=/var/run/puppet factpath=$vardir/lib/facter pluginsync=false templatedir=$confdir/templates prerun_command=/etc/pup

[Puppet Users] help with new type

2011-07-13 Thread Mike Zupan
I'm trying to create a new type.. I followed the example on the wiki and I have for the the type module Puppet newtype(:append_if_no_such_line) do @doc = "Ensure that the given line is defined in the file, and append the line to the end of the file if the line isn't already in

[Puppet Users] Re: wrong nodes.pp being accessed by the client

2011-07-13 Thread newguy
I got the solution as I realize that puppet server needs to have only one nodes.pp for every environment and as client with different environments connect puppet looks for their module paths and install the respective packages, all the node entries irrespective of the environment they are attached

Re: [Puppet Users] Re: wrong nodes.pp being accessed by the client

2011-07-13 Thread Darrell Fuhriman
No, you're right, at least as far as I've been able to tell – though I certainly may have overlooked something. The puppetmaster only gets the configs from one environment, so you're stuck using that. There are other consequences as well, such as defined resources using the definition in the se

[Puppet Users] Re: Seemingly random failures after 2.7.1 upgrade

2011-07-13 Thread Gus
Hi! I've also noticed this (weird) behaviour. I am planning an (huge) upgrade (from 0.25.x to 2.7.1) in all my puppet's boxes... I've installed puppet's 2.7.1 gem and got a lot of "Could not find class" problem... and everything worked just fine with 0.25.x. So, I decided to uninstall the gem fo

[Puppet Users] Solaris mount provider question

2011-07-13 Thread Aaron Grewell
I'm trying to mount multiple swap partitions in Solaris, but I'm not sure how to create a working syntax for that. Since the mountpoint for a swap partition is '-' adding more than one is going to result in a multiple declaration. I'd like to do something like this: mount { '-':

Re: [Puppet Users] Exported Resources with --noop

2011-07-13 Thread Gabriel Filion
On 11-07-13 12:06 PM, Andrew Thompson wrote: > When I puppet with the noop flag resources are being exported to the > db. Is this expected or a bug? Hmm what version of puppet are you using? I've just encountered exactly this with puppet 0.25.4. ran puppet with "-t --noop" on a node that has yet

Re: [Puppet Users] Solaris mount provider question

2011-07-13 Thread Stefan Schulte
On Wed, Jul 13, 2011 at 02:54:07PM -0700, Aaron Grewell wrote: > I'm trying to mount multiple swap partitions in Solaris, but I'm not sure > how to create a working syntax for that. Since the mountpoint for a swap > partition is '-' adding more than one is going to result in a multiple > declarati

[Puppet Users] Open Source Team iteration & planning summary 2011-07-13

2011-07-13 Thread Jacob Helwig
We've made some good progress on getting Facter & Puppet running on Windows. Currently, we have Facter installable and running through install.rb, with all tests passing on Windows Server 2008 R2. We also have Puppet installable through install.rb, and are currently working on getting the code an

Re: [Puppet Users] Solaris mount provider question

2011-07-13 Thread John Warburton
On 14 July 2011 09:06, Stefan Schulte wrote: > On Wed, Jul 13, 2011 at 02:54:07PM -0700, Aaron Grewell wrote: > > I'm trying to mount multiple swap partitions in Solaris, but I'm not sure > > how to create a working syntax for that. Since the mountpoint for a swap > > partition is '-' adding more

Re: [Puppet Users] wrong nodes.pp being accessed by the client

2011-07-13 Thread Nan Liu
On Wed, Jul 13, 2011 at 11:18 AM, newguy wrote: > I have two development environments, main and development and  my > puppet.conf looks like this: > > > [main] > logdir=/var/log/puppet > vardir=/var/lib/puppet > ssldir=/var/lib/puppet/ssl > rundir=/var/run/puppet > factpath=$vardir/lib/facter > pl

Re: [Puppet Users] Re: What is the best practice to clean up installed components on a node?

2011-07-13 Thread Scott Smith
What if you specify a resource as being disabled/uninstalled/etc by default? On Jul 13, 2011 9:40 AM, "Darrell Fuhriman" wrote: > > I've always thought there should be an implicit X::disabled class that gets included for every host where X isn't included. > > Then if I create said class, it gets a

Re: [Puppet Users] puppet manifest execution orders

2011-07-13 Thread Rony KB
Thanks Nigel. Right now i am using two shell scripts for Mysql Database creation and database restore. These shell scripts are calling from puppet manifest through exec.Can we do these from pure puppet manifest, without shell scripts. Roni On Wed, Jul 13, 2011 at 7:32 PM, Nigel Kersten wrote:

[Puppet Users] puppet custom fuction run as user pupprt?

2011-07-13 Thread flex
I wrote a custom fuction to read a root read-only file, it raised an Permission Denied error. During debug, i found this fuction seems to run as user puppet, it is this a feature or a bug? -- System Administrator, Focus on System Management and Basic Development -- You received this message be