Next braindead question:

in your file resource you want the destination on the node to be 
/etc/puppet/modules/hello.txt.
Is the directory /etc/puppet/modules already present? (_on the node_ !!)

- Martin

On 01 Jul 2014, at 08:23, Satish Katuru <[email protected]> wrote:

> Yes It is.The file is available in the /modules/httd
> 
> On Monday, June 30, 2014 6:12:14 PM UTC+5:30, Martin Alfke wrote:
> Hi Brian, 
> 
> braindead question: 
> is a file with name hello in modules/httpd/files/ available?? 
> 
> - Martin 
> 
> 
> On 30 Jun 2014, at 14:06, Satish Katuru <[email protected]> wrote: 
> 
> > Hi Brain, 
> > 
> > Here is the detailed steps: 
> > 
> > 
> > Error: /Stage[main]/Httpd/File[/etc/puppet/modules/hello.txt]: Could not 
> > evaluate: Could not retrieve information from environment production 
> > source(s)puppet://dayrhetamp076.enterprisenet.org/modules/httpd/hello 
> > 
> > 
> > In Master Server it couldn't identify the path of the source file. 
> > 
> > 
> > Here are my nodes.pp,site.pp and init.pp 
> > 
> > node "dayrhetamp077.enterprisenet.org" 
> > { 
> > 
> > include httpd 
> > 
> > } 
> > --- 
> > 
> > import 'nodes.pp' 
> > $puppetserver = 'dayrhetamp076.enterprisenet.org' 
> > 
> > ---- 
> > 
> > class httpd 
> > { 
> > 
> > file 
> > { 
> > "/etc/puppet/modules/hello.txt": 
> > ensure => file, 
> > owner => "katusa02", 
> > group => "katusa02", 
> > mode => "0640", 
> > source =>"puppet://$puppetserver/modules/httpd/hello", 
> > 
> > } 
> > } 
> > 
> > And on the Agent Machine(*077) I have included below code in the config 
> > file 
> > 
> > certname = dayrhetamp077.enterprisenet.org 
> >       autosign = true 
> >       server = dayrhetamp076.enterprisenet.org 
> > 
> > ------ 
> > I folllowed all the steps 
> > a) Stopped Master process on Master machine 
> > b) Removed SSL folder and restarted Puppet Master Service 
> > c) Removed SSL folder from Agent Machine 
> > d) Executed the command sudo  puppet agent -t --waitforcert=60 (Certificate 
> > has been generated and singed) 
> > 
> > Please help me out to resolve this? 
> > 
> > Regards, 
> > Sathish. 
> > 
> > 
> > 
> > On Monday, June 30, 2014 12:33:32 PM UTC+5:30, Satish Katuru wrote: 
> > Hi Brian Mathis, 
> > 
> > I think no need to put 3 slashes after "puppet" because i have declared 
> > this variable in site.pp 
> > $server="..." . 
> > Event I tried with placing 3 slashes and it was throwing an error message. 
> > Am I missing any thing here? 
> > 
> > 
> > My site.pp : 
> > 
> > import 'nodes.pp' 
> > $puppetserver = 'dayrhetamp076.enterprisenet.org' 
> > 
> > and in the nodes.pp I have declared node. 
> > 
> > Regards, 
> > Sathish. 
> > 
> > 
> > 
> > 
> > On Friday, June 27, 2014 12:17:06 AM UTC+5:30, Brian Mathis wrote: 
> > Your "source" line needs 3 slashes after "puppet:" 
> >   source => "puppet:///$puppetserver/modules/httpd/ParserService-1.0.esb", 
> > 
> > 
> > ❧ Brian Mathis 
> > @orev 
> > 
> > 
> > On Thu, Jun 26, 2014 at 2:47 PM, Satish Katuru <[email protected]> wrote: 
> > Hi Brian Mathis, 
> > 
> > I tired to copy the jar files and Zip files from Master to agent machine 
> > but i am unable to do this. 
> > My init.pp looks like below: 
> > 
> > class httpd 
> > { 
> > 
> > 
> > file { 
> > "/home/katusa02/soa/jboss-soa-p-5/jboss-as/server/default/deploy/ParserService-1.0.esb":
> >  
> > ensure => present, 
> > owner => "katusa02", 
> > group => "katusa02", 
> > mode => "0777", 
> > source => "puppet://$puppetserver/modules/httpd/ParserService-1.0.esb", 
> > 
> > } 
> > 
> > } 
> > 
> > I tired with ensure => file and ensure =>"present" but didn't work. 
> > Can you please guide me how to do this? 
> > 
> > Moreover I got following error message: 
> > 
> > 
> > Error: 
> > /Stage[main]/Httpd/File[/home/katusa02/soa/jboss-soa-p-5/jboss-as/server/default/deploy/ParserService]:
> >  Could not evaluate: Could not retrieve information from environment 
> > production source(s) 
> > puppet://dayrhetamp076.enterprisenet.org/modules/httpd/ParserService 
> > 
> > Regards, 
> > Sathish. 
> > 
> > On Saturday, June 21, 2014 3:56:43 AM UTC+5:30, Brian Mathis wrote: 
> > Summary: Do not try to control processes directly with Puppet and instead 
> > properly integrate your service into your operating system. 
> > 
> > ----- 
> > 
> > It sounds like you are misunderstanding how Puppet integrates into the rest 
> > of the system.  Puppet should not "kill processes" directly like you would 
> > with the 'kill' command (actually, it can, but this is almost certainly NOT 
> > what you want).  I think you may also be misunderstanding some basic 
> > concepts of running a Linux/Unix server. 
> > 
> > A process is not the same thing as a service.  A single service may have 
> > many processes, and they are typically controlled by a script in the 
> > /etc/init.d directory (or maybe somewhere else if you are on a newfangled 
> > system running systemd).  If your process does not have a control script in 
> > /etc/init.d, then is is NOT a "service", it's just a process you happen to 
> > have running for a long time.  For Puppet to consider it a service, it must 
> > be controllable using the 'service' command (on RedHat based systems), or 
> > the equivalent for your version of Linux/Unix. 
> > 
> > What you really want is to be making and installing a bash script to 
> > control your java process in /etc/init.d.  Once written, you can use Puppet 
> > to install the script by using the "file" resource.  After you have that 
> > done, then you can use the "service" resource to control the service as you 
> > are tying to do.  The name of the service will be the name that you call 
> > your script in /etc/init.d, for example: /etc/init.d/my_service.  Please do 
> > not call your service "java", as it makes no sense to name a service after 
> > the programming language it is written in.  If it's an accounting system 
> > for example, call the service "accounting_system", or something like that. 
> > 
> > 
> > You are bound to get some other replies telling you how to use an 'exec' 
> > resource to call the "kill" command, etc..., since this is *possible* with 
> > Puppet, but it is grossly abusive of its capabilities and you really should 
> > not be doing that.  Please do this correctly by setting up your software as 
> > a real service and then control it correctly with the "service" resource in 
> > Puppet. 
> > 
> > I strongly suggest you walk through the Puppet tutorials at 
> > https://puppetlabs.com/learn before trying to control your own custom 
> > applications with it. 
> > 
> > 
> > ❧ Brian Mathis 
> > @orev 
> > 
> > 
> > On Fri, Jun 20, 2014 at 6:02 AM, Satish Katuru <[email protected]> wrote: 
> > Hi, 
> > 
> > I am new to Puppet and We are trying to stop and start any one of the 
> > services running on the Puppet master /agent machine. 
> > 
> > Here is the Scenario: 
> > 
> > 
> > 1. we have a Jboss service running on Puppet master and I am trying to kill 
> > this service thru puppet.(this service is runnning with my userid) 
> > 
> > Service name is "java". 
> > 
> > 2. In /etc/puppet/manifests/nodes.pp I have written code like this 
> > 
> > node "servername" 
> > { 
> > 
> > Service { 
> > 
> > "java": 
> > ensure = >"Stopped", 
> > 
> > } 
> > } 
> > 
> > after this I ran this command 
> > 
> > puppet apply nodes.pp 
> > 
> > Nothing has happend.Still the process is running.(I am able to see the 
> > process id : ps -ef|grep java) 
> > 
> > 3.After this i created a module and place this code in init.pp in 
> > /etc/puppet/modues/httpd/ 
> > 
> > node "servername" 
> > { 
> > inlcude httpd 
> > } 
> > 
> > puppet apply nodes.pp 
> > 
> > 
> > Nothing happend. 
> > 
> > Can you please guide us how to kill a process? 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > 
> > -- 
> > 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 [email protected]. 
> > 
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/puppet-users/c81e168e-38f0-416c-b0c2-bd0124c9e760%40googlegroups.com.
> >  
> > For more options, visit https://groups.google.com/d/optout. 
> > 
> > 
> > -- 
> > 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 [email protected]. 
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/puppet-users/2fc0d692-421c-4ea8-87d5-5ce229942e9b%40googlegroups.com.
> >  
> > 
> > For more options, visit https://groups.google.com/d/optout. 
> > 
> > 
> > -- 
> > 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 [email protected]. 
> > To view this discussion on the web visit 
> > https://groups.google.com/d/msgid/puppet-users/63906ca4-8493-4260-8683-120c2d3334af%40googlegroups.com.
> >  
> > For more options, visit https://groups.google.com/d/optout. 
> 
> 
> -- 
> 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 [email protected].
> To view this discussion on the web visit 
> https://groups.google.com/d/msgid/puppet-users/a69ea656-d176-476c-a8f0-bba7c7d31fc6%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/B3CCF91D-0DF7-4E04-92F3-D27305ECDB5A%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to