Usb-Drive
刪除 USB 驅動器上的防寫
我有一個自系統崩潰以來受到防寫的 USB 快閃記憶體驅動器。在dmesg中,設備防寫先關閉,再開啟。
這是dmesg:
sd 2:0:0:0: [sdb] 60566016 512-byte logical blocks: (31.0 GB/28.9 GiB) sd 2:0:0:0: [sdb] Write Protect is off sd 2:0:0:0: [sdb] Mode Sense: 2b 00 00 08 sd 2:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA sdb: sdb1 sdb2 sdb3 sdb4 sd 2:0:0:0: [sdb] Write Protect is on sd 2:0:0:0: [sdb] Mode Sense: 2b 00 80 08 sd 2:0:0:0: [sdb] Attached SCSI removable disk EXT4-fs (sdb3): INFO: recovery required on readonly filesystem EXT4-fs (sdb3): write access unavailable, cannot proceed (try mounting with noload) /dev/sdb4: Can't open blockdev
這是命令的結果
hdparm /dev/sdb
:/dev/sdb: multcount = 0 (off) readonly = 0 (off) readahead = 256 (on) geometry = 29573/64/32, sectors = 60566016, start = 0
我也在
badblocks
/deb/sdb 上執行過,它沒有發現壞塊。我嘗試了該命令
hdparm -r0 /dev/sdb
,但沒有成功。hdparm 安全命令不再成功,例如:hdparm --security-mode m --user-master m --security-unlock p /dev/sdb
這個命令說:
SG_IO: bad/missing sense data, sb[]: 70 00 05 00 00 00 00 0a 00 00 00 00 20 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
hdparm -I /dev/sdb
給出以下結果:/dev/sdb: ATA device, with non-removable media Standards: Likely used: 1 Configuration: Logical max current cylinders 0 0 heads 0 0 sectors/track 0 0 -- Logical/Physical Sector size: 512 bytes device size with M = 1024*1024: 0 MBytes device size with M = 1000*1000: 0 MBytes cache/buffer size = unknown Capabilities: IORDY not likely Cannot perform double-word IO R/W multiple sector transfer: not supported DMA: not supported PIO: pio0
有沒有辦法關閉防寫,或者我的 USB 快閃記憶體驅動器肯定失去了?
USB 很可能有硬體故障,這種情況經常發生,尤其是使用便宜的 USB 驅動器。
您的問題有一個廣泛的答案: