External HDD not "seen" by fdisk -l

Hi !

I recently bought a RPi and installed OSMC on it. I got this morning a 2To external hard drive and I’d like to store my medias on it. I have installed the Samba service and I would like to access directly the external hard drive when browsing with Windows, instead of the /home/osmc folder.

The thing is, my HDD doesn’t seem to be detected by the OS. fdisk -l gives me this :

osmc@MediaServer:~$ fdisk -l

Disk /dev/ram0: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram1: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram2: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram3: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram4: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram5: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram6: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram7: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram8: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram9: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram10: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram11: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram12: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram13: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram14: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/ram15: 4 MiB, 4194304 bytes, 8192 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk /dev/mmcblk0: 29 GiB, 31117541376 bytes, 60776448 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
Disklabel type: dos
Disk identifier: 0x000ce63c

Device         Boot  Start      End  Sectors  Size Id Type
/dev/mmcblk0p1        2048   499711   497664  243M  c W95 FAT32 (LBA)
/dev/mmcblk0p2      501760 60776447 60274688 28.8G 83 Linux`  

The 28.8G drive is my 32Go MicroSD card, but I can’t see the drive anywhere.

Does anyone have a solution for me? Experienced the same problem?

Thanks a lot!
Antoine

Is your hard disk powered by an external power supply or via USB?
If it is powered via USB have you added max_usb_current =1 to config.txt?

It is powered by USB. I did not know that config.txt file but I found it in /boot/config.txt.
I already have one USB device connected (wireless adapter for keyboard), should I set the value to 2 instead of 1 as you said?

No that is a binary value 0=off and 1=on; more is not always more :slight_smile:
You actually also can do this via MyOSMC!

Also when you do that ensure your powersupply is strong enough!

I edited config.txt with the 1 value and rebooted. Now, when I connect my HDD, dmesg tells me:

[  105.177744] usb 1-1.4: new high-speed USB device number 6 using dwc_otg
[  105.489885] usb 1-1.4: New USB device found, idVendor=0480, idProduct=a00a
[  105.489921] usb 1-1.4: New USB device strings: Mfr=2, Product=3, SerialNumber=1
[  105.489939] usb 1-1.4: Product: External USB 3.0
[  105.489955] usb 1-1.4: Manufacturer: TOSHIBA
[  105.489971] usb 1-1.4: SerialNumber: 20131124060615
[  105.491376] usb-storage 1-1.4:1.0: USB Mass Storage device detected
[  105.493631] scsi host1: usb-storage 1-1.4:1.0
[  106.697250] scsi 1:0:0:0: Direct-Access     TOSHIBA  External USB 3.0 0    PQ: 0 ANSI: 6
[  106.699404] sd 1:0:0:0: Attached scsi generic sg0 type 0
[  106.701151] sd 1:0:0:0: [sda] Spinning up disk...

So it detects the drive, but fdisk -l still gives me the same response…

Please post:

fdisk -l | paste-log
mount | paste-log
dmesg | paste-log

fdisk -l : http://paste.osmc.io/olokofoyen
mount : http://paste.osmc.io/yijudumixi
dmesg : http://paste.osmc.io/wetovofuwo

Maybe still not enough power. Suggest you try with a powered USB Hub.
Assume you ensured e.g. with your notebook that the disk works!

[ 106.701151] sd 1:0:0:0: [sda] Spinning up disk…
[ 107.707724] …not responding…
[ 228.594237] sd 1:0:0:0: [sda] Read Capacity(10) failed: Result: hostbyte=0x00 driverbyte=0x08
[ 228.594275] sd 1:0:0:0: [sda] Sense Key : 0x2 [current]
[ 228.594297] sd 1:0:0:0: [sda] ASC=0x4 ASCQ=0x1
[ 235.774137] sd 1:0:0:0: [sda] Test WP failed, assume Write Enabled
[ 242.694419] sd 1:0:0:0: [sda] Asking for cache data failed
[ 242.694462] sd 1:0:0:0: [sda] Assuming drive cache: write through
[ 242.702819] sd 1:0:0:0: [sda] Spinning up disk…
[ 243.708609] …not responding…
[ 364.494617] sd 1:0:0:0: [sda] Read Capacity(10) failed: Result: hostbyte=0x00 driverbyte=0x08
[ 364.494659] sd 1:0:0:0: [sda] Sense Key : 0x2 [current]

The HDD works well on my notebook. I’ll buy a self-powered hub and give feedback tomorrow. Thanks for your help!