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

torcx store has archives of wrong arch #2366

Closed
glevand opened this Issue Feb 21, 2018 · 4 comments

Comments

Projects
None yet
3 participants
@glevand

glevand commented Feb 21, 2018

Issue Report

Bug

Container Linux Version

Local build:

NAME="Container Linux by CoreOS"
ID=coreos
VERSION=1688.0.0+2018-02-14-1153
VERSION_ID=1688.0.0
BUILD_ID=2018-02-14-1153
PRETTY_NAME="Container Linux by CoreOS 1688.0.0+2018-02-14-1153 (Rhyolite)"
ANSI_COLOR="38;5;75"
HOME_URL="https://coreos.com/"
BUG_REPORT_URL="https://issues.coreos.com"
COREOS_BOARD="arm64-usr"

Environment

qemu-system-aarch64 on ubuntu host.

Other Information

Docker wasn't working and I saw this in the journal:

developer-1688 env[755]: /run/torcx/bin/containerd: /run/torcx/bin/containerd: cannot execute binary file

From the console I found this:

core@developer-1688 ~ $ uname -m
aarch64
core@developer-1688 ~ $ head /run/torcx/bin/containerd | od -S 4
0001250 /lib64/ld-linux-x86-64.so.2
core@developer-1688 ~ $ rm -rf /tmp/t-test; mkdir -p /tmp/t-test && tar -C /tmp/t-test -xf /usr/share/torcx/store/docker\:18.02.torcx.tgz && head /tmp/t-test/bin/containerd | od -S 4
0001250 /lib64/ld-linux-x86-64.so.2

So it seems amd64 torcx packages are getting used somehow. But it does seem the SDK builds arm64 torcx packages. From the SDK:

$ rm -rf /tmp/t1; mkdir -p /tmp/t1 && tar -C /tmp/t1 -xf ~/trunk/src/build/torcx/pkgs/arm64-usr/docker/554b6946fddbe87f7a1620dbcaf4e5c735db0ba37dfc5e4f62f61d06904c4d56156bdf19ec406a365020858e229e5eef0acdd5aac5ae6c9ebafccfad52343822/docker\:1.12.torcx.tgz && head /tmp/t1/bin/containerd | od -S 4 | egrep 'ld-linux'
0001160 /lib/ld-linux-aarch64.so.1

I'll look into how the torcx packages get into the store and why the wrong arch packages are getting used. Any pointers would be appreciated.

@euank

This comment has been minimized.

Contributor

euank commented Feb 21, 2018

The files are copied into the image here.

It looks like a few other bits of code near there use FLAGS_board, not BOARD; want to check if that's the issue?

@dm0-

This comment has been minimized.

Member

dm0- commented Feb 21, 2018

It looks like containerd cross-compilation broke with 1.0.1 (Docker 18.02). I can look into it tomorrow unless you want to handle it.

@glevand

This comment has been minimized.

glevand commented Feb 21, 2018

@dm0- I want to look into how torcx works, so I'll try to fix it.

@dm0-

This comment has been minimized.

Member

dm0- commented Feb 21, 2018

Okay, but note that the problem is not related to torcx. It's still broken if you run emerge-arm64-usr containerd.

glevand added a commit to glevand/coreos--coreos-overlay that referenced this issue Feb 21, 2018

app-emulation/containerd: Fix GOOARCH build problem
A call to coreos-go_src_prepare in src_prepare will get go_export
called, which exports the correct GOARCH value.

Fixes coreos/bugs#2366 (torcx store has
archives of wrong arch).

Signed-off-by: Geoff Levand <geoff@infradead.org>

glevand added a commit to glevand/coreos--coreos-overlay that referenced this issue Feb 21, 2018

app-emulation/containerd: Fix GOARCH build problem
A call to coreos-go_src_prepare in src_prepare will get go_export
called, which exports the correct GOARCH value.

Fixes coreos/bugs#2366 (torcx store has
archives of wrong arch).

Signed-off-by: Geoff Levand <geoff@infradead.org>

dm0- added a commit to dm0-/coreos-overlay that referenced this issue Mar 7, 2018

app-emulation/containerd: Fix GOARCH build problem
A call to coreos-go_src_prepare in src_prepare will get go_export
called, which exports the correct GOARCH value.

Fixes coreos/bugs#2366 (torcx store has
archives of wrong arch).

Signed-off-by: Geoff Levand <geoff@infradead.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment