Ubuntu下U盘变成只读的解决方法

首先执行命令:

tail -f /var/log/syslog

然后插入有问题的U盘,tail会打印一些log:

Jan 23 09:40:55 zkw-3330 kernel: [1451066.881318] usb 3-1: new high-speed USB device number 61 using xhci_hcd
Jan 23 09:40:55 zkw-3330 kernel: [1451066.898140] usb 3-1: New USB device found, idVendor=0781, idProduct=5567
Jan 23 09:40:55 zkw-3330 kernel: [1451066.898150] usb 3-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
Jan 23 09:40:55 zkw-3330 kernel: [1451066.898156] usb 3-1: Product: Cruzer Blade
Jan 23 09:40:55 zkw-3330 kernel: [1451066.898161] usb 3-1: Manufacturer: SanDisk
Jan 23 09:40:55 zkw-3330 kernel: [1451066.898165] usb 3-1: SerialNumber: 20060774101E0202EEDF
Jan 23 09:40:55 zkw-3330 kernel: [1451066.898676] usb-storage 3-1:1.0: USB Mass Storage device detected
Jan 23 09:40:55 zkw-3330 kernel: [1451066.900344] scsi32 : usb-storage 3-1:1.0
Jan 23 09:40:55 zkw-3330 mtp-probe: checking bus 3, device 61: "/sys/devices/pci0000:00/0000:00:14.0/usb3/3-1"
Jan 23 09:40:55 zkw-3330 mtp-probe: bus: 3, device: 61 was not an MTP device
Jan 23 09:40:56 zkw-3330 kernel: [1451067.898169] scsi 32:0:0:0: Direct-Access     SanDisk  Cruzer Blade     1.26 PQ: 0 ANSI: 5
Jan 23 09:40:56 zkw-3330 kernel: [1451067.898785] sd 32:0:0:0: Attached scsi generic sg1 type 0
Jan 23 09:40:56 zkw-3330 kernel: [1451067.899778] sd 32:0:0:0: [sdb] 15633408 512-byte logical blocks: (8.00 GB/7.45 GiB)
Jan 23 09:40:56 zkw-3330 kernel: [1451067.902348] sd 32:0:0:0: [sdb] Write Protect is off
Jan 23 09:40:56 zkw-3330 kernel: [1451067.902352] sd 32:0:0:0: [sdb] Mode Sense: 43 00 00 00
Jan 23 09:40:56 zkw-3330 kernel: [1451067.902656] sd 32:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesnt support DPO or FUA
Jan 23 09:40:56 zkw-3330 kernel: [1451067.910687]  sdb: sdb4
Jan 23 09:40:56 zkw-3330 kernel: [1451067.912366] sd 32:0:0:0: [sdb] Attached SCSI removable disk
Jan 23 09:40:56 zkw-3330 kernel: [1451068.146809] FAT-fs (sdb4): Volume was not properly unmounted. Some data may be corrupt. Please run fsck.
Jan 23 09:40:56 zkw-3330 udisksd[1790]: Mounted /dev/sdb4 at /media/zkw/ZHOU_KE_WEN on behalf of uid 1000
Jan 23 09:40:56 zkw-3330 kernel: [1451068.395756] FAT-fs (sdb4): error, fat_get_cluster: invalid cluster chain (i_pos 0)
Jan 23 09:40:56 zkw-3330 kernel: [1451068.395761] FAT-fs (sdb4): Filesystem has been set read-only
Jan 23 09:40:56 zkw-3330 wpa_supplicant[1277]: nl80211: send_and_recv->nl_recvmsgs failed: -33

其中红色的部分表明了u盘出了问题,被挂在为只读的了,使用dosfsck修复一下:

umount /media/(U盘被挂在后的名字)
sudo dosfsck -v -a /dev/sdb4

修复后,u盘就回复读写了。

郑重声明:本站内容如果来自互联网及其他传播媒体,其版权均属原媒体及文章作者所有。转载目的在于传递更多信息及用于网络分享,并不代表本站赞同其观点和对其真实性负责,也不构成任何其他建议。