Fedora 36 install randomly freezes/crashes/black screens on external SSD

I am new to the Fedora community, but have daily-driven various Linux distros in the past, but what I experience with Fedora now would even be abnormal for Vista, and certainly strange for a Linux distro that never crashed on my friend’s laptop, running Fedora since release 28:

Whenever I attempt to execute a write extensive operation on my external SSD, there is a chance Fedora will completely freeze up. I am using an external SSD, but it hasn’t reported smart errors and achieves 400 megabytes per second sequential write speeds. I lost my Minecraft world today, WHEN I WAS READING THE CREDITS FOR THE FIRST TIME, due to this glitch. The credits froze, the music stopped, and my system crashed, leaving a black screen where I can only write text, not even execute commands. I tested the SSD and USB adapter, it copied 32 gb of random data perfectly, as shown by sha-256 hashes of the original and the copy to this SSD.

My system specs are:
Lenovo IdeaPad 14alc6
Ryzen 3 5300u
8gb ram
Radeon Vega 6 igpu.

I used to run Windows 10 from the same SSD and it never crashed.
I hope someone can help me.
Thank you in advance!

*EDIT: booting on a different kernel doesn’t help and the kernel logs indicate numerous system processes suddenly crash. Also, sometimes after the crashes, I reboot into windows even if the external SSD has a higher boot priority, but is still initialized and fully readable in Windows. I ruled out an SSD firmware crash as just unplugging it shows a black screen with a “failed unmounting swap” message. When my system crashes, sometimes I can still move my mouse but the desktop and windows are frozen.

1 Like

Welcome to ask.:fedora:edora @maelitus09

Could you please give us more info’s as :

inxi -Fzx in terminal and post the output as </> Preformatted text here.

Your statement that even if the external SSD has a higher boot priority, but is still initialized and fully readable in Windows. seems to indicate that the SSD (or at least a partition there) is either ntfs or vfat formatted (Windows could not read an ext4 or btrfs file system). When running with a non-native file system it is quite possible that the file system on the device may be responsible for the errors. Filling up swap could also result in a crash as you describe.

How are you running fedora on that device? Is it installed normally on a linux file system? with minecraft in a separate partition? or is in installed in some other method?

Please post the output of inxi -Fzx and lsblk so we can see the hardware configuration.

I can’t access my laptop now, but I just wanted to correct myself: what I mean is that my laptop should boot in Fedora as Windows recognizes it, so the SSD is initialized. I think I can only see the boot partition on Windows though. I will send you the outputs of the commands at around 2:30-3:00 pm GMT if I can. Right now, I am sure I installed Fedora normally, and my home folder (which is also the Minecraft install folder), is on the same partition as the system. Thank you for replying so quickly!

Here is LSBLK:

loop0       7:0    0 346.9M  1 loop /var/lib/snapd/snap/wine-platform-runtime/302
loop1       7:1    0  74.7M  1 loop /var/lib/snapd/snap/imagenes/1
loop2       7:2    0 322.9M  1 loop /var/lib/snapd/snap/wine-platform-6-stable/19
loop3       7:3    0  55.5M  1 loop /var/lib/snapd/snap/core18/2409
loop4       7:4    0 113.9M  1 loop /var/lib/snapd/snap/core/13308
loop5       7:5    0  61.9M  1 loop /var/lib/snapd/snap/core20/1518
loop6       7:6    0 362.6M  1 loop /var/lib/snapd/snap/nativefier/24
sda         8:0    0   472G  0 disk 
├─sda1      8:1    0   576M  0 part /boot/efi
├─sda2      8:2    0     1G  0 part /boot
└─sda3      8:3    0 110.1G  0 part /home
zram0     252:0    0     7G  0 disk [SWAP]
nvme0n1   259:0    0 238.5G  0 disk 
│         259:1    0   260M  0 part 
│         259:2    0    16M  0 part 
│         259:3    0 237.2G  0 part 
          259:4    0  1000M  0 part 

And here is inxi -Fzx:

  Kernel: 5.17.14-300.fc36.x86_64 arch: x86_64 bits: 64 compiler: gcc
    v: 2.37-27.fc36 Desktop: GNOME v: 42.2
    Distro: Fedora release 36 (Thirty Six)
  Type: Laptop System: LENOVO product: 82KT v: IdeaPad 3 14ALC6
    serial: <superuser required>
  Mobo: LENOVO model: LNVNB161216 v: SDK0J40700WIN
    serial: <superuser required> UEFI: LENOVO v: GLCN48WW date: 05/12/2022
  ID-1: BAT0 charge: 23.0 Wh (59.4%) condition: 38.7/38.0 Wh (101.9%)
    volts: 7.9 min: 7.7 model: LGC L20L2PF0 status: N/A
  Info: quad core model: AMD Ryzen 3 5300U with Radeon Graphics bits: 64
    type: MT MCP arch: Zen 2 rev: 1 cache: L1: 256 KiB L2: 2 MiB L3: 4 MiB
  Speed (MHz): avg: 1396 high: 1397 min/max: 1400/3900 boost: enabled
    cores: 1: 1397 2: 1397 3: 1397 4: 1396 5: 1397 6: 1397 7: 1397 8: 1397
    bogomips: 41522
  Flags: avx avx2 ht lm nx pae sse sse2 sse3 sse4_1 sse4_2 sse4a ssse3 svm
  Device-1: AMD Lucienne vendor: Lenovo driver: amdgpu v: kernel
    bus-ID: 03:00.0
  Device-2: Acer Integrated Camera type: USB driver: uvcvideo bus-ID: 1-3:2
  Display: x11 server: X.Org v: 1.20.14 with: Xwayland v: 22.1.2 driver: X:
    loaded: amdgpu unloaded: fbdev,modesetting,vesa gpu: amdgpu
    resolution: 1920x1080~60Hz
    renderer: AMD RENOIR (LLVM 14.0.0 DRM 3.44 5.17.14-300.fc36.x86_64)
    v: 4.6 Mesa 22.1.1 direct render: Yes
  Device-1: AMD Renoir Radeon High Definition Audio vendor: Lenovo
    driver: snd_hda_intel v: kernel bus-ID: 03:00.1
  Device-2: AMD ACP/ACP3X/ACP6x Audio Coprocessor vendor: Lenovo
    driver: N/A bus-ID: 03:00.5
  Device-3: AMD Family 17h/19h HD Audio vendor: Lenovo
    driver: snd_hda_intel v: kernel bus-ID: 03:00.6
  Sound Server-1: ALSA v: k5.17.14-300.fc36.x86_64 running: yes
  Sound Server-2: PulseAudio v: 15.0 running: no
  Sound Server-3: PipeWire v: 0.3.52 running: yes
  Device-1: Realtek RTL8822CE 802.11ac PCIe Wireless Network Adapter
    vendor: Lenovo driver: rtw_8822ce v: N/A port: 2000 bus-ID: 01:00.0
  IF: wlp1s0 state: up mac: <filter>
  Device-1: Realtek Bluetooth Radio type: USB driver: btusb v: 0.8
    bus-ID: 3-4:3
  Report: rfkill ID: hci0 rfk-id: 6 state: down bt-service: enabled,running
    rfk-block: hardware: no software: yes address: see --recommends
  Local Storage: total: 710.47 GiB used: 15.12 GiB (2.1%)
  ID-1: /dev/nvme0n1 vendor: SK Hynix model: HFM256GD3HX015N
    size: 238.47 GiB temp: 26.9 C
  ID-2: /dev/sda type: USB vendor: Intenso model: SSD Sata II size: 472 GiB
  ID-1: / size: 110.12 GiB used: 14.82 GiB (13.5%) fs: btrfs dev: /dev/sda3
  ID-2: /boot size: 1004.8 MiB used: 292.1 MiB (29.1%) fs: ext4
    dev: /dev/sda2
  ID-3: /boot/efi size: 574.8 MiB used: 13.9 MiB (2.4%) fs: vfat
    dev: /dev/sda1
  ID-4: /home size: 110.12 GiB used: 14.82 GiB (13.5%) fs: btrfs
    dev: /dev/sda3
  ID-1: swap-1 type: zram size: 7.01 GiB used: 0 KiB (0.0%) dev: /dev/zram0
  System Temperatures: cpu: N/A mobo: N/A gpu: amdgpu temp: 42.0 C
  Fan Speeds (RPM): N/A
  Processes: 378 Uptime: 15m Memory: 7.01 GiB used: 2.34 GiB (33.4%)
  Init: systemd runlevel: 5 Compilers: gcc: 12.1.1 Packages: 6
  note: see --pkg Shell: Bash v: 5.1.16 inxi: 3.3.16

See the 360 gb difference between my home partition and my /dev/SDA? That’s because I recently switched from a 120gb SSD, thinking it would solve my problem. Spoiler: it didn’t! I know the SSD is not faulty.

Also I am using over 150gb in total with Windows, so “Local Storage: total: 710.47 GiB used: 15.12 GiB (2.1%)” is not true.

It appears your internal drive (nvme0n1) has an efi partition (nvme0n1p1) and your external SSD also has an efi partition (sda1 mounted at /boot/efi). It also appears you are using btrfs which is seen by having both / and /home on sda3.

Having 2 different efi partitions makes things difficult since the only way to dual boot with grub is to have the linux efi partition be the boot partition and then force it to access the windows efi partition to boot windows.

I always only use the primary efi (ESP) partition that was created by windows and have grub control booting from there, with that partition mounted at /boot/efi when I do the install.

I cannot envision why it would change the behavior when you were able to boot before, but you should be able to use the bios boot menu and select the device to boot from. This should allow you to select the internal device to boot windows or the SSD to boot fedora.

Please post the output of efibootmgr and sudo fdisk -l so we can verify the partition types and the efi boot order.

All I know is that I can boot windows through GRUB: it says windows boot manager on nvme0np1. The reason for why I have 2 boot partitions is simply because I didn’t know Windows Boot Manager and GRUB could “coexist”. I just installed Fedora the default way on the external drive. I’ll send you the outputs of the commands when I get home.

I can show you a picture of a crash (I could still move my mouse but the system was frozen):

The external SSD case, which has a read/write light, did not report any SSD activity, like if it were connected to something else than a computer (USB charger per example), which is pretty normal for a frozen, unresponsive system doing nothing. The strange part, however, is that when I unplugged the SSD, I got this:

So the system still noticed that the SSD was unplugged.

But, to be honest I shouldn’t complain as Windows is 100* worse (:upside_down_face::upside_down_face::upside_down_face:)


[mael@maelitus ~]$ efibootmgr
BootCurrent: 0001
Timeout: 0 seconds
BootOrder: 0001,0016,0000,0012,0013,0014,0015,0018,0019
Boot0000* Windows Boot Manager
Boot0001* Fedora
Boot0010  Setup
Boot0011  Boot Menu
Boot0012* NVMe: SKHynix_HFM256GD3HX015N                
Boot0013* ATA HDD:
Boot0014* ATA HDD1:
Boot0015* ATAPI CD:
Boot0016* USB HDD:
Boot0017  PCI LAN:
Boot0018* USB FDD:
Boot0019* USB CD:
[mael@maelitus ~]$ 

I don’t understand why Windows Boot Manager is before USB HDD as the latter is first in my bios…

Super confusing. Also why is my SSD listed as a sata gen 2 device while the read/write speeds are higher than 3 gbps? The SSD itself is advertised as sata III:

sudo fdisk -1:

Disk /dev/sda: 472 GiB, 506806140928 bytes, 989855744 sectors
Disk model:  SSD Sata II    
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 4096 bytes / 33553920 bytes
Disklabel type: gpt
Disk identifier: 21B70A20-3532-03B0-88C2-6D884C0DEC00

Device       Start       End   Sectors   Size Type
/dev/sda1    65535   1245146   1179612   576M EFI System
/dev/sda2  1245165   3407812   2162648     1G Linux filesystem
/dev/sda3  3407820 234353159 230945340 110.1G Linux filesystem

Partition 1 does not start on physical sector boundary.
Partition 2 does not start on physical sector boundary.
Partition 3 does not start on physical sector boundary.

Disk /dev/nvme0n1: 238.47 GiB, 256060514304 bytes, 500118192 sectors
Disk model: SKHynix_HFM256GD3HX015N                 
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: C43DC900-A789-4E15-9DB7-AE3FE34AB261

Device             Start       End   Sectors   Size Type
/dev/nvme0n1p1      2048    534527    532480   260M EFI System
/dev/nvme0n1p2    534528    567295     32768    16M Microsoft reserved
/dev/nvme0n1p3    567296 498067455 497500160 237.2G Microsoft basic data
/dev/nvme0n1p4 498069504 500117503   2048000  1000M Windows recovery environment

Disk /dev/zram0: 7.01 GiB, 7524581376 bytes, 1837056 sectors
Units: sectors of 1 * 4096 = 4096 bytes
Sector size (logical/physical): 4096 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes

Disk /dev/loop3: 346.86 MiB, 363708416 bytes, 710368 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop1: 61.93 MiB, 64933888 bytes, 126824 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop0: 55.54 MiB, 58232832 bytes, 113736 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop2: 322.95 MiB, 338636800 bytes, 661400 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop5: 74.68 MiB, 78311424 bytes, 152952 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop6: 113.89 MiB, 119418880 bytes, 233240 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Disk /dev/loop4: 362.63 MiB, 380243968 bytes, 742664 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes

Likely the BIOS is pointing to the internal nvme drives as primary disks, irrespective of your configuration settings. I had an older (era 2006) mobo with an AMI BIOS that did the same thing, but only with certain drives, like it really liked the Samsung EVO to be primary disk, even if I changed the order of their device connections (like from SATA1 to SATA6 for example). This became very frustrating for me to say the least. I found two areas I had to go to and make changes in the BIOS to have it follow my desires, the area you are mentioning, boot order, then also in the HDD configuration area. The Mobo was a Gigabyte UDH3A with SATAIII and USB3 (but before the USB-C connector came along.
Definitely fixup the two ESP’s since this will confuse things. If you can select windows in Grub menu though this means Grub2 must be installed in the first ESP it found, so Likely /dev/sda1. So maybe you just have to get it to have the shim in the ESP to point to /boot on the external drive. This may require a use of Grubby to add the menu entry then a grub2-mkconfig to get the changes installed. Then reboot into your Fedora, or Windows, or …

1 Like

Thanks very much for this explaination!

It is not actually.

The boot order shows fedora as first (Boot0001), and windows as third just as shown in the bios image.

Oh ok I didn’t notice that!
Should plug my brain in correctly next time…

OK, I will resort to 2 actions to troubleshoot:

  1. Install Cinnamon: if Fedora does not crash anymore, GNOME is the culprit.
  2. Plug the SSD into my old desktop, as an internal one, not a USB device. If Fedora still crashes, the problem is Fedora itself, not my hardware. If no crashes occur within 1h, my USB adapter is maybe to blame.

It may actually be a problem with the SSD firmware. It may support Windows normally but not Linux. For example my Kingston SSD had a firmware bug that would cause my Linux system to totally freeze. Back then I was a newbie and though that Linux isn’t good because it freezes for no reason. Months later I found that Kingston SSD manager had a firmware upgrade for my SSD that fixes SSD freezing on some Linux systems (fixed the problem for me).

Also on another laptop a bug in the SSD firmware causes the laptop to never be able to resume from sleep, unless you set the iommu to software.

SSD firmware bugs can cause wild issues and having it working in Windows does not mean that it isn’t the problem.

1 Like

I did do an SSD firmware for my internal one, that added copy on write support for btrfs. I will try this on my external SSD now. But Linux did not crash on another pc, where the SSD is connected via sata and not USB. The USB adapter may be the problem… Also I don’t think a cheap 50$ (not $$d LOL) can have it’s firmware updated?

EDIT: No firmware update found. After yet another crash, I checked Journalctl, which did not save logs in the minute before the crash… I still don’t know what processes fail. I can still move my mouse when the system freezes, if that helps.
I found when the journal crashed:
“Jun 26 20:19:34 fedora systemd-journald[268]: Journal stopped”
Why is the time the GMT time and not my system time, which is 2h earlier?

Try booting from a live USB and plugging that USB SSD and wait, do some I/O (read/write on the USB SSD) on it and keep checking the logs. Maybe the problem will be properly reported if it is saved to the live USB instead of the flawed USB SSD

I already tried copying a 30+gb file made of data from/dev/random. I did a hash of the file, moved it to my internal SSD, did another hash, and moved it back, did another hash. All three were the same. If the SSD corrupted the data, the hashes would be different.

Have you tried booting the Fedora of the USB SSD from another computer?

Since it is working with windows which is more I/O intensive than Fedora, I think it may be worth to reinstall Fedora. Backup your home then restore it after install, then only you will have to reinstall the applications. Maybe your installation is corrupted for some reason.

Very good point. The unfortunate truth is that I tried this once a week ago. Also Fedora didn’t crash in 4h on a 2011 i7 12gb ram Desktop. What is wrong with my pc??? Anyways Fedora seemed to be stabler on Cinnamon. I can try reinstalling Gnome.

Edit: ran the command to uninstall cinnamon while in cinnamon… Funny results!

Clicking on the apps still works though.

Was fedora made for aliens? I don’t understand this language :joy::upside_down_face:

Funny missing fonts you got there!

I can’t understand why you got critical processes like journalctl crashing for no clear reason. As a last resort try another Linux distro like Ubuntu and see if you get the same problems.