redroid-doc icon indicating copy to clipboard operation
redroid-doc copied to clipboard

Can't run in docker rootless

Open antrusd opened this issue 10 months ago • 1 comments

I'm using docker in the rootless mode as described by method here. When I tried to run redroid with following steps:

sudo modprobe binder_linux devices=binder,hwbinder,vndbinder
sudo chmod 666 /dev/binder /dev/hwbinder /dev/vndbinder
docker run -it --rm --privileged --name redroid11 \
    -v /dev/binder:/dev/binder \
    -v /dev/hwbinder:/dev/hwbinder \
    -v /dev/vndbinder:/dev/vndbinder \
    redroid/redroid:11.0.0-latest \
    androidboot.use_memfd=1 \
    androidboot.hardware=redroid \
    androidboot.redroid_gpu_mode=guest

the docker command above will just fail silently without any logs. I tried to strace the /init with command:

docker run -it --rm --privileged --name redroid11 \
    -v /dev/binder:/dev/binder \
    -v /dev/hwbinder:/dev/hwbinder \
    -v /dev/vndbinder:/dev/vndbinder \
    --entrypoint /system/bin/bootstrap/linker64 \
    redroid/redroid:11.0.0-latest \
    /system/bin/strace /init \
    androidboot.use_memfd=1 \
    androidboot.hardware=redroid \
    androidboot.redroid_gpu_mode=guest

I got some logs here redroid.strace.log.gz

Additional Info:

  • Debian Trixie (6.6.15-amd64)
  • Docker 26.0.0 Rootless
  • CGroup v2 (systemd.unified_cgroup_hierarchy=1)

antrusd avatar Apr 16 '24 07:04 antrusd