Docker Community Forums

Share and learn in the Docker community.

Standard_init_linux.go:175 exec user process caused no such file

(Kenneth Fuglsang Christensen) #1

I just started using Docker for Windows and I quickly run into an error that I cannot resolve.
I have tried both the stable and beta releases with the same result.

standard_init_linux.go:175: exec user process caused "no such file or directory

This happens on e.g. the mongodb 3.2 Dockerfile on the hub. If I remove the ENTRYPOINT in that Dockerfile it will start.

The issue happens in other dockerfiles as well though. I believe it is related to ENTRYPOINT but I am not 100% certain.

Docker version

 Version:      1.12.0
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   8eab29e
 Built:        Thu Jul 28 21:04:48 2016
 OS/Arch:      windows/amd64
 Experimental: true

 Version:      1.12.0
 API version:  1.24
 Go version:   go1.6.3
 Git commit:   8eab29e
 Built:        Thu Jul 28 21:04:48 2016
 OS/Arch:      linux/amd64
 Experimental: true

Docker info

Containers: 5
 Running: 3
 Paused: 0
 Stopped: 2
Images: 68
Server Version: 1.12.0
Storage Driver: aufs
 Root Dir: /var/lib/docker/aufs
 Backing Filesystem: extfs
 Dirs: 55
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
 Volume: local
 Network: bridge host null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Security Options: seccomp
Kernel Version: 4.4.15-moby
Operating System: Alpine Linux v3.4
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 3.855 GiB
Name: moby
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Experimental: true
Insecure Registries:`

(Kenneth Fuglsang Christensen) #2

Just a quick note.

The entrypoint does indeed exist since I’m doing a chmod +x on it.

With the chmod commented out like below I’m getting a “permission denied” error instead of “no such file”.

#RUN chmod +x /

(Kenneth Fuglsang Christensen) #3

Finally figured it.

I had to run dos2unix on the entrypoint script. Wish the error message was more descriptive.

(Sebastiaan van Stijn) #4

Line endings can be a PITA when working with shell scripts on Linux, unfortunately it’s Linux itself that’s producing such an uninformative error.

Running on a Linux machine, and changing a script to DOS line endings;

bash: ./ /bin/sh^M: bad interpreter: No such file or directory

We’re working on trying to improve that error message (at least to try including which file caused the error)

(Markl17) #5

hi can you explain it slowly so I can comprehend your point

(Samfall) #6

Thank you! This worked for me as well after much frustration.

(Geotech) #7

Saved my day… thanks a lot

(Grantwparks) #8

I think you just have to make sure the line endings of your files, especially (exclusively?) the .sh scripts are unix-style not some other (windows).

(Leocavalcante) #9

Thank you! For me was about line endings.

(Skoob) #10

Hi, I’ve run into the same issue creating the .sh file in vscode. Is there a way to save it without having to run dos2unix?