Re: [Puppet Users] Re: Windows Remote Desktop Services (Could not find a suitable provider for dism)

2013-03-15 Thread Vladimir Rutsky
Hello, James!

On Thu, Mar 14, 2013 at 6:08 PM, jim stra...@gmail.com wrote:

 Hiya Vladimir

 I think the issue is, if we remove Puppet and DISM and go back to Windows
 Remote Desktop Services, also known as Terminal Server.

 When you install this feature, it requires a reboot for this feature to
 take effect

 when the host comes back online, its a fully functioning RDS / Terminal
 Server

 If you want to install software, you have to run this command first

 change user /install
 Then install software
 revert back
 change user /execute

 Now add puppet / DISM module onto this, it will look like this

 Server running puppet agent
 install feature APPServer using DISM module
 reboot host
 hosts comes back online a functioning RDS / Terminal Server
 try to run puppet agent again
 Problem 
 Due to RDS / Terminal Server still running in execute mode
 Puppet Run will fail.

 (this is an assumption, RDS / Terminal Server running in execute mode when
 applying ruby syntax for environment variables e..g
 commands :dism = #{Dir::WINDOWS}\\sysnative\\Dism.exe
 will default to %userprofile% path thus *C:\Users\Administrator*\**
 WINDOWS\sysnative\Dism.exe

 Now if the DISM module, could do the following, it would work for RDS /
 Terminal Server:

 Server running puppet agent
 install feature APPServer using DISM module
 reboot host
 hosts comes back online a functioning RDS / Terminal Server
 run puppet agent again, if feature equals RDS / Terminal Server
 execute change user / install mode
 run dism module
 execute change user /execute mode
 Puppet Run will run successfully


 hope this make sense


I'm glad to see that you find source of problems with Terminal Server
installation automation!
I'm not familiar with Terminal Server and how it works so I'm not sure how
to deal with your situation correctly. I think running change user /
install in dism Puppet module is bad idea, most probably Terminal Server
breaks other Puppet modules too. Maybe you should run whole puppet client
in this change user / install mode?

Do you resolved error code 194 problem? I'm quite sure that my fixes
should help.


Best wishes,

Vladimir Rutsky



 regards

 Jim




 On Thursday, 14 March 2013 13:32:43 UTC, Vladimir Rutsky wrote:

 Hello, James!

 I tested and looks like exitcode parameter doesn't work in DISM, sorry
 for not working example. I filled bug about this into DISM bug tracker on
 github: 
 https://github.com/puppetlabs/**puppetlabs-dism/issues/15https://github.com/puppetlabs/puppetlabs-dism/issues/15and
  commited fix for this issue in my master branch of DISM fork.

 I recommend you to get version from there: https://github.com/vrutsky/**
 puppetlabs-dism https://github.com/vrutsky/puppetlabs-dism , this
 should fix issue with first error Unexpected exitcode: 194.

 Source of second issue, C:\Users\Administrator\**WINDOWS\sysnative\Dism.exe
 does not exist, not clear to me.

 --
 Vladimir Rutsky




 On Wed, Mar 13, 2013 at 8:00 PM, jim str...@gmail.com wrote:

 Hi Vladimir


 This error:

 Puppet::Type::Dism::**ProviderDism: file 
 C:\Users\Administrator\**WINDOWS\sysnative\Dism.exe
 does not exist

 Just thought

 this part of the error

 C:\Users\Administrator

 It looks like its picking up the %userprofile% and appending to the
 environment part in dism module


 USERPROFILE=C:\Users\**Administrator

   if Puppet.features.microsoft_**windows?
 if ENV.has_key?('ProgramFiles(**x86)')
   commands :dism = #{Dir::WINDOWS}\\sysnative\\**Dism.exe
 else
   commands :dism = #{Dir::WINDOWS}\\system32\\**Dism.exe
 end
   end

 if that make sense

 On Wednesday, 13 March 2013 15:51:07 UTC, jim wrote:

 I update my DISM module with your changes and added this to my manifest

 dism { 'AppServer':
 ensure  = present,
 exitcode= [0, 3010, 194],
 }


 Here is my SET information:

 C:\Users\Administratorset
 ALLUSERSPROFILE=C:\ProgramData
 APPDATA=C:\Users\**Administrator**\AppData\Roaming
 CLIENTNAME=UKLSQL0156
 CommonProgramFiles=C:\Program Files\Common Files
 CommonProgramFiles(x86)=C:\**Pro**gram Files (x86)\Common Files
 CommonProgramW6432=C:\Program Files\Common Files
 COMPUTERNAME=TMS-A-TRM-01P
 ComSpec=C:\Windows\system32\**cm**d.exe
 FP_NO_HOST_CHECK=NO
 HOMEDRIVE=C:
 HOMEPATH=\Users\Administrator
 LOCALAPPDATA=C:\Users\**Administ**rator\AppData\Local
 LOGONSERVER=\\TMS-A-TRM-01P
 NUMBER_OF_PROCESSORS=2
 OS=Windows_NT
 Path=C:\Windows\system32;C:\**Wi**ndows;C:\Windows\System32\**Wbem**
 ;C:\Windows\System32
 \WindowsPowerShell\v1.0\
 PATHEXT=.COM;.EXE;.BAT;.CMD;.**V**BS;.VBE;.JS;.JSE;.WSF;.WSH;.**MS**C
 PROCESSOR_ARCHITECTURE=AMD64
 PROCESSOR_IDENTIFIER=Intel64 Family 6 Model 44 Stepping 2, GenuineIntel
 PROCESSOR_LEVEL=6
 PROCESSOR_REVISION=2c02
 ProgramData=C:\ProgramData
 ProgramFiles=C:\Program Files
 ProgramFiles(x86)=C:\Program Files (x86)
 ProgramW6432=C:\Program Files
 PROMPT=$P$G
 PSModulePath=C:\Windows\**system**32\WindowsPowerShell\v1.**0\**
 Modules\
 PUBLIC=C:\Users\Public

Re: [Puppet Users] Help me wrap my head around Yaml/Hiera with erwbgy/system

2013-03-15 Thread Keith Burdis
Hi Byron,

Some suggestions:

1) Hiera comes with a handy command-line tool to query your config so try
using that first.  What does running:

  # hiera -h system::augeas

return?  If it returns the ntp hash then your hiera config is good.

2) If not, are /etc/hiera.yaml and /etc/puppet/hiera.yaml the same file?  I
usually symlink one to the other to avoid issues.

3) Assuming your environment is production (the default) based on your
hiera.yaml the common.yaml file should be
/etc/puppet/hieradata/production/common.yaml.  Is this the case?

4) Not the point of your question, but to set NTP servers use system::ntp
:-)  It does uses Augeas underneath but is easier to use.

  - Keith


On 14 March 2013 16:04, Byron Miller byr...@gmail.com wrote:

 Trying to figure out the erwbgy/system plugin and just getting stuck..
 first run it did some changes, but it ignored parameters for ntp and now
 its not refreshing if I update the yaml at all, Im slightly lost at what I
 may be missing :)

 hiera.yaml
 ---
 :hierarchy:
 - %{certname}
 - %{environment}
 - global
 - %{environment}/common
 :backends:
   - yaml
 :yaml:
   :datadir: '/etc/puppet/hieradata'


 common.yaml

 system::packages::schedule:  'never'
 system::yumgroups::schedule: 'never'
 system::augeas:
   'ntp':
 context: '/files/etc/ntp.conf'
 changes:
   - 'set server[0] 0.vmware.pool.ntp.org'
   - 'set server[1] 1.vmware.pool.ntp.org'
   - 'set server[2] 2.vmware.pool.ntp.org'

 first run, it updated to 0.pool.ntp.org and its still doing that, so I
 missed something important here.

 Puppet 3.1.1

 I noticed all the hiera examples on the site for puppet all say coming
 soon.





 --
 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] Host name lookup failure

2013-03-15 Thread yarlagadda ramya
Hi all,

I installed puppet agent in one ip in linux..and am trying to connect to 
master while installing only..agent is getting installed but its giving 
host name look up failure..

But i specified the correct host name only for the master for which it 
needs to be connected during installation..certificate is not getting 
generated..in it..

In the master when am trying to see puppet cert list for requets..it is 
throwing the following error:
err: Could not call list: header too long
header too long


Can any one pls help me with this?

Regards,

Ramya Y

-- 
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: Help me wrap my head around Yaml/Hiera with erwbgy/system

2013-03-15 Thread Keith Burdis
The great thing about Puppet is that it gives you lots of different ways to
manage your host data.  Personally I am a big fan of hiera and its YAML
backend because it is simple for non-Puppet users to understand and allows
them to manage the config without having to write or modify Puppet
manifests.  I also find that using custom facts and different parts of the
hierarchy for things like locations, operating systems and host roles it
scales quite well for small to medium size setups (depending on what that
means to you).

If you're the only one who looks after Puppet config or the team that does
are all Puppeteers or you have a simpler setup then going down the pure
manifests route will work fine.  Most people did this before Puppet 3.
 However hiera was invented for a reason :-)

  - Keith


On 14 March 2013 20:10, windowsrefund windowsref...@gmail.com wrote:

 plugin aside, I strongly suggest not settling for YAML as a backend for
 Hiera since you're basically ending up with the same problem you were
 probably trying to solve; managing data in files. Sure, they're different
 files but still files. You may as well keep the data in your Puppet
 manifests and manage the data there...




  --
 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] Puppetlabs forge modules

2013-03-15 Thread Thomas Bendler
Hi @all,

what is the standard communication method for reporting bugs, enhancements,
... for forge modules. I saw i.e., that the nodejs module support RedHat
but not Scientific Linux which is only a matter of the selector. So I tried
to report this but the issue link is dead. Any hints on how to proceed?

Regards, Thomas
-- 
Linux ... enjoy the ride!

-- 
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] Help me wrap my head around Yaml/Hiera with erwbgy/system

2013-03-15 Thread Byron Miller
 
Great info Keith, thanks for replying.  I'll use this to continue seeing if 
I can make it work on our systems here.
 
What i'd like to do is have something that supports a tiered implementation 
of a  base install, then an app server config for app servers, database for 
database server and other options for custom servers
 
So with straight up manifests I have base then db which includes base 
then I have base with app server which includes base.
 
Is there a way to achieve similar structure with yaml and your plugin?  i 
tried using calling_class or calling_method or whatever it was to invoke a 
specific yaml from a specific class to achieve a layered build process, 
but maybe i'm missing something that is much easier (and i couldn't figure 
out if the variable was being used to be honest, it only applied the 
base.yaml, not the calling methods yaml.. is there a way to Trace which 
yaml its walking down?
 
thanks!
-byron
On Friday, March 15, 2013 4:13:26 AM UTC-5, Keith Burdis wrote:

 Hi Byron,

 Some suggestions:

 1) Hiera comes with a handy command-line tool to query your config so try 
 using that first.  What does running:

   # hiera -h system::augeas

 return?  If it returns the ntp hash then your hiera config is good.

 2) If not, are /etc/hiera.yaml and /etc/puppet/hiera.yaml the same file? 
  I usually symlink one to the other to avoid issues.

 3) Assuming your environment is production (the default) based on your 
 hiera.yaml the common.yaml file should be 
 /etc/puppet/hieradata/production/common.yaml.  Is this the case?

 4) Not the point of your question, but to set NTP servers use system::ntp 
 :-)  It does uses Augeas underneath but is easier to use.

   - Keith


 On 14 March 2013 16:04, Byron Miller byr...@gmail.com javascript:wrote:

 Trying to figure out the erwbgy/system plugin and just getting stuck.. 
 first run it did some changes, but it ignored parameters for ntp and now 
 its not refreshing if I update the yaml at all, Im slightly lost at what I 
 may be missing :)
  
 hiera.yaml
 ---
 :hierarchy:
 - %{certname}
 - %{environment}
 - global
 - %{environment}/common
 :backends:
   - yaml
 :yaml:
   :datadir: '/etc/puppet/hieradata'
  
  
 common.yaml
  
 system::packages::schedule:  'never'
 system::yumgroups::schedule: 'never'
 system::augeas:
   'ntp':
 context: '/files/etc/ntp.conf'
 changes:
   - 'set server[0] 0.vmware.pool.ntp.org'
   - 'set server[1] 1.vmware.pool.ntp.org'
   - 'set server[2] 2.vmware.pool.ntp.org'
  
 first run, it updated to 0.pool.ntp.org and its still doing that, so I 
 missed something important here.
  
 Puppet 3.1.1
  
 I noticed all the hiera examples on the site for puppet all say coming 
 soon.  
  
  
  
  

 -- 
 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 javascript:.
 To post to this group, send email to puppet...@googlegroups.comjavascript:
 .
 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] Puppetlabs forge modules

2013-03-15 Thread Ryan Coleman
Hi Thomas,

When GitHub issues are not active for a particular module, you can file
tickets in the general module project in our Redmine site.
http://projects.puppetlabs.com/projects/module-site/issues

Thanks for reporting the broken link. I'll get that fixed and we'll likely
switch to GH issues for this module soon.


On Fri, Mar 15, 2013 at 8:11 AM, Thomas Bendler thomas.bend...@gmail.comwrote:

 Hi @all,

 what is the standard communication method for reporting bugs,
 enhancements, ... for forge modules. I saw i.e., that the nodejs module
 support RedHat but not Scientific Linux which is only a matter of the
 selector. So I tried to report this but the issue link is dead. Any hints
 on how to proceed?

 Regards, Thomas
 --
 Linux ... enjoy the ride!

 --
 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.






-- 
Ryan Coleman | Modules  Forge | @ryanycoleman | ryancoleman in #puppet

-- 
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: Need help with apt::source and stages

2013-03-15 Thread Cosmin Luță
The apt code I'm using is 
from https://github.com/puppetlabs/puppetlabs-apt ,  commit-id 
e01bbb61b294be1358b147e8de4966d5f4c6efda . 

I've read http://projects.puppetlabs.com/issues/8263 's comments, so the 
anchor pattern should take care of it ? But the apt module I have is using 
that pattern... 

As for using regular relationships instead of stages, that's kinda hard 
since the manifests I have have been designed to use stages, it would be a 
big change to make for someone that barely grasps the concepts of puppet :)



On Thursday, March 14, 2013 4:14:27 PM UTC+2, jcbollinger wrote:



 On Wednesday, March 13, 2013 8:46:42 AM UTC-5, Cosmin Luță wrote:

 Hi,

 I have a local Puppet installation on which I've done:

 # puppet module install puppetlabs/apt  
 Preparing to install into /etc/puppet/modules ...
 Downloading from http://forge.puppetlabs.com ... 
 Installing -- do not interrupt ...   
 /etc/puppet/modules  
 └─┬ puppetlabs-apt (v1.1.0)  
   └── puppetlabs-stdlib (v3.2.0) 


 I also have the following nodes.pp which I want to apply:

 node default {  
 include stdlib  

 class {'apt':
 always_apt_update = true,
 disable_keys = true,
 stage = 'setup'
 }
 -
 apt::source { cassandra:
 location = http://debian.datastax.com/community;,
 release = stable,
 repos = main,
 key = B999A372,
 key_source = http://debian.datastax.com/debian/repo_key;, 
 include_src = false
 }
 }


 When I try to apply it, I get:

 # puppet apply nodes.pp
 err: Could not apply complete catalog: Found 1 dependency cycle:
 (Anchor[apt::key B999A372 present] = Apt::Key[Add key: B999A372 from 
 Apt::Source cassandra] = File[cassandra.list] = Exec[apt_update] = 
 Class[Apt::Update] = Stage[setup] = Stage[main] = Class[Main] = 
 Node[default] = Apt::Source[cassandra] = File[cassandra.list])
 Try the '--graph' option and opening the resulting '.dot' file in 
 OmniGraffle or GraphViz
 notice: Finished catalog run in 0.12 seconds


 The problem seems to be in the stage = 'setup' parameter, but I'd like 
 to understand what's going on and what can I do to solve this issue (this 
 is just a proof of concept of what's going on in the larger puppet codebase 
 I've inherited). 

 I'm using Puppet 2.7.20.



 I'd need to see the code of your class apt to be sure, but you are 
 probably running into http://projects.puppetlabs.com/issues/8263.  If 
 that's so, then the solution is to either use ordinary relationships 
 instead of run stages, or to update your class(es) to propagate the run 
 stage assigned to them to classes they themselves declare (where it is 
 appropriate to do so).  The $stage magic variable can help you do that.


 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: hiera_hash lookups for included classes?

2013-03-15 Thread jcbollinger


On Thursday, March 14, 2013 3:39:41 PM UTC-5, Ellison Marks wrote:

 I'm pretty sure it does do merging, in the yaml backend at least.

 case resolution_type
 ...
 when :hash
 raise Exception, Hiera type mismatch: expected Hash and got 
 #{new_answer.class} unless new_answer.kind_of? Hash
 answer ||= {}
 answer = new_answer.merge answer



Never mind.  I somehow got a totally wrong idea of what hiera_hash() does.  
I probably formed it by analogy with hiera_array(), but in fact they aren't 
very analogous in that hiera_array() gives you all the data in your 
hierarchy, whereas hiera_hash() gives you a digested form.  It looks like 
it does merge (but only shallowly until 1.2).

I got another surprise when studying the code, too: hiera_array() is much 
less general than I thought.  It collects only String and Array values, not 
numeric, boolean, or hash values.  It raises an exception if any of the 
collected values for the give key is of any of the latter types, and it is 
not clear to me why.


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: PuppetDB Constraint error

2013-03-15 Thread jcbollinger


On Thursday, March 14, 2013 4:51:25 PM UTC-5, Ken Barber wrote:

 Hey all, 

 I'm hoping I can get some information from other users on the list in 
 relationship ak0ska's problem listed below. I thought I would start a 
 new thread so more users would see this message and not loose it in 
 the original thread which is already pretty long: 


 https://groups.google.com/forum/?fromgroups=#!topic/puppet-users/yRMI1J_y6Ps 

 Basically I want to see if anyone is seeing the same constraint errors 
 at all in your postgresql log: 


I'm not seeing the errors, but I attached an analysis to your gist.

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: hiera_hash lookups for included classes?

2013-03-15 Thread Ellison Marks
The difference between array and hash resolution makes sense, from a 
certain perspective. As an array is fine with holding duplicate values, it 
just gets all the data and flattens it down, but since a hash needs unique 
keys, to return a fairly flat hash, it can only take one value for each 
key, and prefers the more specific.

The string and array restriction is quite odd though, looking at it now...

On Friday, March 15, 2013 8:28:56 AM UTC-7, jcbollinger wrote:



 On Thursday, March 14, 2013 3:39:41 PM UTC-5, Ellison Marks wrote:

 I'm pretty sure it does do merging, in the yaml backend at least.

 case resolution_type
 ...
 when :hash
 raise Exception, Hiera type mismatch: expected Hash and got 
 #{new_answer.class} unless new_answer.kind_of? Hash
 answer ||= {}
 answer = new_answer.merge answer



 Never mind.  I somehow got a totally wrong idea of what hiera_hash() 
 does.  I probably formed it by analogy with hiera_array(), but in fact they 
 aren't very analogous in that hiera_array() gives you all the data in your 
 hierarchy, whereas hiera_hash() gives you a digested form.  It looks like 
 it does merge (but only shallowly until 1.2).

 I got another surprise when studying the code, too: hiera_array() is much 
 less general than I thought.  It collects only String and Array values, not 
 numeric, boolean, or hash values.  It raises an exception if any of the 
 collected values for the give key is of any of the latter types, and it is 
 not clear to me why.


 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: how puppet restart a service

2013-03-15 Thread Ellison Marks
You don't need the restart command there. When you say hasrestart = 
true, you're telling puppet that the init script has a restart command, so 
it's going to call /sbin/service lighttpd restart anyway. If you say 
hasrestart = false, the default is to do a service lighttpd stop  
service lighttpd start. The restart parameter is for specifying the 
command to restart the service if it isn't handled by the init script and 
you want something more complicated than the default.

On Friday, March 15, 2013 12:06:02 AM UTC-7, 陈士超 wrote:

 i do like this:
 service{
 lighttpd:
 hasrestart = true,
 hasstatus = true,
 restart = /sbin/service lighttpd restart,
 }

 But it dose not work


-- 
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: Installing a tarball using Puppet

2013-03-15 Thread Len Rugen
For example:

file {/usr/local/src/suphp-0.7.1.tar.gz:
owner   = root,
group   = root,
mode= 0775,
ensure  = present,
source  = puppet:///modules/lamp/suphp-0.7.1.tar.gz,
notify  = Exec[unpack suphp]
}

exec { unpack suphp:
command = tar xf /usr/local/src/suphp-0.7.1.tar.gz 
chown -R root:root /usr/local/src/suphp-0.7.1*,
cwd = /usr/local/src,
refreshonly = true,
notify  = Exec[install suphp]
}

exec { install suphp:
cwd = /usr/local/src/suphp-0.7.1,
command = /usr/local/src/suphp-0.7.1/configure
--prefix=/usr --sysconfdir=/etc --with-apr=/usr/bin/apr-1-config  make 
make install,
logoutput   = true,
refreshonly = true,
}


On Fri, Mar 15, 2013 at 7:38 AM, llowder llowde...@gmail.com wrote:



 On Thursday, March 14, 2013 5:28:49 PM UTC-5, joe wrote:

 What llowder said. But he meant fpm, not fom:

 https://github.com/**jordansissel/fpmhttps://github.com/jordansissel/fpm


 Indeed, sorry about that. Too much blood in the caffeine stream as I typed.


 On Thursday, March 14, 2013 3:40:20 PM UTC-6, llowder wrote:



 On Thursday, March 14, 2013 1:20:39 PM UTC-5, ridha gadhgadhi wrote:

 Hi all,

 I want to install opensaf from a tar file. Below, the content of my
 script shell:

 --**--**
 ---
 tar -xvf opensaf
 cd opensaf
 ./configure --disable-tipc
 make
 make install
 --**--**
 

 Any help will be much appreciated !


 You have 2 options. You can put what you did above in a shell script,
 and thenuse a file to push the tarball and the shell script, then exec to
 run the script.

 The BETTER option is to use fom or whatever and build a package (rpm,
 deb, whatever) and then install that using a package resource from a local
 repo.


 Regards,

 --Ridha

  --
 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: Installing a tarball using Puppet

2013-03-15 Thread ridha gadhgadhi
Thank you very much to everyone. It is very useful.
Sincerely,

- Ridha

On Thursday, March 14, 2013 2:20:39 PM UTC-4, ridha gadhgadhi wrote:

 Hi all,

 I want to install opensaf from a tar file. Below, the content of my script 
 shell:

 ---
 tar -xvf opensaf
 cd opensaf 
 ./configure --disable-tipc
 make
 make install

 

 Any help will be much appreciated !

 Regards,

 --Ridha


-- 
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: Custom ensure instead of ensurable in type provider

2013-03-15 Thread Stefan Schulte
On Wed, 13 Mar 2013 09:00:18 -0700 (PDT)
jcbollinger john.bollin...@stjude.org wrote:
 Your problem is that you are conflating distinct (for your purposes) 
 aspects of your resource's state.  If you care at times whether the 
 variable is declared at all or not, and at other times what its value
 is, then those should be separate properties.  Your resource
 declarations will then look like this:
 
 env_var { 'AWESOMENESS':
   value = 'meh',
   # optional:
   ensure = present
 }
 
 or
 
 env_var { 'AWESOMENESS':
   ensure = absent
 }
 
 
 John
 

I tend to disagree here. If the presence of an environment variable
inherently means that it has a value and the absence of a value
inherently means that the resource is absent I don't see the point in
having two properties.

I'd suggest to not use ensurable and define the ensure property
yourself:

in your type:

newproperty(:ensure) do
  newvalues :absent
  newvalues /.*/ # or whatever is valid for a value
end

in your provider, drop exists?, create and destroy and use

def ensure
  if value = get_environment_variable(resource[:name])
value
  else
:absent
  end
end

def ensure=(new_value)
  if new_value == :absent
destroy_environment_variable(resource[:name])
  else
set_environment_variable(resource[:name], new_value)
  end
end

you can then either specify

env_var { 'TMP':
  ensure = 'C:\TEMP'
}

or
env_var { 'TMP':
  ensure = absent,
}

-Stefan

-- 
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: Custom ensure instead of ensurable in type provider

2013-03-15 Thread Rich Siegel
Can you publish your work on github.   I might be able to help it along.  

-- 
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: Copying a 900 mb file to Windows !!!

2013-03-15 Thread Rich Siegel

  exec { 'dlfile':
command   = '. X:\tools\Get-WebFile.ps1 ; get-webfile 
http://myurl.com/file.zip c:\file.zip',
provider  = powershell
  }

I am using the poweshell provider by Josh Cooper and get-webfile is on 
http://poshcode.com/3920

Tweak line 134 from 4096 to 1048576 to make it go a ton faster. Obviously you 
can deploy the script via a separate file resource. 

-- 
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] how puppet restart a service

2013-03-15 Thread 尹川51web
you could try exec type,
http://docs.puppetlabs.com/references/2.7.latest/type.html#exec
or MColletive  http://docs.puppetlabs.com/mcollective


On Fri, Mar 15, 2013 at 3:06 PM, 陈士超 cschy2...@gmail.com wrote:

 i do like this:
 service{
 lighttpd:
 hasrestart = true,
 hasstatus = true,
 restart = /sbin/service lighttpd restart,
 }

 But it dose not work

 --
 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.






-- 
尹川
成都世纪东方网络通信有限公司
手机:18628014224
QQ:254113859

-- 
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] Using custom facts in reports

2013-03-15 Thread KT
Hello,

I am trying to utilize custom facts in a puppet report but can't seem to 
find a way of doing it.
As far as I know, there isn't a built in way to access custom facts inside 
a report but I also haven't been able to find any workarounds either.
Does anyone know if there is a way of doing this?

So far I've tried a system call to `facter -p` (with and without specifying 
the LOAD_PATH env variable) inside the report, but wasn't able to get 
anything other than the normal facts.

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] One Dashboard for Multiple Masters

2013-03-15 Thread Nathan Long
I'm trying to connect multiple masters to one dashboard and I'm having 
trouble with Facter. I started out initially with one master connected to 
the dashboard and that one works perfectly fine. Then I added a second 
master by setting the reporturl to point to the dashboard. The new nodes 
appeared and it shows the run results without any problems. The issue I'm 
having is when I try to look at the facts all I have is an error saying Could 
not retrieve facts from inventory service: 404 Could not find facts 
.domain where xxx.domain is my actual hostname. I know facter works 
because on the second puppet master I can run a puppet facts find command 
and pull the facts about the machine. Has anybody else attempted this 
before and run into this problem?

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] Installing puppet modules

2013-03-15 Thread Mike Power
I want to setup a node using a three step process
1) download node requirements (git)
2) download modules to fit requirements (puppet)
3) Bring up the node in the required state (puppet)

The second step is the one I am having trouble with.  I want a file 
(master.pp) to list out all the modules and what versions are needed before 
applying the site.pp file.  From what I have been able to find there are 
two possible approaches.

1) Use some module to download and unzip tars.  In this master.pp file use 
the module to download the other modules from urls and extract them in the 
module path.  The problem I have is that I cannot figure out how to get the 
modulepath in the master.pp file and parse it such that I can extract the 
tars in the right location.  I tried something like:
archive {$file:
ensure  = present,
url = $url,
checksum= false,
extension   = tar.gz,
target  = split($::modulepath, :)[0],
}

But that doesn't work.  


2) There is another module called puppet_module 
(https://github.com/rcoleman/puppet_module_provider) which allows you to 
download and install modules from puppetforge.  This module works great.  
Except that I need to download modules from an intranet location not an 
internet location. I do not have control over puppetforge so I do not have 
control over how long stuff stays up there, when it changes etc.  I need to 
house the modules on a local file store such that as we make the decision 
to upgrade we can do those upgrades other then that the modules will always 
remain available.  The puppet_module (reading the source code) does have a 
source parameter.  I assume then you could point it at something other than 
puppetforge.  But it is not documented and I am not sure I can easily 
produce a in house puppet forge that would have the needed filesystem 
layout for puppet_module to work.

Have other people looked into this problem?  What have they come up with?

-- 
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] advice on module organization

2013-03-15 Thread supertom
Hi Folks,

Like to get some advice on module organization.  I have a system that has a 
few different components.  One or more components can be installed on a 
host.  The hosts also have a type dimension.  This type dimension could 
(should) ideally be used to configure the system (fill in a bunch of 
variables).  Problem is, I'm not sure how the best way to do this in puppet.

I'm running puppet 2.7x.

To illustrate, I'd like to do something like this (pseudo syntax):

node 'foo.example.com' {
include module::component(systemType = foobar)
include module::component2(systemType = foobar)
}

node 'foo2.example.com' {
include module::component(systemType = foobar2)
include module::component3(systemType = foobar2)
}

or, maybe even better

node 'foo.example.com' {
include module(components = [component1,component2], systemType = 
foobar)
}

node 'foo2.example.com' {
include module(components = [component1,component3], systemType = 
foobar2)
}

In the above illustration, the value of componentType can determine which 
files to load, as well as a bunch of variables (40-60 variables) which 
would be used for things like ensuring directories are present, ownership, 
users installed, etc..

I was thinking that each component would be a class, which is fine in 
itself, but my real problem is the movement of these variables 
(configuration).  There are a lot of components, and enough variables that 
I don't want to add them to each class.  I want to be able to do something 
like:

class mymodule(components, componentType) {
$myconfig = getConfig($componentType)
# can I loop through components?
include mymodule::component($myconfig)
}

Hopefully that's descriptive enough.  Feel free to ask questions.   
Ultimately, my major goal is to boil the configuration down to a single 
location, as the configurations (systemTypes).  Some like this would work 
(I think) if calling the class could be dynamic:
http://docs.puppetlabs.com/guides/parameterized_classes.html#appendix-smart-parameter-defaults

Thanks in advance for the feedback,

Tom

-- 
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] Installing module of the correct version

2013-03-15 Thread Mike Power
I want to install a module into the modulepath.  I can provide either a 
http url to a tar that contains the modules (like puppetforge but the path 
is not as structured) or I could provide a git url and path under that url 
where the module is.

I want to first run puppet standalone on the vagrant vm host.  This should 
download the appropriate modules and make them available on the filesystem 
in the modulepath.  Then I'll stand up a vm and have puppet run standalone 
on the vm using the modules to setup the vm.  

I was looking at two different solutions. 

1) using some sort of archive module to download and extract the module 
(like: http://forge.puppetlabs.com/mthibaut/archive).  The problem being 
puppet requires all paths to be absolute.  I would like to be able to hack 
apart the modulepath configuration in the manifest file.  But I have no 
idea how to do that.  I was trying something like:
archive {$filename:
ensure  = present,
url = $url,
checksum= false,
extension   = tar.gz,
target  = split($::modulepath, :)[0] + /modules/,
}

But obviously I am a bit out of my league getting that to work.

2) Using the puppet module 
provider(https://github.com/rcoleman/puppet_module_provider) to download 
and install a module.  This works great... if the module is on puppet 
forge.  But I need to keep the connections local, for connectivity outages 
and backups in case third party modules disappear from their place on the 
internet.  Also internal modules are  not going to make it out to the 
forge.  I see in the code something about a source.  But it seems that 
would point to some root folder on the web server and expect a certain 
structure underneath that folder.  I am not sure what the folder is and I 
am even less sure that I could produce it in house.


Have people solved this problem?  What has been their approach?

Mike Power

-- 
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] run puppet master with apache , why no module include in catalog ?

2013-03-15 Thread 朱秀龙
First I run puppet master with default webserver webrick, and it work well, 
I have a test module, and when I make any changes to this module, when 
executing puppet agent the system can make corresponding changes.
But when I migrate puppet master from webrick to apache, after changing the 
test module, and run puppet agent , puppet agent don't notice the module 
change, and don't do any change to system, but no error occured. 

I checked the catalog after running puppet agent, when with webrick, the 
catalog inlcude module information as expected, but with apache, the 
catalog don't include any module at all.

Where is the problem? 

-- 
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] ldapmodfiy via exec

2013-03-15 Thread geoff
For followers of this thread, I've started to create a puppet ldap dn 
resource which might help here: https://github.com/gtmtechltd/puppet_ldapdn


On Thursday, November 13, 2008 5:41:14 PM UTC, Russell Miller wrote:

 On Thu, Nov 13, 2008 at 8:55 AM, jbo...@gmail.com javascript: 
 jbo...@gmail.com javascript: wrote:


 I'm trying to execute an ldap modify command but have run into issues
 with multiple lines and can't seem to find a happy medium. Any ideas ?


 I just created a script that does all of the ldap server setup for me.  
 And just execed the script.

 --Russell 



-- 
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] Advice on module organization

2013-03-15 Thread Tom Melendez
Hi Folks,

Like to get some advice on module organization.  I have a system that
has a few different components.  One or more components can be
installed on a host.  The hosts also have a type dimension.  This
type dimension could (should) ideally be used to configure the
system (fill in a bunch of variables).  Problem is, I'm not sure how
the best way to do this in puppet.

I'm running puppet 2.7x.

To illustrate, I'd like to do something like this (pseudo syntax):

node 'foo.example.com' {
include module::component(systemType = foobar)
include module::component2(systemType = foobar)
}

node 'foo2.example.com' {
include module::component(systemType = foobar2)
include module::component3(systemType = foobar2)
}

or, maybe even better

node 'foo.example.com' {
include module(components = [component1,component2], systemType
= foobar)
}

node 'foo2.example.com' {
include module(components = [component1,component3], systemType
= foobar2)
}

In the above illustration, the value of componentType can determine
which files to load, as well as a bunch of variables (40-60 variables)
which would be used for things like ensuring directories are present,
ownership, users installed, etc..

I was thinking that each component would be a class, which is fine in
itself, but my real problem is the movement of these variables
(configuration).  There are a lot of components, and enough variables
that I don't want to add them to each class.  I want to be able to do
something like:

class mymodule(components, componentType) {
$myconfig = getConfig($componentType)
# can I loop through components?
include mymodule::component($myconfig)
}

Hopefully that's descriptive enough.  Feel free to ask questions.
Ultimately, my major goal is to boil the configuration down to a
single location, as the configurations (systemTypes).  Some like this
would work (I think) if calling the class could be dynamic:
http://docs.puppetlabs.com/guides/parameterized_classes.html#appendix-smart-parameter-defaults

Thanks in advance for the feedback,

Tom

-- 
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] issue while installing puppet

2013-03-15 Thread Dan White
The referenced issue enables the puppetlabs-devel repo for installation.  Did 
you try that ?

The “libaugeas.so...” comes from an RPM named augeas-libs

What does the command “yum list augeas-libs” return ?

rubygems (and the RPM of the same name) comes, I believe, from EPEL.
It sounds ike you do n ot have the proper combination of repositories.
What does the command “yum repolist” return ?

Are you using RHEL 6 or CentOS 6 ?  Or something else ?

On Mar 15, 2013, at 9:14 AM, Ripunjay Godhani wrote:

 Hi Heidi,
 
 Now We tried  to install the puppet and puppet-server packages from 
 puppetlabs, but we faced below discrepancy.
 
 Please look into this and let us know your suggestions because issue was not 
 found in Puppet community as well. There was 1 issue related to this but it 
 dint help us
 
  (http://projects.puppetlabs.com/issues/16634 )
 
 We went through 
 http://docs.puppetlabs.com/pe/latest/install_system_requirements.html  and 
 http://docs.puppetlabs.com/guides/installation.html
 
 Also went through Puppet community and could not find the solution for the 
 issue we are facing.
 
 Below is the detail summary of issue we are facing
 
 we have already enabled dependencies repo  from puppetlabs by running 
 following command but still facing issues
 
 rpm -ivh 
 http://yum.puppetlabs.com/el/6/products/x86_64/puppetlabs-release-6-6.noarch.rpm
 
 Below is the repo list
 
 [root@ ]# yum install -y puppet puppet-server
 Loaded plugins: product-id, security, subscription-manager
 Updating certificate-based repositories.
 Unable to read consumer identity
 This machine has not been registered and therefore has
 no access to security and other critical updates. Please
 register using subscription-manager.
  
 Setting up Install Process
 Resolving Dependencies
 -- Running transaction check
 --- Package puppet.noarch 0:3.1.1-1.el6 will be installed
 -- Processing Dependency: ruby = 1.8.7 for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: ruby(abi) = 1.8 for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: facter = 1.6.11 for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: hiera = 1.0.0 for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: ruby(selinux) for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: ruby-augeas for package: puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: /usr/bin/ruby for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: ruby-shadow for package: puppet-3.1.1-1.el6.noarch
 --- Package puppet-server.noarch 0:3.1.1-1.el6 will be installed
 -- Running transaction check
 --- Package facter.x86_64 1:1.6.18-1.el6 will be installed
 -- Processing Dependency: ruby = 1.8.5 for package: 
 1:facter-1.6.18-1.el6.x86_64
 -- Processing Dependency: ruby(abi) = 1.8 for package: 
 1:facter-1.6.18-1.el6.x86_64
 -- Processing Dependency: /usr/bin/ruby for package: 
 1:facter-1.6.18-1.el6.x86_64
 --- Package hiera.noarch 0:1.1.2-1.el6 will be installed
 -- Processing Dependency: ruby = 1.8.5 for package: hiera-1.1.2-1.el6.noarch
 -- Processing Dependency: ruby(abi) = 1.8 for package: 
 hiera-1.1.2-1.el6.noarch
 -- Processing Dependency: rubygem-json for package: hiera-1.1.2-1.el6.noarch
 --- Package puppet.noarch 0:3.1.1-1.el6 will be installed
 -- Processing Dependency: ruby = 1.8.7 for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: ruby(abi) = 1.8 for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: ruby(selinux) for package: 
 puppet-3.1.1-1.el6.noarch
 -- Processing Dependency: /usr/bin/ruby for package: 
 puppet-3.1.1-1.el6.noarch
 --- Package ruby-augeas.x86_64 0:0.4.1-1.el6 will be installed
 -- Processing Dependency: ruby(abi) = 1.8 for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: augeas-libs = 0.8.0 for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libaugeas.so.0(AUGEAS_0.1.0)(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libaugeas.so.0(AUGEAS_0.11.0)(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libaugeas.so.0(AUGEAS_0.10.0)(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libaugeas.so.0(AUGEAS_0.8.0)(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libaugeas.so.0(AUGEAS_0.12.0)(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libruby.so.1.8()(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 -- Processing Dependency: libaugeas.so.0()(64bit) for package: 
 ruby-augeas-0.4.1-1.el6.x86_64
 --- Package ruby-shadow.x86_64 0:1.4.1-13.el6 will be installed
 -- Processing Dependency: ruby(abi) = 1.8 for package: 
 ruby-shadow-1.4.1-13.el6.x86_64
 -- Processing Dependency: libruby.so.1.8()(64bit) for package: 
 ruby-shadow-1.4.1-13.el6.x86_64
 -- Running transaction check
 --- Package facter.x86_64 1:1.6.18-1.el6 will be installed
 -- Processing 

Re: [Puppet Users] how puppet restart a service

2013-03-15 Thread Dan White
Try this: 

service { lighttpd:
   ensure = running,
   enable = true,
   hasrestart = true,
   hasstatus  = true,
   restart= /sbin/service lighttpd restart,
}

The “enable” parameter enables the service to start at boot.
The “ensure” parameter ensures the service is running.

On Mar 15, 2013, at 5:56 AM, 尹川51web wrote:

 you could try exec 
 type,http://docs.puppetlabs.com/references/2.7.latest/type.html#exec
 or MColletive  http://docs.puppetlabs.com/mcollective
 
 
 On Fri, Mar 15, 2013 at 3:06 PM, 陈士超 cschy2...@gmail.com wrote:
 i do like this:
 service{
 lighttpd:
 hasrestart = true,
 hasstatus = true,
 restart = /sbin/service lighttpd restart,
 }
 
 But it dose not work

-- 
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] Host name lookup failure

2013-03-15 Thread Keith Burdis
The Puppet agent tries to connect to the master using the hostname 'puppet'
by default so one solution may be to add an /etc/hosts entry for 'puppet'
with the correct IP for your Puppet master:

* # echo “your puppet master ip puppet”  /etc/hosts*
*
*
For example:*
*

  # echo 10.0.67.1 puppet  /etc/hosts

If you are running the agent manually then you can specify the Puppet
master hostname/IP using the --server parameter - for example:

  # puppet agent --test --server 10.0.67.1

and on RHEL-like systems you can configure the Puppet master hostname for
the agent in /etc/sysconfig/puppet.

  - Keith



On 15 March 2013 09:16, yarlagadda ramya rams.15...@gmail.com wrote:

 Hi all,

 I installed puppet agent in one ip in linux..and am trying to connect to
 master while installing only..agent is getting installed but its giving
 host name look up failure..

 But i specified the correct host name only for the master for which it
 needs to be connected during installation..certificate is not getting
 generated..in it..

 In the master when am trying to see puppet cert list for requets..it is
 throwing the following error:
 err: Could not call list: header too long
 header too long


 Can any one pls help me with this?

 Regards,

 Ramya Y

 --
 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: Installing puppet modules

2013-03-15 Thread Ellison Marks
Unless you're using puppet apply, you don't download modules to the 
individual nodes, you download them to your master. The master uses the 
modules to compile a catalog which it then ships off to a node. Or in other 
words, I'm not sure what your question is. Why do your nodes need to 
download modules?

On Friday, March 15, 2013 9:24:36 AM UTC-7, Mike Power wrote:

 I want to setup a node using a three step process
 1) download node requirements (git)
 2) download modules to fit requirements (puppet)
 3) Bring up the node in the required state (puppet)

 The second step is the one I am having trouble with.  I want a file 
 (master.pp) to list out all the modules and what versions are needed before 
 applying the site.pp file.  From what I have been able to find there are 
 two possible approaches.

 1) Use some module to download and unzip tars.  In this master.pp file use 
 the module to download the other modules from urls and extract them in the 
 module path.  The problem I have is that I cannot figure out how to get the 
 modulepath in the master.pp file and parse it such that I can extract the 
 tars in the right location.  I tried something like:
 archive {$file:
 ensure  = present,
 url = $url,
 checksum= false,
 extension   = tar.gz,
 target  = split($::modulepath, :)[0],
 }

 But that doesn't work.  


 2) There is another module called puppet_module (
 https://github.com/rcoleman/puppet_module_provider) which allows you to 
 download and install modules from puppetforge.  This module works great.  
 Except that I need to download modules from an intranet location not an 
 internet location. I do not have control over puppetforge so I do not have 
 control over how long stuff stays up there, when it changes etc.  I need to 
 house the modules on a local file store such that as we make the decision 
 to upgrade we can do those upgrades other then that the modules will always 
 remain available.  The puppet_module (reading the source code) does have a 
 source parameter.  I assume then you could point it at something other than 
 puppetforge.  But it is not documented and I am not sure I can easily 
 produce a in house puppet forge that would have the needed filesystem 
 layout for puppet_module to work.

 Have other people looked into this problem?  What have they come up with?


-- 
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.