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

fix: failed to resolve argv0 ("/run/rosetta/rosetta") #474

Merged
merged 1 commit into from
Dec 16, 2024

Conversation

RomainMuller
Copy link
Contributor

When running orchestrion in a Docker container using a Rosetta-backed engine (using the vz type of VM), the argv0 found when crawling process trees is the binfmt handler (rosetta) instead of the actual command being executed.

The rosetta handler is only present on the hypervisor (hence it fails on no such file or directory during resolution attempts). When encountering not found errors on linux/amd64 platforms, where the binary name is rosetta, try to resolve argv[1] as a fallback.

When running orchestrion in a Docker container using a Rosetta-backed
engine (using the `vz` type of VM), the `argv0` found when crawling
process trees is the `binfmt` handler (`rosetta`) instead of the actual
command being executed.

The `rosetta` handler is only present on the hypervisor (hence it fails
on `no such file or directory` during resolution attempts). When
encountering not found errors on `linux/amd64` platforms, where the
binary name is `rosetta`, try to resolve `argv[1]` as a fallback.
@RomainMuller RomainMuller requested a review from a team as a code owner December 16, 2024 16:09
@RomainMuller RomainMuller added this pull request to the merge queue Dec 16, 2024
Copy link

codecov bot commented Dec 16, 2024

Codecov Report

Attention: Patch coverage is 0% with 9 lines in your changes missing coverage. Please review.

Project coverage is 63.91%. Comparing base (0e69e71) to head (9f97746).

Files with missing lines Patch % Lines
internal/goflags/flags.go 0.00% 8 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #474      +/-   ##
==========================================
- Coverage   64.01%   63.91%   -0.11%     
==========================================
  Files         184      184              
  Lines       11089    11098       +9     
==========================================
- Hits         7099     7093       -6     
- Misses       3457     3470      +13     
- Partials      533      535       +2     
Components Coverage Δ
Generators 76.15% <ø> (ø)
Instruments 73.41% <ø> (ø)
Go Driver 75.87% <0.00%> (-2.76%) ⬇️
Toolexec Driver 74.21% <ø> (ø)
Aspects 78.75% <ø> (ø)
Injector 77.27% <ø> (ø)
Job Server 67.07% <ø> (-0.70%) ⬇️
Integration Test Suite 57.48% <ø> (ø)
Other 63.91% <0.00%> (-0.11%) ⬇️
Files with missing lines Coverage Δ
internal/goflags/flags.go 75.36% <0.00%> (-5.26%) ⬇️

... and 2 files with indirect coverage changes

Merged via the queue into main with commit e9a8533 Dec 16, 2024
38 checks passed
@RomainMuller RomainMuller deleted the romain.marcadier/run-under-rosetta branch December 16, 2024 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants