Skip to content

standard_init_linux.go:175: exec user process caused "exec format error" #228

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

Closed
KingWu opened this issue Oct 20, 2016 · 10 comments
Closed

Comments

@KingWu
Copy link

KingWu commented Oct 20, 2016

docker version

Client:
Version: 1.12.2
API version: 1.24
Go version: go1.6.3
Git commit: bb80604
Built: Tue Oct 11 18:29:41 2016
OS/Arch: linux/amd64

OS: ubuntu 16.04

Run the mysql dockerfile get this error

panic: standard_init_linux.go:175: exec user process caused "exec format error"

any idea?

@tianon
Copy link
Member

tianon commented Oct 20, 2016

That error usually means you're trying to run this amd64 image on a non-amd64 host (such as 32-bit or ARM).

@IanEdington
Copy link

For googlers check the Sha-Bang on your Entrypoint and CMD scripts.

#!/bin/bash

@dmowcomber
Copy link

Thanks @tianon I'm seeing this on a raspberry pi

@vamsi248
Copy link

Hello i am getting the same error,..
these are the logs and docekrfile i am using
logs : standard_init_linux.go:187: exec user process caused "exec format error"

FROM openjdk:8-jre

MAINTAINER krish<vxxxxxxxx.com>

Define environment variables

ENV ARTIFACTORY_HOME=/opt/artifactory
ENV ARTIFACTORY_VERSION=5.4.6
ENV MIN_HEAP_SIZE="-Xms512m"
ENV MAX_HEAP_SIZE="-Xmx2g"

Create artifactory group and user

RUN groupadd -g 1000 artifactory
&& useradd -d "$ARTIFACTORY_HOME" -u 1000 -g 1000 -s /sbin/nologin artifactory

Install artifactory

RUN wget "https://api.bintray.com/content/jfrog/artifactory/jfrog-artifactory-oss-${ARTIFACTORY_VERSION}.zip;bt_package=jfrog-artifactory-oss-zip" &&
unzip "jfrog-artifactory-oss-${ARTIFACTORY_VERSION}.zip;bt_package=jfrog-artifactory-oss-zip" &&
mv artifactory-oss-${ARTIFACTORY_VERSION} $ARTIFACTORY_HOME &&
rm "jfrog-artifactory-oss-${ARTIFACTORY_VERSION}.zip;bt_package=jfrog-artifactory-oss-zip"

Define mountable directories

VOLUME $ARTIFACTORY_HOME/data
VOLUME $ARTIFACTORY_HOME/etc
VOLUME $ARTIFACTORY_HOME/logs
VOLUME $ARTIFACTORY_HOME/backup
VOLUME $ARTIFACTORY_HOME/access

Add initialization script

ADD entrypoint.sh /opt/artifactory/bin/entrypoint.sh

Modify script permissions

RUN chmod 755 /opt/artifactory/bin/entrypoint.sh

Change directories ownership to artifactory user and group

RUN chown -R artifactory:artifactory $ARTIFACTORY_HOME

Run the container as artifactory user

USER artifactory

Define default command

ENTRYPOINT ["/opt/artifactory/bin/entrypoint.sh"]

Expose port

EXPOSE 8081

@vamsi248
Copy link

@dmowcomber how you cleared this error can u help me bro

@tianon
Copy link
Member

tianon commented Dec 11, 2017

@vamsi248 as noted above, check the shebang on your entrypoint.sh script

I'm going to close this since it's an issue with usage/architecture, not the image.
In the future, these sorts of questions/requests would be more appropriately posted to the Docker Community Forums, the Docker Community Slack, or Stack Overflow. Thanks!

@Foxtrod89

This comment has been minimized.

@wglambert

This comment has been minimized.

@Foxtrod89

This comment has been minimized.

@dmowcomber

This comment has been minimized.

@docker-library docker-library locked as resolved and limited conversation to collaborators Aug 27, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants