Notice: package install ensured on every run

27 views
Skip to first unread message

Lars Van Steenbergen

unread,
Sep 21, 2017, 9:35:42 AM9/21/17
to Puppet Users
So every run my puppetmaster spawns a notice that a certain package install -> created. 
Every time again, this is not a problem but really annoying.

Did a make a beginner mistake in the code, or is this a bug or something else?

This is the manifest:

class icinga::install {
package {'icinga*':
  ensure =>installed,
  provider => 'yum',
  before => Package['openssh-clients','ftp','wget']
}
package {'openssh-clients':
  ensure =>installed,
  provider => 'yum'
}
package {'ftp':
  ensure =>installed,
  provider => 'yum'
}
package {'wget':
  ensure =>installed,
  provider => 'yum'
}
}

R.I.Pienaar

unread,
Sep 21, 2017, 9:40:00 AM9/21/17
to puppet...@googlegroups.com


On Thu, Sep 21, 2017, at 11:35, Lars Van Steenbergen wrote:
> So every run my puppetmaster spawns a notice that a certain package
> install
> -> created.
> Every time again, this is not a problem but really annoying.
>
> Did a make a beginner mistake in the code, or is this a bug or something
> else?
>
> This is the manifest:
>
> class icinga::install {
> package {'icinga*':

package doesnt take wildcards, thats why it happens.

Dirk Heinrichs

unread,
Sep 21, 2017, 9:41:37 AM9/21/17
to puppet...@googlegroups.com



Am 21.09.2017 um 11:35 schrieb Lars Van Steenbergen:
package {'icinga*':
  ensure =>installed,
  provider => 'yum',
  before => Package['openssh-clients','ftp','wget']
}

Guess there's no package named "icinga*" in your distribution. You need to provide the exact package name(s), either as array or as several package resources.

Array example:
package { ['some', 'packages', 'to', 'install']:
    ...
}

HTH...

    Dirk
--
Dirk Heinrichs
Senior Systems Engineer, Delivery Pipeline
OpenTextTM Discovery | Recommind
Email: dirk.he...@recommind.com
Website: www.recommind.de

Recommind GmbH, Von-Liebig-Straße 1, 53359 Rheinbach

Vertretungsberechtigte Geschäftsführer John Marshall Doolittle, Gordon Davies, Roger Illing, Registergericht Amtsgericht Bonn, Registernummer HRB 10646

This e-mail may contain confidential and/or privileged information. If you are not the intended recipient (or have received this e-mail in error) please notify the sender immediately and destroy this e-mail. Any unauthorized copying, disclosure or distribution of the material in this e-mail is strictly forbidden

Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte Informationen. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail irrtümlich erhalten haben, informieren Sie bitte sofort den Absender und vernichten Sie diese Mail. Das unerlaubte Kopieren sowie die unbefugte Weitergabe dieser Mail sind nicht gestattet.

Lars Van Steenbergen

unread,
Sep 21, 2017, 9:45:57 AM9/21/17
to Puppet Users
Thank you both, 

The issue was indeed the wildcard.
I did not notice this because the package did get installed.

Again, lesson learned ;-)

R.I.Pienaar

unread,
Sep 21, 2017, 9:56:24 AM9/21/17
to puppet...@googlegroups.com


On Thu, Sep 21, 2017, at 11:45, Lars Van Steenbergen wrote:
> Thank you both,
>
> The issue was indeed the wildcard.
> I did not notice this because the package did get installed.
>
> Again, lesson learned ;-)

Puppet will pass what you give it to rpm/yum, so "yum install icinga*"
works fine, but then later it wants to know if "icinga*" is installed
and it looks for exactly that package name - it doesnt understand the
glob. So it does not find a package called "icinga*" so it tries to
install it again etc

--
R.I.Pienaar / www.devco.net / @ripienaar
Reply all
Reply to author
Forward
0 new messages