Generic x86_64 chromium not loading

Testing out Balena, tried to use browser image posted on git (https://github.com/balenablocks/browser) for my Generic x86_64 image. Please see log snippet below:

03.09.21 11:27:43 (-0500) browser (==) Using system config directory “/usr/share/X11/xorg.conf.d”
03.09.21 11:27:43 (-0500) browser (II) modeset(0): Initializing kms color map for depth 24, 8 bpc.
03.09.21 11:27:43 (-0500) browser Detecting window size from framebuffer
03.09.21 11:27:43 (-0500) browser Window size detected as 1920,1080
03.09.21 11:27:44 (-0500) browser Browser API running on port: 5011
03.09.21 11:27:44 (-0500) browser Using LAUNCH_URL: https://google.com
03.09.21 11:27:44 (-0500) browser Enabling GPU
03.09.21 11:27:44 (-0500) browser Enabling KIOSK mode
03.09.21 11:27:44 (-0500) 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=1920,1080,–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
03.09.21 11:27:44 (-0500) browser Displaying URL: --app= https://google.com
03.09.21 11:28:09 (-0500) browser (node:235) UnhandledPromiseRejectionWarning: Error: connect ECONNREFUSED 127.0.0.1:35173
03.09.21 11:28:09 (-0500) browser at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1144:16)
03.09.21 11:28:09 (-0500) browser (node:235) 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 Command-line options | Node.js v16.8.0 Documentation). (rejection id: 1)

Hello @kid welcome to the balena community!

Our team just made a PR on the repo to make the errors more readable (check here) and we are speaking internally to solve this issue. We will keep you updated once this is solved.

Thank you for sending us the logs and let’s stay connected.

BTW could you please give us more details to try to reproduce this issue ourselves? What Intel device are you using? what OS and supervisor version?

Thanks

CPU: OptiPlex 3050
Specification:
Dell Specs

HOST OS VERSION
balenaOS 2.83.18+rev1

SUPERVISOR VERSION
12.10.3

@mpous, should I retest, so I can receive a more meaningful error message?

Hello @kid my colleagues from the Labs team are trying to reproduce your issue and see where this is coming from. We will keep you updated.

Meanwhile if you succeed on another part of the application let us know.

Let’s stay connected

Hello @kid

Can you please share more details on how you are deploying the browser block?

  • Are you using a docker-compose file?
  • If so, can you please share it? Want to make sure you have the right settings especially for ports

Thanks

@rahul-thakoor I am using the docker-compose file from here: https://github.com/balenablocks/browser/blob/master/docker-compose.yml (verbatim).

Adding a little more context this work for me on a Raspberry pie. But no success with the X86

@rahul-thakoor any updates?

Hey @kid,

Thank you for reporting this. We found that from 2.83.10+rev1 we have disabled user namespacing as a security measure. However Chromium relies on it for starting the browser in a sandbox process. We are looking into the best way of sorting this here: https://github.com/balena-os/meta-balena/issues/2319
We are also working out how to stop this being an issue in the browser block here: https://github.com/balenablocks/browser/issues/77

For now you can use OS version 2.82.10+rev1 without issue, and we’ll let you know when the issues have been resolved.

Phil

1 Like

@phil-d-wilson I don’t see OS version 2.82.10+rev1.
Do you recommend downgrading to version 2.58.6+rev1?

@kid

I would hold tight, we have a fix for the browser block we’re just testing.

@phil-d-wilson This is great let me hold, because I was in the process of downgrading my OS (Already downgraded 2 machines).

@phil-d-wilson I pulled branch “https://github.com/balenablocks/browser/pull/83” and this is working.
let me know when this is merged and the image created.

1 Like

Oh great! Thanks for testing it already! :grin:

Mr @rahul-thakoor, your work is already tested here. Nice job. :+1:

1 Like

@phil-d-wilson @rahul-thakoor I found a bug in the Browser code change that I am testing.
I noticed when “ROTATE_DISPLAY = right” the screen is blank but when no “ROTATE_DISPLAY” is set the screen is visible.
I also downgrade to OS version 2.56.6+rev1 and retest and the screen rotate correct and the display is alway visible.

@rahul-thakoor I also noticed that if the launch url is pointing to a carousel with kiosk mode enabled. The webpage stays on the first display. I am also seeing some slow rendering of gif contents at time.

@kid Thanks - we have a similar issue open here:

ROTATE_DISPLAY does not work on RPi 4 · Issue #75 · balenablocks/browser (github.com)

I’ll link this support thread to that issue, so that we can investigate and update you. Thank you for letting us know that an OS downgrade works around the problem, that may help us understand what is happening.

Phil

BTW the latest image is pushed to dockerhub, with the fix for the Chromium sandbox crashes.