hello list.. I am sharing a yum configuration in a class (centos.pp) between two nodes. But the yum configuration doesn''t apply at all to one node even tho it does to another identically configured node. ## packages are failing to install via yum on one ec2 aws instance and another identical ec2 instance works fine [root@kromep2 ~]# cat /etc/redhat-release CentOS release 5.5 (Final) ## machine info for the machine with errors [root@ec2-184-72-200-83 ~]# uname -a Linux ec2-184-72-200-83.compute-1.amazonaws.com 2.6.21.7-2.fc8xen #1 SMP Fri Feb 15 12:39:36 EST 2008 i686 i686 i386 GNU/Linux [root@ec2-184-72-200-83 ~]# puppetd -t info: Caching catalog for ec2-184-72-200-83.compute-1.amazonaws.com ## errors installing packages via yum info: //apache/Tidy[/etc/httpd/conf.d/ssl.conf]: File does not exist info: //centos/Tidy[/etc/yum.repos.d/CentOS-Media.repo]: File does not exist info: //centos/Tidy[/etc/yum.repos.d/CentOS.repo]: File does not exist info: Applying configuration version ''1300227365'' notice: //centos/Cron[runPuppet]/hour: defined ''hour'' as ''*'' notice: //centos/Cron[runPuppet]/weekday: defined ''weekday'' as ''*'' err: //apache/Package[php-mysql.i386]/ensure: change from absent to present failed: Could not find package php-mysql.i386 err: //apache/Package[php-mcrypt.i386]/ensure: change from absent to present failed: Could not find package php-mcrypt.i386 notice: //centos/Exec[/bin/rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt]/returns: executed successfully err: //apache/Package[php-common.i386]/ensure: change from absent to present failed: Could not find package php-common.i386 err: //apache/Package[php-cli.i386]/ensure: change from absent to present failed: Could not find package php-cli.i386 err: //apache/Package[php-mhash.i386]/ensure: change from absent to present failed: Could not find package php-mhash.i386 err: //apache/Package[php-gd.i386]/ensure: change from absent to present failed: Could not find package php-gd.i386 err: //apache/Package[php.i386]/ensure: change from absent to present failed: Could not find package php.i386 err: //apache/Package[php-xmlrpc.i386]/ensure: change from absent to present failed: Could not find package php-xmlrpc.i386 err: //apache/Service[httpd]/ensure: change from stopped to running failed: Could not start Service[httpd]: Execution of ''/sbin/service httpd start'' returned 1: at /etc/puppet/modules/apache/manifests/init.pp:177 err: //apache/Package[php-devel.i386]/ensure: change from absent to present failed: Could not find package php-devel.i386 err: //apache/Package[php-pdo.i386]/ensure: change from absent to present failed: Could not find package php-pdo.i386 err: //apache/Package[php-pear.noarch]/ensure: change from absent to present failed: Could not find package php-pear.noarch err: //apache/Package[php-soap.i386]/ensure: change from absent to present failed: Could not find package php-soap.i386 err: //apache/Package[php-xml.i386]/ensure: change from absent to present failed: Could not find package php-xml.i386 notice: Finished catalog run in 26.97 seconds ## packages install via yum on another identical ec2 cloud instance notice: //apache/Package[php-xmlrpc.i386]/ensure: created notice: //apache/Exec[create apache log dir]/returns: executed successfully notice: //baseapps/Package[koan]/ensure: created notice: //apache/Package[php-pear.noarch]/ensure: created ## this is the machine info on the machine that works [root@kromep2 ~]# cat /etc/redhat-release CentOS release 5.5 (Final) [root@kromep2 ~]# uname -a Linux kromep2 2.6.21.7-2.fc8xen #1 SMP Fri Feb 15 12:39:36 EST 2008 i686 athlon i386 GNU/Linux ## nodes.pp [root@puppet ~]# cat /etc/puppet/manifests/nodes.pp { .... node ''ec2-184-72-200-83.compute-1.amazonaws.com'' inherits webserver { ## <- packages don''t install here } node ''kromep2.acadaca.net'' inherits webserver { ## <- packages do install here } ... } ## these nodes both inherit a webserver class from /etc/puppet/manifests/classes/template.pp node basenode { case $operatingsystem { centos: { include centos } ubuntu: { include ubuntu } default: { include centos } } include baseapps, sshd } node default inherits basenode {} node webserver inherits basenode { include apache } node dbserver inherits basenode { include mysql } node mailserver inherits basenode { include postfix } ## /etc/puppet/manifests/os/centos.pp -- this is where the yum configuation is done class centos { include basefiles include baseapps exec { "create ssl dir": command => "/bin/mkdir /etc/ssl", creates => "/etc/ssl" } exec {"create amanda dir": command => "/bin/mkdir /etc/amanda", creates => "/etc/amanda" } exec {"create amanda home": command => "/bin/mkdir /var/lib/amanda", creates => "/var/lib/amanda" } exec { "/usr/bin/wget http://apt.sw.be/RPM-GPG-KEY.dag.txt": cwd => "/etc/pki/rpm-gpg/", creates => "/etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt", path => "/usr/bin" } exec { "/bin/rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt": cwd => "/etc/pki/rpm-gpg", require => Exec["/usr/bin/wget http://apt.sw.be/RPM-GPG-KEY.dag.txt"], path => "/bin" } cron { "runPuppet": command => "/usr/sbin/puppetd", user => root, weekday => ''*'', minute => "0", hour => ''*'' } tidy { "/etc/yum.repos.d/CentOS-Media.repo": age => ''0s'', } tidy { "/etc/yum.repos.d/CentOS.repo": age => ''0s'', } yumrepo { ''epel-testing'': mirrorlist => ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-epel5&arch=$basearch'', enabled => ''0'', failovermethod => ''priority'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', descr => ''Extra Packages for Enterprise Linux 5 - Testing - $basearch '' } yumrepo { ''epel-testing-debuginfo'': mirrorlist => ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-debug-epel5&arch=$basearch'', enabled => ''0'', failovermethod => ''priority'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', descr => ''Extra Packages for Enterprise Linux 5 - Testing - $basearch - Debug'' } yumrepo { ''epel-testing-source'': mirrorlist => ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-source-epel5&arch=$basearch'', enabled => ''0'', failovermethod => ''priority'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', descr => ''Extra Packages for Enterprise Linux 5 - Testing - $basearch - Source'' } yumrepo { ''rpmforge'': mirrorlist => '' http://apt.sw.be/redhat/el5/en/mirrors-rpmforge'', protect => '' 0'', enabled => '' 1'', gpgcheck => '' 1'', gpgkey => '' file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-dag'', descr => '' Red Hat Enterprise $releasever - RPMforge.net - dag'' } yumrepo { ''epel'': mirrorlist => ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch'', enabled => ''1'', failovermethod => ''priority'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', descr => ''Extra Packages for Enterprise Linux 5 - $basearch'' } yumrepo { ''epel-debuginfo'': mirrorlist => ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-5&arch=$basearch'', enabled => ''0'', failovermethod => ''priority'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', descr => ''Extra Packages for Enterprise Linux 5 - $basearch - Debug'' } yumrepo { ''epel-source'': mirrorlist => ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-5&arch=$basearch'', enabled => ''0'', failovermethod => ''priority'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', descr => ''Extra Packages for Enterprise Linux 5 - $basearch - Source'' } yumrepo { ''base'': mirrorlist => ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Base'' } yumrepo { ''updates'': mirrorlist => ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Updates'' } yumrepo { ''addons'': mirrorlist => ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addons'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Addons'' } yumrepo { ''extras'': mirrorlist => ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Extras'' } yumrepo { ''centosplus'': mirrorlist => ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus'', enabled => ''0'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Plus'' } yumrepo { ''contrib'': mirrorlist => ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib'', enabled => ''0'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Contrib'' } yumrepo { ''c5-media'': baseurl => ''file:///media/CentOS/ file:///media/cdrom/ file:///media/cdrecorder/'', enabled => ''0'', gpgcheck => ''1'', gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', descr => ''CentOS-$releasever - Media'' } yumrepo { ''scalr'': baseurl => ''http://rpm.scalr.net/rpm/rhel/$releasever/$basearch'', enabled => ''1'', gpgcheck => ''0'', descr => ''scalr'' } } ## /etc/puppet/modules/apache/manifests/init.pp.. this is where the majority of packages that I am trying to install are failing on the one node, yet succeeding on the other. class apache { $packagelist ["httpd.$architecture","httpd-devel.$architecture","webalizer.$architecture","php.$architecture","php-common.$architecture","php-devel.$architecture","php-xmlrpc.$architecture","php-gd.$architecture", "php-pear.noarch", "php-pdo.$architecture", "php-mcrypt.$architecture", "php-mhash.$architecture", "php-mysql.$architecture", "php-cli.$architecture", "php-soap.$architecture", "php-xml.$architecture", "mod_ssl.$architecture"] package { $packagelist: ensure => "installed" } exec { "create httpd dir": command => "/bin/mkdir -p /etc/httpd", creates => "/etc/httpd" } exec {"create apache module dir": command => "/bin/mkdir -p /usr/lib/httpd/modules", creates => "/usr/lib/httpd/modules/mod_file_cache.so" } exec { "create apache module link": command => "/bin/ln -s /usr/lib/httpd/modules /etc/httpd/modules", require => Exec["create apache module dir"], creates => "/etc/httpd/modules" } exec { "create apache log dir": command => "/bin/mkdir -p /var/log/httpd/logs", creates => "/var/log/httpd/logs" } exec { "create apache error log": command => "/bin/touch /etc/httpd/logs/error_log", require => Exec["create apache log dir"], creates => "/etc/httpd/logs/error_log" } exec { "create apache log link": command => "/bin/ln -s /var/log/httpd/logs /etc/httpd/logs", require => Exec["create apache log dir"], creates => "/etc/httpd/logs" } exec { "create apache run dir": command => "/bin/mkdir -p /var/run/httpd", creates => "/var/run/httpd" } exec { "create apache run link": command => "/bin/ln -s /var/run/httpd /etc/httpd/run", require => Exec["create apache log dir"], creates => "/etc/httpd/run" } exec { "create httpd conf dir": command => "/bin/mkdir -p /etc/httpd/conf.d", creates => "/etc/httpd/conf.d" } exec { "create httpd vhost conf dir": command => "/bin/mkdir -p /etc/httpd/conf", creates => "/etc/httpd/conf" } file { "/etc/php.ini": owner => root, group => root, mode => 440, source => "puppet:///apache/php.ini" } file { "/usr/lib/httpd/modules/mod_file_cache.so": owner => root, group => root, mode => 766, require => Exec["create apache module dir"], source => "puppet:///apache/krome/httpd/modules/mod_file_cache.so" } file { "/etc/httpd/conf/httpd.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf/httpd.conf" } file { "/usr/lib/httpd/modules/mod_auth_basic.so": owner => root, group => root, mode => 766, source => "puppet:///apache/krome/httpd/modules/mod_auth_basic.so" } file { "/etc/httpd/conf.d/000-ssl.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf.d/000-ssl.conf" } file { "/etc/httpd/conf.d/001-chrome-ssl.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf.d/001-chrome-ssl.conf" } file { "/etc/httpd/conf.d/002-chrome.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf.d/002-chrome.conf" } file { "/etc/httpd/conf.d/php.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf.d/php.conf" } file { "/etc/httpd/conf.d/proxy_ajp.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf.d/proxy_ajp.conf" } file { "/etc/httpd/conf.d/welcome.conf": owner => root, group => root, mode => 440, require => Exec["create httpd conf dir"], source => "puppet:///apache/krome/httpd/conf.d/welcome.conf" } tidy { "/etc/httpd/conf.d/ssl.conf": age => ''0s'', } service { "httpd": enable => "true", ensure => "running", hasrestart => "true", hasstatus => "true", require => [ Package["httpd.$architecture"], Tidy["/etc/httpd/conf.d/ssl.conf"] ] } } Thanks for your help! -- GPG me!! gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B -- 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.
to clarify the classes between the working and non-working machine seem identical ## problem node [root@ec2-184-72-200-83 ~]# cat /var/lib/puppet/classes.txt basenode centos basefiles baseapps sshd webserver apache ec2-184-72-200-83.compute-1.amazonaws.com ## working node [root@kromep2 ~]# cat /var/lib/puppet/classes.txt basenode centos basefiles baseapps sshd webserver apache kromep2.acadaca.net and the versions of puppet on each machine are identical and the fqdns of each machine match up with what I have in the nodes.pp file ## facter | grep fqdn of both hosts ec2-184-72-200-83.compute-1.amazonaws.com # <-- problem machine kromep2.acadaca.net # <-- working machine ## puppet versions puppet-0.25.5-1.el5 # <-- non working machine puppet-0.25.5-1.el5 # <-- working machine ## nodes node ''ec2-184-72-200-83.compute-1.amazonaws.com'' inherits webserver { include centos } node ''kromep2.acadaca.net'' inherits webserver { } thanks in advance and best regards! On Wed, Mar 16, 2011 at 10:52 AM, Tim Dunphy <bluethundr@gmail.com> wrote:> hello list.. > > I am sharing a yum configuration in a class (centos.pp) between two > nodes. But the yum configuration doesn''t apply at all to one node > even tho it does to another identically configured node. > > > ## packages are failing to install via yum on one ec2 aws instance and > another identical ec2 instance works fine > > [root@kromep2 ~]# cat /etc/redhat-release > CentOS release 5.5 (Final) > > ## machine info for the machine with errors > > [root@ec2-184-72-200-83 ~]# uname -a > Linux ec2-184-72-200-83.compute-1.amazonaws.com 2.6.21.7-2.fc8xen #1 > SMP Fri Feb 15 12:39:36 EST 2008 i686 i686 i386 GNU/Linux > > > [root@ec2-184-72-200-83 ~]# puppetd -t > info: Caching catalog for ec2-184-72-200-83.compute-1.amazonaws.com > > > ## errors installing packages via yum > > info: //apache/Tidy[/etc/httpd/conf.d/ssl.conf]: File does not exist > info: //centos/Tidy[/etc/yum.repos.d/CentOS-Media.repo]: File does not exist > > info: //centos/Tidy[/etc/yum.repos.d/CentOS.repo]: File does not exist > > info: Applying configuration version ''1300227365'' > > notice: //centos/Cron[runPuppet]/hour: defined ''hour'' as ''*'' > > notice: //centos/Cron[runPuppet]/weekday: defined ''weekday'' as ''*'' > > err: //apache/Package[php-mysql.i386]/ensure: change from absent to > present failed: Could not find package php-mysql.i386 > > err: //apache/Package[php-mcrypt.i386]/ensure: change from absent to > present failed: Could not find package php-mcrypt.i386 > > notice: //centos/Exec[/bin/rpm --import > /etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt]/returns: executed successfully > err: //apache/Package[php-common.i386]/ensure: change from absent to > present failed: Could not find package php-common.i386 > > err: //apache/Package[php-cli.i386]/ensure: change from absent to > present failed: Could not find package php-cli.i386 > > err: //apache/Package[php-mhash.i386]/ensure: change from absent to > present failed: Could not find package php-mhash.i386 > > err: //apache/Package[php-gd.i386]/ensure: change from absent to > present failed: Could not find package php-gd.i386 > > err: //apache/Package[php.i386]/ensure: change from absent to present > failed: Could not find package php.i386 > > err: //apache/Package[php-xmlrpc.i386]/ensure: change from absent to > present failed: Could not find package php-xmlrpc.i386 > > err: //apache/Service[httpd]/ensure: change from stopped to running > failed: Could not start Service[httpd]: Execution of ''/sbin/service > httpd start'' returned 1: at > /etc/puppet/modules/apache/manifests/init.pp:177 > > err: //apache/Package[php-devel.i386]/ensure: change from absent to > present failed: Could not find package php-devel.i386 > > err: //apache/Package[php-pdo.i386]/ensure: change from absent to > present failed: Could not find package php-pdo.i386 > > err: //apache/Package[php-pear.noarch]/ensure: change from absent to > present failed: Could not find package php-pear.noarch > > err: //apache/Package[php-soap.i386]/ensure: change from absent to > present failed: Could not find package php-soap.i386 > > err: //apache/Package[php-xml.i386]/ensure: change from absent to > present failed: Could not find package php-xml.i386 > > notice: Finished catalog run in 26.97 seconds > > ## packages install via yum on another identical ec2 cloud instance > > notice: //apache/Package[php-xmlrpc.i386]/ensure: created > notice: //apache/Exec[create apache log dir]/returns: executed successfully > notice: //baseapps/Package[koan]/ensure: created > notice: //apache/Package[php-pear.noarch]/ensure: created > > > ## this is the machine info on the machine that works > > [root@kromep2 ~]# cat /etc/redhat-release > CentOS release 5.5 (Final) > > [root@kromep2 ~]# uname -a > Linux kromep2 2.6.21.7-2.fc8xen #1 SMP Fri Feb 15 12:39:36 EST 2008 > i686 athlon i386 GNU/Linux > > > > > ## nodes.pp > > > [root@puppet ~]# cat /etc/puppet/manifests/nodes.pp > { > > .... > > node ''ec2-184-72-200-83.compute-1.amazonaws.com'' inherits webserver { > ## <- packages don''t install here > } > > > > node ''kromep2.acadaca.net'' inherits webserver { ## <- packages do install here > } > > > > ... > > } > > ## these nodes both inherit a webserver class from > /etc/puppet/manifests/classes/template.pp > > node basenode { > > case $operatingsystem { > centos: { include centos } > ubuntu: { include ubuntu } > default: { include centos } > } > include baseapps, sshd > } > > node default inherits basenode {} > node webserver inherits basenode { > include apache > } > > node dbserver inherits basenode { > include mysql > } > > node mailserver inherits basenode { > include postfix > } > > > > ## /etc/puppet/manifests/os/centos.pp -- this is where the yum > configuation is done > > class centos { > > include basefiles > include baseapps > > > exec { "create ssl dir": > command => "/bin/mkdir /etc/ssl", > creates => "/etc/ssl" > > } > > > exec {"create amanda dir": > command => "/bin/mkdir /etc/amanda", > creates => "/etc/amanda" > > } > > exec {"create amanda home": > command => "/bin/mkdir /var/lib/amanda", > creates => "/var/lib/amanda" > } > > > exec { "/usr/bin/wget http://apt.sw.be/RPM-GPG-KEY.dag.txt": > cwd => "/etc/pki/rpm-gpg/", > creates => "/etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt", > path => "/usr/bin" > } > > > exec { "/bin/rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt": > cwd => "/etc/pki/rpm-gpg", > require => Exec["/usr/bin/wget http://apt.sw.be/RPM-GPG-KEY.dag.txt"], > path => "/bin" > } > > cron { > "runPuppet": > command => "/usr/sbin/puppetd", > user => root, > weekday => ''*'', > minute => "0", > hour => ''*'' > > } > > > tidy { "/etc/yum.repos.d/CentOS-Media.repo": > age => ''0s'', > } > > tidy { "/etc/yum.repos.d/CentOS.repo": > age => ''0s'', > } > > yumrepo { ''epel-testing'': > mirrorlist => > ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-epel5&arch=$basearch'', > enabled => ''0'', > failovermethod => ''priority'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', > descr => ''Extra Packages for Enterprise Linux 5 - Testing - $basearch '' > } > yumrepo { ''epel-testing-debuginfo'': > mirrorlist => > ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-debug-epel5&arch=$basearch'', > enabled => ''0'', > failovermethod => ''priority'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', > descr => ''Extra Packages for Enterprise Linux 5 - Testing - > $basearch - Debug'' > } > yumrepo { ''epel-testing-source'': > mirrorlist => > ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-source-epel5&arch=$basearch'', > enabled => ''0'', > failovermethod => ''priority'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', > descr => ''Extra Packages for Enterprise Linux 5 - Testing - > $basearch - Source'' > } > yumrepo { ''rpmforge'': > mirrorlist => '' http://apt.sw.be/redhat/el5/en/mirrors-rpmforge'', > protect => '' 0'', > enabled => '' 1'', > gpgcheck => '' 1'', > gpgkey => '' file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-dag'', > descr => '' Red Hat Enterprise $releasever - RPMforge.net - dag'' > } > yumrepo { ''epel'': > mirrorlist => > ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch'', > enabled => ''1'', > failovermethod => ''priority'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', > descr => ''Extra Packages for Enterprise Linux 5 - $basearch'' > } > yumrepo { ''epel-debuginfo'': > mirrorlist => > ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-5&arch=$basearch'', > enabled => ''0'', > failovermethod => ''priority'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', > descr => ''Extra Packages for Enterprise Linux 5 - $basearch - Debug'' > } > yumrepo { ''epel-source'': > mirrorlist => > ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-5&arch=$basearch'', > enabled => ''0'', > failovermethod => ''priority'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', > descr => ''Extra Packages for Enterprise Linux 5 - $basearch - Source'' > } > yumrepo { ''base'': > mirrorlist => > ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Base'' > } > yumrepo { ''updates'': > mirrorlist => > ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Updates'' > } > yumrepo { ''addons'': > mirrorlist => > ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addons'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Addons'' > } > yumrepo { ''extras'': > mirrorlist => > ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Extras'' > } > yumrepo { ''centosplus'': > mirrorlist => > ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus'', > enabled => ''0'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Plus'' > } > yumrepo { ''contrib'': > mirrorlist => > ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib'', > enabled => ''0'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Contrib'' > } > yumrepo { ''c5-media'': > baseurl => ''file:///media/CentOS/ > file:///media/cdrom/ > file:///media/cdrecorder/'', > enabled => ''0'', > gpgcheck => ''1'', > gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', > descr => ''CentOS-$releasever - Media'' > } > yumrepo { ''scalr'': > baseurl => ''http://rpm.scalr.net/rpm/rhel/$releasever/$basearch'', > enabled => ''1'', > gpgcheck => ''0'', > descr => ''scalr'' > } > } > > > ## /etc/puppet/modules/apache/manifests/init.pp.. this is where the > majority of packages that I am trying to install are failing on the > one node, yet succeeding on the other. > > class apache { > > $packagelist > ["httpd.$architecture","httpd-devel.$architecture","webalizer.$architecture","php.$architecture","php-common.$architecture","php-devel.$architecture","php-xmlrpc.$architecture","php-gd.$architecture", > "php-pear.noarch", "php-pdo.$architecture", > "php-mcrypt.$architecture", "php-mhash.$architecture", > "php-mysql.$architecture", "php-cli.$architecture", > "php-soap.$architecture", "php-xml.$architecture", > "mod_ssl.$architecture"] > > package { $packagelist: > ensure => "installed" > } > > > > > exec { "create httpd dir": > command => "/bin/mkdir -p /etc/httpd", > creates => "/etc/httpd" > > } > > exec {"create apache module dir": > command => "/bin/mkdir -p /usr/lib/httpd/modules", > creates => "/usr/lib/httpd/modules/mod_file_cache.so" > } > > exec { "create apache module link": > command => "/bin/ln -s /usr/lib/httpd/modules /etc/httpd/modules", > require => Exec["create apache module dir"], > creates => "/etc/httpd/modules" > } > > exec { "create apache log dir": > command => "/bin/mkdir -p /var/log/httpd/logs", > creates => "/var/log/httpd/logs" > } > > > exec { "create apache error log": > command => "/bin/touch /etc/httpd/logs/error_log", > require => Exec["create apache log dir"], > creates => "/etc/httpd/logs/error_log" > } > > exec { "create apache log link": > command => "/bin/ln -s /var/log/httpd/logs /etc/httpd/logs", > require => Exec["create apache log dir"], > creates => "/etc/httpd/logs" > } > > > > exec { "create apache run dir": > command => "/bin/mkdir -p /var/run/httpd", > creates => "/var/run/httpd" > } > > > exec { "create apache run link": > command => "/bin/ln -s /var/run/httpd /etc/httpd/run", > require => Exec["create apache log dir"], > creates => "/etc/httpd/run" > } > > exec { "create httpd conf dir": > command => "/bin/mkdir -p /etc/httpd/conf.d", > creates => "/etc/httpd/conf.d" > > } > > > exec { "create httpd vhost conf dir": > command => "/bin/mkdir -p /etc/httpd/conf", > creates => "/etc/httpd/conf" > > } > > > file { "/etc/php.ini": > owner => root, > group => root, > mode => 440, > source => "puppet:///apache/php.ini" > } > > file { "/usr/lib/httpd/modules/mod_file_cache.so": > owner => root, > group => root, > mode => 766, > require => Exec["create apache module dir"], > source => "puppet:///apache/krome/httpd/modules/mod_file_cache.so" > } > > file { > "/etc/httpd/conf/httpd.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf/httpd.conf" > } > > > file { > "/usr/lib/httpd/modules/mod_auth_basic.so": > owner => root, > group => root, > mode => 766, > source => "puppet:///apache/krome/httpd/modules/mod_auth_basic.so" > } > > > > file { > "/etc/httpd/conf.d/000-ssl.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf.d/000-ssl.conf" > } > > file { > "/etc/httpd/conf.d/001-chrome-ssl.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf.d/001-chrome-ssl.conf" > } > > file { > "/etc/httpd/conf.d/002-chrome.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf.d/002-chrome.conf" > } > > file { > "/etc/httpd/conf.d/php.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf.d/php.conf" > } > > file { > "/etc/httpd/conf.d/proxy_ajp.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf.d/proxy_ajp.conf" > } > > > file { > "/etc/httpd/conf.d/welcome.conf": > owner => root, > group => root, > mode => 440, > require => Exec["create httpd conf dir"], > source => "puppet:///apache/krome/httpd/conf.d/welcome.conf" > } > > tidy { "/etc/httpd/conf.d/ssl.conf": > age => ''0s'', > } > > > > service { "httpd": > enable => "true", > ensure => "running", > hasrestart => "true", > hasstatus => "true", > require => [ Package["httpd.$architecture"], > Tidy["/etc/httpd/conf.d/ssl.conf"] ] > } > > } > > > Thanks for your help! > > -- > GPG me!! > > gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B >-- GPG me!! gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B -- 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.
First I would look to see if your repositories defined on the node are as you expect, then I would check your network can reach them, then I would issue the yum command manually to verify there are no other issues. If you run puppetd manually on the node with verbose and debug you''ll get a better idea what it is doing. Cheers, On 17/03/2011, at 2:47, Tim Dunphy <bluethundr@gmail.com> wrote:> to clarify the classes between the working and non-working machine > seem identical > > ## problem node > > > [root@ec2-184-72-200-83 ~]# cat /var/lib/puppet/classes.txt > basenode > centos > basefiles > baseapps > sshd > webserver > apache > ec2-184-72-200-83.compute-1.amazonaws.com > > > ## working node > > > [root@kromep2 ~]# cat /var/lib/puppet/classes.txt > basenode > centos > basefiles > baseapps > sshd > webserver > apache > kromep2.acadaca.net > > and the versions of puppet on each machine are identical and the fqdns > of each machine match up with what I have in the nodes.pp file > > ## facter | grep fqdn of both hosts > > ec2-184-72-200-83.compute-1.amazonaws.com # <-- problem machine > > kromep2.acadaca.net # <-- working machine > > > ## puppet versions > > puppet-0.25.5-1.el5 # <-- non working machine > puppet-0.25.5-1.el5 # <-- working machine > > > ## nodes > > > node ''ec2-184-72-200-83.compute-1.amazonaws.com'' inherits webserver { > include centos > } > > > node ''kromep2.acadaca.net'' inherits webserver { > } > > > thanks in advance and best regards! > > On Wed, Mar 16, 2011 at 10:52 AM, Tim Dunphy <bluethundr@gmail.com> wrote: >> hello list.. >> >> I am sharing a yum configuration in a class (centos.pp) between two >> nodes. But the yum configuration doesn''t apply at all to one node >> even tho it does to another identically configured node. >> >> >> ## packages are failing to install via yum on one ec2 aws instance and >> another identical ec2 instance works fine >> >> [root@kromep2 ~]# cat /etc/redhat-release >> CentOS release 5.5 (Final) >> >> ## machine info for the machine with errors >> >> [root@ec2-184-72-200-83 ~]# uname -a >> Linux ec2-184-72-200-83.compute-1.amazonaws.com 2.6.21.7-2.fc8xen #1 >> SMP Fri Feb 15 12:39:36 EST 2008 i686 i686 i386 GNU/Linux >> >> >> [root@ec2-184-72-200-83 ~]# puppetd -t >> info: Caching catalog for ec2-184-72-200-83.compute-1.amazonaws.com >> >> >> ## errors installing packages via yum >> >> info: //apache/Tidy[/etc/httpd/conf.d/ssl.conf]: File does not exist >> info: //centos/Tidy[/etc/yum.repos.d/CentOS-Media.repo]: File does not exist >> >> info: //centos/Tidy[/etc/yum.repos.d/CentOS.repo]: File does not exist >> >> info: Applying configuration version ''1300227365'' >> >> notice: //centos/Cron[runPuppet]/hour: defined ''hour'' as ''*'' >> >> notice: //centos/Cron[runPuppet]/weekday: defined ''weekday'' as ''*'' >> >> err: //apache/Package[php-mysql.i386]/ensure: change from absent to >> present failed: Could not find package php-mysql.i386 >> >> err: //apache/Package[php-mcrypt.i386]/ensure: change from absent to >> present failed: Could not find package php-mcrypt.i386 >> >> notice: //centos/Exec[/bin/rpm --import >> /etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt]/returns: executed successfully >> err: //apache/Package[php-common.i386]/ensure: change from absent to >> present failed: Could not find package php-common.i386 >> >> err: //apache/Package[php-cli.i386]/ensure: change from absent to >> present failed: Could not find package php-cli.i386 >> >> err: //apache/Package[php-mhash.i386]/ensure: change from absent to >> present failed: Could not find package php-mhash.i386 >> >> err: //apache/Package[php-gd.i386]/ensure: change from absent to >> present failed: Could not find package php-gd.i386 >> >> err: //apache/Package[php.i386]/ensure: change from absent to present >> failed: Could not find package php.i386 >> >> err: //apache/Package[php-xmlrpc.i386]/ensure: change from absent to >> present failed: Could not find package php-xmlrpc.i386 >> >> err: //apache/Service[httpd]/ensure: change from stopped to running >> failed: Could not start Service[httpd]: Execution of ''/sbin/service >> httpd start'' returned 1: at >> /etc/puppet/modules/apache/manifests/init.pp:177 >> >> err: //apache/Package[php-devel.i386]/ensure: change from absent to >> present failed: Could not find package php-devel.i386 >> >> err: //apache/Package[php-pdo.i386]/ensure: change from absent to >> present failed: Could not find package php-pdo.i386 >> >> err: //apache/Package[php-pear.noarch]/ensure: change from absent to >> present failed: Could not find package php-pear.noarch >> >> err: //apache/Package[php-soap.i386]/ensure: change from absent to >> present failed: Could not find package php-soap.i386 >> >> err: //apache/Package[php-xml.i386]/ensure: change from absent to >> present failed: Could not find package php-xml.i386 >> >> notice: Finished catalog run in 26.97 seconds >> >> ## packages install via yum on another identical ec2 cloud instance >> >> notice: //apache/Package[php-xmlrpc.i386]/ensure: created >> notice: //apache/Exec[create apache log dir]/returns: executed successfully >> notice: //baseapps/Package[koan]/ensure: created >> notice: //apache/Package[php-pear.noarch]/ensure: created >> >> >> ## this is the machine info on the machine that works >> >> [root@kromep2 ~]# cat /etc/redhat-release >> CentOS release 5.5 (Final) >> >> [root@kromep2 ~]# uname -a >> Linux kromep2 2.6.21.7-2.fc8xen #1 SMP Fri Feb 15 12:39:36 EST 2008 >> i686 athlon i386 GNU/Linux >> >> >> >> >> ## nodes.pp >> >> >> [root@puppet ~]# cat /etc/puppet/manifests/nodes.pp >> { >> >> .... >> >> node ''ec2-184-72-200-83.compute-1.amazonaws.com'' inherits webserver { >> ## <- packages don''t install here >> } >> >> >> >> node ''kromep2.acadaca.net'' inherits webserver { ## <- packages do install here >> } >> >> >> >> ... >> >> } >> >> ## these nodes both inherit a webserver class from >> /etc/puppet/manifests/classes/template.pp >> >> node basenode { >> >> case $operatingsystem { >> centos: { include centos } >> ubuntu: { include ubuntu } >> default: { include centos } >> } >> include baseapps, sshd >> } >> >> node default inherits basenode {} >> node webserver inherits basenode { >> include apache >> } >> >> node dbserver inherits basenode { >> include mysql >> } >> >> node mailserver inherits basenode { >> include postfix >> } >> >> >> >> ## /etc/puppet/manifests/os/centos.pp -- this is where the yum >> configuation is done >> >> class centos { >> >> include basefiles >> include baseapps >> >> >> exec { "create ssl dir": >> command => "/bin/mkdir /etc/ssl", >> creates => "/etc/ssl" >> >> } >> >> >> exec {"create amanda dir": >> command => "/bin/mkdir /etc/amanda", >> creates => "/etc/amanda" >> >> } >> >> exec {"create amanda home": >> command => "/bin/mkdir /var/lib/amanda", >> creates => "/var/lib/amanda" >> } >> >> >> exec { "/usr/bin/wget http://apt.sw.be/RPM-GPG-KEY.dag.txt": >> cwd => "/etc/pki/rpm-gpg/", >> creates => "/etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt", >> path => "/usr/bin" >> } >> >> >> exec { "/bin/rpm --import /etc/pki/rpm-gpg/RPM-GPG-KEY.dag.txt": >> cwd => "/etc/pki/rpm-gpg", >> require => Exec["/usr/bin/wget http://apt.sw.be/RPM-GPG-KEY.dag.txt"], >> path => "/bin" >> } >> >> cron { >> "runPuppet": >> command => "/usr/sbin/puppetd", >> user => root, >> weekday => ''*'', >> minute => "0", >> hour => ''*'' >> >> } >> >> >> tidy { "/etc/yum.repos.d/CentOS-Media.repo": >> age => ''0s'', >> } >> >> tidy { "/etc/yum.repos.d/CentOS.repo": >> age => ''0s'', >> } >> >> yumrepo { ''epel-testing'': >> mirrorlist => >> ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-epel5&arch=$basearch'', >> enabled => ''0'', >> failovermethod => ''priority'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', >> descr => ''Extra Packages for Enterprise Linux 5 - Testing - $basearch '' >> } >> yumrepo { ''epel-testing-debuginfo'': >> mirrorlist => >> ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-debug-epel5&arch=$basearch'', >> enabled => ''0'', >> failovermethod => ''priority'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', >> descr => ''Extra Packages for Enterprise Linux 5 - Testing - >> $basearch - Debug'' >> } >> yumrepo { ''epel-testing-source'': >> mirrorlist => >> ''http://mirrors.fedoraproject.org/mirrorlist?repo=testing-source-epel5&arch=$basearch'', >> enabled => ''0'', >> failovermethod => ''priority'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', >> descr => ''Extra Packages for Enterprise Linux 5 - Testing - >> $basearch - Source'' >> } >> yumrepo { ''rpmforge'': >> mirrorlist => '' http://apt.sw.be/redhat/el5/en/mirrors-rpmforge'', >> protect => '' 0'', >> enabled => '' 1'', >> gpgcheck => '' 1'', >> gpgkey => '' file:///etc/pki/rpm-gpg/RPM-GPG-KEY-rpmforge-dag'', >> descr => '' Red Hat Enterprise $releasever - RPMforge.net - dag'' >> } >> yumrepo { ''epel'': >> mirrorlist => >> ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-5&arch=$basearch'', >> enabled => ''1'', >> failovermethod => ''priority'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', >> descr => ''Extra Packages for Enterprise Linux 5 - $basearch'' >> } >> yumrepo { ''epel-debuginfo'': >> mirrorlist => >> ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-debug-5&arch=$basearch'', >> enabled => ''0'', >> failovermethod => ''priority'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', >> descr => ''Extra Packages for Enterprise Linux 5 - $basearch - Debug'' >> } >> yumrepo { ''epel-source'': >> mirrorlist => >> ''http://mirrors.fedoraproject.org/mirrorlist?repo=epel-source-5&arch=$basearch'', >> enabled => ''0'', >> failovermethod => ''priority'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL'', >> descr => ''Extra Packages for Enterprise Linux 5 - $basearch - Source'' >> } >> yumrepo { ''base'': >> mirrorlist => >> ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=os'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Base'' >> } >> yumrepo { ''updates'': >> mirrorlist => >> ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=updates'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Updates'' >> } >> yumrepo { ''addons'': >> mirrorlist => >> ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=addons'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Addons'' >> } >> yumrepo { ''extras'': >> mirrorlist => >> ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=extras'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Extras'' >> } >> yumrepo { ''centosplus'': >> mirrorlist => >> ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=centosplus'', >> enabled => ''0'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Plus'' >> } >> yumrepo { ''contrib'': >> mirrorlist => >> ''http://mirrorlist.centos.org/?release=$releasever&arch=$basearch&repo=contrib'', >> enabled => ''0'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Contrib'' >> } >> yumrepo { ''c5-media'': >> baseurl => ''file:///media/CentOS/ >> file:///media/cdrom/ >> file:///media/cdrecorder/'', >> enabled => ''0'', >> gpgcheck => ''1'', >> gpgkey => ''file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-5'', >> descr => ''CentOS-$releasever - Media'' >> } >> yumrepo { ''scalr'': >> baseurl => ''http://rpm.scalr.net/rpm/rhel/$releasever/$basearch'', >> enabled => ''1'', >> gpgcheck => ''0'', >> descr => ''scalr'' >> } >> } >> >> >> ## /etc/puppet/modules/apache/manifests/init.pp.. this is where the >> majority of packages that I am trying to install are failing on the >> one node, yet succeeding on the other. >> >> class apache { >> >> $packagelist >> ["httpd.$architecture","httpd-devel.$architecture","webalizer.$architecture","php.$architecture","php-common.$architecture","php-devel.$architecture","php-xmlrpc.$architecture","php-gd.$architecture", >> "php-pear.noarch", "php-pdo.$architecture", >> "php-mcrypt.$architecture", "php-mhash.$architecture", >> "php-mysql.$architecture", "php-cli.$architecture", >> "php-soap.$architecture", "php-xml.$architecture", >> "mod_ssl.$architecture"] >> >> package { $packagelist: >> ensure => "installed" >> } >> >> >> >> >> exec { "create httpd dir": >> command => "/bin/mkdir -p /etc/httpd", >> creates => "/etc/httpd" >> >> } >> >> exec {"create apache module dir": >> command => "/bin/mkdir -p /usr/lib/httpd/modules", >> creates => "/usr/lib/httpd/modules/mod_file_cache.so" >> } >> >> exec { "create apache module link": >> command => "/bin/ln -s /usr/lib/httpd/modules /etc/httpd/modules", >> require => Exec["create apache module dir"], >> creates => "/etc/httpd/modules" >> } >> >> exec { "create apache log dir": >> command => "/bin/mkdir -p /var/log/httpd/logs", >> creates => "/var/log/httpd/logs" >> } >> >> >> exec { "create apache error log": >> command => "/bin/touch /etc/httpd/logs/error_log", >> require => Exec["create apache log dir"], >> creates => "/etc/httpd/logs/error_log" >> } >> >> exec { "create apache log link": >> command => "/bin/ln -s /var/log/httpd/logs /etc/httpd/logs", >> require => Exec["create apache log dir"], >> creates => "/etc/httpd/logs" >> } >> >> >> >> exec { "create apache run dir": >> command => "/bin/mkdir -p /var/run/httpd", >> creates => "/var/run/httpd" >> } >> >> >> exec { "create apache run link": >> command => "/bin/ln -s /var/run/httpd /etc/httpd/run", >> require => Exec["create apache log dir"], >> creates => "/etc/httpd/run" >> } >> >> exec { "create httpd conf dir": >> command => "/bin/mkdir -p /etc/httpd/conf.d", >> creates => "/etc/httpd/conf.d" >> >> } >> >> >> exec { "create httpd vhost conf dir": >> command => "/bin/mkdir -p /etc/httpd/conf", >> creates => "/etc/httpd/conf" >> >> } >> >> >> file { "/etc/php.ini": >> owner => root, >> group => root, >> mode => 440, >> source => "puppet:///apache/php.ini" >> } >> >> file { "/usr/lib/httpd/modules/mod_file_cache.so": >> owner => root, >> group => root, >> mode => 766, >> require => Exec["create apache module dir"], >> source => "puppet:///apache/krome/httpd/modules/mod_file_cache.so" >> } >> >> file { >> "/etc/httpd/conf/httpd.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf/httpd.conf" >> } >> >> >> file { >> "/usr/lib/httpd/modules/mod_auth_basic.so": >> owner => root, >> group => root, >> mode => 766, >> source => "puppet:///apache/krome/httpd/modules/mod_auth_basic.so" >> } >> >> >> >> file { >> "/etc/httpd/conf.d/000-ssl.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf.d/000-ssl.conf" >> } >> >> file { >> "/etc/httpd/conf.d/001-chrome-ssl.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf.d/001-chrome-ssl.conf" >> } >> >> file { >> "/etc/httpd/conf.d/002-chrome.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf.d/002-chrome.conf" >> } >> >> file { >> "/etc/httpd/conf.d/php.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf.d/php.conf" >> } >> >> file { >> "/etc/httpd/conf.d/proxy_ajp.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf.d/proxy_ajp.conf" >> } >> >> >> file { >> "/etc/httpd/conf.d/welcome.conf": >> owner => root, >> group => root, >> mode => 440, >> require => Exec["create httpd conf dir"], >> source => "puppet:///apache/krome/httpd/conf.d/welcome.conf" >> } >> >> tidy { "/etc/httpd/conf.d/ssl.conf": >> age => ''0s'', >> } >> >> >> >> service { "httpd": >> enable => "true", >> ensure => "running", >> hasrestart => "true", >> hasstatus => "true", >> require => [ Package["httpd.$architecture"], >> Tidy["/etc/httpd/conf.d/ssl.conf"] ] >> } >> >> } >> >> >> Thanks for your help! >> >> -- >> GPG me!! >> >> gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B >> > > > > -- > GPG me!! > > gpg --keyserver pool.sks-keyservers.net --recv-keys F186197B > > -- > 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. >-- 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.
jcbollinger
2011-Mar-17 13:21 UTC
[Puppet Users] Re: only one puppet client fails with yum
On Mar 16, 10:47 am, Tim Dunphy <bluethu...@gmail.com> wrote:> to clarify the classes between the working and non-working machine > seem identical > > ## problem node > > [root@ec2-184-72-200-83 ~]# cat /var/lib/puppet/classes.txt > basenode > centos > basefiles > baseapps > sshd > webserver > apache > ec2-184-72-200-83.compute-1.amazonaws.com > > ## working node > > [root@kromep2 ~]# cat /var/lib/puppet/classes.txt > basenode > centos > basefiles > baseapps > sshd > webserver > apache > kromep2.acadaca.net > > and the versions of puppet on each machine are identical and the fqdns > of each machine match up with what I have in the nodes.pp file > > ## facter | grep fqdn of both hosts > > ec2-184-72-200-83.compute-1.amazonaws.com # <-- problem machine > > kromep2.acadaca.net # <-- working machine > > ## puppet versions > > puppet-0.25.5-1.el5 # <-- non working machine > puppet-0.25.5-1.el5 # <-- working machine > > ## nodes > > node ''ec2-184-72-200-83.compute-1.amazonaws.com'' inherits webserver { > include centos > > } > > node ''kromep2.acadaca.net'' inherits webserver { > > }Denmat offered some good advice. Follow it. In addition, I observe that the manifests you posted lack any dependency declarations. That might or might not be your problem now, but it is likely to cause you trouble at some point in the future. For instance, you must set up appropriate dependencies to ensure that Package resources are applied *after* the Yumrepos by which their repositories are configured, or else risk problems quite like those you report. This is what the "require" and "before" metaparameters are for. One relatively simple way to do that would be a) Create a class containing all your Yumrepo resources, for instance "environment::repositories". Do not put anything else in that class. b) In your "basenode" node, make all packages require that class: node basenode { ... Package { require => Class[''environment::repositories''] } ... } Alternatively, you might might define a run stage before "main", and have the ''environment::repositories'' class applied there (but that''s not enough if you also apply any packages in that same stage). Of course, you always have the option of declaring repository dependencies per-package for some or all packages. Adjust or substitute to suit your needs. John -- 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.
Maybe Matching Threads
- Struggling to define multiple yum/rug repositories
- run stages in puppet 2.6
- Yumrepo and managing the contents of /etc/yum.repos.d directory...
- YumRepo Warning: not using ftp, http[s], or file for repos, skipping - 5 is not a valid release or hasnt been released yet
- Puppet and yum repositories