scarts
2011-Apr-18 18:18 UTC
[Puppet Users] Deleted zypper repo not re-created on subsequent puppetd runs
I''m testing zypprepo successfully to configure additional repositories to my SLES/SLED boxes, but as a final test I deleted a named repo manually from a computer that had previously been successfully configured by puppet, re-ran puppetd and it just seems to think the repo is still there. My agent log just says: info: /Whit[SUSE-Linux-Enterprise-Server-11]: Evaluated in 0.00 seconds Checking the client, I can confirm the file /etc/zypp/repos.d/SUSE- Linux-Enterprise-Server-11.repo doesn''t exist. The only way I seem to be able to ''get it back'' is to brute force the client ''rm -rf /var/lib/puppet/*'' then start the client again (with a new cert) as if it''s brand new. Once I do that, zypprepo does create this repository again. Is this something special about how zypprepo checks for existing configured repositories? I tested a simple testfile resource and it correctly is re-created between runs whenever I delete my testfile, so I don''t think it''s puppet specifically. I''m using zypprepo from mikeknox-puppet-zypprepo-0813875 Thanks for any assistence. -- 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.
Michael Knox
2011-Apr-18 20:42 UTC
Re: [Puppet Users] Deleted zypper repo not re-created on subsequent puppetd runs
Hi, For checking that a resource exists Zypprepo (and yumrepo) simply check for the presence of the repo file. Is your zypprepo defined using the name SUSE-Linux-Enterprise-Server-11? zypprepo {"SUSE-Linux-Enterprise-Server-11": .... } This causes zypprepo to look for /etc/zypp/repos.d/SUSE-Linux-Enterprise-Server-11.repo If that''s not it, could you pastie the relevant section from your manifest and also the --debug output and I''ll have a look at it. Cheers Mike On 19/04/11 4:18 AM, scarts wrote:> I''m testing zypprepo successfully to configure additional repositories > to my SLES/SLED boxes, but as a final test I deleted a named repo > manually from a computer that had previously been successfully > configured by puppet, re-ran puppetd and it just seems to think the > repo is still there. My agent log just says: > > info: /Whit[SUSE-Linux-Enterprise-Server-11]: Evaluated in 0.00 > seconds > > Checking the client, I can confirm the file /etc/zypp/repos.d/SUSE- > Linux-Enterprise-Server-11.repo doesn''t exist. > > The only way I seem to be able to ''get it back'' is to brute force the > client ''rm -rf /var/lib/puppet/*'' then start the client again (with a > new cert) as if it''s brand new. Once I do that, zypprepo does create > this repository again. > > Is this something special about how zypprepo checks for existing > configured repositories? I tested a simple testfile resource and it > correctly is re-created between runs whenever I delete my testfile, so > I don''t think it''s puppet specifically. > I''m using zypprepo from mikeknox-puppet-zypprepo-0813875 > > Thanks for any assistence. >-- 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.
scarts
2011-Apr-18 21:09 UTC
[Puppet Users] Re: Deleted zypper repo not re-created on subsequent puppetd runs
Hi Michael, Thanks for the quick reply. Hopefully this is what you''re looking for. Sorry for the obfuscation - it''s important where I work. In summary, below you can see I have SUSE-Linux-Enterprise-Server-11 repository defined. I applied this through zypprepo successfully. Then I manually remove it and run the puppet client again, but it thinks it''s still there and the .repo file is also confirmed gone? I''m stumped. serverX:/var/lib/puppet/lib/provider/package # zypper repos # | Alias | Name | Enabled | Refresh --+-------------------------------------------------------- +--------------------------------------------------------+--------- +-------- 1 | XXX-SLES11 | XXX YaST repository | Yes | Yes 2 | SUSE-Linux-Enterprise-Server-11 | SUSE- Linux-Enterprise-Server-11 11-0 | Yes | Yes 3 | SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0 | SUSE- Linux-Enterprise-Software-Development-Kit-11 11-0 | Yes | Yes serverX:/var/lib/puppet/lib/provider/package # ll /etc/zypp/repos.d/ total 12 -rw-r--r-- 1 root root 156 Apr 18 19:07 XXX-SLES11.repo -rw-r--r-- 1 root root 191 Apr 18 19:07 SUSE-Linux-Enterprise- Server-11.repo -rw-r--r-- 1 root root 247 Apr 18 19:07 SUSE-Linux-Enterprise-Software- Development-Kit-11_11-0.repo serverX:/var/lib/puppet/lib/provider/package # zypper removerepo SUSE- Linux-Enterprise-Server-11 Removing repository ''SUSE-Linux-Enterprise-Server-11 11-0'' [done] Repository ''SUSE-Linux-Enterprise-Server-11 11-0'' has been removed. serverX:/var/lib/puppet/lib/provider/package # zypper repos # | Alias | Name | Enabled | Refresh --+-------------------------------------------------------- +--------------------------------------------------------+--------- +-------- 1 | XXX-SLES11 | XXX YaST repository | Yes | Yes 2 | SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0 | SUSE- Linux-Enterprise-Software-Development-Kit-11 11-0 | Yes | Yes serverX:/var/lib/puppet/lib/provider/package # puppetd --server puppet.somedomain.com --test --debug debug: Failed to load library ''rubygems'' for feature ''rubygems'' debug: Failed to load library ''selinux'' for feature ''selinux'' debug: Failed to load library ''shadow'' for feature ''libshadow'' debug: Failed to load library ''ldap'' for feature ''ldap'' debug: Puppet::Type::User::ProviderLdap: feature ldap is missing debug: Puppet::Type::User::ProviderUser_role_add: file roledel does not exist debug: Puppet::Type::User::ProviderDirectoryservice: file /usr/bin/ dscl does not exist debug: Puppet::Type::User::ProviderPw: file pw does not exist debug: Puppet::Type::File::ProviderMicrosoft_windows: feature microsoft_windows is missing debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring File[/var/lib/puppet/ssl] debug: /File[/var/lib/puppet/state/state.yaml]: Autorequiring File[/ var/lib/puppet/state] debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/public_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ public_keys] debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ var/lib/puppet/ssl] debug: /File[/var/lib/puppet/clientbucket]: Autorequiring File[/var/ lib/puppet] debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ lib/puppet/ssl] debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/client_yaml]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ puppet] debug: /File[/etc/puppet/puppet.conf]: Autorequiring File[/etc/puppet] debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/classes.txt]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/state/graphs]: Autorequiring File[/var/ lib/puppet/state] debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/private_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ private_keys] debug: /File[/var/lib/puppet/client_data]: Autorequiring File[/var/lib/ puppet] debug: Finishing transaction 70158457981100 debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ var/lib/puppet/ssl] debug: /File[/var/lib/puppet/ssl/private_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ private_keys] debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ lib/puppet/ssl] debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/ssl/public_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ public_keys] debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring File[/var/lib/puppet/ssl] debug: Finishing transaction 70158458003480 debug: Using cached certificate for ca debug: Using cached certificate for serverX.somedomain.com debug: Finishing transaction 70158457575980 debug: Loaded state in 0.00 seconds info: Retrieving plugin debug: Loaded state in 0.00 seconds debug: Using cached certificate for ca debug: Using cached certificate for serverX.somedomain.com debug: Using cached certificate_revocation_list for ca debug: file_metadata supports formats: b64_zlib_yaml marshal pson raw yaml; using pson info: /File[/var/lib/puppet/lib]: Evaluated in 0.06 seconds debug: Finishing transaction 70158457426780 debug: Storing state debug: Stored state in 0.00 seconds debug: catalog supports formats: b64_zlib_yaml dot marshal pson raw yaml; using pson debug: Puppet::Type::Package::ProviderRpm: Executing ''/bin/rpm -- version'' debug: Puppet::Type::Package::ProviderAptrpm: Executing ''/bin/rpm -ql rpm'' debug: Puppet::Type::Package::ProviderYum: Executing ''/bin/rpm -- version'' debug: Puppet::Type::Package::ProviderUrpmi: Executing ''/bin/rpm -ql rpm'' info: Caching catalog for serverX.somedomain.com debug: Puppet::Type::Package::ProviderUrpmi: file urpmi does not exist debug: Puppet::Type::Package::ProviderNim: file /usr/sbin/nimclient does not exist debug: Puppet::Type::Package::ProviderGem: file gem does not exist debug: Puppet::Type::Package::ProviderPortage: file /usr/bin/emerge does not exist debug: Puppet::Type::Package::ProviderRug: file /usr/bin/rug does not exist debug: Puppet::Type::Package::ProviderOpenbsd: file pkg_add does not exist debug: Puppet::Type::Package::ProviderPkg: file /usr/bin/pkg does not exist debug: Puppet::Type::Package::ProviderSunfreeware: file pkg-get does not exist debug: Puppet::Type::Package::ProviderHpux: file /usr/sbin/swinstall does not exist debug: Puppet::Type::Package::ProviderAptrpm: file apt-get does not exist debug: Puppet::Type::Package::ProviderAix: file /usr/bin/lslpp does not exist debug: Puppet::Type::Package::ProviderSun: file /usr/sbin/pkgadd does not exist debug: Puppet::Type::Package::ProviderAptitude: file /usr/bin/aptitude does not exist debug: Puppet::Type::Package::ProviderPorts: file /usr/local/sbin/ portversion does not exist debug: Puppet::Type::Package::ProviderFreebsd: file /usr/sbin/pkg_add does not exist debug: Puppet::Type::Package::ProviderYum: file yum does not exist debug: Puppet::Type::Package::ProviderFink: file /sw/bin/fink does not exist debug: Puppet::Type::Package::ProviderUp2date: file /usr/sbin/up2date- nox does not exist debug: Puppet::Type::Package::ProviderApt: file /usr/bin/apt-get does not exist debug: Puppet::Type::Package::ProviderPortupgrade: file /usr/local/ sbin/portversion does not exist debug: Puppet::Type::Package::ProviderDpkg: file /usr/bin/dpkg does not exist debug: Puppet::Type::Service::ProviderDebian: file /usr/sbin/update- rc.d does not exist debug: Puppet::Type::Service::ProviderDaemontools: file /usr/bin/svc does not exist debug: Puppet::Type::Service::ProviderRunit: file /usr/bin/sv does not exist debug: Puppet::Type::Service::ProviderGentoo: file /sbin/rc-update does not exist debug: Puppet::Type::Service::ProviderLaunchd: file /bin/launchctl does not exist debug: Puppet::Type::Group::ProviderLdap: false value when expecting true debug: Puppet::Type::Group::ProviderDirectoryservice: file /usr/bin/ dscl does not exist debug: Puppet::Type::Group::ProviderPw: file /usr/sbin/pw does not exist debug: Creating default schedules debug: Loaded state in 0.00 seconds debug: Prefetching zypper resources for package debug: Puppet::Type::Package::ProviderZypper: Executing ''/bin/rpm -- version'' debug: Puppet::Type::Package::ProviderZypper: Executing ''/bin/rpm -qa --nosignature --nodigest --qf ''%{NAME} %|EPOCH?{%{EPOCH}}:{0}| % {VERSION} %{RELEASE} %{ARCH} '''' debug: /Stage[first]/before: requires Stage[main] debug: /Stage[main]/Puppet/Service[puppet]/require: requires Package[puppet] debug: /Stage[main]/Puppet/Package[puppet]/require: requires Zypprepo[XXX-SLES11] debug: /Stage[main]/Puppet/User[puppet]: Autorequiring Group[puppet] info: Applying configuration version ''1303149801'' info: /Schedule[monthly]: Evaluated in 0.00 seconds info: /Whit[SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0]: Evaluated in 0.00 seconds info: /Schedule[never]: Evaluated in 0.00 seconds info: /Schedule[weekly]: Evaluated in 0.00 seconds info: /Whit[SUSE-Linux-Enterprise-Server-11]: Evaluated in 0.00 seconds info: /Schedule[daily]: Evaluated in 0.00 seconds info: /Schedule[hourly]: Evaluated in 0.00 seconds info: /Whit[XXX-SLES11]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[kernel-source]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[squashfs]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[tcpdump]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[zlib]: Evaluated in 0.00 seconds info: /Whit[basenode]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[libgfortran43]: Evaluated in 0.00 seconds info: /Stage[main]/Puppet/Package[puppet]: Evaluated in 0.00 seconds debug: Service[puppet](provider=redhat): Executing ''/sbin/service puppet status'' debug: Puppet::Type::Service::ProviderRedhat: Executing ''/sbin/ chkconfig puppet'' info: /Stage[main]/Puppet/Service[puppet]: Evaluated in 0.06 seconds info: /Whit[tm-sdes-mdd3]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[zlib-devel]: Evaluated in 0.00 seconds info: /Stage[main]/Puppet/Group[puppet]: Evaluated in 0.00 seconds info: /Stage[main]/Puppet/User[puppet]: Evaluated in 0.00 seconds info: /Whit[tm]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[libexpat-devel]: Evaluated in 0.00 seconds debug: file_metadata supports formats: b64_zlib_yaml marshal pson raw yaml; using pson info: /Stage[main]/Puppet/File[/etc/puppet/puppet.conf]: Evaluated in 0.01 seconds info: /Whit[tm-md]: Evaluated in 0.00 seconds debug: file_metadata supports formats: b64_zlib_yaml marshal pson raw yaml; using pson info: /Stage[main]/Cron/File[/etc/sysconfig/cron]: Evaluated in 0.01 seconds info: /Stage[main]/Tm_packages/Package[libnuma1]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[libxml2]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[sysstat]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[ib-bonding]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[tcl-devel]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[netcat]: Evaluated in 0.00 seconds info: /Whit[tm-md-dev]: Evaluated in 0.00 seconds info: /Stage[main]/Testfile/File[/tmp/testfile]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[lsof]: Evaluated in 0.00 seconds info: /Stage[main]/Tm_packages/Package[nmap]: Evaluated in 0.00 seconds info: /Filebucket[puppet]: Evaluated in 0.00 seconds info: /Schedule[puppet]: Evaluated in 0.00 seconds debug: Finishing transaction 70158458151460 debug: Storing state debug: Stored state in 0.01 seconds notice: Finished catalog run in 0.22 seconds serverX:/var/lib/puppet/lib/provider/package # zypper repos # | Alias | Name | Enabled | Refresh --+-------------------------------------------------------- +--------------------------------------------------------+--------- +-------- 1 | XXX-SLES11 | XXX YaST repository | Yes | Yes 2 | SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0 | SUSE- Linux-Enterprise-Software-Development-Kit-11 11-0 | Yes | Yes serverX:/var/lib/puppet/lib/provider/package # ll /etc/zypp/repos.d/ total 8 -rw-r--r-- 1 root root 156 Apr 18 19:07 XXX-SLES11.repo -rw-r--r-- 1 root root 247 Apr 18 19:07 SUSE-Linux-Enterprise-Software- Development-Kit-11_11-0.repo serverX:/var/lib/puppet/lib/provider/package # -- 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.
Michael Knox
2011-Apr-18 22:09 UTC
Re: [Puppet Users] Re: Deleted zypper repo not re-created on subsequent puppetd runs
No problem, Are you sure that the manifest is being included? I don''t see any mention of zypprepo in the debug output below. Perhaps try something like puppet agent --test --debug --tags zypprepo so you only see what zypprepo is doing. Also could you post the relevant section of your manifest? Cheers On 19/04/11 7:09 AM, scarts wrote:> Hi Michael, > Thanks for the quick reply. > Hopefully this is what you''re looking for. Sorry for the obfuscation - > it''s important where I work. > In summary, below you can see I have SUSE-Linux-Enterprise-Server-11 > repository defined. I applied this through zypprepo successfully. Then > I manually remove it and run the puppet client again, but it thinks > it''s still there and the .repo file is also confirmed gone? I''m > stumped. > > serverX:/var/lib/puppet/lib/provider/package # zypper repos > # | Alias | > Name | Enabled | > Refresh > --+-------------------------------------------------------- > +--------------------------------------------------------+--------- > +-------- > 1 | XXX-SLES11 | XXX YaST > repository | Yes | Yes > 2 | SUSE-Linux-Enterprise-Server-11 | SUSE- > Linux-Enterprise-Server-11 11-0 | Yes | Yes > 3 | SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0 | SUSE- > Linux-Enterprise-Software-Development-Kit-11 11-0 | Yes | Yes > > serverX:/var/lib/puppet/lib/provider/package # ll /etc/zypp/repos.d/ > total 12 > -rw-r--r-- 1 root root 156 Apr 18 19:07 XXX-SLES11.repo > -rw-r--r-- 1 root root 191 Apr 18 19:07 SUSE-Linux-Enterprise- > Server-11.repo > -rw-r--r-- 1 root root 247 Apr 18 19:07 SUSE-Linux-Enterprise-Software- > Development-Kit-11_11-0.repo > > serverX:/var/lib/puppet/lib/provider/package # zypper removerepo SUSE- > Linux-Enterprise-Server-11 > Removing repository ''SUSE-Linux-Enterprise-Server-11 11-0'' [done] > Repository ''SUSE-Linux-Enterprise-Server-11 11-0'' has been removed. > > serverX:/var/lib/puppet/lib/provider/package # zypper repos > # | Alias | > Name | Enabled | > Refresh > --+-------------------------------------------------------- > +--------------------------------------------------------+--------- > +-------- > 1 | XXX-SLES11 | XXX YaST > repository | Yes | Yes > 2 | SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0 | SUSE- > Linux-Enterprise-Software-Development-Kit-11 11-0 | Yes | Yes > > serverX:/var/lib/puppet/lib/provider/package # puppetd --server > puppet.somedomain.com --test --debug > debug: Failed to load library ''rubygems'' for feature ''rubygems'' > debug: Failed to load library ''selinux'' for feature ''selinux'' > debug: Failed to load library ''shadow'' for feature ''libshadow'' > debug: Failed to load library ''ldap'' for feature ''ldap'' > debug: Puppet::Type::User::ProviderLdap: feature ldap is missing > debug: Puppet::Type::User::ProviderUser_role_add: file roledel does > not exist > debug: Puppet::Type::User::ProviderDirectoryservice: file /usr/bin/ > dscl does not exist > debug: Puppet::Type::User::ProviderPw: file pw does not exist > debug: Puppet::Type::File::ProviderMicrosoft_windows: feature > microsoft_windows is missing > debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: > Autorequiring File[/var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring > File[/var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/state/state.yaml]: Autorequiring File[/ > var/lib/puppet/state] > debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/public_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > public_keys] > debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ > var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/clientbucket]: Autorequiring File[/var/ > lib/puppet] > debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ > lib/puppet/ssl] > debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/client_yaml]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/etc/puppet/puppet.conf]: Autorequiring File[/etc/puppet] > debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ > var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/classes.txt]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/state/graphs]: Autorequiring File[/var/ > lib/puppet/state] > debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > private_keys] > debug: /File[/var/lib/puppet/client_data]: Autorequiring File[/var/lib/ > puppet] > debug: Finishing transaction 70158457981100 > debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ > var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > private_keys] > debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ > var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: > Autorequiring File[/var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ > lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl/public_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > public_keys] > debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring > File[/var/lib/puppet/ssl] > debug: Finishing transaction 70158458003480 > debug: Using cached certificate for ca > debug: Using cached certificate for serverX.somedomain.com > debug: Finishing transaction 70158457575980 > debug: Loaded state in 0.00 seconds > info: Retrieving plugin > debug: Loaded state in 0.00 seconds > debug: Using cached certificate for ca > debug: Using cached certificate for serverX.somedomain.com > debug: Using cached certificate_revocation_list for ca > debug: file_metadata supports formats: b64_zlib_yaml marshal pson raw > yaml; using pson > info: /File[/var/lib/puppet/lib]: Evaluated in 0.06 seconds > debug: Finishing transaction 70158457426780 > debug: Storing state > debug: Stored state in 0.00 seconds > debug: catalog supports formats: b64_zlib_yaml dot marshal pson raw > yaml; using pson > debug: Puppet::Type::Package::ProviderRpm: Executing ''/bin/rpm -- > version'' > debug: Puppet::Type::Package::ProviderAptrpm: Executing ''/bin/rpm -ql > rpm'' > debug: Puppet::Type::Package::ProviderYum: Executing ''/bin/rpm -- > version'' > debug: Puppet::Type::Package::ProviderUrpmi: Executing ''/bin/rpm -ql > rpm'' > info: Caching catalog for serverX.somedomain.com > debug: Puppet::Type::Package::ProviderUrpmi: file urpmi does not exist > debug: Puppet::Type::Package::ProviderNim: file /usr/sbin/nimclient > does not exist > debug: Puppet::Type::Package::ProviderGem: file gem does not exist > debug: Puppet::Type::Package::ProviderPortage: file /usr/bin/emerge > does not exist > debug: Puppet::Type::Package::ProviderRug: file /usr/bin/rug does not > exist > debug: Puppet::Type::Package::ProviderOpenbsd: file pkg_add does not > exist > debug: Puppet::Type::Package::ProviderPkg: file /usr/bin/pkg does not > exist > debug: Puppet::Type::Package::ProviderSunfreeware: file pkg-get does > not exist > debug: Puppet::Type::Package::ProviderHpux: file /usr/sbin/swinstall > does not exist > debug: Puppet::Type::Package::ProviderAptrpm: file apt-get does not > exist > debug: Puppet::Type::Package::ProviderAix: file /usr/bin/lslpp does > not exist > debug: Puppet::Type::Package::ProviderSun: file /usr/sbin/pkgadd does > not exist > debug: Puppet::Type::Package::ProviderAptitude: file /usr/bin/aptitude > does not exist > debug: Puppet::Type::Package::ProviderPorts: file /usr/local/sbin/ > portversion does not exist > debug: Puppet::Type::Package::ProviderFreebsd: file /usr/sbin/pkg_add > does not exist > debug: Puppet::Type::Package::ProviderYum: file yum does not exist > debug: Puppet::Type::Package::ProviderFink: file /sw/bin/fink does not > exist > debug: Puppet::Type::Package::ProviderUp2date: file /usr/sbin/up2date- > nox does not exist > debug: Puppet::Type::Package::ProviderApt: file /usr/bin/apt-get does > not exist > debug: Puppet::Type::Package::ProviderPortupgrade: file /usr/local/ > sbin/portversion does not exist > debug: Puppet::Type::Package::ProviderDpkg: file /usr/bin/dpkg does > not exist > debug: Puppet::Type::Service::ProviderDebian: file /usr/sbin/update- > rc.d does not exist > debug: Puppet::Type::Service::ProviderDaemontools: file /usr/bin/svc > does not exist > debug: Puppet::Type::Service::ProviderRunit: file /usr/bin/sv does not > exist > debug: Puppet::Type::Service::ProviderGentoo: file /sbin/rc-update > does not exist > debug: Puppet::Type::Service::ProviderLaunchd: file /bin/launchctl > does not exist > debug: Puppet::Type::Group::ProviderLdap: false value when expecting > true > debug: Puppet::Type::Group::ProviderDirectoryservice: file /usr/bin/ > dscl does not exist > debug: Puppet::Type::Group::ProviderPw: file /usr/sbin/pw does not > exist > debug: Creating default schedules > debug: Loaded state in 0.00 seconds > debug: Prefetching zypper resources for package > debug: Puppet::Type::Package::ProviderZypper: Executing ''/bin/rpm -- > version'' > debug: Puppet::Type::Package::ProviderZypper: Executing ''/bin/rpm -qa > --nosignature --nodigest --qf ''%{NAME} %|EPOCH?{%{EPOCH}}:{0}| % > {VERSION} %{RELEASE} %{ARCH} > '''' > debug: /Stage[first]/before: requires Stage[main] > debug: /Stage[main]/Puppet/Service[puppet]/require: requires > Package[puppet] > debug: /Stage[main]/Puppet/Package[puppet]/require: requires > Zypprepo[XXX-SLES11] > debug: /Stage[main]/Puppet/User[puppet]: Autorequiring Group[puppet] > info: Applying configuration version ''1303149801'' > info: /Schedule[monthly]: Evaluated in 0.00 seconds > info: /Whit[SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0]: > Evaluated in 0.00 seconds > info: /Schedule[never]: Evaluated in 0.00 seconds > info: /Schedule[weekly]: Evaluated in 0.00 seconds > info: /Whit[SUSE-Linux-Enterprise-Server-11]: Evaluated in 0.00 > seconds > info: /Schedule[daily]: Evaluated in 0.00 seconds > info: /Schedule[hourly]: Evaluated in 0.00 seconds > info: /Whit[XXX-SLES11]: Evaluated in 0.00 seconds > info: /Stage[main]/Tm_packages/Package[kernel-source]: Evaluated in > 0.00 seconds > info: /Stage[main]/Tm_packages/Package[squashfs]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[tcpdump]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[zlib]: Evaluated in 0.00 > seconds > info: /Whit[basenode]: Evaluated in 0.00 seconds > info: /Stage[main]/Tm_packages/Package[libgfortran43]: Evaluated in > 0.00 seconds > info: /Stage[main]/Puppet/Package[puppet]: Evaluated in 0.00 seconds > debug: Service[puppet](provider=redhat): Executing ''/sbin/service > puppet status'' > debug: Puppet::Type::Service::ProviderRedhat: Executing ''/sbin/ > chkconfig puppet'' > info: /Stage[main]/Puppet/Service[puppet]: Evaluated in 0.06 seconds > info: /Whit[tm-sdes-mdd3]: Evaluated in 0.00 seconds > info: /Stage[main]/Tm_packages/Package[zlib-devel]: Evaluated in 0.00 > seconds > info: /Stage[main]/Puppet/Group[puppet]: Evaluated in 0.00 seconds > info: /Stage[main]/Puppet/User[puppet]: Evaluated in 0.00 seconds > info: /Whit[tm]: Evaluated in 0.00 seconds > info: /Stage[main]/Tm_packages/Package[libexpat-devel]: Evaluated in > 0.00 seconds > debug: file_metadata supports formats: b64_zlib_yaml marshal pson raw > yaml; using pson > info: /Stage[main]/Puppet/File[/etc/puppet/puppet.conf]: Evaluated in > 0.01 seconds > info: /Whit[tm-md]: Evaluated in 0.00 seconds > debug: file_metadata supports formats: b64_zlib_yaml marshal pson raw > yaml; using pson > info: /Stage[main]/Cron/File[/etc/sysconfig/cron]: Evaluated in 0.01 > seconds > info: /Stage[main]/Tm_packages/Package[libnuma1]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[libxml2]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[sysstat]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[ib-bonding]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[tcl-devel]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[netcat]: Evaluated in 0.00 > seconds > info: /Whit[tm-md-dev]: Evaluated in 0.00 seconds > info: /Stage[main]/Testfile/File[/tmp/testfile]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[lsof]: Evaluated in 0.00 > seconds > info: /Stage[main]/Tm_packages/Package[nmap]: Evaluated in 0.00 > seconds > info: /Filebucket[puppet]: Evaluated in 0.00 seconds > info: /Schedule[puppet]: Evaluated in 0.00 seconds > debug: Finishing transaction 70158458151460 > debug: Storing state > debug: Stored state in 0.01 seconds > notice: Finished catalog run in 0.22 seconds > > serverX:/var/lib/puppet/lib/provider/package # zypper repos > # | Alias | > Name | Enabled | > Refresh > --+-------------------------------------------------------- > +--------------------------------------------------------+--------- > +-------- > 1 | XXX-SLES11 | XXX YaST > repository | Yes | Yes > 2 | SUSE-Linux-Enterprise-Software-Development-Kit-11_11-0 | SUSE- > Linux-Enterprise-Software-Development-Kit-11 11-0 | Yes | Yes > > serverX:/var/lib/puppet/lib/provider/package # ll /etc/zypp/repos.d/ > total 8 > -rw-r--r-- 1 root root 156 Apr 18 19:07 XXX-SLES11.repo > -rw-r--r-- 1 root root 247 Apr 18 19:07 SUSE-Linux-Enterprise-Software- > Development-Kit-11_11-0.repo > serverX:/var/lib/puppet/lib/provider/package # >-- 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.
scarts
2011-Apr-19 08:34 UTC
[Puppet Users] Re: Deleted zypper repo not re-created on subsequent puppetd runs
I think this should fill in the blanks. Because this is a test environment I''ve stripped down the config to what I believe to be close to minimum. PUPPETMASTER: ******** # puppet --version 2.6.5 ******** ******** /etc/puppet/puppet.conf: <cut> # The configuration file for master. # The default value is ''$confdir/puppet.conf''. config = /etc/puppet/puppet.conf # The entry-point manifest for puppet master. # The default value is ''$manifestdir/site.pp''. manifest = /etc/puppet/manifests/site.pp <cut> # The search path for modules as a colon-separated list of # directories. # The default value is ''$confdir/modules:/usr/share/puppet/ modules''. modulepath = /etc/puppet/modules:/usr/share/puppet/modules # Where puppet master looks for its manifests. # The default value is ''$confdir/manifests''. manifestdir = /etc/puppet/manifests <cut> ******** ******** /etc/puppet/manifests # cat modules.pp import ''testfile'' import ''repositories'' ******** ******** /etc/puppet/manifests # cat site.pp import "nodes/*" ******** ******** /etc/puppet/manifests/nodes # cat basenode.pp # Top level node that everything inherits from #import "*/*" node basenode { Package { provider => $operatingsystem ? { SLES => zypper, } } } node serverX inherits basenode { include repositories } ******** ******** /etc/puppet/modules/repositories # ls -R .: lib manifests ./lib: puppet ./lib/puppet: type ./lib/puppet/type: zypprepo.rb ./manifests: init.pp ******** ******** /etc/puppet/modules/repositories # cat manifests/init.pp class repositories { case $operatingsystem { SLES: { zypprepo {"LSE-SLES11": descr => "LSE YaST repository", autorefresh => 1, type => "yum", path => "/", keeppackages => 0, gpgcheck => 0, baseurl => "nfs://10.0.0.1/data/install/LSE/SLES11/", enabled => 1, } zypprepo {"SUSE-Linux-Enterprise-Server-11": descr => "SUSE-Linux-Enterprise-Server-11 11-0", autorefresh => 1, type => "yast2", path => "/", keeppackages => 0, baseurl => "nfs://10.0.0.1/data/install/SLES11-x86_64- GM/", enabled => 1, } zypprepo {"SUSE-Linux-Enterprise-Software-Development- Kit-11_11-0": descr => "SUSE-Linux-Enterprise-Software-Development- Kit-11 11-0", autorefresh => 1, type => "yast2", path => "/", keeppackages => 0, baseurl => => "nfs://10.0.0.1/data/install/SLE-11-SDK- DVD-x86_64-GM-Media1/", enabled => 1, } } } } PUPPET CLIENT: ******** serverX:/ # puppetd --version 2.6.5 ******** ******** serverX:/ # ps -ef | grep pupp root 8855 26185 0 09:21 pts/4 00:00:00 grep pupp ******** serverX:/ # find / -name zypprepo.rb /var/lib/puppet/lib/provider/package/zypprepo.rb ******** serverX:/ # puppetd --server puppet.t-tsr-ops.stockex.com --test -- debug --tags zypprepo debug: Failed to load library ''rubygems'' for feature ''rubygems'' debug: Failed to load library ''selinux'' for feature ''selinux'' debug: Failed to load library ''shadow'' for feature ''libshadow'' debug: Failed to load library ''ldap'' for feature ''ldap'' debug: Puppet::Type::User::ProviderLdap: feature ldap is missing debug: Puppet::Type::User::ProviderUser_role_add: file roledel does not exist debug: Puppet::Type::User::ProviderDirectoryservice: file /usr/bin/ dscl does not exist debug: Puppet::Type::User::ProviderPw: file pw does not exist debug: Puppet::Type::File::ProviderMicrosoft_windows: feature microsoft_windows is missing debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ puppet] debug: /File[/etc/puppet/puppet.conf]: Autorequiring File[/etc/puppet] debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/client_data]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/classes.txt]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/state/graphs]: Autorequiring File[/var/ lib/puppet/state] debug: /File[/var/lib/puppet/ssl/private_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ private_keys] debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring File[/var/lib/puppet/ssl] debug: /File[/var/lib/puppet/state/state.yaml]: Autorequiring File[/ var/lib/puppet/state] debug: /File[/var/lib/puppet/clientbucket]: Autorequiring File[/var/ lib/puppet] debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/public_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ public_keys] debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ lib/puppet/ssl] debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/client_yaml]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ var/lib/puppet/ssl] debug: Finishing transaction 70071335720380 debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ lib/puppet/ssl] debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring File[/var/lib/puppet/ssl] debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/certs] debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ puppet/ssl] debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ var/lib/puppet/ssl] debug: /File[/var/lib/puppet/ssl/private_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ private_keys] debug: /File[/var/lib/puppet/ssl/public_keys/ serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ public_keys] debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ puppet] debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ var/lib/puppet/ssl/certs] debug: Finishing transaction 70071335742480 debug: Using cached certificate for ca debug: Using cached certificate for serverX.somedomain.com debug: Finishing transaction 70071335315320 debug: Loaded state in 0.00 seconds info: Retrieving plugin debug: Loaded state in 0.00 seconds debug: /File[/var/lib/puppet/lib]: Not tagged with zypprepo info: /File[/var/lib/puppet/lib]: Evaluated in 0.00 seconds debug: Finishing transaction 70071335166200 debug: Storing state debug: Stored state in 0.00 seconds debug: Using cached certificate for ca debug: Using cached certificate for serverX.somedomain.com debug: Using cached certificate_revocation_list for ca debug: catalog supports formats: b64_zlib_yaml dot marshal pson raw yaml; using pson info: Caching catalog for serverX.somedomain.com debug: Creating default schedules debug: Loaded state in 0.00 seconds info: Applying configuration version ''1303201355'' debug: /Schedule[hourly]: Not tagged with zypprepo info: /Schedule[hourly]: Evaluated in 0.00 seconds debug: /Schedule[never]: Not tagged with zypprepo info: /Schedule[never]: Evaluated in 0.00 seconds debug: /Schedule[daily]: Not tagged with zypprepo info: /Schedule[daily]: Evaluated in 0.00 seconds debug: /Schedule[monthly]: Not tagged with zypprepo info: /Schedule[monthly]: Evaluated in 0.00 seconds debug: /Schedule[weekly]: Not tagged with zypprepo info: /Schedule[weekly]: Evaluated in 0.00 seconds debug: /Schedule[puppet]: Not tagged with zypprepo info: /Schedule[puppet]: Evaluated in 0.00 seconds debug: /Filebucket[puppet]: Not tagged with zypprepo info: /Filebucket[puppet]: Evaluated in 0.00 seconds debug: Finishing transaction 70071335893200 debug: Storing state debug: Stored state in 0.00 seconds notice: Finished catalog run in 0.01 seconds ********* -- 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.
scarts
2011-Apr-19 08:59 UTC
[Puppet Users] Re: Deleted zypper repo not re-created on subsequent puppetd runs
Apologies. It''s working now but I''m not sure why. I created a new repository module init.pp from scratch, walking through examples again and it''s working correctly. Diff between the 2 init.pp files I can''t see anything. Maybe in some small way this may help others with general troubleshooting. Michael, thanks again for your assistence, and your efforts towards this community. On Apr 19, 9:34 am, scarts <stephenandmi...@me.com> wrote:> I think this should fill in the blanks. > Because this is a test environment I''ve stripped down the config to > what I believe to be close to minimum. > > PUPPETMASTER: > ******** > # puppet --version > 2.6.5 > ******** > ******** > /etc/puppet/puppet.conf: <cut> > # The configuration file for master. > # The default value is ''$confdir/puppet.conf''. > config = /etc/puppet/puppet.conf > > # The entry-point manifest for puppet master. > # The default value is ''$manifestdir/site.pp''. > manifest = /etc/puppet/manifests/site.pp > <cut> > # The search path for modules as a colon-separated list of > # directories. > # The default value is ''$confdir/modules:/usr/share/puppet/ > modules''. > modulepath = /etc/puppet/modules:/usr/share/puppet/modules > > # Where puppet master looks for its manifests. > # The default value is ''$confdir/manifests''. > manifestdir = /etc/puppet/manifests > <cut> > ******** > ******** > /etc/puppet/manifests # cat modules.pp > import ''testfile'' > import ''repositories'' > ******** > ******** > /etc/puppet/manifests # cat site.pp > import "nodes/*" > ******** > ******** > /etc/puppet/manifests/nodes # cat basenode.pp > # Top level node that everything inherits from > #import "*/*" > > node basenode { > > Package { > provider => $operatingsystem ? { > SLES => zypper, > } > } > > } > > node serverX inherits basenode { > > include repositories > > } > > ******** > ******** > /etc/puppet/modules/repositories # ls -R > .: > lib manifests > > ./lib: > puppet > > ./lib/puppet: > type > > ./lib/puppet/type: > zypprepo.rb > > ./manifests: > init.pp > ******** > ******** > /etc/puppet/modules/repositories # cat manifests/init.pp > class repositories { > > case $operatingsystem { > SLES: { > > zypprepo {"LSE-SLES11": > descr => "LSE YaST repository", > autorefresh => 1, > type => "yum", > path => "/", > keeppackages => 0, > gpgcheck => 0, > baseurl => "nfs://10.0.0.1/data/install/LSE/SLES11/", > enabled => 1, > } > > zypprepo {"SUSE-Linux-Enterprise-Server-11": > descr => "SUSE-Linux-Enterprise-Server-11 11-0", > autorefresh => 1, > type => "yast2", > path => "/", > keeppackages => 0, > baseurl => "nfs://10.0.0.1/data/install/SLES11-x86_64- > GM/", > enabled => 1, > } > > zypprepo {"SUSE-Linux-Enterprise-Software-Development- > Kit-11_11-0": > descr => "SUSE-Linux-Enterprise-Software-Development- > Kit-11 11-0", > autorefresh => 1, > type => "yast2", > path => "/", > keeppackages => 0, > baseurl => => "nfs://10.0.0.1/data/install/SLE-11-SDK- > DVD-x86_64-GM-Media1/", > enabled => 1, > } > } > } > > } > > PUPPET CLIENT: > ******** > serverX:/ # puppetd --version > 2.6.5 > ******** > ******** > serverX:/ # ps -ef | grep pupp > root 8855 26185 0 09:21 pts/4 00:00:00 grep pupp > ******** > serverX:/ # find / -name zypprepo.rb > /var/lib/puppet/lib/provider/package/zypprepo.rb > ******** > serverX:/ # puppetd --server puppet.t-tsr-ops.stockex.com --test -- > debug --tags zypprepo > debug: Failed to load library ''rubygems'' for feature ''rubygems'' > debug: Failed to load library ''selinux'' for feature ''selinux'' > debug: Failed to load library ''shadow'' for feature ''libshadow'' > debug: Failed to load library ''ldap'' for feature ''ldap'' > debug: Puppet::Type::User::ProviderLdap: feature ldap is missing > debug: Puppet::Type::User::ProviderUser_role_add: file roledel does > not exist > debug: Puppet::Type::User::ProviderDirectoryservice: file /usr/bin/ > dscl does not exist > debug: Puppet::Type::User::ProviderPw: file pw does not exist > debug: Puppet::Type::File::ProviderMicrosoft_windows: feature > microsoft_windows is missing > debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/etc/puppet/puppet.conf]: Autorequiring File[/etc/puppet] > debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ > var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/client_data]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/classes.txt]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/state/graphs]: Autorequiring File[/var/ > lib/puppet/state] > debug: /File[/var/lib/puppet/ssl/private_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > private_keys] > debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: > Autorequiring File[/var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring > File[/var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/state/state.yaml]: Autorequiring File[/ > var/lib/puppet/state] > debug: /File[/var/lib/puppet/clientbucket]: Autorequiring File[/var/ > lib/puppet] > debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/public_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > public_keys] > debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ > lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/client_yaml]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ > var/lib/puppet/ssl] > debug: Finishing transaction 70071335720380 > debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ > lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring > File[/var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: > Autorequiring File[/var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ > var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > private_keys] > debug: /File[/var/lib/puppet/ssl/public_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > public_keys] > debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ > var/lib/puppet/ssl/certs] > debug: Finishing transaction 70071335742480 > debug: Using cached certificate for ca > debug: Using cached certificate for serverX.somedomain.com > debug: Finishing transaction 70071335315320 > debug: Loaded state in 0.00 seconds > info: Retrieving plugin > debug: Loaded state in 0.00 seconds > debug: /File[/var/lib/puppet/lib]: Not tagged with zypprepo > info: /File[/var/lib/puppet/lib]: Evaluated in 0.00 seconds > debug: Finishing transaction 70071335166200 > debug: Storing state > debug: Stored state in 0.00 seconds > debug: Using cached certificate for ca > debug: Using cached certificate for serverX.somedomain.com > debug: Using cached certificate_revocation_list for ca > debug: catalog supports formats: b64_zlib_yaml dot marshal pson raw > yaml; using pson > info: Caching catalog for serverX.somedomain.com > debug: Creating default schedules > debug: Loaded state in 0.00 seconds > info: Applying configuration version ''1303201355'' > debug: /Schedule[hourly]: Not tagged with zypprepo > info: /Schedule[hourly]: Evaluated in 0.00 seconds > debug: /Schedule[never]: Not tagged with zypprepo > info: /Schedule[never]: Evaluated in 0.00 seconds > debug: /Schedule[daily]: Not tagged with zypprepo > info: /Schedule[daily]: Evaluated in 0.00 seconds > debug: /Schedule[monthly]: Not tagged with zypprepo > info: /Schedule[monthly]: Evaluated in 0.00 seconds > debug: /Schedule[weekly]: Not tagged with zypprepo > info: /Schedule[weekly]: Evaluated in 0.00 seconds > debug: /Schedule[puppet]: Not tagged with zypprepo > info: /Schedule[puppet]: Evaluated in 0.00 seconds > debug: /Filebucket[puppet]: Not tagged with zypprepo > info: /Filebucket[puppet]: Evaluated in 0.00 seconds > debug: Finishing transaction 70071335893200 > debug: Storing state > debug: Stored state in 0.00 seconds > notice: Finished catalog run in 0.01 seconds > *********-- 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.
Michael Knox
2011-Apr-19 08:59 UTC
Re: [Puppet Users] Re: Deleted zypper repo not re-created on subsequent puppetd runs
Hi, That seems ok, but I''m still not seeing anything from zypprepo in the debug output which leads me to think it''s being included for some reason. I just tried removing the repos on SLED and SLES test systems and the repo files were recreated without any intervention. I''m wondering about your node definition ... should node serverX inherits basenode { include repositories } be node serverX.somedomain.com inherits basenode { include repositories } I think there is something simple that we''re missing, as zypprepo and yumrepo simply check for the existence of the file. They then set the values in it appropriately. Cheers On 19/04/11 6:34 PM, scarts wrote:> I think this should fill in the blanks. > Because this is a test environment I''ve stripped down the config to > what I believe to be close to minimum. > > PUPPETMASTER: > ******** > # puppet --version > 2.6.5 > ******** > ******** > /etc/puppet/puppet.conf:<cut> > # The configuration file for master. > # The default value is ''$confdir/puppet.conf''. > config = /etc/puppet/puppet.conf > > # The entry-point manifest for puppet master. > # The default value is ''$manifestdir/site.pp''. > manifest = /etc/puppet/manifests/site.pp > <cut> > # The search path for modules as a colon-separated list of > # directories. > # The default value is ''$confdir/modules:/usr/share/puppet/ > modules''. > modulepath = /etc/puppet/modules:/usr/share/puppet/modules > > # Where puppet master looks for its manifests. > # The default value is ''$confdir/manifests''. > manifestdir = /etc/puppet/manifests > <cut> > ******** > ******** > /etc/puppet/manifests # cat modules.pp > import ''testfile'' > import ''repositories'' > ******** > ******** > /etc/puppet/manifests # cat site.pp > import "nodes/*" > ******** > ******** > /etc/puppet/manifests/nodes # cat basenode.pp > # Top level node that everything inherits from > #import "*/*" > > node basenode { > > Package { > provider => $operatingsystem ? { > SLES => zypper, > } > } > } > > node serverX inherits basenode { > > include repositories > > } > ******** > ******** > /etc/puppet/modules/repositories # ls -R > .: > lib manifests > > ./lib: > puppet > > ./lib/puppet: > type > > ./lib/puppet/type: > zypprepo.rb > > ./manifests: > init.pp > ******** > ******** > /etc/puppet/modules/repositories # cat manifests/init.pp > class repositories { > > case $operatingsystem { > SLES: { > > zypprepo {"LSE-SLES11": > descr => "LSE YaST repository", > autorefresh => 1, > type => "yum", > path => "/", > keeppackages => 0, > gpgcheck => 0, > baseurl => "nfs://10.0.0.1/data/install/LSE/SLES11/", > enabled => 1, > } > > zypprepo {"SUSE-Linux-Enterprise-Server-11": > descr => "SUSE-Linux-Enterprise-Server-11 11-0", > autorefresh => 1, > type => "yast2", > path => "/", > keeppackages => 0, > baseurl => "nfs://10.0.0.1/data/install/SLES11-x86_64- > GM/", > enabled => 1, > } > > zypprepo {"SUSE-Linux-Enterprise-Software-Development- > Kit-11_11-0": > descr => "SUSE-Linux-Enterprise-Software-Development- > Kit-11 11-0", > autorefresh => 1, > type => "yast2", > path => "/", > keeppackages => 0, > baseurl => => "nfs://10.0.0.1/data/install/SLE-11-SDK- > DVD-x86_64-GM-Media1/", > enabled => 1, > } > } > } > } > > PUPPET CLIENT: > ******** > serverX:/ # puppetd --version > 2.6.5 > ******** > ******** > serverX:/ # ps -ef | grep pupp > root 8855 26185 0 09:21 pts/4 00:00:00 grep pupp > ******** > serverX:/ # find / -name zypprepo.rb > /var/lib/puppet/lib/provider/package/zypprepo.rb > ******** > serverX:/ # puppetd --server puppet.t-tsr-ops.stockex.com --test -- > debug --tags zypprepo > debug: Failed to load library ''rubygems'' for feature ''rubygems'' > debug: Failed to load library ''selinux'' for feature ''selinux'' > debug: Failed to load library ''shadow'' for feature ''libshadow'' > debug: Failed to load library ''ldap'' for feature ''ldap'' > debug: Puppet::Type::User::ProviderLdap: feature ldap is missing > debug: Puppet::Type::User::ProviderUser_role_add: file roledel does > not exist > debug: Puppet::Type::User::ProviderDirectoryservice: file /usr/bin/ > dscl does not exist > debug: Puppet::Type::User::ProviderPw: file pw does not exist > debug: Puppet::Type::File::ProviderMicrosoft_windows: feature > microsoft_windows is missing > debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/etc/puppet/puppet.conf]: Autorequiring File[/etc/puppet] > debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ > var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/client_data]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/classes.txt]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/state/graphs]: Autorequiring File[/var/ > lib/puppet/state] > debug: /File[/var/lib/puppet/ssl/private_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > private_keys] > debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: > Autorequiring File[/var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring > File[/var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/state/state.yaml]: Autorequiring File[/ > var/lib/puppet/state] > debug: /File[/var/lib/puppet/clientbucket]: Autorequiring File[/var/ > lib/puppet] > debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/public_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > public_keys] > debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ > lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/client_yaml]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ > var/lib/puppet/ssl] > debug: Finishing transaction 70071335720380 > debug: /File[/var/lib/puppet/ssl/private]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/lib]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/ssl]: Autorequiring File[/var/lib/puppet] > debug: /File[/var/lib/puppet/state]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl/public_keys]: Autorequiring File[/var/ > lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/crl.pem]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/certificate_requests]: Autorequiring > File[/var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/certs/serverX.somedomain.com.pem]: > Autorequiring File[/var/lib/puppet/ssl/certs] > debug: /File[/var/lib/puppet/ssl/certs]: Autorequiring File[/var/lib/ > puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys]: Autorequiring File[/ > var/lib/puppet/ssl] > debug: /File[/var/lib/puppet/ssl/private_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > private_keys] > debug: /File[/var/lib/puppet/ssl/public_keys/ > serverX.somedomain.com.pem]: Autorequiring File[/var/lib/puppet/ssl/ > public_keys] > debug: /File[/var/lib/puppet/facts]: Autorequiring File[/var/lib/ > puppet] > debug: /File[/var/lib/puppet/ssl/certs/ca.pem]: Autorequiring File[/ > var/lib/puppet/ssl/certs] > debug: Finishing transaction 70071335742480 > debug: Using cached certificate for ca > debug: Using cached certificate for serverX.somedomain.com > debug: Finishing transaction 70071335315320 > debug: Loaded state in 0.00 seconds > info: Retrieving plugin > debug: Loaded state in 0.00 seconds > debug: /File[/var/lib/puppet/lib]: Not tagged with zypprepo > info: /File[/var/lib/puppet/lib]: Evaluated in 0.00 seconds > debug: Finishing transaction 70071335166200 > debug: Storing state > debug: Stored state in 0.00 seconds > debug: Using cached certificate for ca > debug: Using cached certificate for serverX.somedomain.com > debug: Using cached certificate_revocation_list for ca > debug: catalog supports formats: b64_zlib_yaml dot marshal pson raw > yaml; using pson > info: Caching catalog for serverX.somedomain.com > debug: Creating default schedules > debug: Loaded state in 0.00 seconds > info: Applying configuration version ''1303201355'' > debug: /Schedule[hourly]: Not tagged with zypprepo > info: /Schedule[hourly]: Evaluated in 0.00 seconds > debug: /Schedule[never]: Not tagged with zypprepo > info: /Schedule[never]: Evaluated in 0.00 seconds > debug: /Schedule[daily]: Not tagged with zypprepo > info: /Schedule[daily]: Evaluated in 0.00 seconds > debug: /Schedule[monthly]: Not tagged with zypprepo > info: /Schedule[monthly]: Evaluated in 0.00 seconds > debug: /Schedule[weekly]: Not tagged with zypprepo > info: /Schedule[weekly]: Evaluated in 0.00 seconds > debug: /Schedule[puppet]: Not tagged with zypprepo > info: /Schedule[puppet]: Evaluated in 0.00 seconds > debug: /Filebucket[puppet]: Not tagged with zypprepo > info: /Filebucket[puppet]: Evaluated in 0.00 seconds > debug: Finishing transaction 70071335893200 > debug: Storing state > debug: Stored state in 0.00 seconds > notice: Finished catalog run in 0.01 seconds > ********* >-- 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.