Fedora 39 freezes sometimes

Hello!

Sorry for yet another thread about random freezes in Fedora. I couldn’t find a solution in the existing ones that I looked at.

Sometimes Fedora kind of freezes for 30 seconds or so. It typically happens when:

  • I click a Firefox bookmark folder
  • I open a new Firefox window
  • I open the terminal
  • I click the shutdown button in the “start” menu, before the shutdown dialog shows up
  • All of these with no other program open and less than 5 browser tabs

During a freeze the keyboard responds to caps-lock / num-lock, and sometimes I can alt-tab between windows, but the windows themselves don’t respond. It doesn’t happen on Linux Mint and Windows, so I assume the hardware is ok. I looked at iotop and didn’t see any unusual disk traffic during a freeze.

Can someone please advise where I should look to find what might be causing this?

System info:

System:
  Kernel: 6.7.11-200.fc39.x86_64 arch: x86_64 bits: 64 compiler: gcc v: 2.40-14.fc39
    clocksource: tsc
  Desktop: Cinnamon v: 6.0.4 tk: GTK v: 3.24.41 wm: Muffin vt: 1 dm: LightDM v: 1.32.0
    Distro: Fedora Linux 39 (Cinnamon)
Machine:
  Type: Desktop Mobo: Micro-Star model: PRO B760M-P DDR4 (MS-7E02) v: 1.0
    serial: <superuser required> uuid: <superuser required> UEFI: American Megatrends LLC. v: 1.30
    date: 03/24/2023
CPU:
  Info: 16-core (8-mt/8-st) model: 13th Gen Intel Core i7-13700F bits: 64 type: MST AMCP
    smt: enabled arch: Raptor Lake rev: 1 cache: L1: 1.4 MiB L2: 24 MiB L3: 30 MiB
  Speed (MHz): avg: 880 high: 1205 min/max: 800/5100:5200:4100 cores: 1: 1100 2: 800 3: 800
    4: 800 5: 800 6: 800 7: 1099 8: 800 9: 1100 10: 800 11: 1126 12: 1100 13: 1205 14: 800 15: 800
    16: 800 17: 800 18: 800 19: 800 20: 800 21: 800 22: 800 23: 800 24: 800 bogomips: 101376
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx
Graphics:
  Device-1: NVIDIA GA106 [GeForce RTX 3060 Lite Hash Rate] vendor: ASUSTeK driver: nvidia v: 550.67
    arch: Ampere pcie: speed: 2.5 GT/s lanes: 16 ports: active: none off: HDMI-A-1
    empty: DP-1,DP-2,DP-3 bus-ID: 01:00.0 chip-ID: 10de:2504 class-ID: 0300
  Device-2: Jieli USB PHY 2.0 driver: snd-usb-audio,uvcvideo type: USB rev: 2.0 speed: 480 Mb/s
    lanes: 1 bus-ID: 1-9.3.3:8 chip-ID: 1124:2925 class-ID: 0102
  Display: x11 server: X.Org v: 1.20.14 with: Xwayland v: 23.2.4 driver: X: loaded: nvidia
    unloaded: fbdev,modesetting,nouveau,vesa alternate: nv gpu: nvidia,nvidia-nvswitch display-ID: :0
    screens: 1
  Screen-1: 0 s-res: 2560x1440 s-dpi: 92 s-size: 707x402mm (27.83x15.83") s-diag: 813mm (32.02")
  Monitor-1: HDMI-A-1 mapped: HDMI-0 note: disabled model: Samsung LC32G5xT serial: <filter>
    res: 2560x1440 hz: 60 dpi: 93 size: 698x393mm (27.48x15.47") diag: 806mm (31.7") modes:
    max: 2560x1440 min: 640x480
  API: OpenGL v: 4.6.0 vendor: nvidia v: 550.67 glx-v: 1.4 direct-render: yes renderer: NVIDIA
    GeForce RTX 3060/PCIe/SSE2
  API: EGL Message: EGL data requires eglinfo. Check --recommends.
Audio:
  Device-1: Intel Raptor Lake High Definition Audio vendor: Micro-Star MSI driver: snd_hda_intel
    v: kernel bus-ID: 00:1f.3 chip-ID: 8086:7a50 class-ID: 0403
  Device-2: NVIDIA GA106 High Definition Audio vendor: ASUSTeK driver: snd_hda_intel v: kernel
    pcie: speed: 16 GT/s lanes: 16 bus-ID: 01:00.1 chip-ID: 10de:228e class-ID: 0403
  Device-3: RODE Microphones NT-USB driver: hid-generic,snd-usb-audio,usbhid type: USB rev: 1.1
    speed: 12 Mb/s lanes: 1 bus-ID: 1-9.2:4 chip-ID: 19f7:0003 class-ID: 0300
  Device-4: Jieli USB PHY 2.0 driver: snd-usb-audio,uvcvideo type: USB rev: 2.0 speed: 480 Mb/s
    lanes: 1 bus-ID: 1-9.3.3:8 chip-ID: 1124:2925 class-ID: 0102
  Device-5: Focusrite-Novation Scarlett 2i2 3rd Gen driver: snd-usb-audio,usb-storage type: USB
    rev: 2.1 speed: 480 Mb/s lanes: 1 bus-ID: 1-9.3.4:9 chip-ID: 1235:8210 class-ID: 0806
    serial: <filter>
  API: ALSA v: k6.7.11-200.fc39.x86_64 status: kernel-api
  Server-1: JACK v: 1.9.22 status: off
  Server-2: PipeWire v: 1.0.4 status: active with: 1: pipewire-pulse status: active
    2: wireplumber status: active 3: pipewire-alsa type: plugin
Network:
  Device-1: Realtek RTL8111/8168/8211/8411 PCI Express Gigabit Ethernet vendor: Micro-Star MSI
    driver: r8169 v: kernel pcie: speed: 2.5 GT/s lanes: 1 port: 3000 bus-ID: 04:00.0
    chip-ID: 10ec:8168 class-ID: 0200
  IF: enp4s0 state: down mac: <filter>
  Device-2: TP-Link Archer T4U ver.3 driver: rtw_8822bu type: USB rev: 2.1 speed: 480 Mb/s
    lanes: 1 bus-ID: 1-9.3.1:6 chip-ID: 2357:0115 class-ID: 0000 serial: <filter>
  IF: wlp0s20f0u9u3u1 state: up mac: <filter>
Drives:
  Local Storage: total: 1.94 TiB used: 39.4 GiB (2.0%)
  ID-1: /dev/nvme0n1 vendor: Kingston model: SNV2S2000G size: 1.82 TiB speed: 63.2 Gb/s lanes: 4
    tech: SSD serial: <filter> fw-rev: ELFK1N.1 temp: 38.9 C scheme: GPT
  ID-2: /dev/sda vendor: Samsung model: Type-C size: 119.51 GiB type: USB rev: 3.1 spd: 5 Gb/s
    lanes: 1 tech: N/A serial: <filter> fw-rev: 1100 scheme: GPT
  ID-3: /dev/sdb model: Scarlett Welcome Disk size: 192 KiB type: USB rev: 2.1 spd: 480 Mb/s
    lanes: 1 tech: N/A serial: <filter> fw-rev: 0.10 scheme: MBR
Partition:
  ID-1: / size: 118.01 GiB used: 39.01 GiB (33.1%) fs: btrfs dev: /dev/sda3
  ID-2: /boot size: 973.4 MiB used: 373.1 MiB (38.3%) fs: ext4 dev: /dev/sda2
  ID-3: /boot/efi size: 511 MiB used: 27.2 MiB (5.3%) fs: vfat dev: /dev/sda1
  ID-4: /home size: 118.01 GiB used: 39.01 GiB (33.1%) fs: btrfs dev: /dev/sda3
Swap:
  Alert: No swap data was found.
USB:
  Hub-1: 1-0:1 info: hi-speed hub with single TT ports: 16 rev: 2.0 speed: 480 Mb/s lanes: 1
    chip-ID: 1d6b:0002 class-ID: 0900
  Hub-2: 1-9:2 info: VIA Labs USB2.0 Hub ports: 4 rev: 2.1 speed: 480 Mb/s lanes: 1
    chip-ID: 2109:2817 class-ID: 0900
  Device-1: 1-9.1:3 info: Razer USA DeathAdder Essential type: mouse,keyboard
    driver: hid-generic,usbhid interfaces: 3 rev: 2.0 speed: 12 Mb/s lanes: 1 power: 500mA
    chip-ID: 1532:0098 class-ID: 0300
  Device-2: 1-9.2:4 info: RODE Microphones NT-USB type: audio,HID
    driver: hid-generic,snd-usb-audio,usbhid interfaces: 4 rev: 1.1 speed: 12 Mb/s lanes: 1
    power: 100mA chip-ID: 19f7:0003 class-ID: 0300
  Hub-3: 1-9.3:5 info: VIA Labs USB2.0 Hub ports: 4 rev: 2.1 speed: 480 Mb/s lanes: 1
    chip-ID: 2109:2817 class-ID: 0900
  Device-1: 1-9.3.1:6 info: TP-Link Archer T4U ver.3 type: Network driver: rtw_8822bu
    interfaces: 1 rev: 2.1 speed: 480 Mb/s lanes: 1 power: 500mA chip-ID: 2357:0115 class-ID: 0000
    serial: <filter>
  Device-2: 1-9.3.2:7 info: Razer USA RZ03-0274 Gaming Keyboard [Cynosa Lite]
    type: keyboard,mouse driver: hid-generic,usbhid interfaces: 3 rev: 2.0 speed: 12 Mb/s lanes: 1
    power: 500mA chip-ID: 1532:023f class-ID: 0300
  Device-3: 1-9.3.3:8 info: Jieli USB PHY 2.0 type: video,audio driver: snd-usb-audio,uvcvideo
    interfaces: 4 rev: 2.0 speed: 480 Mb/s lanes: 1 power: 500mA chip-ID: 1124:2925 class-ID: 0102
  Device-4: 1-9.3.4:9 info: Focusrite-Novation Scarlett 2i2 3rd Gen type: audio,mass storage
    driver: snd-usb-audio,usb-storage interfaces: 5 rev: 2.1 speed: 480 Mb/s lanes: 1 power: 500mA
    chip-ID: 1235:8210 class-ID: 0806 serial: <filter>
  Hub-4: 2-0:1 info: super-speed hub ports: 10 rev: 3.1 speed: 20 Gb/s lanes: 2
    chip-ID: 1d6b:0003 class-ID: 0900
  Device-1: 2-2:2 info: Silicon Motion - Taiwan (formerly Feiya ) Flash Drive type: mass storage
    driver: usb-storage interfaces: 1 rev: 3.1 speed: 5 Gb/s lanes: 1 power: 304mA chip-ID: 090c:1000
    class-ID: 0806 serial: <filter>
Sensors:
  System Temperatures: cpu: 36.0 C mobo: N/A gpu: nvidia temp: 32 C
  Fan Speeds (rpm): N/A gpu: nvidia fan: 30%
Repos:
  Packages: pm: flatpak pkgs: 16
  No active dnf repos in: /etc/dnf/dnf.conf
  Active yum repos in: /etc/yum.repos.d/_copr:copr.fedorainfracloud.org:group_go-sig:golang-rawhide.repo
    1: copr:copr.fedorainfracloud.org:group_go-sig:golang-rawhide ~ https: //download.copr.fedorainfracloud.org/results/@go-sig/golang-rawhide/fedora-$releasever-$basearch/
  Active yum repos in: /etc/yum.repos.d/_copr:copr.fedorainfracloud.org:peterwu:rendezvous.repo
    1: copr:copr.fedorainfracloud.org:peterwu:rendezvous ~ https: //download.copr.fedorainfracloud.org/results/peterwu/rendezvous/fedora-$releasever-$basearch/
  Active yum repos in: /etc/yum.repos.d/fedora-cisco-openh264.repo
    1: fedora-cisco-openh264 ~ https: //mirrors.fedoraproject.org/metalink?repo=fedora-cisco-openh264-$releasever&arch=$basearch
  No active yum repos in: /etc/yum.repos.d/fedora-updates-testing.repo
  Active yum repos in: /etc/yum.repos.d/fedora-updates.repo
    1: updates ~ https: //mirrors.fedoraproject.org/metalink?repo=updates-released-f$releasever&arch=$basearch
  Active yum repos in: /etc/yum.repos.d/fedora.repo
    1: fedora ~ https: //mirrors.fedoraproject.org/metalink?repo=fedora-$releasever&arch=$basearch
  No active yum repos in: /etc/yum.repos.d/rpmfusion-free-updates-testing.repo
  Active yum repos in: /etc/yum.repos.d/rpmfusion-free-updates.repo
    1: rpmfusion-free-updates ~ https: //mirrors.rpmfusion.org/metalink?repo=free-fedora-updates-released-$releasever&arch=$basearch
  Active yum repos in: /etc/yum.repos.d/rpmfusion-free.repo
    1: rpmfusion-free ~ https: //mirrors.rpmfusion.org/metalink?repo=free-fedora-$releasever&arch=$basearch
  No active yum repos in: /etc/yum.repos.d/rpmfusion-nonfree-updates-testing.repo
  Active yum repos in: /etc/yum.repos.d/rpmfusion-nonfree-updates.repo
    1: rpmfusion-nonfree-updates ~ https: //mirrors.rpmfusion.org/metalink?repo=nonfree-fedora-updates-released-$releasever&arch=$basearch
  Active yum repos in: /etc/yum.repos.d/rpmfusion-nonfree.repo
    1: rpmfusion-nonfree ~ https: //mirrors.rpmfusion.org/metalink?repo=nonfree-fedora-$releasever&arch=$basearch
Info:
  Memory: total: 32 GiB available: 31.19 GiB used: 5.52 GiB (17.7%)
  Processes: 485 Power: uptime: 28m states: freeze,mem,disk suspend: deep wakeups: 0
    hibernate: platform Init: systemd v: 254 target: graphical (5) default: graphical
  Compilers: gcc: 13.2.1 Client: Cinnamon v: 6.0.4 inxi: 3.3.33

Look in the journal for logs around the time of a freeze.
Are there any clues there?

Drives:
  Local Storage: total: 1.94 TiB used: 39.4 GiB (2.0%)
  ID-1: /dev/nvme0n1 vendor: Kingston model: SNV2S2000G size: 1.82 TiB speed: 63.2 Gb/s lanes: 4
    tech: SSD serial: <filter> fw-rev: ELFK1N.1 temp: 38.9 C scheme: GPT
  ID-2: /dev/sda vendor: Samsung model: Type-C size: 119.51 GiB type: USB rev: 3.1 spd: 5 Gb/s
    lanes: 1 tech: N/A serial: <filter> fw-rev: 1100 scheme: GPT
  ID-3: /dev/sdb model: Scarlett Welcome Disk size: 192 KiB type: USB rev: 2.1 spd: 480 Mb/s
    lanes: 1 tech: N/A serial: <filter> fw-rev: 0.10 scheme: MBR
Partition:
  ID-1: / size: 118.01 GiB used: 39.01 GiB (33.1%) fs: btrfs dev: /dev/sda3
  ID-2: /boot size: 973.4 MiB used: 373.1 MiB (38.3%) fs: ext4 dev: /dev/sda2
  ID-3: /boot/efi size: 511 MiB used: 27.2 MiB (5.3%) fs: vfat dev: /dev/sda1
  ID-4: /home size: 118.01 GiB used: 39.01 GiB (33.1%) fs: btrfs dev: /dev/sda3

Is sda a USB key? Are any of the drives new? There have been problems with counterfeit storage device devices.

I run Fedora on an old iMac from an external USBC nvme drive and performance is much better than using the internal drive, but most USB keys are not designed for use as system drives so both longevity and performance suffer.

For sda the value of “model” may be bogus. There have been problems with counterfit USB keys.

If the OP is running Fedora on a USB stick and is experiencing issues with stuttering and latency, You have to factor in that, a USB stick is going over the USB bus, I/O controller, and potentially throttled by the USB drive cache ( if the drive even has one ) . If this is a Live environment, you can have similar experiences when you reach certain limits on RAM since the Live Environments loads the OS into RAM.

Can @fluhus verify if this is installed on a USB drive or is Live Environment ???

Thanks for the responses!

Yes, sda is a USB key, on which Fedora is installed (forgot to mention that). In the past I had Mint and ZorinOS installed on it, with big games, and didn’t experience such stuttering.

How can I tell if the device is counterfeit?
Could this be a throttling / caching issue? How can I tell for sure?

Watch out for less than advertised capacity, perfomance, and durability.

There are programs that test speed and capacity, but they will trash the contents of the drive, and many are for Windows. A web search the the details (model, capacity, USB-C) may give you some pictures to compare or even side-by-side real and fake comparisons.

I would see what Gnome DIsks drive health reports. Since the key has worked well with other linux versions, if it is still “healthy”, then try Barry’s suggestion to examine journalctl records.

I need to ask, Did you have an identical setup where you can say you had you didn’t experience issues with? Did you have the OS USB drive in the same port ? ( Your motherboard will route USB differently over specific ports. Also, Since you have Intel and their famous DMI for Peripherals, you will be throttled down during high traffic intervals.

Here’s some things you can try :

  • Consult your motherboard manual and find a USB Port with the highest bandwidth link ( In your case Intel DMI which is only PCIe3 x4 ) or a Thunderbolt/USB4 port which bypasses DMI and is direct to CPU over PCIe.

  • To test, Disconnect peripherals you do not need and start your normal operations. Try different ports with less peripherals. Rinse / Repeat adding 1 device back at a time.

  • My Personal recommendation, Do not run a OS on a USB device unless you know you have a setup with the fastest lanes, and a less desirable option is to dual/triple boot if you need to do so, but is much better for performance.

Hi, so just to follow up. I reinstalled Fedora, this time with the ext4 filesystem rather than the default btrfs. Two days and not a single freeze so far :partying_face: (used to happen at least once an hour).

I hope this helps anyone who runs into this problem.

Thanks everyone for your advice!