Forum Navigation
You need to log in to create posts and topics.

Add extra disk without rebooting

Problem

User wants to add extra disk to the Linux. But when running fdisk -l to list all the partitions the new device is not available

Solution

Run hardware scan to detect the new installed disk

echo “- – -” | tee /sys/class/scsi_host/host*/scan

or

for host in /sys/class/scsi_host/*; do echo “- – -” | sudo tee $host/scan; ls /dev/sd* ; done

When see a list of disk not initialized for example

Disk /dev/sdb: 85.9 GB, 85899345920 bytes, 167772160 sectors

you can mount it directlry

first run

fdisk /dev/sdb

create new partition

then format the disk

mkfs.xfs /dev/sdb1

then mount the disk

mount /dev/sdb1 /mnt

 

 

 

 

Uploaded files:

another option

echo “- – -” >> /sys/class/scsi_host/host_$i/scan

If you have found my website, guides, articles or videos useful, please buy me a coffee