ubuntu-asahi icon indicating copy to clipboard operation
ubuntu-asahi copied to clipboard

Installing vlc crashes X configuration

Open mpgalaxy opened this issue 5 months ago • 8 comments

Hi,

I installed Ubuntu desktop 25.04 on my M1, worked flawlessly. Running ubuntu I did a (in terminal)

apt-get update && apt-get upgrade

followed by

apt-get clean && apt-get autoremove

Even after reboot everything is working perfectly. Hardware acceleration for youtube is working perfectly fine, although DRM in firefox and chromium is not working and I couldn't get it to work.

Then I installed vlc via apt and on next reboot the X configuration was completely broken due to driver issues, I was stuck in console.

Could you please investigate / check why this is happening exactly ?

mpgalaxy avatar Sep 26 '25 07:09 mpgalaxy

Thanks, I'll take a look. Can you extract some logs from your system, in particular /var/log/apt?

tobhe avatar Sep 26 '25 11:09 tobhe

Hardware acceleration for youtube is working perfectly

Hard to believe since the drivers do not exist yet.

Are you not using Wayland?

mkurz avatar Sep 26 '25 11:09 mkurz

Thanks, I'll take a look. Can you extract some logs from your system, in particular /var/log/apt?

Hi, this is my apt history on the regular system: history.log

And this is my dmesg: dmesg.txt

Gigabit LAN via usb is working out of the box, but I couldn't upload any files in the browser (firefox, chromium), had to transfer them and upload in MacOS. Sometimes when I start a terminal I get an error, but it works perfetcly anyway and there doesn't seem to be a pattern when this occurrs.

mpgalaxy avatar Sep 26 '25 17:09 mpgalaxy

Hardware acceleration for youtube is working perfectly

Hard to believe since the drivers do not exist yet.

Are you not using Wayland?

I'm using the ubuntu image as provided. Playing 4k streams in youtube on full screen the cpu cores are between 20 and 30 %, mostly at 20/25 (using firefox).

mpgalaxy avatar Sep 26 '25 18:09 mpgalaxy

I'm using the ubuntu image as provided. Playing 4k streams in youtube on full screen the cpu cores are between 20 and 30 %, mostly at 20/25 (using firefox).

That does not mean acceleration acceleration is enabled. The Video decoder is still WIP: https://asahilinux.org/docs/platform/feature-support/m1/#table-of-contents You are using the CPU to decode video, not the gpu.

mkurz avatar Sep 26 '25 20:09 mkurz

@tobhe : I just installed vlc, now providing you with the before and after comparison. At first the apt packages to be installed with vlc (output is in german):

Die folgenden zusätzlichen Pakete werden installiert:
  fonts-freefont-ttf liba52-0.7.4 libaacs0 libaribb24-0t64 libass9 libavcodec61 libavformat61 libavutil59 libbdplus0
  libbluray2 libcddb2 libchromaprint1 libcjson1 libcodec2-1.2 libdav1d7 libdc1394-25 libdca0 libdvbpsi10 libdvdnav4
  libdvdread8t64 libebml5 libegl-mesa0 libfaad2 libgbm1 libgl1-mesa-dri libglx-mesa0 libgme0 libgsm1 libixml11t64
  libkate1 liblua5.2-0 libmad0 libmatroska7 libmbedcrypto16 libmpcdec6 libmpeg2-4 libnorm1t64 libopenmpt-modplug1
  libopenmpt0t64 libpgm-5.3-0t64 libpostproc58 libprotobuf-lite32t64 libproxy-tools librabbitmq4 librav1e0.7
  libresid-builder0c2a librist4 libshine3 libsidplay2 libsoxr0 libspatialaudio0t64 libsrt1.5-gnutls libsvtav1enc2
  libswresample5 libswscale8 libudfread0 libunibreak6 libupnp17t64 libva-wayland2 libva-x11-2 libvdpau1 libvlc-bin
  libvlc5 libvlccore9 libx264-164 libx265-215 libxcb-composite0 libxvidcore4 libzmq5 libzvbi-common libzvbi0t64
  mesa-libgallium mesa-vdpau-drivers ocl-icd-libopencl1 vdpau-driver-all vlc-bin vlc-data vlc-l10n
  vlc-plugin-access-extra vlc-plugin-base vlc-plugin-notify vlc-plugin-qt vlc-plugin-samba vlc-plugin-skins2
  vlc-plugin-video-output vlc-plugin-video-splitter vlc-plugin-visualization
Vorgeschlagene Pakete:
  libcuda1 libnvcuvid1 libnvidia-encode1 libbluray-bdj libdvdcss2 opencl-icd libvdpau-va-gl1 vlc-plugin-fluidsynth
  vlc-plugin-jack vlc-plugin-pipewire vlc-plugin-svg
Die folgenden Pakete werden ENTFERNT:
  libgl1-amber-dri libglapi-amber
Die folgenden NEUEN Pakete werden installiert:
  fonts-freefont-ttf liba52-0.7.4 libaacs0 libaribb24-0t64 libass9 libavcodec61 libavformat61 libavutil59 libbdplus0
  libbluray2 libcddb2 libchromaprint1 libcjson1 libcodec2-1.2 libdav1d7 libdc1394-25 libdca0 libdvbpsi10 libdvdnav4
  libdvdread8t64 libebml5 libfaad2 libgme0 libgsm1 libixml11t64 libkate1 liblua5.2-0 libmad0 libmatroska7
  libmbedcrypto16 libmpcdec6 libmpeg2-4 libnorm1t64 libopenmpt-modplug1 libopenmpt0t64 libpgm-5.3-0t64 libpostproc58
  libprotobuf-lite32t64 libproxy-tools librabbitmq4 librav1e0.7 libresid-builder0c2a librist4 libshine3 libsidplay2
  libsoxr0 libspatialaudio0t64 libsrt1.5-gnutls libsvtav1enc2 libswresample5 libswscale8 libudfread0 libunibreak6
  libupnp17t64 libva-wayland2 libva-x11-2 libvdpau1 libvlc-bin libvlc5 libvlccore9 libx264-164 libx265-215
  libxcb-composite0 libxvidcore4 libzmq5 libzvbi-common libzvbi0t64 mesa-vdpau-drivers ocl-icd-libopencl1
  vdpau-driver-all vlc vlc-bin vlc-data vlc-l10n vlc-plugin-access-extra vlc-plugin-base vlc-plugin-notify
  vlc-plugin-qt vlc-plugin-samba vlc-plugin-skins2 vlc-plugin-video-output vlc-plugin-video-splitter
  vlc-plugin-visualization
Die folgenden Pakete werden aktualisiert (Upgrade):
  libegl-mesa0 libgbm1 libgl1-mesa-dri libglx-mesa0 mesa-libgallium

Maybe it is because of the removal of libgl1-amber-dri libglapi-amber. Autoremove also listed libllvm18:arm64 (1:18.1.8-17) for removal.

Or the update of libegl-mesa0 libgbm1 libgl1-mesa-dri libglx-mesa0 mesa-libgallium breaks the mesa stuff.

Here is my syslog of the broken system with vlc: syslog-with-vlc.txt

and dmesg: dmesg-with-vlc.txt

Xorg.log: Xorg.log

from syslog:

2025-09-27T09:38:00.249178+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (II) AIGLX: Screen 0 is not DRI2 capable
2025-09-27T09:38:00.252103+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: DRM_IOCTL_ASAHI_GET_PARAMS failed: Invalid argument
2025-09-27T09:38:00.255972+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_IOCTL_VIRTGPU_GET_CAPS failed with Bad file descriptor
2025-09-27T09:38:00.255998+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_IOCTL_VIRTGPU_CONTEXT_INIT failed with Bad file descriptor, continuing without context...
2025-09-27T09:38:00.256008+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.256016+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.256142+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.256151+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.256410+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.256418+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.258306+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.258319+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.258327+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.258334+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.258342+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.258349+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.258357+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: DRM_VIRTGPU_RESOURCE_CREATE_BLOB failed with Bad file descriptor
2025-09-27T09:38:00.258365+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: MESA: error: Failed to create virtgpu AddressSpaceStream
2025-09-27T09:38:00.260529+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: DRM_IOCTL_ASAHI_GET_PARAMS failed: Invalid argument
2025-09-27T09:38:00.260539+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE)
2025-09-27T09:38:00.260547+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE) Backtrace:
2025-09-27T09:38:00.260652+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE) unw_get_proc_info failed: no unwind info found [-10]
2025-09-27T09:38:00.260662+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE)
2025-09-27T09:38:00.260669+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE) Segmentation fault at address 0x40
2025-09-27T09:38:00.260677+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE)
2025-09-27T09:38:00.260685+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: Fatal server error:
2025-09-27T09:38:00.260693+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE) Caught signal 11 (Segmentation fault). Server aborting
2025-09-27T09:38:00.260701+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE)
2025-09-27T09:38:00.260711+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE)
2025-09-27T09:38:00.260719+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: Please consult the The X.Org Foundation support
2025-09-27T09:38:00.260726+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: #011 at http://wiki.x.org
2025-09-27T09:38:00.260734+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]:  for help.
2025-09-27T09:38:00.260742+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
2025-09-27T09:38:00.260750+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE)
2025-09-27T09:38:00.262502+02:00 m1galaxy /usr/libexec/gdm-x-session[2774]: (EE) Server terminated with error (1). Closing log file.

hope that helps

Add1: I tried to reinstall libgl1-amber-dri libglapi-amber, but that completely broke my system, deleted the Container and partitions and installed from scratch via install.sh. Now my system is back to initial state. I did an apt-get update without upgrade and provided you the list of packages that would be upgraded initially: initial-upgrade-list.txt

mpgalaxy avatar Sep 27 '25 08:09 mpgalaxy

Interesting, yes it does indeed look like a mesa issue. I wonder if installing mesa from this ppa that always backports the latest version helps: https://launchpad.net/~kisak/+archive/ubuntu/kisak-mesa

tobhe avatar Sep 27 '25 20:09 tobhe

Interesting, yes it does indeed look like a mesa issue. I wonder if installing mesa from this ppa that always backports the latest version helps: https://launchpad.net/~kisak/+archive/ubuntu/kisak-mesa

Hi, yes, maybe this could help. As I reinstalled ubuntu-sashi about 10 times in the last 4 days I'll stay with the current installation until there is a fix available. This really decimates the lifetime of the soldered in thus not exchangeable ssd of the mac and booting MacOS from an external SSD is not supported.

Looking forward to your results...

mpgalaxy avatar Sep 28 '25 07:09 mpgalaxy