Hi, I have a big problem with Puppet and JBoss. In jboss/server/ directory, there are several instances. And instances started, +100000 files are presents. Puppetrun takes several hours to complete his cycle. tmp/ directory is ignore in file resource (ignore => [ ''tmp'', ''work'', ''data'', ''.git'', ''*puppet-bak'', ''*class'', ''*tld'', ''*jsp'' ],) but this directory is still processed. I don''t understand. How to reduced execution time ? Thx. -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/Z_sNqoE6xDcJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Budicom, One thing I might suggest is not to put the entire JBoss directory in puppet and realize it as a file resource. As gross as it is for a former employer I used the zip deployment and extracted the zip file. Disclaimer: No syntax checking, no validation YMMV, for example only. :) file { "$somepath/jboss-$version.zip": ensure => ''present'', source => $somewhere, } exec { "unzip-jboss-$version.zip": command => "unzip $somepath/jboss-$version.zip -q -d $someotherdir", requires => [ File["$somepath/jboss-$version.zip", Package[''zip''] ], } exec { "backup-jboss-$version-profiles": command => "mv $someotherdir/jboss-$version/server/ $someotherdir/jboss-$version/server.orig", creates => "$someotherdir/jboss-$version/server.orig", requires => "unzip-jboss-$version.zip", } class jboss::instance ( installdir = undef, profile = ''default'', ) { exec { "copy-jboss-profile-$name": command => "cp $installdir/jboss-$version/server.orig/$profile $installdir/jboss-$version/server/$name" creates => "$installdir/jboss-$version/server/$name" } # setup an init script # configure other instance properties w/ augeas/files } Campt to camp has a great "archive" installer you could cannibalize or perhaps use in its entirety. It didn''t quite work in my last situation but perhaps it would work for you. https://github.com/camptocamp/puppet-archive Regards, -Alan On Tue, Nov 6, 2012 at 7:30 AM, Budicom <ndutertre@geodisbm.com> wrote:> Hi, > > I have a big problem with Puppet and JBoss. > > In jboss/server/ directory, there are several instances. And instances > started, +100000 files are presents. > > Puppetrun takes several hours to complete his cycle. > > tmp/ directory is ignore in file resource (ignore => [ ''tmp'', ''work'', > ''data'', ''.git'', ''*puppet-bak'', ''*class'', ''*tld'', ''*jsp'' ],) but this > directory is still processed. > > I don''t understand. > > How to reduced execution time ? > > Thx. > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To view this discussion on the web visit > https://groups.google.com/d/msg/puppet-users/-/Z_sNqoE6xDcJ. > To post to this group, send email to puppet-users@googlegroups.com. > To unsubscribe from this group, send email to > puppet-users+unsubscribe@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/puppet-users?hl=en.-- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
On Tuesday, November 6, 2012 8:30:53 AM UTC-6, Budicom wrote:> > Hi, > > I have a big problem with Puppet and JBoss. > > In jboss/server/ directory, there are several instances. And instances > started, +100000 files are presents. > > Puppetrun takes several hours to complete his cycle. > > tmp/ directory is ignore in file resource (ignore => [ ''tmp'', ''work'', > ''data'', ''.git'', ''*puppet-bak'', ''*class'', ''*tld'', ''*jsp'' ],) but this > directory is still processed. > > I don''t understand. >You didn''t say anything about what resources Puppet is actually managing, and that makes a big difference. Nevertheless, it sounds like probably you have it managing part or all of one or more JBoss instance directories, as recursive files. That will be very costly (which is why I suppose it''s what you are doing). On each run, Puppet checks every managed file individually to see whether it is up-to-date, and when you set up recursive management that can be a lot of files. Cost scales both with the total number of files and with the aggregate size of the files.> > How to reduced execution time ? > >Avoid recursively managing directories, especially directories containing many files, large files, or both. Prefer to install software and even data via your system''s native package manager (yum / apt / whatever), even if it means rolling your own packages and keeping them in a local repository (neither of which is all that hard). Where packages are unsuitable for some reason, approximate them by packing up your big directories into tarballs or other archive files, managing those as individual files, and installing from from them at need. For borderline cases, you may be able to achieve some speedup by switching your expensive File resources to a cheaper checksum method, or otherwise tweaking the File parameters, but the case you describe is far beyond borderline. John -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/36_Z36AHf9oJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Sorry for the top posting. So, configuration and package management are different problem: trying to solve a problem with a tool born for solving the other problem can have, in the short or long run, some issue. Ymmv, as everyone else. Best 2012/11/6, Alan Evans <alanwevans@gmail.com>:> Budicom, > > One thing I might suggest is not to put the entire JBoss directory in > puppet and realize it as a file resource. As gross as it is for a > former employer I used the zip deployment and extracted the zip file. > > Disclaimer: No syntax checking, no validation YMMV, for example only. :) > > file { "$somepath/jboss-$version.zip": > ensure => ''present'', > source => $somewhere, > } > > exec { "unzip-jboss-$version.zip": > command => "unzip $somepath/jboss-$version.zip -q -d $someotherdir", > requires => [ File["$somepath/jboss-$version.zip", Package[''zip''] ], > } > > exec { "backup-jboss-$version-profiles": > command => "mv $someotherdir/jboss-$version/server/ > $someotherdir/jboss-$version/server.orig", > creates => "$someotherdir/jboss-$version/server.orig", > requires => "unzip-jboss-$version.zip", > } > > class jboss::instance ( > installdir = undef, > profile = ''default'', > ) { > exec { "copy-jboss-profile-$name": > command => "cp $installdir/jboss-$version/server.orig/$profile > $installdir/jboss-$version/server/$name" > creates => "$installdir/jboss-$version/server/$name" > } > > # setup an init script > # configure other instance properties w/ augeas/files > } > > Campt to camp has a great "archive" installer you could cannibalize or > perhaps use in its entirety. It didn''t quite work in my last > situation but perhaps it would work for you. > > https://github.com/camptocamp/puppet-archive > > Regards, > -Alan > > > On Tue, Nov 6, 2012 at 7:30 AM, Budicom <ndutertre@geodisbm.com> wrote: >> Hi, >> >> I have a big problem with Puppet and JBoss. >> >> In jboss/server/ directory, there are several instances. And instances >> started, +100000 files are presents. >> >> Puppetrun takes several hours to complete his cycle. >> >> tmp/ directory is ignore in file resource (ignore => [ ''tmp'', ''work'', >> ''data'', ''.git'', ''*puppet-bak'', ''*class'', ''*tld'', ''*jsp'' ],) but this >> directory is still processed. >> >> I don''t understand. >> >> How to reduced execution time ? >> >> Thx. >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Puppet Users" group. >> To view this discussion on the web visit >> https://groups.google.com/d/msg/puppet-users/-/Z_sNqoE6xDcJ. >> To post to this group, send email to puppet-users@googlegroups.com. >> To unsubscribe from this group, send email to >> puppet-users+unsubscribe@googlegroups.com. >> For more options, visit this group at >> http://groups.google.com/group/puppet-users?hl=en. > > -- > You received this message because you are subscribed to the Google Groups > "Puppet Users" group. > To post to this group, send email to puppet-users@googlegroups.com. > To unsubscribe from this group, send email to > puppet-users+unsubscribe@googlegroups.com. > For more options, visit this group at > http://groups.google.com/group/puppet-users?hl=en. > >-- Inviato dal mio dispositivo mobile -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
Budicom I had the same problem with JBoss, and (following advice I read on this group) looked into creating my own deb. It turned out to be amazingly straightforward using a bit of software that''s been discussed on here before (fpm: https://github.com/jordansissel/fpm). I now have my own deb installers (created by fpm) for JBoss and even the wars and ears that are deployed in jboss (that way you can manage the version numbers easily too). Give yourself a half day to get into fpm and you''ll never look back. James On Tuesday, November 6, 2012 11:09:17 PM UTC, yersinia.spiros wrote:> > Sorry for the top posting. > > So, configuration and package management are different problem: trying > to solve a problem with a tool born for solving the other problem can > have, in the short or long run, some issue. > Ymmv, as everyone else. > > > Best > > 2012/11/6, Alan Evans <alanw...@gmail.com <javascript:>>: > > Budicom, > > > > One thing I might suggest is not to put the entire JBoss directory in > > puppet and realize it as a file resource. As gross as it is for a > > former employer I used the zip deployment and extracted the zip file. > > > > Disclaimer: No syntax checking, no validation YMMV, for example only. :) > > > > file { "$somepath/jboss-$version.zip": > > ensure => ''present'', > > source => $somewhere, > > } > > > > exec { "unzip-jboss-$version.zip": > > command => "unzip $somepath/jboss-$version.zip -q -d $someotherdir", > > requires => [ File["$somepath/jboss-$version.zip", Package[''zip''] ], > > } > > > > exec { "backup-jboss-$version-profiles": > > command => "mv $someotherdir/jboss-$version/server/ > > $someotherdir/jboss-$version/server.orig", > > creates => "$someotherdir/jboss-$version/server.orig", > > requires => "unzip-jboss-$version.zip", > > } > > > > class jboss::instance ( > > installdir = undef, > > profile = ''default'', > > ) { > > exec { "copy-jboss-profile-$name": > > command => "cp $installdir/jboss-$version/server.orig/$profile > > $installdir/jboss-$version/server/$name" > > creates => "$installdir/jboss-$version/server/$name" > > } > > > > # setup an init script > > # configure other instance properties w/ augeas/files > > } > > > > Campt to camp has a great "archive" installer you could cannibalize or > > perhaps use in its entirety. It didn''t quite work in my last > > situation but perhaps it would work for you. > > > > https://github.com/camptocamp/puppet-archive > > > > Regards, > > -Alan > > > > > > On Tue, Nov 6, 2012 at 7:30 AM, Budicom <ndut...@geodisbm.com<javascript:>> > wrote: > >> Hi, > >> > >> I have a big problem with Puppet and JBoss. > >> > >> In jboss/server/ directory, there are several instances. And instances > >> started, +100000 files are presents. > >> > >> Puppetrun takes several hours to complete his cycle. > >> > >> tmp/ directory is ignore in file resource (ignore => [ ''tmp'', ''work'', > >> ''data'', ''.git'', ''*puppet-bak'', ''*class'', ''*tld'', ''*jsp'' ],) but this > >> directory is still processed. > >> > >> I don''t understand. > >> > >> How to reduced execution time ? > >> > >> Thx. > >> > >> -- > >> You received this message because you are subscribed to the Google > Groups > >> "Puppet Users" group. > >> To view this discussion on the web visit > >> https://groups.google.com/d/msg/puppet-users/-/Z_sNqoE6xDcJ. > >> To post to this group, send email to puppet...@googlegroups.com<javascript:>. > > >> To unsubscribe from this group, send email to > >> puppet-users...@googlegroups.com <javascript:>. > >> For more options, visit this group at > >> http://groups.google.com/group/puppet-users?hl=en. > > > > -- > > You received this message because you are subscribed to the Google > Groups > > "Puppet Users" group. > > To post to this group, send email to puppet...@googlegroups.com<javascript:>. > > > To unsubscribe from this group, send email to > > puppet-users...@googlegroups.com <javascript:>. > > For more options, visit this group at > > http://groups.google.com/group/puppet-users?hl=en. > > > > > > -- > Inviato dal mio dispositivo mobile >-- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/83joHbRaWFwJ. To post to this group, send email to puppet-users@googlegroups.com. To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.