Details
-
Bug
-
Status: Accepted
-
Normal
-
Resolution: Unresolved
-
PUP 3.7.4
-
None
-
CentOS 7, puppet 3.7.4
-
Night's Watch
-
Client 2016-05-04
Description
I created a new meta RPM and added it to my yum repo.
I then added a package resource to install the new RPM.
The manifest fails as follows:
Error: /Stage[main]/Profile_sensu_client::Nagios_plugins/Package[ubnt-meta-nagios-plugins]/ensure: change from absent to present failed: Execution of '/bin/yum -d 0 -e 0 -y list ubnt-meta-nagios-plugins' returned 1: Error: No matching Packages to list
|
This is because "yum list" does not update the yum cache:
# yum list ubnt-meta-nagios-plugins
|
Loaded plugins: fastestmirror
|
Loading mirror speeds from cached hostfile
|
* base: mirror.solarvps.com
|
* epel: mirror.cogentco.com
|
* extras: mirror.us.leaseweb.net
|
* updates: mirror.steadfast.net
|
Error: No matching Packages to list
|
However, if I just try "yum install" directly, the cache is updated, and the package is found and installed:
# yum install ubnt-meta-nagios-plugins
|
Loaded plugins: fastestmirror
|
base | 3.6 kB 00:00:00
|
epel | 4.4 kB 00:00:00
|
extras | 3.4 kB 00:00:00
|
foreman | 2.9 kB 00:00:00
|
foreman-plugins | 2.9 kB 00:00:00
|
puppetlabs-deps | 2.5 kB 00:00:00
|
puppetlabs-products | 2.5 kB 00:00:00
|
updates | 3.4 kB 00:00:00
|
yo61 | 2.9 kB 00:00:00
|
(1/4): foreman-plugins/x86_64/primary_db | 49 kB 00:00:00
|
(2/4): epel/x86_64/primary_db | 4.0 MB 00:00:00
|
(3/4): yo61/primary_db | 242 kB 00:00:00
|
(4/4): updates/7/x86_64/primary_db | 6.6 MB 00:00:07
|
(1/2): epel/x86_64/updateinfo | 288 kB 00:00:00
|
(2/2): epel/x86_64/pkgtags | 1.4 MB 00:00:00
|
Loading mirror speeds from cached hostfile
|
* base: distro.ibiblio.org
|
* epel: mirror.cogentco.com
|
* extras: mirror.us.leaseweb.net
|
* updates: mirror.steadfast.net
|
Resolving Dependencies
|
--> Running transaction check
|
---> Package ubnt-meta-nagios-plugins.noarch 0:1.0.0-1 will be installed
|
--> Finished Dependency Resolution
|
|
Dependencies Resolved
|
|
=============================================================================================================================================
|
Package Arch Version Repository Size
|
=============================================================================================================================================
|
Installing:
|
ubnt-meta-nagios-plugins noarch 1.0.0-1 yo61 3.5 k
|
|
Transaction Summary
|
=============================================================================================================================================
|
Install 1 Package
|
|
Total download size: 3.5 k
|
Installed size: 0
|
Is this ok [y/d/N]:
|
It seems there is no way to install the package on this node without manually refreshing the cache in this way.
Attachments
Issue Links
- relates to
-
PUP-1061 Install multiple packages within a single call to the package manager
-
- Needs Information
-