Purpose:
Guide FWA-6183 users to work SATA hot plug in Ubuntu OS.
Target Audience:
AMD x86 platforms with SATA disks and running in Ubuntu OS.
AMD x86 platforms such as FWA-6183, SKY-721E3...
Steps:
1. Find SCSI bus of disks.
# dmesg | grep -i scsi
[ 7.156468] scsi 0:0:0:0: Direct-Access ATA SQF-SM8M2-64G-SB A010 PQ: 0 ANSI: 5
[ 7.156729] scsi 2:0:0:0: Direct-Access ATA SQF-SM8V4-512G-S A611 PQ: 0 ANSI: 5
[ 7.157067] scsi 4:0:0:0: Direct-Access ATA INTEL SSDSC2BB24 0101 PQ: 0 ANSI: 5
2. Check link_power_management_policy of each SCSI host.
https://elixir.bootlin.com/linux/v5.15/source/Documentation/ABI/testing/sysfs-class-scsi_host
# cat /sys/class/scsi_host/host0/link_power_management_policy
med_power_with_dipm
# cat /sys/class/scsi_host/host2/link_power_management_policy
med_power_with_dipm
# cat /sys/class/scsi_host/host4/link_power_management_policy
med_power_with_dipm
3. Change link_power_management_policy to "max_performance"
# echo "max_performance" > /sys/class/scsi_host/host0/link_power_management_policy
# echo "max_performance" > /sys/class/scsi_host/host2/link_power_management_policy
# echo "max_performance" > /sys/class/scsi_host/host4/link_power_management_policy
4. Follow step #2 to double check the value correctly replaced in each SCSI hosts.
5. Physically unplug each HDD tray and plug it back.
6. Manually scan each SCSI hosts, disks will be reloaded in OS.
# echo "- - -" | sudo tee /sys/class/scsi_host/host0/scan
# echo "- - -" | sudo tee /sys/class/scsi_host/host2/scan
# echo "- - -" | sudo tee /sys/class/scsi_host/host4/scan
# fdisk -l | grep -i /dev/sd
Disk /dev/sda: 59.6 GiB, 64023257088 bytes, 125045424 sectors
Disk /dev/sdc: 223.6 GiB, 240057409536 bytes, 468862128 sectors
Disk /dev/sdb: 477 GiB, 512110190592 bytes, 1000215216 sectors
7. It is unnecessary to do step #6 after step #5 since after. OS will always reload disks after hot plug.
Comments
0 comments
Please sign in to leave a comment.