Upgrade from Fedora 30 to 33 and lost SATA SSD

Post Reply
rolypoly
Posts: 4
Joined: Tue Feb 09, 2021 6:14 am
languages_spoken: english
ODROIDs: odroid-hc1 x 4
Has thanked: 0
Been thanked: 0
Contact:

Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by rolypoly »

Hi,
I've got 4 odroid hc1 each running Fedora 33. They were running Fedora 30, each with a 1TB HDD, and running GlusterFS 6.9.
I replaced the 1TB HDD with a Samsung 1TB SSD (870 QVO) but was disappointed not to see a performance increase (transfers were still around 20Mb/sec).
Fedora 30 and GlusterFS 6.9 were getting a bit old, so I decided to upgrade them, using dnf, one release at a time ie: Fedora 30 -> 31 -> 32 -> 33
This worked and they're all now running Fedora 33, however, I've lost access to the 1TB SSD!
dmesg reports this:

Code: Select all

dmesg|grep sd
[    8.697218] sd 0:0:0:0: Attached scsi generic sg0 type 0
[    8.697776] sd 0:0:0:0: [sda] Unit Not Ready
[    8.697793] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[    8.697815] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81 
[    8.698676] sd 0:0:0:0: [sda] Read Capacity(16) failed: Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[    8.698696] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[    8.698717] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81 
[    8.699579] sd 0:0:0:0: [sda] Read Capacity(10) failed: Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[    8.699597] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[    8.699619] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81 
[    8.700395] sd 0:0:0:0: [sda] 0 512-byte logical blocks: (0 B/0 B)
[    8.700413] sd 0:0:0:0: [sda] 0-byte physical blocks
[    8.701205] sd 0:0:0:0: [sda] Test WP failed, assume Write Enabled
[    8.701463] sd 0:0:0:0: [sda] Asking for cache data failed
[    8.701478] sd 0:0:0:0: [sda] Assuming drive cache: write through
[    8.702212] sd 0:0:0:0: [sda] Optimal transfer size 33553920 bytes not a multiple of physical block size (0 bytes)
[    8.716327] sd 0:0:0:0: [sda] Unit Not Ready
[    8.716347] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[    8.716371] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81 
[    8.717255] sd 0:0:0:0: [sda] Read Capacity(16) failed: Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[    8.717273] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[    8.717295] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81 
[    8.718130] sd 0:0:0:0: [sda] Read Capacity(10) failed: Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[    8.718148] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[    8.718168] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81 
[    8.720870] sd 0:0:0:0: [sda] Attached SCSI disk
So it still detects the SSD, but shows as errors.
Could this be something that requires the usb-storage.quirks=152d:0578:u on the kernel command line?
I've got the latest JMicron firmware installed and lsusb shows the device ids:

Code: Select all

[root@odroid-node1 ~]# ./JMS578FwUpdate -v -d /dev/sda
Bridge Firmware Version: v173.1.0.2

[root@odroid-node1 ~]# lsusb
Bus 004 Device 002: ID 0bda:8153 Realtek Semiconductor Corp. RTL8153 Gigabit Ethernet Adapter
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 006 Device 002: ID 152d:0578 JMicron Technology Corp. / JMicron USA Technology Corp. JMS578 SATA 6Gb/s
Bus 006 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 005 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
I'd try the quirks option, but am not sure where to put it. It looks like it should go into the /boot/extlinux/extlinux.conf file, but, according to that the default boot option is still Fedora 32, yet my system boots directly into Fedora 33.

Code: Select all

[root@odroid-node1 ~]# cat /boot/extlinux/extlinux.conf      
# extlinux.conf generated by appliance-creator
ui menu.c32
menu autoboot Welcome to Fedora-Minimal-armhfp-30-1.2. Automatic boot in # second{,s}. Press a key for options.
menu title Fedora-Minimal-armhfp-30-1.2 Boot Options.
menu hidden
timeout 20
totaltimeout 600

default=Fedora (5.10.13-100.fc32.armv7hl) 32 (Thirty Two)
label Fedora (5.10.13-200.fc33.armv7hl) 33 (Thirty Three)
        kernel /vmlinuz-5.10.13-200.fc33.armv7hl
        append console=ttySAC2,115200n8 cpuidle.off=1 rd.driver.pre=ledtrig-heartbeat,xhci-plat-hcd no_bL_switcher ro root=UUID=1fbfc662-dacf-44b9-a27a-1c31c345ab59 rhgb quiet LANG=en_US.UTF-8
        fdtdir /dtb-5.10.13-200.fc33.armv7hl/
        initrd /initramfs-5.10.13-200.fc33.armv7hl.img

label Fedora (5.10.13-100.fc32.armv7hl) 32 (Thirty Two)
        kernel /vmlinuz-5.10.13-100.fc32.armv7hl
        append console=ttySAC2,115200n8 cpuidle.off=1 rd.driver.pre=ledtrig-heartbeat,xhci-plat-hcd no_bL_switcher ro root=UUID=1fbfc662-dacf-44b9-a27a-1c31c345ab59 rhgb quiet LANG=en_US.UTF-8
        fdtdir /dtb-5.10.13-100.fc32.armv7hl/
        initrd /initramfs-5.10.13-100.fc32.armv7hl.img

label Fedora (5.8.18-100.fc31.armv7hl) 31 (Thirty One)
        kernel /vmlinuz-5.8.18-100.fc31.armv7hl
        append console=ttySAC2,115200n8 cpuidle.off=1 rd.driver.pre=ledtrig-heartbeat,xhci-plat-hcd no_bL_switcher ro root=UUID=1fbfc662-dacf-44b9-a27a-1c31c345ab59 rhgb quiet LANG=en_US.UTF-8
        fdtdir /dtb-5.8.18-100.fc31.armv7hl/
        initrd /initramfs-5.8.18-100.fc31.armv7hl.img

[root@odroid-node1 ~]# uname -r
5.10.13-200.fc33.armv7hl

[root@odroid-node1 ~]# cat /etc/redhat-release 
Fedora release 33 (Thirty Three)

Any ideas on either issue?

Thanks,
Roland.

rolypoly
Posts: 4
Joined: Tue Feb 09, 2021 6:14 am
languages_spoken: english
ODROIDs: odroid-hc1 x 4
Has thanked: 0
Been thanked: 0
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by rolypoly »

Update:
Added the usb-storage.quirks option to the extlinux.conf and rebooted.
No change, but dmesg now shows that the quirks have been registered:

Code: Select all

[    8.970519] usb 4-1: UAS is ignored for this device, using usb-storage instead
[    8.970537] usb-storage 4-1:1.0: USB Mass Storage device detected
[    8.975925] usb-storage 4-1:1.0: Quirks match for vid 152d pid 0578: 1800000
[    8.979407] scsi host0: usb-storage 4-1:1.0
[    8.980118] usbcore: registered new interface driver usb-storage
[    8.997101] usbcore: registered new interface driver uas
[    9.481589] audit: type=1334 audit(947283954.583:21): prog-id=9 op=LOAD
[   10.034501] scsi 0:0:0:0: Direct-Access     JMicron  Generic          3102 PQ: 0 ANSI: 6
[   10.039090] sd 0:0:0:0: Attached scsi generic sg0 type 0
[   10.050490] sd 0:0:0:0: [sda] Unit Not Ready
[   10.050541] sd 0:0:0:0: [sda] Sense Key : Hardware Error [current] 
[   10.050609] sd 0:0:0:0: [sda] ASC=0x44 <<vendor>>ASCQ=0x81
lsblk still only shows the SD card

Code: Select all

[root@odroid-node1 ~]# lsblk
NAME        MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
mmcblk0     179:0    0  7.4G  0 disk 
├─mmcblk0p1 179:1    0   76M  0 part /boot/efi
├─mmcblk0p2 179:2    0  489M  0 part /boot
└─mmcblk0p3 179:3    0  6.8G  0 part /
zram0       252:0    0  993M  0 disk [SWAP]
[root@odroid-node1 ~]# 
Since the usb-storage.quirks isn't the issue, I'll remove it.

User avatar
odroid
Site Admin
Posts: 37366
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 1781 times
Been thanked: 1138 times
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by odroid »

Since Jmicron JMS578 controller supports the UAS mode well with Kernel 4.4 ~ 5.10, you don't need to use the usb-quirks option probably.
But I have no experience of using Fedora, and I have no idea what is wrong.

Can you show me "lsusb -t" output?

rolypoly
Posts: 4
Joined: Tue Feb 09, 2021 6:14 am
languages_spoken: english
ODROIDs: odroid-hc1 x 4
Has thanked: 0
Been thanked: 0
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by rolypoly »

I would have thought fedora would be much the same as any other linux, like ubuntu, for the most part as it's all kernel related?
Here is the output from lsusb -t

Code: Select all

[root@odroid-node1 ~]# lsusb -t
/:  Bus 06.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Vendor Specific Class, Driver=r8152, 5000M
/:  Bus 05.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
/:  Bus 04.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 5000M
    |__ Port 1: Dev 2, If 0, Class=Mass Storage, Driver=uas, 5000M
/:  Bus 03.Port 1: Dev 1, Class=root_hub, Driver=xhci-hcd/1p, 480M
/:  Bus 02.Port 1: Dev 1, Class=root_hub, Driver=exynos-ehci/3p, 480M
/:  Bus 01.Port 1: Dev 1, Class=root_hub, Driver=exynos-ohci/3p, 12M
As I said, this used to work perfectly, it's only since upgrading that I've had issues. I might try hot plugging the SSD and see if it re-detects it.

User avatar
odroid
Site Admin
Posts: 37366
Joined: Fri Feb 22, 2013 11:14 pm
languages_spoken: English, Korean
ODROIDs: ODROID
Has thanked: 1781 times
Been thanked: 1138 times
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by odroid »

The USB 3.0 to SATA bridge controller seems to detect fine at least.

Code: Select all

    |__ Port 1: Dev 2, If 0, Class=Mass Storage, Driver=uas, 5000M 
Can you try @tobetter's Ubuntu 20.04 + Kernel 5.10 server image to confirm the SATA controller compatibility for comparing with Fedora 33 + Kernel 5.10?
viewtopic.php?p=318136#p318136

User avatar
mad_ady
Posts: 9402
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, C4, N1, N2, H2, Go, Go Advance
Location: Bucharest, Romania
Has thanked: 599 times
Been thanked: 664 times
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by mad_ady »

If it works you can steal the kernel and modules and transplant them in your fedora image.

User avatar
tobetter
Posts: 7754
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: Many
Location: Paju, South Korea
Has thanked: 428 times
Been thanked: 1192 times
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by tobetter »

I know there is a tool to convert DEB to RPM, which is alien, but not tested with Fedora.

Please use this script if you like to hook the kernel package from my private package server, this will extract the latest kernel and will create 3 directories boot, lib/modules and usr, copy them to Fedora respectively and see if it boots.

Code: Select all

#!/bin/sh

KERNEL_URL=http://ppa.linuxfactory.or.kr/pool/main/l/linux
MAJOR=5
MINOR=10
VERSION=${MAJOR}.${MINOR}
CODENAME=groovy

link=$(lynx -dump -listonly $KERNEL_URL | grep linux-image-${MAJOR}.${MINOR}.0-odroid-arm64 | grep ${VERSION} | grep ${CODENAME} | sort -rV | head -1 | awk '{print $2}')
package=${link#${KERNEL_URL}/}
header=$(echo $package | sed "s/image/headers/g")

for f in $package $header; do
        wget $KERNEL_URL/$f -P /tmp/ && ar x /tmp/$f data.tar.xz
        tar xJf data.tar.xz
        rm data.tar.xz
done

rolypoly
Posts: 4
Joined: Tue Feb 09, 2021 6:14 am
languages_spoken: english
ODROIDs: odroid-hc1 x 4
Has thanked: 0
Been thanked: 0
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by rolypoly »

Short story: This is now fixed.
Basically, I hot plugged the SATA drive. Probably shouldn't have, but did anyway. No change, not even an entry in dmesg!
Shutdown.
Pulled the power and waited 10 seconds.
Powered on and everything now working. Not sure why
Performance still sucks :(

svoop
Posts: 42
Joined: Sat Jan 30, 2016 10:25 pm
languages_spoken: english
ODROIDs: C4, C1+
Has thanked: 4 times
Been thanked: 1 time
Contact:

Re: Upgrade from Fedora 30 to 33 and lost SATA SSD

Post by svoop »

I've refactored the script a little to get rid of "lynx". (This way, I can bundle it with the Gentoo ebuild without additional RDEPENDs.)

Code: Select all

#!/bin/sh

KERNEL_URL=http://ppa.linuxfactory.or.kr/pool/main/l/linux/
MAJOR=5
MINOR=10
VERSION=${MAJOR}.${MINOR}
CODENAME=groovy

echo "Fetching listings"
package=$((wget -qO - $KERNEL_URL) | grep -oP 'href="\K[^"]+' | grep linux-image-${MAJOR}.${MINOR}.0-odroid-arm64 | grep ${VERSION} | grep ${CODENAME} | sort -rV | head -1)
header=$(echo $package | sed "s/image/headers/g")

for f in $package $header; do
  wget $KERNEL_URL/$f -P /tmp/ && ar x /tmp/$f data.tar.xz
  tar xJf data.tar.xz
  rm data.tar.xz
done
These users thanked the author svoop for the post:
tobetter (Mon Feb 15, 2021 10:02 pm)

Post Reply

Return to “Other OS”

Who is online

Users browsing this forum: No registered users and 3 guests