0

I am facing "exit status 34" while creating docker service. please suggest what is the issue.

Docker version : Docker version 17.09.1-ce, build 19e2cf6 Error Log :nsenter: failed to unshare namespaces: Cannot allocate memory container_linux.go:265: starting container process caused "process_linux.go:270: running exec setns process for init caused \"exit status 34\"" ERROR: Service 'web' failed to build: oci runtime error: container_linux.go:265: starting container process caused "process_linux.go:270: running exec setns process for init caused \"exit status 34\""

2 Answers2

1

We have seen a similar error. "nsenter: failed to unshare namespaces: cannot allocate memory".

In my experience it was directly related to memory, and in our case swap. We have our swap space set fairly low but our Red Hat OS was still using it. We have found two actions that seem to help.

  1. Increasing the RAM on our host to have enough overhead where it discourages RHEL from using swap. This is not a bad option if you have the ability to add RAM.

  2. We followed this document and that helped. However you will need to do some analysis on whether this is right for you. Once you make this change, you will use more active ram. For example, we have an angular build that was using 4GB of RAM and 2GB of swap. After this change, all 6GB was in RAM. So if you choose this method you will need to be careful that you don't end up using up all of your ram and forcing the OS to use swap for critical work.

https://success.docker.com/article/node-using-swap-memory-instead-of-host-memory

Tim Razik
  • 11
  • 1
0

I'm facing this issue too.

Here what I did find:

I have a situation where the client reports that the hosts was running and after some unknown update it stop working. I'm still looking for a coherent explanation. I'll update when fix it.

ton
  • 180
  • 4