Skip to content

fix(upgrade): bind mount /lib during upgrade (needed for ARM)#70

Merged
starbops merged 1 commit into
harvester:mainfrom
starbops:fix/aarch64-lib-bind-mount
Jun 12, 2026
Merged

fix(upgrade): bind mount /lib during upgrade (needed for ARM)#70
starbops merged 1 commit into
harvester:mainfrom
starbops:fix/aarch64-lib-bind-mount

Conversation

@starbops

@starbops starbops commented Jun 9, 2026

Copy link
Copy Markdown
Member

Problem:

Solution:

On aarch64 (e.g., SL Micro 5.5), /lib/ld-linux-aarch64.so.1 is a symlink into /lib64, so bind-mounting only /lib64 from the upgrade container over the host breaks the dynamic linker inside the chroot and chroot $HOST_DIR /tmp/elemental upgrade fails with "No such file or directory". Bind-mounting /lib alongside /lib64 brings in a usable ld-linux-aarch64.so.1 and the chroot works on both x86_64 and aarch64.

Related Issue(s):

harvester/harvester#10765

Test plan:

Additional documentation or context

This ports the V1 fix in harvester/harvester#10458 to Upgrade V2.

On aarch64 (e.g., SL Micro 5.5), /lib/ld-linux-aarch64.so.1 is a
symlink into /lib64, so bind-mounting only /lib64 from the upgrade
container over the host breaks the dynamic linker inside the chroot
and `chroot $HOST_DIR /tmp/elemental upgrade` fails with
"No such file or directory". Bind-mounting /lib alongside /lib64
brings in a usable ld-linux-aarch64.so.1 and the chroot works on
both x86_64 and aarch64.

This ports the V1 fix in harvester/harvester#10458 to Upgrade V2.

Refs: harvester/harvester#10765
Signed-off-by: Zespre Chang <[email protected]>
@starbops
starbops marked this pull request as ready for review June 12, 2026 09:40
Copilot AI review requested due to automatic review settings June 12, 2026 09:40
@starbops
starbops requested a review from tserong June 12, 2026 09:41

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the node OS upgrade script to make the “newer elemental binary needs newer glibc” bind-mount workaround function correctly on aarch64/ARM systems where the dynamic linker path under /lib can depend on content under /lib64.

Changes:

  • Bind-mount /lib into the host chroot alongside the existing /lib64 bind mount when the glibc workaround is triggered.
  • Unmount the newly added /lib bind mount after the elemental upgrade attempt.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread package/upgrade_node.sh
Comment on lines 608 to 611
if [ -n "$glibc_too_old" ]; then
umount $HOST_DIR/lib64
umount $HOST_DIR/lib
fi
@starbops
starbops merged commit d80ee65 into harvester:main Jun 12, 2026
12 checks passed
@starbops
starbops deleted the fix/aarch64-lib-bind-mount branch June 12, 2026 15:42
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.

3 participants