6

I've installed anbox from the default repositories.

The ashmem and binder modules are loaded:

$ lsmod | grep _linux
binder_linux          163840  0
ashmem_linux           20480  0

The anbox-container-manager system service is running:

$ systemctl status anbox-container-manager
● anbox-container-manager.service - Anbox Container Manager
   Loaded: loaded (/lib/systemd/system/anbox-container-manager.service; enabled; vendor preset: enabled)
   Active: active (running) since Fri 2019-11-08 12:17:33 GMT; 7min ago
     Docs: man:anbox(1)
  Process: 1239 ExecStartPre=/sbin/modprobe ashmem_linux (code=exited, status=0/SUCCESS)
  Process: 1250 ExecStartPre=/sbin/modprobe binder_linux (code=exited, status=0/SUCCESS)
  Process: 1265 ExecStartPre=/usr/share/anbox/anbox-bridge.sh start (code=exited, status=0/SUCCESS)
 Main PID: 1334 (anbox)
    Tasks: 9 (limit: 4915)
   Memory: 11.3M
   CGroup: /system.slice/anbox-container-manager.service
           └─1334 /usr/bin/anbox container-manager --daemon --privileged --data-path=/var/lib/anbox

Nov 08 12:17:33 frog systemd[1]: Starting Anbox Container Manager...
Nov 08 12:17:33 frog systemd[1]: Started Anbox Container Manager.

But when I try to start the session manager it claims the kernel modules are not installed:

$ anbox session-manager
[ 2019-11-08 12:25:39] [session_manager.cpp:130@operator()] Failed to start as either binder or ashmem kernel drivers are not loaded

Is this a known issue?

Tom
  • 1,242

2 Answers2

2

The kernel modules are there, but /dev/binder isn't—because that's not the way the binder_linux module works, now. morphis however consider it not a bug, because they have a pull request to make anbox work with the current binder_linux module. As far as I can tell, you should be able to make it work with the "edge" channel of the snap. I.e.,

sudo snap install --devmode --edge anbox

but my experience with snaps is non-existent

Auspex
  • 1,158
1

Same error here today, my system:

$ uname -a
Linux ntg-pc 5.3.0-26-generic #28-Ubuntu SMP Wed Dec 18 05:37:46 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux

One thing I've noticed is that although modprobe works ok, only /dev/ashmem is created...

sudo modprobe ashmem_linux
$ sudo modprobe binder_linux
$ lsmod | grep -e ashmem_linux -e binder_linux
2:ashmem_linux           20480  0
3:binder_linux          163840  0
$ ls -alh /dev/binder /dev/ashmem
ls: cannot access '/dev/binder': No such file or directory
crw------- 1 root root 10, 53 Jan 21 19:10 /dev/ashmem
ntg
  • 571