[Linuxulator] How to install Brave (Linux app) on FreeBSD 13.0+

I've tried using various combinations of --no-sandbox --no-zygote --test-type but they all either crash on startup or refuse to allow me to login.
 
I've the following error logs while booting. How can I fix that?


Code:
compat.linux.emul_path: /compat/linux -> /compat/ubuntu
stat: /compat/ubuntu/ome: stat: No such file or directory
stat: /compat/ubuntu/ome/..: stat: No such file or directory
stat: /compat/ubuntu/ome: stat: No such file or directory
stat: /compat/ubuntu/ome/..: stat: No such file or directory
 

Thanks again.

I can't imagine installation of Plasma Desktop (alone) leading to problems with Brave in Linuxulator.

[This stuff maybe better in another thread.] … Maybe the Brave issue after installing plasma5 was to do with application launchers or paths for different users. …

👍 If anyone can reproduce symptoms: let's start a new topic, or chat in a desktop channel.
 
I've tried using this process to run Chrome (adapting the 2 wrapper scripts to start /opt/google/chrome/chrome) and it consistently crashes:

Looking in /var/log/messages, I see a variety of error messages:


I've checked and /compat/ubuntu/proc/ is definitely mounted and looks like a Linux procfs. Does anyone have any suggestions to get it running?
I recently installed GhostBSD 13.1-STABLE and followed this guide to install Brave. I couldn't get Brave to run, it was crashing as well.
I then used this script and it worked fine. Might be worth giving it a go.
 
I recently installed GhostBSD 13.1-STABLE and followed this guide to install Brave. I couldn't get Brave to run, it was crashing as well.
I then used this script and it worked fine. Might be worth giving it a go.
The script description says it is based on OP.
 
*Notice: Accessing your google account won't work. It will display something like this:
"Couldn't sign you in This browser or app may not be secure. Try using a different browser. If you’re already using a supported browser, you can refresh your screen and try again to sign in."

To fix this, change your user agent to a non-chromium web browser, like Firefox for instance, and login to Gmail or any other google service (making sure to keep logged in). After this you can change your user agent back to default.
The good thing is you won't need to repeat this step later, not even when logging-in to a different account 👍.
For reference, this extension worked for me: User-Agent Switcher and Manager

Couldn’t sign you in​

This browser or app may not be secure. Learn more
Try using a different browser. If you’re already using a supported browser, you can try again to sign in.

Presently 2 issues with DRM content on https://iview.abc.net.au/:
1. Accessing Google account not working even if using the User-Agent Switcher and Manager.

Default agent

user-agent according to ua-parser-js v0.7.19

Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.60 Safari/537.36

Tried multiple versions of agents. Doesn't seem to make a difference if 2FA is enabled or not for account. Need more clues....

2. After logging in with a non-google account, DRM content streaming fails but ABC local (presume non-DRM) content is ok.

Video Player Error​

Sorry, there has been a technical error with this video stream. For tips and troubleshooting please check our technical support page .

Error Code: 203000
102630
203000
There is potentially an issue with the video you are trying to play.
This kind of error is usually resolved by:
  • rebooting your device and;
  • relaunching your web browser

The error code description is a bit vague.
 
The script description says it is based on OP.
But the guide for version 13.0 says it took its cue from the script on GitHub (exchange of favors). I can confirm that on 13.1 the script works for me, but not the guide.

EDIT: Actually this guide still works on 13.1, it was me doing something wrong. It works even better than the script because with this guide, I can log into my Google account.
 
Last edited:
Presently 2 issues with DRM content on https://iview.abc.net.au/:
1. Accessing Google account not working even if using the User-Agent Switcher and Manager.

Default agent


Tried multiple versions of agents. Doesn't seem to make a difference if 2FA is enabled or not for account. Need more clues....

2. After logging in with a non-google account, DRM content streaming fails but ABC local (presume non-DRM) content is ok.



The error code description is a bit vague.
You can try changing your user agent without the need of any extension by appending --user-agent="Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64)" to your Brave / Chrome wrapper. Something like this:
/usr/local/bin/linux-brave --user-agent="Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64)"
After login in for the first time, you won't need to use that workaround anymore. (Otherwise many websites look terribly outdated or kinda broken).
 
You can try changing your user agent without the need of any extension by appending --user-agent="Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64)" to your Brave / Chrome wrapper. Something like this:
/usr/local/bin/linux-brave --user-agent="Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64)"
After login in for the first time, you won't need to use that workaround anymore. (Otherwise many websites look terribly outdated or kinda broken).
So that worked. Brave wrapper looks like this.

Code:
# vi /compat/ubuntu/opt/brave.com/brave/brave-wrapper
.....
# Original
# "$HERE/brave" --no-sandbox --test-type --v=0 "$@" || true
# https://forums.freebsd.org/threads/linuxulator-how-to-install-brave-linux-app-on-freebsd-13-0.78879/post-533098
#  "$HERE/brave"  --no-sandbox --no-zygote --test-type --v=0 "$@" || true
 "$HERE/brave" --user-agent="Mozilla/5.0 (X11; FreeBSD amd64; Linux x86_64)" --no-sandbox --no-zygote --test-type --v=0 "$@" || true

ABC iview technical support replied on error 203000:
Code:
The ABC and its suppliers, authorised platform providers and content partners may embed digital rights management security in ABC iview or certain ABC Content and/or use other technical content protection measures as required to protect ABC Content from unauthorised access, and in order to meet obligations to third parties who own rights in ABC Content.

Please note, ABC iview is supported only with Google Chrome and Firefox browsers when using Linux.
 
Here are some things you can try to troubleshoot the issues:
1. Make sure you have the latest version of your internet browser installed.
2. Ensure that your browser's Digital Rights Management (DRM) settings are set to allow or enable.
3. Reduce the restrictive cookie settings, i.e. enable Allow Cookies and ensure browser add-ons or plugins such as ad blockers are allowing ABC iview to come through.
4. Switch off your internet modem/router for 30 seconds then switch everything on again.
5. Clear your web browser cache and delete temporary files.
There were no issues or changes made to 1,2,3. I ignored 4. Just had to delete the web site temporary files. Still took several attempts but the error flushed itself out and DRM video now plays in iview. I suggested they need to fix the bad code in iview.

PS works a bit better always clearing cookies on window close. Brave>Settings>Cookies...>Always clear cookies when windows are closed>[Add "abc.net.au" including third party cookies]. Still generates the error 203000 but second attempt to view seems to work.
 
Last edited:
# Set correct timezone inside your chroot:
printf "%b\n" "0.0 0 0.0\n0\nUTC" > /etc/adjtime
sudo dpkg-reconfigure tzdata # For some reason sudo is necessary here, otherwise it fails.
Between the two, I would add this:
Code:
dpkg-reconfigure locales
And I would delete the sudo because the only thing to fail is the missing language configuration, which precisely happens with the command to be added.
 
After upgrading to FreeBSD 13.1-RELEASE amd64, linux-brave stopped working with the following error message.

Code:
% linux-brave
No matching processes belonging to you were found
W: [(null)] caps.c: Normally all extra capabilities would be dropped now, but that's impossible because PulseAudio was built without capabilities support.
ELF interpreter /lib64/ld-linux-x86-64.so.2 not found, error 2
Abort trap
 

patovm04 Is there any way to add fonts to the browser? I've added a .fonts folder, with all the Google fonts in it, to the jail root home, but Chrome still fails to display some fonts correctly.​

 
Got Google Chrome working on FreeBSD-13.1-RELEASE.

It had worked as described by OP on FreeBSD-13.0-RELEASE, but stopped working after the OS-upgrade. The symptom was Chrome opening an empty window and displaying nothing.

I gathered up some information spread across this forum. Here is the resulting invocation of Chrome in the chrome-wrapper script (aka brave-wrapper):
Code:
...

export LIBGL_DRI3_DISABLE=1

"$HERE/chrome" --in-process-gpu --no-sandbox --no-zygote --test-type --enable-features=UseOzonePlatform --ozone-platform=x11 --v=0 "$@" || true
The Ozone- and Zygote-related switches are essential, as is the LIBGL_* variable!
 
I had trouble making it work on 13.1. However, followed Holger's instructions and replaced the $HERE/chrome with $HERE/brave (obvious, you would think, until you forget to do so<sigh>). I then had to restart the ubuntu service again, and try a couple of times, but in the end, it worked perfectly. I did need the line (not sure exactly which parts were needed, I just wanted it to work so didn't test), that Holger supplied but aside from that, the original tutorial worked.
 
Another streaming service binge.com.au fails on Linux multiple browsers with error:
Code:
InvalidStateError: Failed to execute 'update' on 'MediaKeySession': Rejected with system code (72)

Problem and fix are discussed here:
https://github.com/masterneko/binge-on-linux

Installed the chrome.crx file in Brave>Extensions and works now!
 
i am getting an error about security when trying to install brave in the chroot

Code:
root@my-ghostbsd-pc:/# apt update ; apt install -y brave-browser
Get:1 http://dl.google.com/linux/chrome/deb stable InRelease [1811 B]
Ign:2 https://repo.vivaldi.com/archive/deb stable InRelease                                             
Hit:3 http://archive.ubuntu.com/ubuntu focal InRelease                 
Err:1 http://dl.google.com/linux/chrome/deb stable InRelease
  The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 4EB27DB2A3B88B8B
Err:4 https://repo.vivaldi.com/archive/deb stable Release
  Certificate verification failed: The certificate is NOT trusted. The certificate chain uses expired certificate.  Could not handshake: Error in the certificate verification. [IP: 151.101.65.91 443]
Reading package lists... Done                     
W: GPG error: http://dl.google.com/linux/chrome/deb stable InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 4EB27DB2A3B88B8B
E: The repository 'http://dl.google.com/linux/chrome/deb stable InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
E: The repository 'https://repo.vivaldi.com/archive/deb stable Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
E: Unable to locate package brave-browser
 
Greetings,
Has anyone tried https://play.geforcenow.com/ ? Chrome crashes after a few seconds when I visit the site.

The same story is happening with gfn-electron wrapper https://github.com/hmlendea/gfn-electron

Cheers
Haven't tried before, but yes. Crashes Brave - renders home page then crashes - nasty.

Everything else works, except Amazon Prime won't do HD as on all Linux. (No issues on Windows 10 on same hardware.) Some suggest installing some wine components permits HD to play on Linux. Anyone know how to do this with Brave/Linuxulator?
 
Back
Top