Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-04 Thread MC_Sequoia
"PRO TIP: Connect JUST the USB adapter - no drive - and check dmesg.
It should not disconnect (just show 'media removed') and the USB adapter MUST 
be listed in 'lsusb'. For example, for my 3.0 USB adapter."

I didn't see this mentioned or perhaps you already now, but the best way to see 
log mssgs realtime is the command: tail -f /var/log/messages

Here's the command output when I disconnect and reconnect my usb speaker.


Link] on usb-:00:1d.0-1.2/input0
Jan  4 16:46:34 mc-bunsen kernel: [16035.930728] usb 3-1.2: USB disconnect, 
device number 7
Jan  4 16:46:38 mc-bunsen kernel: [16039.479790] usb 3-1.2: new full-speed USB 
device number 8 using ehci-pci
Jan  4 16:46:38 mc-bunsen kernel: [16039.594705] usb 3-1.2: New USB device 
found, idVendor=05a7, idProduct=40fe, bcdDevice= 1.00
Jan  4 16:46:38 mc-bunsen kernel: [16039.594714] usb 3-1.2: New USB device 
strings: Mfr=1, Product=2, SerialNumber=3
Jan  4 16:46:38 mc-bunsen kernel: [16039.594717] usb 3-1.2: Product: Bose Micro 
SoundLink
Jan  4 16:46:38 mc-bunsen kernel: [16039.594721] usb 3-1.2: Manufacturer: Bose 
Corporation
Jan  4 16:46:38 mc-bunsen kernel: [16039.594723] usb 3-1.2: SerialNumber: 
Q1222049006784949K80080
Jan  4 16:46:38 mc-bunsen kernel: [16039.618227] input: Bose Corporation Bose 
Micro SoundLink Consumer Control as 
/devices/pci:00/:00:1d.0/usb3/3-1/3-1.2/3-1.2:1.0/0003:05A7:40FE.000C/input/input51
Jan  4 16:46:38 mc-bunsen kernel: [16039.676337] hid-generic 
0003:05A7:40FE.000C: input,hiddev2,hidraw5: USB HID v1.11 Device [Bose 
Corporation Bose Micro SoundLink] on usb-:00:1d.0-1.2/input0

Also, check to see if the drive shows up in your bios prior to OS bootup. For 
example, when I want to boot off a usb thumb drive, it has to bee seen and 
mounted by the BIOS during initial hardware boot-up. 

HTH



Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-04 Thread Rich Shepard

On Thu, 4 Jan 2024, King Beowulf wrote:


As Russell mentioned, your USB adapter is disconnecting, that is why
/dev/sdg is AWOL.  Are you sure you are plugging into a the correct
port?  Bad USB adapter?


Ed,

The disconnect was intentional. When fdisk -l did not display /dev/sdg/
after several attempts I gave up for the day.


PRO TIP: Connect *JUST* the USB adapter - no drive - and check dmesg. 
It should not disconnect (just show 'media removed') and the USB adapter
*MUST* be listed in 'lsusb'. For example, for my 3.0 USB adapter


Will do this.

Thanks,

Rich


Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-04 Thread Rich Shepard

On Wed, 3 Jan 2024, Russell Senior wrote:


The last message seems to say that the USB device disconnected a couple
minutes after it was plugged in.


Russell,

Yes, that's when I shut it down. The dmesg log was from my earlier attempt;
will re-do today.


The sd in sdg stands for scsi disk. Prior to nvme, in Linux, storage tends
to be treated as scsi disks because regardless of connection technology
(USB, SATA, SAS, etc) the underlying commands sent to devices were scsi
commands.


Thanks for clarifying.

Rich


Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-03 Thread King Beowulf
On 1/3/24 15:48, Rich Shepard wrote:
> [Wed Jan  3 14:13:21 2024] usb 1-11: new high-speed USB device number 2 using 
> xhci_hcd
> [Wed Jan  3 14:13:21 2024] usb 1-11: New USB device found, idVendor=1f75, 
> idProduct=0611, bcdDevice= 0.06
> [Wed Jan  3 14:13:21 2024] usb 1-11: New USB device strings: Mfr=4, 
> Product=5, SerialNumber=6
> [Wed Jan  3 14:13:21 2024] usb 1-11: Product: XT-U33502
> [Wed Jan  3 14:13:21 2024] usb 1-11: Manufacturer: XinTop
> [Wed Jan  3 14:13:21 2024] usb 1-11: SerialNumber: 20230921
> [Wed Jan  3 14:13:21 2024] usb-storage 1-11:1.0: USB Mass Storage device 
> detected
> [Wed Jan  3 14:13:21 2024] scsi host10: usb-storage 1-11:1.0
> [Wed Jan  3 14:13:22 2024] scsi host10: scsi scan: INQUIRY result too short 
> (5), using 36
> [Wed Jan  3 14:13:22 2024] scsi 10:0:0:0: Direct-Access XinTop   
> XT-U33502 PQ: 0 ANSI: 0
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to use 
> READ CAPACITY(16).
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] 7814037168 512-byte logical 
> blocks: (4.00 TB/3.64 TiB)
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Write Protect is off
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Mode Sense: 3b 00 00 00
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] No Caching mode page found
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Assuming drive cache: write 
> through
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to use 
> READ CAPACITY(16).
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to use 
> READ CAPACITY(16).
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Attached SCSI disk
> [Wed Jan  3 14:15:17 2024] usb 1-11: USB disconnect, device number 2

As Russell mentioned, your USB adapter is disconnecting, that is why 
/dev/sdg is AWOL.  Are you sure you are plugging into a the correct 
port?  Bad USB adapter?

PRO TIP: Connect *JUST* the USB adapter - no drive - and check dmesg.  
It should not disconnect (just show 'media removed') and the USB adapter 
*MUST* be listed in 'lsusb'.  For example, for my 3.0 USB adapter

# dmesg
[603063.361794] usb 4-4: USB disconnect, device number 2
[603067.792014] usb 4-4: new SuperSpeed USB device number 3 using xhci_hcd
[603067.804645] usb 4-4: New USB device found, idVendor=174c, 
idProduct=5106, bcdDevice= 0.01
[603067.804650] usb 4-4: New USB device strings: Mfr=2, Product=3, 
SerialNumber=1
[603067.804652] usb 4-4: Product: AS2105
[603067.804654] usb 4-4: Manufacturer: ASMedia
[603067.804656] usb 4-4: SerialNumber: 
[603067.805029] usb-storage 4-4:1.0: USB Mass Storage device detected
[603067.805311] scsi host10: usb-storage 4-4:1.0
[603068.822185] scsi 10:0:0:0: Direct-Access ASMT 2105 
0    PQ: 0 ANSI: 5
[603068.822690] sd 10:0:0:0: [sdf] Media removed, stopped polling
[603068.823478] sd 10:0:0:0: [sdf] Attached SCSI removable disk

and

$ lsusb

...
Bus 004 Device 002: ID 174c:5106 ASMedia Technology Inc. ASM1051 SATA 
3Gb/s bridge
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
...

If you do not see something similar, then fighting with fdisk is folly.

-Ed.



Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-03 Thread Russell Senior
The last message seems to say that the USB device disconnected a couple
minutes after it was plugged in.

The sd in sdg stands for scsi disk. Prior to nvme, in Linux, storage tends
to be treated as scsi disks because regardless of connection technology
(USB, SATA, SAS, etc) the underlying commands sent to devices were scsi
commands.

On Wed, Jan 3, 2024, 15:48 Rich Shepard  wrote:

> On Wed, 3 Jan 2024, Russell Senior wrote:
>
> > Look in dmesg output after plugging it in:
> >  dmesg -T (provides decoded timestamps)
>
> Russell,
>
> Good idea. Thanks.
>
> [Wed Jan  3 14:13:21 2024] usb 1-11: new high-speed USB device number 2
> using xhci_hcd
> [Wed Jan  3 14:13:21 2024] usb 1-11: New USB device found, idVendor=1f75,
> idProduct=0611, bcdDevice= 0.06
> [Wed Jan  3 14:13:21 2024] usb 1-11: New USB device strings: Mfr=4,
> Product=5, SerialNumber=6
> [Wed Jan  3 14:13:21 2024] usb 1-11: Product: XT-U33502
> [Wed Jan  3 14:13:21 2024] usb 1-11: Manufacturer: XinTop
> [Wed Jan  3 14:13:21 2024] usb 1-11: SerialNumber: 20230921
> [Wed Jan  3 14:13:21 2024] usb-storage 1-11:1.0: USB Mass Storage device
> detected
> [Wed Jan  3 14:13:21 2024] scsi host10: usb-storage 1-11:1.0
> [Wed Jan  3 14:13:22 2024] scsi host10: scsi scan: INQUIRY result too
> short (5), using 36
> [Wed Jan  3 14:13:22 2024] scsi 10:0:0:0: Direct-Access XinTop
>  XT-U33502 PQ: 0 ANSI: 0
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to
> use READ CAPACITY(16).
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] 7814037168 512-byte logical
> blocks: (4.00 TB/3.64 TiB)
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Write Protect is off
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Mode Sense: 3b 00 00 00
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] No Caching mode page found
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Assuming drive cache: write
> through
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to
> use READ CAPACITY(16).
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to
> use READ CAPACITY(16).
> [Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Attached SCSI disk
> [Wed Jan  3 14:15:17 2024] usb 1-11: USB disconnect, device number 2
>
> But, `fdisk -l' didn't display any information for /dev/sdg/. That's what I
> looked for. After all the RAM drives, and the M.2 SSD drive, were the SCSI
> SSD and HDD drives sda--sdf.
>
> Why is the device type changed to `sd' from `scsi?'
>
> I'll continue looking for sdg.
>
> Regards,
>
> Rich
>


Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-03 Thread Rich Shepard

On Wed, 3 Jan 2024, Russell Senior wrote:


Look in dmesg output after plugging it in:
 dmesg -T (provides decoded timestamps)


Russell,

Good idea. Thanks.

[Wed Jan  3 14:13:21 2024] usb 1-11: new high-speed USB device number 2 using 
xhci_hcd
[Wed Jan  3 14:13:21 2024] usb 1-11: New USB device found, idVendor=1f75, 
idProduct=0611, bcdDevice= 0.06
[Wed Jan  3 14:13:21 2024] usb 1-11: New USB device strings: Mfr=4, Product=5, 
SerialNumber=6
[Wed Jan  3 14:13:21 2024] usb 1-11: Product: XT-U33502
[Wed Jan  3 14:13:21 2024] usb 1-11: Manufacturer: XinTop
[Wed Jan  3 14:13:21 2024] usb 1-11: SerialNumber: 20230921
[Wed Jan  3 14:13:21 2024] usb-storage 1-11:1.0: USB Mass Storage device 
detected
[Wed Jan  3 14:13:21 2024] scsi host10: usb-storage 1-11:1.0
[Wed Jan  3 14:13:22 2024] scsi host10: scsi scan: INQUIRY result too short 
(5), using 36
[Wed Jan  3 14:13:22 2024] scsi 10:0:0:0: Direct-Access XinTop   XT-U33502  
   PQ: 0 ANSI: 0
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to use 
READ CAPACITY(16).
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] 7814037168 512-byte logical 
blocks: (4.00 TB/3.64 TiB)
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Write Protect is off
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Mode Sense: 3b 00 00 00
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] No Caching mode page found
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Assuming drive cache: write 
through
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to use 
READ CAPACITY(16).
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Very big device. Trying to use 
READ CAPACITY(16).
[Wed Jan  3 14:13:22 2024] sd 10:0:0:0: [sdg] Attached SCSI disk
[Wed Jan  3 14:15:17 2024] usb 1-11: USB disconnect, device number 2

But, `fdisk -l' didn't display any information for /dev/sdg/. That's what I
looked for. After all the RAM drives, and the M.2 SSD drive, were the SCSI
SSD and HDD drives sda--sdf.

Why is the device type changed to `sd' from `scsi?'

I'll continue looking for sdg.

Regards,

Rich


Re: [PLUG] fdisk not recognizing external SATA HDD

2024-01-03 Thread Russell Senior
Look in dmesg output after plugging it in:

  dmesg -T (provides decoded timestamps)

You can also run "smartctl -i /dev/sda" (etc) to get the model and serial
numbers to make sure you are talking to the right thing.

On Wed, Jan 3, 2024 at 2:28 PM Rich Shepard 
wrote:

> This desktop has an internal SATA hdd (/dev/sdb/) with bad sectors on one
> partition. I've purchased a Seagate FireCuda 4T SATA hdd to replace it.
>
> Connected a USB3.0 adapter (powered by a wall wart) to the drive, and the
> drive to a USB3.1 port on the front of the case and turned it on.
>
> fdisk -l recognizes the two internal and 4 external drives (/dev/sda/
> through /dev/sdf/) but not the new drive. I don't recall this happening in
> the past with an external naked hard drive.
>
> What might I be missing?
>
> TIA,
>
> Rich
>
>


[PLUG] fdisk not recognizing external SATA HDD

2024-01-03 Thread Rich Shepard

This desktop has an internal SATA hdd (/dev/sdb/) with bad sectors on one
partition. I've purchased a Seagate FireCuda 4T SATA hdd to replace it.

Connected a USB3.0 adapter (powered by a wall wart) to the drive, and the
drive to a USB3.1 port on the front of the case and turned it on.

fdisk -l recognizes the two internal and 4 external drives (/dev/sda/
through /dev/sdf/) but not the new drive. I don't recall this happening in
the past with an external naked hard drive.

What might I be missing?

TIA,

Rich