FAQ
Amazon this week took ruby1.8 out of their Amazon Linux distro.

Only ruby2.0 is installed.

After installing the puppetlabs yum repo package, and then yum install
puppet, I have this error:

# puppet agent -t
/usr/share/ruby/vendor_ruby/2.0/rubygems/core_ext/kernel_require.rb:55:in
`require': cannot load such file -- puppet/util/command_line (LoadError)
         from
/usr/share/ruby/vendor_ruby/2.0/rubygems/core_ext/kernel_require.rb:55:in
`require'
         from /usr/bin/puppet:3:in `<main>'

If I install ruby18, I can get things working again, but puppet's web page
says ruby 2.0 is perfectly supported.

I note that the puppetlabs puppet RPM installs a TON of stuff in
/usr/lib/ruby/site_ruby/1.8 but there's no corresponding 'stuff' for 2.0.
Specifically, the 'command_line' bit certainly is only in the 1.8 path...

Any insights would be deeply appreciated.

(and yes, I could install 1.8, set alternatives to use 1.8, etc, but I'd
rather not bother)

System details:

# rpm -qa | grep puppet
puppetlabs-release-6-10.noarch
puppet-3.4.3-1.el6.noarch

# rpm -qa | grep ruby
rubygems20-2.0.14-1.14.amzn1.noarch
ruby-shadow-1.4.1-15.5.amzn1.x86_64
libselinux-ruby-2.1.10-3.17.amzn1.x86_64
ruby20-libs-2.0.0.451-1.14.amzn1.x86_64
ruby-rgen-0.6.5-2.el6.noarch
rubygem20-psych-2.0.0-1.14.amzn1.x86_64
rubygem20-rdoc-4.0.1-2.18.amzn1.noarch
ruby-2.0-0.3.amzn1.noarch
rubygem20-bigdecimal-1.2.0-1.14.amzn1.x86_64
ruby-augeas-0.4.1-1.6.amzn1.x86_64
rubygem20-json-1.7.7-101.27.amzn1.x86_64
ruby20-irb-2.0.0.451-1.14.amzn1.noarch
ruby20-2.0.0.451-1.14.amzn1.x86_64
ruby18-libs-1.8.7.374-2.42.3.amzn1.x86_64
rubygem-json-2.0-0.3.amzn1.noarch

--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAChvjRAzPFqP%3D05YOXj1sgpeEiPr_4ee%3DUi%2BV_sqZG4SRQzxvw%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

  • Jason Price at Mar 30, 2014 at 10:03 pm
    ok. So for anyone else digging for this issue:

    Amazon Linux just did an update to be closer to what RHEL7 will look like,
    which means they dropped a default install of ruby 1.8.x

    The Puppet RPM package is compiled against RHEL5/6 which has ruby 1.8.x.
    So it drops a ton of its dependencies into /usr/lib/ruby/site_ruby/1.8.

    If Ruby 1.8 isn't there, everything is broken. Fix is to "yum install
    ruby18 ; alternatives --configure ruby" and set 1.8 as the default ruby.
    Which is ugly. Or build your own RPM.

    --Jason (yuck)

    On Sat, Mar 29, 2014 at 10:54 PM, Jason Price wrote:

    Amazon this week took ruby1.8 out of their Amazon Linux distro.

    Only ruby2.0 is installed.

    After installing the puppetlabs yum repo package, and then yum install
    puppet, I have this error:

    # puppet agent -t
    /usr/share/ruby/vendor_ruby/2.0/rubygems/core_ext/kernel_require.rb:55:in
    `require': cannot load such file -- puppet/util/command_line (LoadError)
    from
    /usr/share/ruby/vendor_ruby/2.0/rubygems/core_ext/kernel_require.rb:55:in
    `require'
    from /usr/bin/puppet:3:in `<main>'

    If I install ruby18, I can get things working again, but puppet's web page
    says ruby 2.0 is perfectly supported.

    I note that the puppetlabs puppet RPM installs a TON of stuff in
    /usr/lib/ruby/site_ruby/1.8 but there's no corresponding 'stuff' for 2.0.
    Specifically, the 'command_line' bit certainly is only in the 1.8 path...

    Any insights would be deeply appreciated.

    (and yes, I could install 1.8, set alternatives to use 1.8, etc, but I'd
    rather not bother)

    System details:

    # rpm -qa | grep puppet
    puppetlabs-release-6-10.noarch
    puppet-3.4.3-1.el6.noarch

    # rpm -qa | grep ruby
    rubygems20-2.0.14-1.14.amzn1.noarch
    ruby-shadow-1.4.1-15.5.amzn1.x86_64
    libselinux-ruby-2.1.10-3.17.amzn1.x86_64
    ruby20-libs-2.0.0.451-1.14.amzn1.x86_64
    ruby-rgen-0.6.5-2.el6.noarch
    rubygem20-psych-2.0.0-1.14.amzn1.x86_64
    rubygem20-rdoc-4.0.1-2.18.amzn1.noarch
    ruby-2.0-0.3.amzn1.noarch
    rubygem20-bigdecimal-1.2.0-1.14.amzn1.x86_64
    ruby-augeas-0.4.1-1.6.amzn1.x86_64
    rubygem20-json-1.7.7-101.27.amzn1.x86_64
    ruby20-irb-2.0.0.451-1.14.amzn1.noarch
    ruby20-2.0.0.451-1.14.amzn1.x86_64
    ruby18-libs-1.8.7.374-2.42.3.amzn1.x86_64
    rubygem-json-2.0-0.3.amzn1.noarch
    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAChvjRBdcseVB0FD%2B7q_PJRxeDZPeTUf8RknLURsvspKH7-35A%40mail.gmail.com.
    For more options, visit https://groups.google.com/d/optout.
  • Michael O'Dea at Mar 31, 2014 at 7:02 pm
    I ran into the same issue this weekend, and discovered that the Amazon yum
    repo's latest Puppet package (2.7.25) has ruby1.8 "shebang'd". With that
    puppet release, you can have ruby2.0 on the system as the default and still
    have puppet running correctly. If your hosts are running the puppet agent
    as a service, and you haven't restarted them since the 2.0 release (last
    Thursday?), you can even upgrade puppet with a simple:

    package { 'puppet': ensure => 'latest' }

    YMMV, that worked with the 10 or so hosts I had that were still on puppet <
    2.7.25.

    --
    M
    On Sunday, March 30, 2014 6:03:02 PM UTC-4, Jason Price wrote:

    ok. So for anyone else digging for this issue:

    Amazon Linux just did an update to be closer to what RHEL7 will look like,
    which means they dropped a default install of ruby 1.8.x

    The Puppet RPM package is compiled against RHEL5/6 which has ruby 1.8.x.
    So it drops a ton of its dependencies into /usr/lib/ruby/site_ruby/1.8.

    If Ruby 1.8 isn't there, everything is broken. Fix is to "yum install
    ruby18 ; alternatives --configure ruby" and set 1.8 as the default ruby.
    Which is ugly. Or build your own RPM.

    --Jason (yuck)


    On Sat, Mar 29, 2014 at 10:54 PM, Jason Price <jap...@gmail.com<javascript:>
    wrote:
    Amazon this week took ruby1.8 out of their Amazon Linux distro.

    Only ruby2.0 is installed.

    After installing the puppetlabs yum repo package, and then yum install
    puppet, I have this error:

    # puppet agent -t
    /usr/share/ruby/vendor_ruby/2.0/rubygems/core_ext/kernel_require.rb:55:in
    `require': cannot load such file -- puppet/util/command_line (LoadError)
    from
    /usr/share/ruby/vendor_ruby/2.0/rubygems/core_ext/kernel_require.rb:55:in
    `require'
    from /usr/bin/puppet:3:in `<main>'

    If I install ruby18, I can get things working again, but puppet's web
    page says ruby 2.0 is perfectly supported.

    I note that the puppetlabs puppet RPM installs a TON of stuff in
    /usr/lib/ruby/site_ruby/1.8 but there's no corresponding 'stuff' for 2.0.
    Specifically, the 'command_line' bit certainly is only in the 1.8 path...

    Any insights would be deeply appreciated.

    (and yes, I could install 1.8, set alternatives to use 1.8, etc, but I'd
    rather not bother)

    System details:

    # rpm -qa | grep puppet
    puppetlabs-release-6-10.noarch
    puppet-3.4.3-1.el6.noarch

    # rpm -qa | grep ruby
    rubygems20-2.0.14-1.14.amzn1.noarch
    ruby-shadow-1.4.1-15.5.amzn1.x86_64
    libselinux-ruby-2.1.10-3.17.amzn1.x86_64
    ruby20-libs-2.0.0.451-1.14.amzn1.x86_64
    ruby-rgen-0.6.5-2.el6.noarch
    rubygem20-psych-2.0.0-1.14.amzn1.x86_64
    rubygem20-rdoc-4.0.1-2.18.amzn1.noarch
    ruby-2.0-0.3.amzn1.noarch
    rubygem20-bigdecimal-1.2.0-1.14.amzn1.x86_64
    ruby-augeas-0.4.1-1.6.amzn1.x86_64
    rubygem20-json-1.7.7-101.27.amzn1.x86_64
    ruby20-irb-2.0.0.451-1.14.amzn1.noarch
    ruby20-2.0.0.451-1.14.amzn1.x86_64
    ruby18-libs-1.8.7.374-2.42.3.amzn1.x86_64
    rubygem-json-2.0-0.3.amzn1.noarch
    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/20adf55d-ebec-45c7-8755-8bafe55991a6%40googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Tom Poulton at Apr 4, 2014 at 7:40 pm
    I was running into this problem as well so I ran:

    *sudo cp -r /usr/lib/ruby/site_ruby/1.8/*
    /usr/local/share/ruby/site_ruby/2.0/*

    /usr/local/share/ruby/site_ruby/2.0/ is part of the $LOAD_PATH so I figured
    why not stick the files in there and see what happens, now I can run *puppet
    --version* plus *facter ipaddress* etc. That's all I've run so far so there
    might be some weirdness down the line, but it's a start!?

    It would be better if it was a symlink or something so you wouldn't have to
    run this again after a yum update, but hopefully puppetlabs will ralease a
    new RPM soon that works, I'm guessing they will now that AWS are running
    ruby 2.0.0 as default!?

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/ada194cd-89bb-49dd-841b-39c4f2cbf42b%40googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Nick Cammorato at Apr 4, 2014 at 7:51 pm
    Did anyone try using the EL7 RPM? I've had success with testing with it in
    the RHEL7 beta, so if amazon has moved closer to RHEL7, it should be worth
    a shot.

    --Nick

    On Fri, Apr 4, 2014 at 3:40 PM, Tom Poulton wrote:

    I was running into this problem as well so I ran:

    *sudo cp -r /usr/lib/ruby/site_ruby/1.8/*
    /usr/local/share/ruby/site_ruby/2.0/*

    /usr/local/share/ruby/site_ruby/2.0/ is part of the $LOAD_PATH so I
    figured why not stick the files in there and see what happens, now I can
    run *puppet --version* plus *facter ipaddress* etc. That's all I've run
    so far so there might be some weirdness down the line, but it's a start!?

    It would be better if it was a symlink or something so you wouldn't have
    to run this again after a yum update, but hopefully puppetlabs will ralease
    a new RPM soon that works, I'm guessing they will now that AWS are running
    ruby 2.0.0 as default!?

    --
    You received this message because you are subscribed to the Google Groups
    "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an
    email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit
    https://groups.google.com/d/msgid/puppet-users/ada194cd-89bb-49dd-841b-39c4f2cbf42b%40googlegroups.com<https://groups.google.com/d/msgid/puppet-users/ada194cd-89bb-49dd-841b-39c4f2cbf42b%40googlegroups.com?utm_medium=email&utm_source=footer>
    .

    For more options, visit https://groups.google.com/d/optout.
    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/CAKJ8awe7owwc7%2BSrFo0%2BeuRZaRPkW79OjQxoHwPOnkpPM%3DCLRA%40mail.gmail.com.
    For more options, visit https://groups.google.com/d/optout.
  • Michael G. Noll at Apr 23, 2014 at 10:04 am

    On Friday, April 4, 2014 9:50:59 PM UTC+2, Nick Cammorato wrote:
    Did anyone try using the EL7 RPM? I've had success with testing with it
    in the RHEL7 beta, so if amazon has moved closer to RHEL7, it should be
    worth a shot.
    Using the EL7 RPM does not work on the 2014 Amazon Linux AMI. The EL7
    version of Puppet requires systemd, and the latter is not available on
    Amazon Linux.

    $ sudo rpm -ivh
    https://yum.puppetlabs.com/el/7/products/x86_64/puppetlabs-release-7-10.noarch.rpm
    $ sudo yum clean all
    $ sudo yum install puppet facter
    [...]
    Error: Package: puppet-3.5.1-1.el7.noarch (puppetlabs-products)
                Requires: systemd
      You could try using --skip-broken to work around the problem
      You could try running: rpm -Va --nofiles --nodigest


    Best,
    Michael

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/0a034011-8d2e-4cfb-9563-f1a48fd99b33%40googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.
  • Charlie Sharpsteen at Apr 5, 2014 at 2:25 am

    On Friday, April 4, 2014 12:40:44 PM UTC-7, Tom Poulton wrote:
    I was running into this problem as well so I ran:

    *sudo cp -r /usr/lib/ruby/site_ruby/1.8/*
    /usr/local/share/ruby/site_ruby/2.0/*

    /usr/local/share/ruby/site_ruby/2.0/ is part of the $LOAD_PATH so I
    figured why not stick the files in there and see what happens, now I can
    run *puppet --version* plus *facter ipaddress* etc. That's all I've run
    so far so there might be some weirdness down the line, but it's a start!?

    It would be better if it was a symlink or something so you wouldn't have
    to run this again after a yum update, but hopefully puppetlabs will ralease
    a new RPM soon that works, I'm guessing they will now that AWS are running
    ruby 2.0.0 as default!?
    The Puppet Labs EL 6 repos are designed to be compatible with RHEL 6.x and
    CentOS 6.x which will remain on Ruby 1.8.7 for the rest of their lifetimes.
    By upgrading the default Ruby to 2.0, Amazon Linux has broken compatibility
    with EL 6. Puppet Labs probably won't be able to compensate for this in the
    EL 6 repos due to the need to stay compatible with systems running 1.8.7.

    Renaming the site_ruby directory may bring varying degrees of success, but
    the puppet package has at least two dependencies, ruby-augeas and
    ruby-shadow, that contain extensions that have been compiled against the
    Ruby 1.8.7 libraries. The only way to achieve compatibility in these cases
    is to re-build the packages against Ruby 2.0.0.

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscribe@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/1b2c7286-b8c9-4234-afc9-8903ec188b68%40googlegroups.com.
    For more options, visit https://groups.google.com/d/optout.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppuppet-users @
categoriespuppet
postedMar 30, '14 at 2:54a
activeApr 23, '14 at 10:04a
posts7
users6
websitepuppetlabs.com

People

Translate

site design / logo © 2017 Grokbase