Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use older rubygems-update on AIX 7.2 #2457

Merged
merged 1 commit into from
Jan 3, 2024

Conversation

joshcooper
Copy link
Contributor

@joshcooper joshcooper commented Jan 3, 2024

The validate_vendored_ruby test started failing on AIX 7.2 when loading the
gemspecs from artifactory:

# /opt/puppetlabs/puppet/bin/gem update --system -V
GET https://rubygems.org/specs.4.8.gz
304 Not Modified
GET https://artifactory.delivery.puppetlabs.net/artifactory/api/gems/rubygems/specs.4.8.gz
304 Not Modified
[FATAL] failed to allocate memory

It appears the new behavior is triggered when using the new safe marshall code
introduced in rubygems-update[1]:

# truss -f -i -t kopen /opt/puppetlabs/puppet/bin/gem update --system
...
10813880: 11338039: kopen("/root/.local/share/gem/specs/rubygems.org%443/specs.4.8", 0440000002) = 9
10813880: 11338039: kopen("/opt/puppetlabs/puppet/lib/ruby/site_ruby/3.2.0/rubygems/safe_marshal.rb", 0440000004) = 9
...
10813880: 11338039: kopen("/root/.local/share/gem/specs/artifactory.delivery.puppetlabs.net%443/artifactory/api/gems/rubygems/specs.4.8", 0440000004) = 10
[FATAL] failed to allocate memory

Pin back to an older rubygems-update on AIX 7.2.

[1] rubygems/rubygems#6896

@joshcooper joshcooper requested a review from a team as a code owner January 3, 2024 20:23
The validate_vendored_ruby test started failing on AIX 7.2 when loading the
gemspecs from artifactory:

    # /opt/puppetlabs/puppet/bin/gem update --system -V
    GET https://rubygems.org/specs.4.8.gz
    304 Not Modified
    GET https://artifactory.delivery.puppetlabs.net/artifactory/api/gems/rubygems/specs.4.8.gz
    304 Not Modified
    [FATAL] failed to allocate memory

It appears the new behavior is triggered when using the new safe marshall code
introduced in rubygems-update[1]:

    # truss -f -i -t kopen /opt/puppetlabs/puppet/bin/gem update --system
    ...
    10813880: 11338039: kopen("/root/.local/share/gem/specs/rubygems.org%443/specs.4.8", 0440000002) = 9
    10813880: 11338039: kopen("/opt/puppetlabs/puppet/lib/ruby/site_ruby/3.2.0/rubygems/safe_marshal.rb", 0440000004) = 9
    ...
    10813880: 11338039: kopen("/root/.local/share/gem/specs/artifactory.delivery.puppetlabs.net%443/artifactory/api/gems/rubygems/specs.4.8", 0440000004) = 10
    [FATAL] failed to allocate memory

Pin back to an older rubygems-update on AIX 7.2.

[1] rubygems/rubygems#6896
@joshcooper
Copy link
Contributor Author

I manually tested this using:

export SHA=e955ce4c2cf1cfa9ad43ad16e1d1df1c476cd45a
export GEM_SOURCE=https://artifactory.delivery.puppetlabs.net/artifactory/api/gems/rubygems/
bundle exec beaker-hostgenerator aix72-POWERfa%7Bpackaging_platform=aix-7.2-power%7D --hypervisor abs --disable-default-role --osinfo-version 1 > hosts.yaml
bundle exec rake ci:test:setup HOSTS=hosts.yaml
bundle exec beaker exec tests/validate_vendored_ruby.rb

@joshcooper joshcooper merged commit 5e2a083 into puppetlabs:main Jan 3, 2024
2 checks passed
@joshcooper joshcooper deleted the skip_aix72 branch January 3, 2024 20:35
@joshcooper
Copy link
Contributor Author

This doesn't need to be backported because we already pinned this test to use rubygems 3.4.22 in the 7.x branch, see 3ce3b43

@joshcooper joshcooper added the maintenance Maintenance chores are typically excluded from changelogs label Jan 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Maintenance chores are typically excluded from changelogs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant