Brave keeps crashing every few minutes

Hello,

I’m new to OpenSuse and currently at a loss about what to do. I switched from Linux Mint on my old laptop to OpenSuse Tumbleweed Slowroll with KDE Plasma on my new laptop because I wanted something more modern and with Wayland. Everything is working great so far except for Brave.

The browser just keeps crashing every few minutes when hardware acceleration is enabled. It’s a completely new install of the system and the browser. I could use it without hardware acceleration but this wastes a lot of energy in portable mode.

How can I diagnose this issue? I’m still a novice Linux user.

Operating System: openSUSE Tumbleweed-Slowroll 20250601
KDE Plasma Version: 6.3.5
KDE Frameworks Version: 6.14.0
Qt Version: 6.9.0
Kernel Version: 6.15.3-1.0.10.sr20250601-default (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 9 8945HS w/ Radeon 780M Graphics
Memory: 30.6 GiB of RAM
Graphics Processor: AMD Radeon Graphics
Manufacturer: ASUSTeK COMPUTER INC.
Product Name: ASUS Vivobook S 15 M5506UA_M5506UA
System Version: 1.0

Hi. Being an external repository to openSUSE, I think you should better ask in the Brave forum.
My advice is not to add external repositories to openSUSE as much as possible, both for security and stable operation of the system.
You can use Chromium directly from the official openSUSE repositories and add the ublock origin lite extension, enabling the filter lists. You will have a browser similar to Brave in terms of ad blocking, privacy and speed.

As far as I know it is either Tumbleweed or Slowroll.
Better explain what you really use so others can help more efficient.

I did install Brave with the official installation script which added the brave repo to my system but I could also test the flatpak if you think that makes a difference.

I noticed that the screen sometimes flashes black when using Brave with hwa. If this was Windows I would assume this is a graphics driver bug.

I’m using Slowroll. But it identifies itself as “openSUSE Tumbleweed-Slowroll 20250601”.

Not an unusual issue. There is one well-known “fix” , and is used not just for Brave, but for all Chromium based browsers. Delete Brave’s GPUCache content.

Explained here:

If that does not fix the issue, log out of your user account, then at login screen, choose “Plasma / X11” (vs “Plasma / Wayland”) and log in … test.
Not unusual for Wayland to cause the issue.

Started brave yesterday. It’s running some 24 hours without further ado:

karl@erlangen:~> journalctl --user -b -u app-brave*
Jun 27 14:22:15 erlangen systemd[1380]: Started Brave Web Browser - Web Browser.
Jun 27 14:22:17 erlangen brave-browser-stable[171483]: [171484:171501:0627/142217.975131:ERROR:crypto/nss_util.cc:344] After loading Root Certs, loaded==false: NSS error code: -8018
Jun 27 14:22:47 erlangen brave-browser-stable[171483]: [171484:171664:0627/142247.815273:ERROR:../src/content/browser/browser_main_loop.cc:278] GLib: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
Jun 27 14:22:47 erlangen brave-browser-stable[171483]: [171484:171663:0627/142247.815273:ERROR:../src/content/browser/browser_main_loop.cc:278] GLib: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
Jun 27 14:22:47 erlangen brave-browser-stable[171483]: [171484:171665:0627/142247.815274:ERROR:../src/content/browser/browser_main_loop.cc:278] GLib: g_main_context_pop_thread_default: assertion 'stack != NULL' failed
karl@erlangen:~> 

Thank you! I don’t want to call it right now, but it at least seems like deleting the GPUCache folders in all the profile folders has fixed the issue. This is really surprising to me as I started with a fresh install of Brave and immediately encountered the issues.

I’m really surprised to get so many helpful comments on a saturday. This community is amazing! :grin:

choose “Plasma / X11” (vs “Plasma / Wayland”) and log in … test.

I will try X11 to diagnose the issue if it still persists, however X11 isn’t really usable for me day to day as it is extremely limited and seems to support only half the features of my hardware (no HDR, bad support for my mixed refresh display setup, bad support for wide color gamut, no variable refresh-rate, no per screen fractional scaling, etc). Good Wayland support is why I made the switch from Linux Mint. :slight_smile:

It is an odd anomaly, isn’t it (?).

We use Brave for 80% of browsing activity. Chrome for personal account activity.

When we used TW, we experienced this issue somewhat regularly … we eventually wrote a script to do the delete GPUCache subdir for Chrome and Brave.

If you do a search in the TW forum, you will find numerous posts about this issue and the solution.

We have since switched to Leap, and have NEVER experienced the issue anymore.

As it is a users help users forum it should not surprise you that in the weekend most users have more time to try helping then during working hours.

Yeah, I encountered the issue again after the next reboot…

The script is a good idea. I replaced the shortcut to Brave with a script containing

rm -rf "/home/Susfra/.config/BraveSoftware/Brave-Browser/Default/GPUCache"
rm -rf "/home/Susfra/.config/BraveSoftware/Brave-Browser/Profile 1/GPUCache"

...

rm -rf "/home/Susfra/.config/BraveSoftware/Brave-Browser/Profile 10/GPUCache"

brave-browser &

And that seems to help. Let’s see how permanent this solution is. Leap with its yearly releases would be fine for me in general but right now it’s just a bit too old for my new hardware with its kernel 6.4. Maybe I will reconsider with Leap 16 in Fall.

@Susfra … here’s a “notice” posted (a Brave Support team member) back in 2023 at Brave website.

That post has a link to a Ghacks article, claiming updates to LLVM cause the various browser issues.

If you do a Net search with:
linux GPUCache issue
… you will see it affects Chromium-based browsers and distros.

All recommend the “delete GPUCache” workaround. :+1:

Oh, one other thing. Some apps (not browsers) that use underlying web features, can also have the same issues

Such as Electron-based apps … discord, vscode, obsidian, etc.

Please post the script.

I’m having a hard time synchronizing both commands.

This launch the browser without deleting GPUCache

#!/bin/bash

rm -rf "~/.config/BraveSoftware/Brave-Browser/Default/GPUCache"
rm -rf "~/.config/BraveSoftware/Brave-Browser/Profile\ 1/GPUCache"

brave-browser &

The script I posted above works for me. Are you sure your paths are correct? “…Profile\ 1/GPUCache…” looks wrong to me for example.

I have to say that running Brave/Chromium trough a script like this isn’t a perfect solution. For example Brave will start fine but when I try to open a file (.pdf for example) or a link, Brave opens the profile manager instead of opening the file and I can’t choose any of the open profiles since they are already running.

I can start Brave using the script and then open files/links by calling Brave directly without the script which opens the file/link in the most recent Brave window as it should. However this then causes Brave to crash again soon after… So this is a bit of a mess.

Basically:

  1. Using Brave with HWA: Crashes
  2. Using Brave without HWA: No crashes but bad performance
  3. Deleting GPUCache before opening Brave: Problems related to profiles

Right now I’m testing the command line argument brave-browser --disable-gpu-shader-disk-cache and hope that this is a better solution.

Thank you for answering. For me, both commands not carried out at the same time.
From script Browser launches but fails to extinguish GPUCache folder.

My secondary “Profile 1” folder have a space, won’t deleting anything if i don’t put \ before.
Directories with space this is how it is done to read, or delete a file.

This command won’t delete files inside GPUCache.
$ rm -rf ~/.config/BraveSoftware/Brave-Browser/Profile 1/GPUCache/*
This does (tested) correct.
$ rm -rf ~/.config/BraveSoftware/Brave-Browser/Profile\ 1/GPUCache/*

Indeed, not a perfect solution to launch browser with a script, so we call it workaround.

Basically to me:

  1. Using Brave with HWA: Crashes
  2. Using Brave without HWA: Still Crashes
  3. Continue running background apps when Brave is closed: Enabled but Crashes.
  4. Deleting GPUCache before opening browser regenerates it again as soon launched: Crashes
  5. Deleting GPUCache after browser launched - Not Crashing all time the browser is running.

As soon as i launch Brave i have to run this alias command in Konsole.
alias gp1="rm -rf ~/.config/BraveSoftware/Brave-Browser/Default/GPUCache/*"

I’ll test too –disable-gpu-shader-disk-cache to see how it goes.

So what’s your experience with –disable-gpu-shader-disk-cache so far?

Brave still runs great so far for me.

Didn’t get any crash at all launch with

–disable-gpu-shader-disk-cache

I did two days test without closing browser and haven’t a single crash.

However, i switched to LibreWolf just a little while ago. Firefox is it lot more stable on Tumbleweed as far as i have ascertained.

Okay … just to be clear (seems to be slight confusion), I thought I’d jump in and provide feedback :+1:

  1. The “GPUCache issue” we (and many others) experienced all the time is when we used TW. Since we moved to Leap, never an issue.
  2. The setting
    “disable-gpu-shader-disk-cache”
    is used to DISABLE the creation of the GPUCache subdirectory contents and its intended function.
  3. It’s also worth reiterating… this GPUCache issue can affect ALL Chromium based browsers … it’s NOT specific to Brave. A 'Net search will reveal this issue.

So, to further #2, if you use the
“disable-gpu-shader-disk-cache”
setting, there is NO NEED to constantly delete the GPUCache subdirectory contents, because that setting “turns it off”. Doing both is redundant.

The GPUCache feature is designed to improve performance of the browser.

1 Like

Thank you for your writing myswtest.

When i started writing here opened a thread on reddit early.

People address the Tumbleweed issue for Chromium/Brave crash.
According to them, there is no such crash in other distros like Fedora.

I didn’t manage to test it with LIVECD as haven’t time for it.

When i run Brave with below command, i didn’t perform removing GPUCache since it’s more or less the same thing.

disable-gpu-shader-disk-cache

However, the situation with Brave is not very pleasant in Tumbleweed.

You should not rely on a nine day old Reddit post with only 4 Replies.

There are countless hits about this issue, many of which are not associated with openSUSE … and go back years. Many are on cutting edge distros.

Go back to earlier posts … this also affects Electron-based apps, not just browser specific.

1 Like