nerdctl icon indicating copy to clipboard operation
nerdctl copied to clipboard

build image fail in linux/arm64

Open xuegege5290 opened this issue 1 year ago • 5 comments

Description

when i try to do the test of TestBuild ,it alway failed,and exitcode is 1.This is the log print(i add the log).There is lot of test failed when they start build images.

cat Dockerfile

FROM myregistry.domain.com:5001/stargz-containers/fluent/fluentd:v1.14-1-org
RUN rm -rf /fluentd/etc/test.conf && echo  -e '\
 <source>\n\
   @type forward\n\
 </source>\n\
\n\
 <match *>\n\
   @type file\n\
   path /data/fluentd\n\
   append true\n\
  <buffer>\n\
    flush_mode immediate\n\
  </buffer>\n\
 </match>\n\
'>> /fluentd/etc/test.conf
# nerdctl build -t test .
[+] Building 4.4s (5/5)                                                                                                                                                                                            
 => [internal] load build definition from Dockerfile                                                                                                                                                          0.1s
 => => transferring dockerfile: 387B                                                                                                                                                                          0.0s
[+] Building 4.4s (5/5) FINISHED                                                                                                                                                                                   
 => [internal] load build definition from Dockerfile                                                                                                                                                          0.1s
 => => transferring dockerfile: 387B                                                                                                                                                                          0.0s
 => [internal] load .dockerignore                                                                                                                                                                             0.1s
 => => transferring context: 2B                                                                                                                                                                               0.0s
 => [internal] load metadata for myregistry.domain.com:5001/stargz-containers/fluent/fluentd:v1.14-1-org                                                                                                      0.1s
 => [1/2] FROM myregistry.domain.com:5001/stargz-containers/fluent/fluentd:v1.14-1-org@sha256:3e0bd37d74c95cff04a5a70ca4bb7470c6f807075cb914c1267c89f5801e1333                                                3.3s
 => => resolve myregistry.domain.com:5001/stargz-containers/fluent/fluentd:v1.14-1-org@sha256:3e0bd37d74c95cff04a5a70ca4bb7470c6f807075cb914c1267c89f5801e1333                                                0.0s
 => => sha256:b05ff3fb7de52f8953e0f4b9e01e518472f33c6d0e9603868fbf29361a01ec00 458B / 458B                                                                                                                    0.0s
 => => sha256:ea86cadf5e05860c7cc92a42e5f0842ee22bd5344c1f1dda3589f2b84e5d6adc 405B / 405B                                                                                                                    0.0s
 => => sha256:26054f1c5f4292f739db2f328dce92ae95c1d4281ab74a73661c9f6dd2bf2ac3 1.33kB / 1.33kB                                                                                                                0.0s
 => => sha256:fbc3d36e35e4029d06fc0a2affe9861224f768911beb58acf5fcb3bb1ffbe0c3 16.32MB / 16.32MB                                                                                                              0.5s
 => => sha256:6097bfa160c13665f946cea95b206a812a795d2517d7690a0a0796d64ec5f817 2.82MB / 2.82MB                                                                                                                0.1s
 => => extracting sha256:6097bfa160c13665f946cea95b206a812a795d2517d7690a0a0796d64ec5f817                                                                                                                     0.4s
 => => extracting sha256:fbc3d36e35e4029d06fc0a2affe9861224f768911beb58acf5fcb3bb1ffbe0c3                                                                                                                     2.5s
 => => extracting sha256:26054f1c5f4292f739db2f328dce92ae95c1d4281ab74a73661c9f6dd2bf2ac3                                                                                                                     0.0s
 => => extracting sha256:ea86cadf5e05860c7cc92a42e5f0842ee22bd5344c1f1dda3589f2b84e5d6adc                                                                                                                     0.0se => => extracting sha256:b05ff3fb7de52f8953e0f4b9e01e518472f33c6d0e9603868fbf29361a01ec00                                                                                                                     0.0se => ERROR [2/2] RUN rm -rf /fluentd/etc/test.conf && echo  -e ' <source>\n   @type forward\n </source>\n\n <match *>\n   @type file\n   path /data/fluentd\n   append true\n  <buffer>\n    flush_mode immed  0.8s
------
 > [2/2] RUN rm -rf /fluentd/etc/test.conf && echo  -e ' <source>\n   @type forward\n </source>\n\n <match *>\n   @type file\n   path /data/fluentd\n   append true\n  <buffer>\n    flush_mode immediate\n  </buffer>\n </match>\n'>> /fluentd/etc/test.conf:
0 0.360 standard_init_linux.go:228: exec user process caused: exec format error
------
Dockerfile:2
--------------------
   1 |     FROM myregistry.domain.com:5001/stargz-containers/fluent/fluentd:v1.14-1-org
   2 | >>> RUN rm -rf /fluentd/etc/test.conf && echo  -e '\
   3 | >>>  <source>\n\
   4 | >>>    @type forward\n\
   5 | >>>  </source>\n\
   6 | >>> \n\
   7 | >>>  <match *>\n\
   8 | >>>    @type file\n\
   9 | >>>    path /data/fluentd\n\
  10 | >>>    append true\n\
  11 | >>>   <buffer>\n\
  12 | >>>     flush_mode immediate\n\
  13 | >>>   </buffer>\n\
  14 | >>>  </match>\n\
  15 | >>> '>> /fluentd/etc/test.conf
  16 |     
--------------------
error: failed to solve: process "/bin/sh -c rm -rf /fluentd/etc/test.conf && echo  -e ' <source>\\n   @type forward\\n </source>\\n\\n <match *>\\n   @type file\\n   path /data/fluentd\\n   append true\\n  <buffer>\\n    flush_mode immediate\\n  </buffer>\\n </match>\\n'>> /fluentd/etc/test.conf" did not complete successfully: exit code: 1
FATA[0004] unrecognized image format     

Steps to reproduce the issue

Describe the results you received and expected

i wanna it build success

What version of nerdctl are you using?

**nerdctl version**
Client:
 Version:	59b14cc8.m
 OS/Arch:	linux/arm64
 Git commit:	59b14cc82f71b071c0c111fc87193c697bda5d29.m

Server:
 containerd:
  Version:	v1.4.0-beta.1-3526-g98f12768b
  GitCommit:	98f12768b6c71d6b0e837140ef19b98187f0dce2

centos8  el8_2.aarch64

cni 1.1.0

**buildkitd -v**
buildkitd github.com/moby/buildkit v0.10.3 c8d25d9a103b70dc300a4fd55e7e576472284e31

 **buildg version**
buildg v0.3.0 d0b75aa61a0729230d243b3e28092939cf5dc212

**ipfs version** 
ipfs version 0.11.0

Are you using a variant of nerdctl? (e.g., Rancher Desktop)

# nerdctl info
Client:
 Namespace:	default
 Debug Mode:	false

Server:
 Server Version: v1.5.9
 Storage Driver: overlayfs
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 1
 Plugins:
  Log: json-file
  Storage: native overlayfs stargz
 Security Options:
  seccomp
   Profile: default
 Kernel Version: 4.18.0-193.14.2.el8_2.aarch64
 Operating System: Ubuntu 21.10
 OSType: linux
 Architecture: aarch64
 CPUs: 8
 Total Memory: 7.448GiB
 Name: a8ace712afc4
 ID: d2c6eeb2-881d-407b-b8d5-5abd3c0ec323

WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled

Host information

4.18.0-193.14.2.el8_2.aarch64 #1 SMP Wed Aug 12 02:46:47 EDT 2020 aarch64 aarch64 aarch64 GNU/Linux

xuegege5290 avatar Aug 11 '22 11:08 xuegege5290

@junnplus

xuegege5290 avatar Aug 11 '22 14:08 xuegege5290

@kzys @dqminh @mattfarina @vbatts

xuegege5290 avatar Aug 11 '22 14:08 xuegege5290

You should make your question readable first.

junnplus avatar Aug 11 '22 15:08 junnplus

uhmm i just run the it-test, all the test failed when they start use the commd of "nerdctl build".i feel so confused... i provide the message is actually mess, but it jsut the log i add,when i run test. ok i will provide clearly logs later.

xuegege5290 avatar Aug 11 '22 15:08 xuegege5290

You should make your question readable first.

update the message ,please have a look.

xuegege5290 avatar Aug 12 '22 09:08 xuegege5290

You should make your question readable first.

update the message ,please have a look.

u

xuegege5290 avatar Aug 16 '22 10:08 xuegege5290