19

For the past month or so, since upgrading to Ubuntu 24.04 (during the beta period), I've been getting this error when launching Flatpak applications from Gnome-Software or the terminal:

ldconfig failed, exit status 256

When I launch them otherwise, of course, there's no error, but also no apps.

Running: sudo flatpak -v repair --reinstall-all does fix the issue, but only temporarily. Installing any other Flatpak, or installing updates, immediately brings the error back.

Sometimes, the error also seems to be triggered when an application (for example Inkscape), crashes. After this, the application in question (possibly sometimes others) will no longer open until I repair everything as stated above.

I've been scouring the internet for solutions but coming up short. What should I do to get back to a normal, working state?

RolandiXor
  • 51,797

3 Answers3

27

Per this comment on the bug report for this issue:

Basically create the file /etc/apparmor.d/bwrap with the following contents :

abi <abi/4.0>,
include <tunables/global>

profile bwrap /usr/bin/bwrap flags=(unconfined) { userns,

Site-specific additions and overrides. See local/README for details.

include if exists <local/bwrap> }

and execute:

sudo systemctl reload apparmor
pwaterz
  • 477
7

From the original post (for Ubuntu 23.10) to disable the new constraints:

https://ubuntu.com/blog/ubuntu-23-10-restricted-unprivileged-user-namespaces

sudo sysctl -w kernel.apparmor_restrict_unprivileged_unconfined=0
sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0
lnksz
  • 171
-1

I am getting the same issue. I tried doing a fresh uninstall and install of flatpak flathub, without any luck.

  • Have you tried inspecting the issue?:

    flatpak --verbose run io.github.ungoogled_software.ungoogled_chromium

  • My error was due to missing pulseaudio config:

    Pulseaudio user configuration file '/home/user/.config/pulse/client.conf': Error opening file /home/user/.config/pulse/client.conf: No such file or directory

  • I resolved the issue by installing pulseaduio again and flatpak apps seem to be running fine.

I know this was how I solved the issue for particular application but maybe you could try this to resolve the issues you have. Good Luck!