прости мой английский sh. При подключении USB-накопителя к ноутбуку и введите следующую команду, следующую за клавишей ввода:
$ dmesg | tail -9
Отображает следующий вывод:
usb-storage 1-3:1.0: USB Mass Storage device detected
scsi host4: usb-storage 1-3:1.0
scsi 4:0:0:0: Direct-Access Generic Flash Disk 8.07 PQ: 0 ANSI: 4
sd 4:0:0:0: Attached scsi generic sg1 type 0
sd 4:0:0:0: [sdb] 61069312 512-byte logical blocks: (31.3 GB/29.1 GiB)
sd 4:0:0:0: [sdb] Write Protect is on
sd 4:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
sdb: sdb1
sd 4:0:0:0: [sdb] Attached SCSI removable disk
Набрав вторую команду ниже, и нажав клавишу ввода:
$ sudo /usr/local/sbin/hdparm -r0 /dev/sdb
Отображает следующий вывод:
/dev/sdb:
setting readonly to 0 (off)
readonly = 0 (off)
Набрав третью команду ниже и нажав клавишу ввода:
$ sudo mount -t vfat /dev/sdb1 /mnt/sdb1
I можно просмотреть файлы и папки на USB-накопителе с помощью команды «ls». Набрав четвертую команду ниже и нажав клавишу ввода:
$ lsusb
Отображает следующий вывод:
Bus 001 Device 006: ID 058f:6387 Alcor Micro Corp. Flash Drive
Bus 001 Device 002: ID 04f2:b175 Chicony Electronics Co., Ltd 4-Port Hub
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 005 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Набрав пятую команду ниже и нажав клавишу ввода:
$ lsusb -D /dev/bus/usb/001/006
Отображает следующий вывод:
Device: ID 058f:6387 Alcor Micro Corp. Flash Drive
Device Descriptor:
bLength 18
bDescriptorType 1
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
idVendor 0x058f Alcor Micro Corp.
idProduct 0x6387 Flash Drive
bcdDevice 1.00
iManufacturer 1 Generic
iProduct 2 Mass Storage
iSerial 3 16BFB156
bNumConfigurations 1
Configuration Descriptor:
bLength 9
bDescriptorType 2
wTotalLength 32
bNumInterfaces 1
bConfigurationValue 1
iConfiguration 0
bmAttributes 0x80
(Bus Powered)
MaxPower 200mA
Interface Descriptor:
bLength 9
bDescriptorType 4
bInterfaceNumber 0
bAlternateSetting 0
bNumEndpoints 2
bInterfaceClass 8 Mass Storage
bInterfaceSubClass 6 SCSI
bInterfaceProtocol 80 Bulk-Only
iInterface 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x01 EP 1 OUT
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Endpoint Descriptor:
bLength 7
bDescriptorType 5
bEndpointAddress 0x82 EP 2 IN
bmAttributes 2
Transfer Type Bulk
Synch Type None
Usage Type Data
wMaxPacketSize 0x0200 1x 512 bytes
bInterval 0
Device Qualifier (for other device speed):
bLength 10
bDescriptorType 6
bcdUSB 2.00
bDeviceClass 0 (Defined at Interface level)
bDeviceSubClass 0
bDeviceProtocol 0
bMaxPacketSize0 64
bNumConfigurations 1
Device Status: 0x0000
(Bus Powered)
Но, набрав шестую команду ниже и нажав клавишу ввода:
$ mkdir /mnt/sdb1/newfolder
Отображает следующий вывод:
mkdir: cannot create directory '/mnt/sdb1/newfolder': Filesystem read only
Я много смеюсь от стыда, узнавая, где я ошибся.