Eu quero testar um disco rígido usb com smartctl no disco ubuntu.
alex@Guilmon:~$ LANG=C
alex@Guilmon:~$ sudo smartctl -d usbjmicron --all /dev/sdc
smartctl 6.6 2017-11-05 r4594 [x86_64-linux-5.0.0-36-generic] (local build)
Copyright (C) 2002-17, Bruce Allen, Christian Franke, www.smartmontools.org
Read Device Identity failed: empty IDENTIFY data
A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options
a opção -d usbjmicron eu recebo de smartmontools.org/wiki/
lsusb | grep -i micron
Bus 003 Device 002: ID 152d:2329 JMicron Technology Corp. / JMicron USA Technology Corp. JM20329 SATA Bridge
e smartctl --scan mostra também
sudo smartctl --scan
/dev/sda -d scsi # /dev/sda, SCSI device
/dev/sdb -d scsi # /dev/sdb, SCSI device
/dev/sdc -d usbjmicron # /dev/sdc [USB JMicron], ATA device
Fdisk e parted trava depois de um tempo.
Nov 27 16:35:16 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Nov 27 16:35:16 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Sense Key : Unit Attention [current]
Nov 27 16:35:16 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Add. Sense: Not ready to ready change, medium may have changed
Nov 27 16:35:16 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 00 00 00 00 00 00 08 00
Nov 27 16:35:16 Guilmon kernel: print_req_error: I/O error, dev sdc, sector 0 flags 0
Nov 27 16:35:16 Guilmon kernel: Buffer I/O error on dev sdc, logical block 0, async page read
Nov 27 16:36:30 Guilmon sudo[14829]: alex : TTY=pts/0 ; PWD=/home/alex ; USER=root ; COMMAND=/usr/sbin/fdisk -l /dev/sdc
Nov 27 16:38:17 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Nov 27 16:38:17 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Sense Key : Unit Attention [current]
Nov 27 16:38:17 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Add. Sense: Not ready to ready change, medium may have changed
Nov 27 16:38:17 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 03 8a 47 80 00 00 08 00
Nov 27 16:38:17 Guilmon kernel: print_req_error: I/O error, dev sdc, sector 59393920 flags 80700
Nov 27 16:41:18 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Nov 27 16:41:18 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Sense Key : Unit Attention [current]
Nov 27 16:41:18 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Add. Sense: Not ready to ready change, medium may have changed
Nov 27 16:41:18 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 03 8a 4f fe 00 00 02 00
Nov 27 16:41:18 Guilmon kernel: print_req_error: I/O error, dev sdc, sector 59396094 flags 80700
Nov 27 16:44:20 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 FAILED Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
Nov 27 16:44:20 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Sense Key : Unit Attention [current]
Nov 27 16:44:20 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 Add. Sense: Not ready to ready change, medium may have changed
Nov 27 16:44:20 Guilmon kernel: sd 6:0:0:0: [sdc] tag#0 CDB: Read(10) 28 00 00 00 00 00 00 00 08 00
Nov 27 16:44:20 Guilmon kernel: print_req_error: I/O error, dev sdc, sector 0 flags 0
Nov 27 16:44:20 Guilmon kernel: Buffer I/O error on dev sdc, logical block 0, async page read
sistema de arquivo
sudo lsblk -f | grep sdc
sdc
├─sdc1 ext4 bionic 8cc02316-1cd7-4f54-bd1a-c3f174e55251 #my bionic installation
├─sdc2 swap f923fdf9-3416-420d-898c-e481c82a757b
├─sdc3
└─sdc5 ext4 bionic-home f7217969-9cde-4eff-940b-761ebb06189b #old debian home
verificação do sistema de arquivos
sudo fsck.ext4 /dev/sdc1
[sudo] password for alex:
e2fsck 1.44.6 (5-Mar-2019)
bionic: recovering journal
bionic: clean, 373117/1602496 files, 2540186/6400000 blocks
alex@Guilmon:~$ sudo fsck.ext4 /dev/sdc5
e2fsck 1.44.6 (5-Mar-2019)
bionic-home: clean, 161503/28672000 files, 102109567/114672128 blocks
quando eu plugo o disco rígido ele monta bem. Mas ontem meu gerenciador de arquivos trava durante a pesquisa de dados nele.
O disco rígido foi testado antes de eu substituí-lo por um maior e não é usado com muita frequência. Como posso verificar este disco rígido. Tentei vários cabos. Tenho apenas um chassi.
Observe que posso inicializar meu biônico nele sem problemas.
desculpe tanto texto.
Agora eu recebo a saída do fdisk
sudo fdisk -l /dev/sdc
Disk /dev/sdc: 465,8 GiB, 500107862016 bytes, 976773168 sectors
Disk model: IB-272StU-OT
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: 0x000e2cd8
Device Boot Start End Sectors Size Id Type
/dev/sdc1 2048 51202047 51200000 24,4G 83 Linux
/dev/sdc2 51202048 59394047 8192000 3,9G 82 Linux swap / Solaris
/dev/sdc3 59396094 976773119 917377026 437,5G 5 Extended
/dev/sdc5 59396096 976773119 917377024 437,5G 83 Linux
Ok, no meu caso, o daemon udisksd apresenta erros
Eu estava pesquisando e encontrei um relatório de bug mais antigo
Eu expando minha regra udev para meu script de backup
Agora o recurso para smartd está desabilitado para este hardrive.