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

Segmentation fault with arm64 Docker image #310

Closed
YC opened this issue Jul 7, 2021 · 0 comments · Fixed by #311
Closed

Segmentation fault with arm64 Docker image #310

YC opened this issue Jul 7, 2021 · 0 comments · Fixed by #311

Comments

@YC
Copy link
Contributor

YC commented Jul 7, 2021

Steps to reproduce:

$ docker run -it --entrypoint /bin/sh cesanta/docker_auth
/ # cd docker_auth/
/docker_auth # ./auth_server 
Segmentation fault (core dumped)
# `apk add file`
/docker_auth # file auth_server 
auth_server: ELF 64-bit LSB executable, ARM aarch64, version 1 (SYSV), dynamically linked, interpreter /lib/ld-musl-aarch64.so.1, Go BuildID=JGlLhsWhVBxrFUFFeOUa/2LumMT82sgppoxbQ0vAS/Ny_Qbnuv9X6kDDNOqnQL/0Hkp7oHjnGgAUZMY0qw3, not stripped

It also segfaults when:

  • Docker image is built on the machine from source
  • I start from golang:1.16-alpine3.13, install packages, clone repository and run make

However, it does work when built outside Docker.

$ make build
$ ./auth_server
F0707 12:58:31.861938  261872 main.go:217] Config file not specified

gdb:

(gdb) run
Starting program: /docker_auth/auth_server/auth_server 

Program received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0  0x0000000000000000 in ?? ()
#1  0x000000000079f758 in frame_dummy ()
#2  0x0000fffff7fb66a8 in ?? () from /lib/ld-musl-aarch64.so.1
#3  0x0000fffffffffcd8 in ?? ()
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
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 a pull request may close this issue.

1 participant