balenaOS RPi 3/4 or balenaBrowser graphics issues

Dear all,

(maybe @chrisys - please tell me if I should note someone differently :slight_smile: )

last week I tried to roll out balenaBrowser on an RPi 4 with the latest dev OS BalenaOS 2.83.10+rev1.
However, balenaBrowser did always crash, I could not find a reason (and needed to deploy fast), so I switched back to BalenaOS 2.82.10+rev1 (dev) and it worked.

Fast forward to today, I need to deploy balenaBrowser on an RPi 3 (32 bit). I tried the latest dev OS BalenaOS 2.83.21+rev1 - and again, balenaBrowser crashed - but this time with a log:

[Live]    Watching for file changes...
[Live]    Waiting for device state to settle...
[Logs]    [2021-9-13 10:10:22] Creating volume 'settings'
[Logs]    [2021-9-13 10:10:22] Creating network 'default'
[Logs]    [2021-9-13 10:10:24] Installing service 'browser sha256:d149e39c490502f62695ae21b1dc572d70f8a76c985b88a7926a074d75311f14'
[Logs]    [2021-9-13 10:10:25] Installed service 'browser sha256:d149e39c490502f62695ae21b1dc572d70f8a76c985b88a7926a074d75311f14'
[Logs]    [2021-9-13 10:10:25] Starting service 'browser sha256:d149e39c490502f62695ae21b1dc572d70f8a76c985b88a7926a074d75311f14'
[Logs]    [2021-9-13 10:10:29] Started service 'browser sha256:d149e39c490502f62695ae21b1dc572d70f8a76c985b88a7926a074d75311f14'
[Logs]    [2021-9-13 10:10:32] [browser] umount: /dev: target is busy.
[Live]    Device state settled
[Logs]    [2021-9-13 10:10:32] [browser] mount: /sys/kernel/debug: nodev already mounted on /sys/kernel/debug.
[Logs]    [2021-9-13 10:10:34] [browser] Running balena base image entrypoint...
[Logs]    [2021-9-13 10:10:41] [browser] setting xserver-xorg-legacy/xwrapper/allowed_users from configuration file
[Logs]    [2021-9-13 10:10:42] [browser] balenaBlocks browser version: 2.0.3
[Logs]    [2021-9-13 10:10:42] [browser] Setting CPU Scaling Governor to 'performance'
[Logs]    [2021-9-13 10:10:42] [browser] Disabling cursor
[Logs]    [2021-9-13 10:10:42] [browser] Checking GPU memory
[Logs]    [2021-9-13 10:10:42] [browser] hostname: No address associated with hostname
[Logs]    [2021-9-13 10:10:43] [browser] xauth:  file /home/chromium/.Xauthority does not exist
[Logs]    [2021-9-13 10:10:43] [browser] xauth: (stdin):1:  bad display name "REDACTED:0" in "add" command
[Logs]    [2021-9-13 10:10:43] [browser]
[Logs]    [2021-9-13 10:10:43] [browser]
[Logs]    [2021-9-13 10:10:43] [browser] X.Org X Server 1.20.4
[Logs]    [2021-9-13 10:10:43] [browser] X Protocol Version 11, Revision 0
[Logs]    [2021-9-13 10:10:43] [browser] Build Operating System: Linux 5.10.17-v8+ aarch64 Raspbian
[Logs]    [2021-9-13 10:10:43] [browser] Current Operating System: Linux muscISSMap 5.10.31-v7 #1 SMP Fri Apr 23 15:16:49 UTC 2021 armv7l
[Logs]    [2021-9-13 10:10:43] [browser] Kernel command line: coherent_pool=1M 8250.nr_uarts=1 snd_bcm2835.enable_compat_alsa=0 snd_bcm2835.enable_hdmi=1 bcm2708_fb.fbwidth=1280 bcm2708_fb.fbheight=720 bcm2708_fb.fbswap=1 vc_mem.mem_base=0x3ec00000 vc_mem.mem_size=0x40000000  dwc_otg.lpm_enable=0 console=tty3 loglevel=3 vt.global_cursor_default=0 console=ttyS0,115200 rootwait cgroup_enable=memory root=UUID=58fd2e13-1c5b-47da-be8d-07c20740fda4 rootwait
[Logs]    [2021-9-13 10:10:43] [browser] Build Date: 19 April 2021  03:23:36PM
[Logs]    [2021-9-13 10:10:43] [browser] xorg-server 2:1.20.4-1+rpt3+deb10u3 (
[Logs]    [2021-9-13 10:10:43] [browser] Current version of pixman: 0.36.0
[Logs]    [2021-9-13 10:10:43] [browser]        Before reporting problems, check
[Logs]    [2021-9-13 10:10:43] [browser]        to make sure that you have the latest version.
[Logs]    [2021-9-13 10:10:43] [browser] Markers: (--) probed, (**) from config file, (==) default setting,
[Logs]    [2021-9-13 10:10:43] [browser]        (++) from command line, (!!) notice, (II) informational,
[Logs]    [2021-9-13 10:10:43] [browser]        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[Logs]    [2021-9-13 10:10:43] [browser] (==) Log file: "/var/log/Xorg.0.log", Time: Mon Sep 13 08:10:43 2021
[Logs]    [2021-9-13 10:10:43] [browser] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[Logs]    [2021-9-13 10:10:45] [browser] Detecting window size from framebuffer
[Logs]    [2021-9-13 10:10:45] [browser] Window size detected as 1280,720
[Logs]    [2021-9-13 10:10:46] [browser] dpkg-query: no packages found matching bluealsa
[Logs]    [2021-9-13 10:10:51] [browser] Browser API running on port: 5011
[Logs]    [2021-9-13 10:10:51] [browser] Using LAUNCH_URL: REDACTED
[Logs]    [2021-9-13 10:10:51] [browser] Enabling GPU
[Logs]    [2021-9-13 10:10:51] [browser] Enabling KIOSK mode
[Logs]    [2021-9-13 10:10:51] [browser] Starting Chromium with flags: --disable-features=TranslateUI,--disable-component-extensions-with-background-pages,--disable-background-networking,--disable-sync,--metrics-recording-only,--disable-default-apps,--no-default-browser-check,--no-first-run,--disable-backgrounding-occluded-windows,--disable-renderer-backgrounding,--disable-background-timer-throttling,--force-fieldtrials=*BackgroundTracing/default/,--window-size=1280,720,--window-position=0,0,--autoplay-policy=no-user-gesture-required,--noerrdialogs,--disable-session-crashed-bubble,--check-for-update-interval=31536000,--disable-dev-shm-usage,--enable-zero-copy,--num-raster-threads=4,--ignore-gpu-blacklist,--enable-gpu-rasterization
[Logs]    [2021-9-13 10:10:51] [browser] Displaying URL: --app= REDACTED
[Logs]    [2021-9-13 10:11:16] [browser] (node:196) UnhandledPromiseRejectionWarning: Error: connect ECONNREFUSED
[Logs]    [2021-9-13 10:11:16] [browser]     at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1144:16)
[Logs]    [2021-9-13 10:11:16] [browser] (node:196) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see (rejection id: 1)
[Logs]    [2021-9-13 10:11:16] [browser] (node:196) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

I don’t know, could be a bug in balenaOS regarding the X-Server?
Changing back to 2.80.3 (I could not figure out another version fast…) did work again without issues on the RPi 3.

I guess between 2.82.10 and 2.83.10 something broke something in balenaOS, because balenaBrowser has not changed in 3? 4? months.



Thanks for all the info @nmaas87 - I’ve pinged Mr. @rahul-thakoor as I know he was looking at a similar issue with the browser block last week.

1 Like

Hey @nmaas87

Thank you for pushing on this! @rahul-thakoor found that we disabled user namespacing support in OS version 2.83.21+rev1 which Chromium (and others) need for how they use a sandboxed process. We are looking into the best way to sort this out here:

In the meantime, you can carry on using BalenaOS 2.82.10+rev1 for the browser block, and we are looking into ways to make the browser block work despite user namespacing being disabled. For instance running chmod 4755 on the sandbox executable stops the crash.


1 Like

Thanks @chrisys @phil-d-wilson and @rahul-thakoor for the support.
For the moment (as these are offline, internal network / internet seperate-deployed RPis) I let them stay at the current version because we needed the services - so I am not in a terrible hurry to get a new version out. But I wanted to give more input and push so that the error gets fixed because - along this error and the USB problems with specifically RPi 4 Rev. 1.4 boards (due to the new way they handle the USB 3 controller) - it seems that these both issues are of highest priority right now, looking at the current incoming problems of other users - and as I had the same issue, I might give context :). So no worries and thanks for supporting! :slight_smile:

We really appreciate your efforts here @nmaas87 - it helped us zero in on the cause much quicker. :slight_smile:

1 Like