Choose style:

Author Topic: Can't get SATA enclosure to work in Linux [Solved]  (Read 4561 times)

0 Members and 1 Guest are viewing this topic.

Offline mattosensei

  • Member
  • ***
  • Posts: 222
  • Karma: 28
  • Linux with 'L' plates
    • View Profile
  • Peppermint version(s): 6
Can't get SATA enclosure to work in Linux [Solved]
« on: May 06, 2014, 04:18:23 pm »
Hi guys

My laptop HD was dying not long ago (endless BSODs) so I swapped it out for an SSD and it's all now good (it runs Win7; Peppermint is on the Netbook).

I picked up a very cheap 2.5" SATA enclosure (USB2.0) and this works fine on Win7. I have got most of my old files off so am not facing a data issue as such - but when mounted to Win7 I still get BSODs after a while.

So I thought I'd try it on Linux but I can't get Linux to recognise the drive (it's a two partion drive).

Just wondering if this is a hardware limitation or if there is something I can try? The badly written instruction that came with the enclosure states compatibility with  xp/vista/win and Mac but nothing about Linux. So perhaps that is why. But was just wondering if there was anything to try. Gparted won't show the drive and nor does fdisk. So I'm assuming it's a driver issue?

Thanks if you can help.

fdisk readout:

Code: [Select]
peppermint@peppermint ~ $ fdisk -l
peppermint@peppermint ~ $ sudo fdisk -l

Disk /dev/sda: 256.1 GB, 256060514304 bytes
255 heads, 63 sectors/track, 31130 cylinders, total 500118192 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 identifier: 0xa52d772c

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      206847      102400    7  HPFS/NTFS/exFAT
/dev/sda2          206848   500115455   249954304    7  HPFS/NTFS/exFAT

WARNING: GPT (GUID Partition Table) detected on '/dev/sdc'! The util fdisk doesn't support GPT. Use GNU Parted.


Disk /dev/sdc: 4009 MB, 4009754624 bytes
124 heads, 62 sectors/track, 1018 cylinders, total 7831552 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 identifier: 0x00000000

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1   *          34     5119999     2559983    c  W95 FAT32 (LBA)
/dev/sdc4               1          33          16+  ee  GPT

Partition table entries are not in disk order
peppermint@peppermint ~ $ ^C

« Last Edit: May 07, 2014, 01:30:10 pm by mattosensei »

Online PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25496
  • Karma: 2807
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Re: Can't get SATA enclosure to work in Linux
« Reply #1 on: May 06, 2014, 04:48:11 pm »
how many drives are attached to the PC ?

is /dev/sdc the external drive ?

how large is the external drive ?
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline mattosensei

  • Member
  • ***
  • Posts: 222
  • Karma: 28
  • Linux with 'L' plates
    • View Profile
  • Peppermint version(s): 6
Re: Can't get SATA enclosure to work in Linux
« Reply #2 on: May 06, 2014, 04:54:48 pm »
Native SSD is 256GB (encrypted)
USB LiveCD (Peppermint) is 2 GB
Old HD in the enclosure is 500GB total partitioned into 250GB each

Am fairly sure the enclosure is not showing at all in that fdisk readout I pasted. I have also tried different distros on LiveCD and in none can I get the enclosure to show.

Online PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25496
  • Karma: 2807
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Re: Can't get SATA enclosure to work in Linux
« Reply #3 on: May 06, 2014, 05:00:49 pm »
OK, unplug the enclosure .. wait 10 seconds .. replug it, and then post the output from:
Code: [Select]
dmesg | tail -n 25
and
Code: [Select]
lsusb
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline mattosensei

  • Member
  • ***
  • Posts: 222
  • Karma: 28
  • Linux with 'L' plates
    • View Profile
  • Peppermint version(s): 6
Re: Can't get SATA enclosure to work in Linux
« Reply #4 on: May 06, 2014, 05:09:55 pm »
Code: [Select]
peppermint@peppermint ~ $ dmesg | tail -n 25
[   15.454435] snd_hda_intel 0000:01:00.1: irq 44 for MSI/MSI-X
[   15.470584] rtl8192se: FW Power Save off (module option)
[   15.470643] rtl8192se: Driver for Realtek RTL8192SE/RTL8191SE
[   15.470643] Loading firmware rtlwifi/rtl8192sefw.bin
[   15.494426] input: HD-Audio Generic HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input7
[   15.519330] ieee80211 phy0: Selected rate control algorithm 'rtl_rc'
[   15.742912] atl1c 0000:02:00.0: irq 45 for MSI/MSI-X
[   15.760171] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   15.765881] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   15.925205] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   15.928301] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   16.092281] init: alsa-restore main process (1869) terminated with status 99
[   16.432554] psmouse serio1: synaptics: Touchpad model: 1, fw: 7.2, id: 0x1c0b1, caps: 0xd04733/0xa40000/0xa0000, board id: 3655, fw id: 582762
[   16.432563] psmouse serio1: synaptics: Toshiba Satellite L650 detected, limiting rate to 40pps.
[   16.516462] input: SynPS/2 Synaptics TouchPad as /devices/platform/i8042/serio1/input/input8
[  163.253348] wlan0: authenticate with 00:1e:74:0e:dc:30
[  163.271667] wlan0: send auth to 00:1e:74:0e:dc:30 (try 1/3)
[  163.274482] wlan0: authenticated
[  163.274670] rtl8192se 0000:03:00.0 wlan0: disabling HT/VHT due to WEP/TKIP use
[  163.274676] rtl8192se 0000:03:00.0 wlan0: disabling HT as WMM/QoS is not supported by the AP
[  163.274679] rtl8192se 0000:03:00.0 wlan0: disabling VHT as WMM/QoS is not supported by the AP
[  163.275495] wlan0: associate with 00:1e:74:0e:dc:30 (try 1/3)
[  163.277525] wlan0: RX AssocResp from 00:1e:74:0e:dc:30 (capab=0x411 status=0 aid=3)
[  163.278535] wlan0: associated
[  163.278547] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
peppermint@peppermint ~ $

and

Code: [Select]
peppermint@peppermint ~ $ lsusb
Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 10f1:1a2a Importek
Bus 002 Device 003: ID 090c:1000 Silicon Motion, Inc. - Taiwan (formerly Feiya Technology Corp.) 64MB QDI U2 DISK
peppermint@peppermint ~ $

Online PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25496
  • Karma: 2807
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Re: Can't get SATA enclosure to work in Linux
« Reply #5 on: May 06, 2014, 05:21:25 pm »
Hmm .. dmesg didn't register anything being attached to the system  :-\

Try doing the same again .. but using a different USB port.

be SURE to be re-plugging the USB enclosure BEFORE running the command to gather the output.
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline mattosensei

  • Member
  • ***
  • Posts: 222
  • Karma: 28
  • Linux with 'L' plates
    • View Profile
  • Peppermint version(s): 6
Re: Can't get SATA enclosure to work in Linux
« Reply #6 on: May 06, 2014, 05:34:57 pm »
Hmmm last line looks different now? This readout is after unplugging, waiting, plugging back in and waiting a bit.

Code: [Select]
peppermint@peppermint ~ $ dmesg | tail -n 25
[   15.470584] rtl8192se: FW Power Save off (module option)
[   15.470643] rtl8192se: Driver for Realtek RTL8192SE/RTL8191SE
[   15.470643] Loading firmware rtlwifi/rtl8192sefw.bin
[   15.494426] input: HD-Audio Generic HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:01.0/0000:01:00.1/sound/card1/input7
[   15.519330] ieee80211 phy0: Selected rate control algorithm 'rtl_rc'
[   15.742912] atl1c 0000:02:00.0: irq 45 for MSI/MSI-X
[   15.760171] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   15.765881] IPv6: ADDRCONF(NETDEV_UP): eth0: link is not ready
[   15.925205] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   15.928301] IPv6: ADDRCONF(NETDEV_UP): wlan0: link is not ready
[   16.092281] init: alsa-restore main process (1869) terminated with status 99
[   16.432554] psmouse serio1: synaptics: Touchpad model: 1, fw: 7.2, id: 0x1c0b1, caps: 0xd04733/0xa40000/0xa0000, board id: 3655, fw id: 582762
[   16.432563] psmouse serio1: synaptics: Toshiba Satellite L650 detected, limiting rate to 40pps.
[   16.516462] input: SynPS/2 Synaptics TouchPad as /devices/platform/i8042/serio1/input/input8
[  163.253348] wlan0: authenticate with 00:1e:74:0e:dc:30
[  163.271667] wlan0: send auth to 00:1e:74:0e:dc:30 (try 1/3)
[  163.274482] wlan0: authenticated
[  163.274670] rtl8192se 0000:03:00.0 wlan0: disabling HT/VHT due to WEP/TKIP use
[  163.274676] rtl8192se 0000:03:00.0 wlan0: disabling HT as WMM/QoS is not supported by the AP
[  163.274679] rtl8192se 0000:03:00.0 wlan0: disabling VHT as WMM/QoS is not supported by the AP
[  163.275495] wlan0: associate with 00:1e:74:0e:dc:30 (try 1/3)
[  163.277525] wlan0: RX AssocResp from 00:1e:74:0e:dc:30 (capab=0x411 status=0 aid=3)
[  163.278535] wlan0: associated
[  163.278547] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
[ 1408.396815] usb 2-1.1: USB disconnect, device number 3
peppermint@peppermint ~ $ ^C
peppermint@peppermint ~ $


Code: [Select]
peppermint@peppermint ~ $ lsusb
Bus 001 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0020 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 003: ID 10f1:1a2a Importek
peppermint@peppermint ~ $


Oh. Just tried the first command again, now getting errors. I think this drive is on last legs. Was getting multiple SMART errors (hence me changing it).

Code: [Select]
peppermint@peppermint ~ $  dmesg | tail -n 25
[ 1535.563011] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563017] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563021] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563027] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563031] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563036] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563040] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563045] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563049] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563054] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563058] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563063] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563067] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563095] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563111] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563126] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563142] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563160] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563164] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563169] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563172] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563177] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563180] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
[ 1535.563202] SQUASHFS error: Unable to read fragment cache entry [1a5308f3]
[ 1535.563206] SQUASHFS error: Unable to read page, block 1a5308f3, size 10675
peppermint@peppermint ~ $


Online PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25496
  • Karma: 2807
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Re: Can't get SATA enclosure to work in Linux
« Reply #7 on: May 06, 2014, 05:42:46 pm »
The SQUASHFS errors are probably on your USB stick .. unless the external HDD also has a squashfs file system on it.

The first dmesg output shows a USB device as being disconnected .. again probably the USB stick, and what probably caused the SQUASHFS errors because the USB stick was disconnected by your plugging in the external HDD

So it seems your system REALLY doesn't like that external enclosure ... if it's inserted into the same hub that the USB stick is on -

a) it's not detected
and
b) it causes anything else on the same hub to disconnect
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline mattosensei

  • Member
  • ***
  • Posts: 222
  • Karma: 28
  • Linux with 'L' plates
    • View Profile
  • Peppermint version(s): 6
Re: Can't get SATA enclosure to work in Linux
« Reply #8 on: May 06, 2014, 05:45:15 pm »
Thanks for looking into it.

Tomorrow I will boot-into Peppermint on my desktop (duel boot, won't need the USB stick) then attach the enc and see what readouts I get.

Online PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25496
  • Karma: 2807
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Re: Can't get SATA enclosure to work in Linux
« Reply #9 on: May 06, 2014, 05:48:24 pm »
Okey dokey :)
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec

Offline mattosensei

  • Member
  • ***
  • Posts: 222
  • Karma: 28
  • Linux with 'L' plates
    • View Profile
  • Peppermint version(s): 6
Re: Can't get SATA enclosure to work in Linux [Solved]
« Reply #10 on: May 07, 2014, 01:29:43 pm »
Hi Mark, seems to be working now (I'm on the desktop). I think it was a loose connection (this is a dirt-cheap somewhat crappy enclosure) between the USB going into the enc. Didn't work initially (same as laptop) but having fiddled with the USB and pushed it in further it is now working (odd as the enc was whirring to show it was connected beforehand and last night - but obvs not a good connection). But it is now working and I can see the 2x partitions on there and open/copy files.

So possibly it was user-error?  :D Thanks for your help anyway.

Code: [Select]
ms@desktop ~ $ dmesg | tail -n 25
[    2.550833] <6>[fglrx] Reserved FB block: Unshared offset:7ffef000, size:11000
[    2.684314] scsi 6:0:0:0: Direct-Access     TOSHIBA  MK6465GSX             PQ: 0 ANSI: 2 CCS
[    2.686546] sd 6:0:0:0: Attached scsi generic sg2 type 0
[    2.687778] sd 6:0:0:0: [sdc] 1250263728 512-byte logical blocks: (640 GB/596 GiB)
[    2.688372] sd 6:0:0:0: [sdc] Write Protect is off
[    2.688374] sd 6:0:0:0: [sdc] Mode Sense: 00 38 00 00
[    2.688996] sd 6:0:0:0: [sdc] Asking for cache data failed
[    2.688997] sd 6:0:0:0: [sdc] Assuming drive cache: write through
[    2.690872] sd 6:0:0:0: [sdc] Asking for cache data failed
[    2.690875] sd 6:0:0:0: [sdc] Assuming drive cache: write through
[    2.692018]  sdc: sdc1 sdc2 sdc3 sdc4 < sdc5 sdc6 >
[    2.695772] sd 6:0:0:0: [sdc] Asking for cache data failed
[    2.695775] sd 6:0:0:0: [sdc] Assuming drive cache: write through
[    2.695777] sd 6:0:0:0: [sdc] Attached SCSI disk
[    3.626793] wlan0: authenticate with 00:1e:74:0e:dc:30
[    3.639334] wlan0: send auth to 00:1e:74:0e:dc:30 (try 1/3)
[    3.641295] wlan0: authenticated
[    3.641389] ath9k 0000:06:00.0 wlan0: disabling HT/VHT due to WEP/TKIP use
[    3.641391] ath9k 0000:06:00.0 wlan0: disabling HT as WMM/QoS is not supported by the AP
[    3.641392] ath9k 0000:06:00.0 wlan0: disabling VHT as WMM/QoS is not supported by the AP
[    3.642447] wlan0: associate with 00:1e:74:0e:dc:30 (try 1/3)
[    3.644882] wlan0: RX AssocResp from 00:1e:74:0e:dc:30 (capab=0x411 status=0 aid=3)
[    3.645037] wlan0: associated
[    3.645043] IPv6: ADDRCONF(NETDEV_CHANGE): wlan0: link becomes ready
[    4.287793] EXT4-fs (sdc5): mounted filesystem with ordered data mode. Opts: (null)
ms@desktop ~ $ lsusb
Bus 001 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 002 Device 002: ID 8087:0024 Intel Corp. Integrated Rate Matching Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 001 Device 003: ID 152d:2339 JMicron Technology Corp. / JMicron USA Technology Corp. JM20339 SATA Bridge
Bus 002 Device 003: ID 046d:c05a Logitech, Inc. Optical Mouse M90
Bus 002 Device 004: ID 046d:c326 Logitech, Inc.
ms@desktop ~ $ ^C
ms@desktop ~ $


Online PCNetSpec

  • Administrator
  • Hero
  • *****
  • Posts: 25496
  • Karma: 2807
  • "-rw-rw-rw-" .. The Number Of The Beast
    • View Profile
    • PCNetSpec
  • Peppermint version(s): Peppermint 8R, 9, and 9R
Re: Can't get SATA enclosure to work in Linux [Solved]
« Reply #11 on: May 07, 2014, 02:10:23 pm »
Loose plug beat the heck outa failed drive :) .. cheers for the update, and marking the topic solved.
WARNING: You are logged into reality as 'root' .. logging in as 'insane' is the only safe option.

Team Peppermint
PCNetSpec