Failed to load anbox required ashmem binder modules with zen kernel

Hi Community !

I installed Garuda a week ago and everything went fine until I did a full system update. I had anbox working out of the box when first installed, but after the upgrade It does not load the required kernel modules.

[ 2022-06-08 16:47:12] [session_manager.cpp:149@operator()] Failed to start as either binder or ashmem kernel drivers are not loaded

I tried looking on the Arch forums but acording to this post, zen kernels should include this modules by default and not as external modules. thanks for all the help. This is the output of my garduda-inxi command:

System:
  Kernel: 5.18.1-zen1-1-zen arch: x86_64 bits: 64 compiler: gcc v: 12.1.0
    parameters: BOOT_IMAGE=/@/boot/vmlinuz-linux-zen
    root=UUID=d76ebb87-d569-4e03-abaa-dc45790bf71d rw rootflags=subvol=@
    quiet quiet splash rd.udev.log_priority=3 vt.global_cursor_default=0
    loglevel=3
  Desktop: KDE Plasma v: 5.24.5 tk: Qt v: 5.15.4 info: latte-dock
    wm: kwin_x11 vt: 1 dm: SDDM Distro: Garuda Linux base: Arch Linux
Machine:
  Type: Laptop System: HP product: HP Notebook v: CNB1
    serial: <superuser required> Chassis: type: 10 serial: <superuser required>
  Mobo: HP model: 81DF v: KBC Version 70.12 serial: <superuser required>
    UEFI: Insyde v: F.15 date: 07/21/2016
Battery:
  ID-1: BAT0 charge: 0% condition: 41.6/41.6 Wh (100.0%) volts: 1.5 min: 14.6
    model: Hewlett-Packard Primary type: Li-ion serial: <filter> status: N/A
CPU:
  Info: model: Intel Core i3-5005U bits: 64 type: MT MCP arch: Broadwell
    family: 6 model-id: 0x3D (61) stepping: 4 microcode: 0x2F
  Topology: cpus: 1x cores: 2 tpc: 2 threads: 4 smt: enabled cache:
    L1: 128 KiB desc: d-2x32 KiB; i-2x32 KiB L2: 512 KiB desc: 2x256 KiB
    L3: 3 MiB desc: 1x3 MiB
  Speed (MHz): avg: 1900 high: 1901 min/max: 500/1900 scaling:
    driver: intel_cpufreq governor: schedutil cores: 1: 1901 2: 1900 3: 1900
    4: 1900 bogomips: 15999
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
  Vulnerabilities:
  Type: itlb_multihit status: KVM: VMX disabled
  Type: l1tf
    mitigation: PTE Inversion; VMX: conditional cache flushes, SMT vulnerable
  Type: mds mitigation: Clear CPU buffers; SMT vulnerable
  Type: meltdown mitigation: PTI
  Type: spec_store_bypass
    mitigation: Speculative Store Bypass disabled via prctl
  Type: spectre_v1
    mitigation: usercopy/swapgs barriers and __user pointer sanitization
  Type: spectre_v2 mitigation: Retpolines, IBPB: conditional, IBRS_FW,
    STIBP: conditional, RSB filling
  Type: srbds mitigation: Microcode
  Type: tsx_async_abort status: Not affected
Graphics:
  Device-1: Intel HD Graphics 5500 vendor: Hewlett-Packard driver: i915
    v: kernel ports: active: eDP-1 empty: DP-1,HDMI-A-1 bus-ID: 00:02.0
    chip-ID: 8086:1616 class-ID: 0300
  Device-2: Chicony HP Webcam type: USB driver: uvcvideo bus-ID: 1-1.5:3
    chip-ID: 04f2:b52d class-ID: 0e02 serial: <filter>
  Display: x11 server: X.Org v: 21.1.3 with: Xwayland v: 22.1.2
    compositor: kwin_x11 driver: X: loaded: modesetting
    alternate: fbdev,intel,vesa gpu: i915 display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1366x768 s-dpi: 96 s-size: 361x203mm (14.21x7.99")
    s-diag: 414mm (16.31")
  Monitor-1: eDP-1 model: BOE Display 0x0696 built: 2015 res: 1366x768
    hz: 60 dpi: 112 gamma: 1.2 size: 309x173mm (12.17x6.81")
    diag: 354mm (13.9") ratio: 16:9 modes: 1366x768
  OpenGL: renderer: Mesa Intel HD Graphics 5500 (BDW GT2)
    v: 4.6 Mesa 22.1.1 direct render: Yes
Audio:
  Device-1: Intel Broadwell-U Audio vendor: Hewlett-Packard
    driver: snd_hda_intel v: kernel bus-ID: 00:03.0 chip-ID: 8086:160c
    class-ID: 0403
  Device-2: Intel Wildcat Point-LP High Definition Audio
    vendor: Hewlett-Packard driver: snd_hda_intel v: kernel bus-ID: 00:1b.0
    chip-ID: 8086:9ca0 class-ID: 0403
  Sound Server-1: ALSA v: k5.18.1-zen1-1-zen running: yes
  Sound Server-2: PulseAudio v: 16.0 running: no
  Sound Server-3: PipeWire v: 0.3.51 running: yes
Network:
  Device-1: Realtek RTL810xE PCI Express Fast Ethernet
    vendor: Hewlett-Packard driver: r8169 v: kernel pcie: gen: 1
    speed: 2.5 GT/s lanes: 1 port: 4000 bus-ID: 01:00.0 chip-ID: 10ec:8136
    class-ID: 0200
  IF: enp1s0 state: up speed: 100 Mbps duplex: full mac: <filter>
  Device-2: Realtek RTL8723BE PCIe Wireless Network Adapter
    vendor: Hewlett-Packard driver: rtl8723be v: kernel pcie: gen: 1
    speed: 2.5 GT/s lanes: 1 port: 3000 bus-ID: 02:00.0 chip-ID: 10ec:b723
    class-ID: 0280
  IF: wlp2s0 state: down mac: <filter>
  IF-ID-1: anbox0 state: down mac: <filter>
  IF-ID-2: docker0 state: down mac: <filter>
Bluetooth:
  Device-1: Realtek Bluetooth Radio type: USB driver: btusb v: 0.8
    bus-ID: 1-1.6:4 chip-ID: 0bda:b008 class-ID: e001 serial: <filter>
  Report: bt-adapter ID: hci0 rfk-id: 0 state: up address: <filter>
Drives:
  Local Storage: total: 1.13 TiB used: 867.27 GiB (75.1%)
  SMART Message: Unable to run smartctl. Root privileges required.
  ID-1: /dev/sda maj-min: 8:0 vendor: Crucial model: CT240BX500SSD1
    size: 223.57 GiB block-size: physical: 512 B logical: 512 B speed: 6.0 Gb/s
    type: SSD serial: <filter> rev: 052 scheme: GPT
  ID-2: /dev/sdb maj-min: 8:16 vendor: Toshiba model: MQ01ABD100
    size: 931.51 GiB block-size: physical: 4096 B logical: 512 B
    speed: 6.0 Gb/s type: HDD rpm: 5400 serial: <filter> rev: 4C scheme: GPT
Partition:
  ID-1: / raw-size: 206.16 GiB size: 206.16 GiB (100.00%)
    used: 40.99 GiB (19.9%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
  ID-2: /boot/efi raw-size: 300 MiB size: 299.4 MiB (99.80%)
    used: 716 KiB (0.2%) fs: vfat dev: /dev/sda1 maj-min: 8:1
  ID-3: /home raw-size: 206.16 GiB size: 206.16 GiB (100.00%)
    used: 40.99 GiB (19.9%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
  ID-4: /var/log raw-size: 206.16 GiB size: 206.16 GiB (100.00%)
    used: 40.99 GiB (19.9%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
  ID-5: /var/tmp raw-size: 206.16 GiB size: 206.16 GiB (100.00%)
    used: 40.99 GiB (19.9%) fs: btrfs dev: /dev/sda2 maj-min: 8:2
Swap:
  Kernel: swappiness: 133 (default 60) cache-pressure: 100 (default)
  ID-1: swap-1 type: zram size: 15.54 GiB used: 2.28 GiB (14.7%)
    priority: 100 dev: /dev/zram0
  ID-2: swap-2 type: partition size: 17.11 GiB used: 0 KiB (0.0%)
    priority: -2 dev: /dev/sda3 maj-min: 8:3
Sensors:
  System Temperatures: cpu: 60.0 C mobo: 0.0 C
  Fan Speeds (RPM): N/A
Info:
  Processes: 356 Uptime: 3h 12m wakeups: 6 Memory: 15.54 GiB
  used: 8.91 GiB (57.3%) Init: systemd v: 251 tool: systemctl Compilers:
  gcc: 12.1.0 clang: 13.0.1 Packages: pacman: 1970 lib: 409 Shell: fish
  v: 3.4.1 running-in: konsole inxi: 3.3.16
Garuda (2.6.3-2):
  System install date:     2022-05-24
  Last full system update: 2022-06-08 ↻
  Is partially upgraded:   No
  Relevant software:       NetworkManager
  Windows dual boot:       No/Undetected
  Snapshots:               Snapper
  Failed units:            systemd-networkd-wait-online.service 

You need to reboot after updating the kernel.

4 Likes

I tried that multiple times and I even tried booting with previous snapshots but it seems like they are more recent that that update because I kept installing individual packages after the update and each action was recorded as snapshot.

I'd suggest you get your system up-to-date and re-post the garuda-inxi information so we know where we stand.

Then, read through the Arch wiki page for anbox (Anbox - ArchWiki), specifically the part about using the linux-zen kernel.

4 Likes

This could be the reason.

7 Likes

In which case, the workaround would be to use linux-lts while waiting for the anbox developers to fix their software.

4 Likes

Oh!! Thanks for pointing this out !! I don't have time to try it now but at least you put me in the right track.

1 Like

Setting sys.use_memfd=true option in /var/lib/waydroid/waydroid_base.prop and restarting the container is supposed to help on Waydroid, maybe something like this exists in Anbox too?

Edit: it seems there were no more commits to their repo since 8 months, so unlikely :thinking: waydroid however seems to have figured it out, might be a valid solution to switch to it for Wayland users only.

5 Likes

Switching to lts does not fix the issue…

sudo modprobe -a binder_linux ashmem_linux
[sudo] password for USER:              
modprobe: WARNING: Module binder_linux not found in directory /lib/modules/5.15.55-1-lts
modprobe: WARNING: Module ashmem_linux not found in directory /lib/modules/5.15.55-1-lts
1 Like

Hi @shard, welcome to the Garuda community! Hope you'll find the forum and wiki as helpful as I have. :slightly_smiling_face:

To be honest, I've ran into the same problem as you without any success getting the ashmem module to load.

After days of digging through the Arch wiki, I finally got it working by downloading and compiling the xanmod-anbox kernel from Aur with all the modules in place.

Compiling my first kernel completely self-taught wan't easy but in doing so, you have much better overall support for your hardware

2 Likes

Please read the wiki page (already linked earlier in the thread) where module installation is described in some detail: https://wiki.archlinux.org/title/Anbox#Module_installation_options

2 Likes