Skip to content

docker build hangs/crashes when useradd with large UID #5419

@mcieslik-mctp

Description

@mcieslik-mctp

When I try to add a user during a "docker build ." the process hangs for approx 2-3 min and crashes with a

$ docker build .
Uploading context  5.12 kB
Uploading context 
Step 0 : FROM ubuntu:14.04
 ---> 99ec81b80c55
Step 1 : RUN useradd -u 99900000 -g users mcieslik
 ---> Running in 3ba3c92673fd
2014/04/26 14:58:55 write /var/lib/docker/devicemapper/mnt/.../rootfs/var/log/lastlog: no space left on device

Dockerfile

FROM ubuntu:14.04 
RUN useradd -u 99900000 -g users mcieslik

If I change the above to

FROM ubuntu:14.04 
RUN useradd -u 1001 -g users mcieslik

or run

useradd -u 99900000 -g users mcieslik

in a

docker run -i -t ubuntu:14.04 /bin/bash

everything works fine

Metadata

Metadata

Assignees

No one assigned

    Labels

    area/builderBuildkind/enhancementEnhancements are not bugs or new features but can improve usability or performance.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions