Thanks for the response. There doesn't seem to be another process updating
the files on before the puppet run. I believe the issue was the presence of
a dynamic tag on the template file.
The problem appears to be that the tag <%= @uptime_seconds %> was in some
of the configuration files. When I removed that tag from the apache config
files, and from the tomcat6 config files, there were no longer any updates
due to file changes.
The <%= @uptime_seconds %> appears to be set before execution of the puppet
run, which I didn't expect, since tags such as <%= @fqdn %> resolve on the
target agent node.
Does this sound correct?
if so, how do I know which tags or variables will be set before the puppet
execution, and which are set on the agent side after the catalog run?
On Wednesday, August 21, 2013 7:14:21 AM UTC-6, Rahul Khengare wrote:
>
> Hi Ed,
> Puppet execute their file resource only if contents of target file get
> changed at the before execution of puppet run.
> I checked your problem on RHEL-6.2 using puppet version 2.7.12, httpd.conf
> file not transferred each time if there is not change in the contents.
> You may have to check the contents of httpd.conf file before and running
> the puppet(use vimdiff command). There may possibility that httpd.conf file
> is edited by another service,
>
> Thanks and Regards,
> Rahul Khengare,
> NTT DATA OSS Center, Pune, India.
>
>
> On Tuesday, August 20, 2013 6:33:03 AM UTC+5:30, Ed Young wrote:
>>
>>
>> Despite no change in file (actually, template) content, with each catalog
>> run I get such log output as:
>>
>> Aug 19 20:49:50 app-dev puppet-agent[30132]:
>> (/Stage[main]/Apache-httpd/File[/etc/httpd/conf/httpd.conf]/content)
>> content changed '{md5}b8a5c22154e45771bc09ef5c34
>> [root@chimps-dev puppet]# service puppet restart
>> │603e7f' to
>> '{md5}14699f9c769a61cbc6cc5e2c2a7465ff'
>>
>> Which indicates that the file changed on the puppet master and so will be
>> updated on the agent.
>>
>> This happens consistently and results in a service restart when the files
>> are config files like httpd.conf.
>>
>> this is with puppet 2.6.18 on RHEL 6 (puppet master) and RHEL 5 (puppet
>> agent)
>>
>> Here is my init.pp in my apache module. Note that I'm using templates
>> only (nothing in my files directory)
>>
>> class apache-httpd {
>>
>> $moduleName = "apache-httpd"
>>
>> file { '/etc/httpd/conf/httpd.conf':
>> owner => "root",
>> group => "root",
>> mode => 0644,
>> ensure => 'file',
>> # source =>
>> 'puppet:///modules/apache-httpd/etc/httpd/conf/httpd.conf',
>> content => template('apache-httpd/etc/httpd/conf/httpd.conf.erb'),
>> }
>>
>> file { '/etc/httpd/conf.d/proxy_ajp.conf':
>> owner => "root",
>> group => "root",
>> mode => 0644,
>> ensure => 'file',
>> # source =>
>> 'puppet:///modules/apache-httpd/etc/httpd/conf.d/proxy_ajp.conf',
>> content =>
>> template('apache-httpd/etc/httpd/conf.d/proxy_ajp.conf.erb'),
>> }
>>
>> file { '/etc/httpd/conf.d/ssl.conf':
>> owner => "root",
>> group => "root",
>> mode => 0644,
>> ensure => 'file',
>> ## source =>
>> 'puppet:///modules/apache-httpd/etc/httpd/conf.d/ssl.conf',
>> content => template('apache-httpd/etc/httpd/conf.d/ssl.conf.erb'),
>> }
>>
>> }
>>
>
--
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 post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/puppet-users.
For more options, visit https://groups.google.com/groups/opt_out.