kingston usb thumb drive " Problem opening /dev/sdb for reading! Error is 6 "
by erpils72 from LinuxQuestions.org on (#5SQE8)
(kibotkali)-[~]
$ sudo fdisk /dev/sdb
Welcome to fdisk (util-linux 2.37.2).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Device does not contain a recognized partition table.
Created a new DOS disklabel with disk identifier 0x11b3e285.
Command (m for help): w
The partition table has been altered.
Calling ioctl() to re-read partition table.
Re-reading the partition table failed.: No such device or address
The kernel still uses the old table. The new table will be used at the next reboot or after you run partprobe(8) or partx(8)
(kibotkali)-[~]
$ sudo partprobe -d /dev/sdb
Show nothing..
I tried gdisk--
(kibotkali)-[~]
$ sudo gdisk /dev/sdb
GPT fdisk (gdisk) version 1.0.8
Partition table scan:
MBR: not present
BSD: not present
APM: not present
GPT: not present
Command (? for help): t
No partitions
Command (? for help): x
Expert command (? for help): v
No problems found. 60437425 free sectors (28.8 GiB) available in 1
segments, the largest of which is 60437425 (28.8 GiB) in size.
Expert command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 1957FC8B-5119-41E9-BB56-AB7E10C4BFC4
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 60437425 sectors (28.8 GiB)
Command (? for help): n
Partition number (1-128, default 1):
First sector (34-60437458, default = 2048) or {+-}size{KMGTP}:
Last sector (2048-60437458, default = 60437458) or {+-}size{KMGTP}: +100M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 60232625 sectors (28.7 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
Command (? for help): n
Partition number (2-128, default 2):
First sector (34-60437458, default = 206848) or {+-}size{KMGTP}:
Last sector (206848-60437458, default = 60437458) or {+-}size{KMGTP}: +200M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 59823025 sectors (28.5 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
2 206848 616447 200.0 MiB 8300 Linux filesystem
Command (? for help): n
Partition number (3-128, default 3):
First sector (34-60437458, default = 616448) or {+-}size{KMGTP}:
Last sector (616448-60437458, default = 60437458) or {+-}size{KMGTP}: +100M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): n
Partition number (4-128, default 4):
First sector (34-60437458, default = 821248) or {+-}size{KMGTP}:
Last sector (821248-60437458, default = 60437458) or {+-}size{KMGTP}: +100M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 59413425 sectors (28.3 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
2 206848 616447 200.0 MiB 8300 Linux filesystem
3 616448 821247 100.0 MiB 8300 Linux filesystem
4 821248 1026047 100.0 MiB 8300 Linux filesystem
Command (? for help): n
Partition number (5-128, default 5):
First sector (34-60437458, default = 1026048) or {+-}size{KMGTP}:
Last sector (1026048-60437458, default = 60437458) or {+-}size{KMGTP}:
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 2014 sectors (1007.0 KiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
2 206848 616447 200.0 MiB 8300 Linux filesystem
3 616448 821247 100.0 MiB 8300 Linux filesystem
4 821248 1026047 100.0 MiB 8300 Linux filesystem
5 1026048 60437458 28.3 GiB 8300 Linux filesystem
Command (? for help): w
Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING
PARTITIONS!!
Do you want to proceed? (Y/N): Y
OK; writing new GUID partition table (GPT) to /dev/sdb.
Problem opening /dev/sdb for reading! Error is 6.
The operation has completed successfully.
when i pull out the thumb drive and put back in and run fdisk it shows this....
$ sudo fdisk -l
Disk /dev/sda: 74.53 GiB, 80026361856 bytes, 156301488 sectors
Disk model: FUJITSU MHV2080B
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: 0x8e8b7a62
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 154300415 154298368 73.6G 83 Linux
/dev/sda2 154302462 156301311 1998850 976M 5 Extended
/dev/sda5 154302464 156301311 1998848 976M 82 Linux swap / Solaris
Disk /dev/sdb: 28.82 GiB, 30943995904 bytes, 60437492 sectors
Disk model: DataTraveler 3.0
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
$ sudo fdisk /dev/sdb
Welcome to fdisk (util-linux 2.37.2).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.
Device does not contain a recognized partition table.
Created a new DOS disklabel with disk identifier 0x11b3e285.
Command (m for help): w
The partition table has been altered.
Calling ioctl() to re-read partition table.
Re-reading the partition table failed.: No such device or address
The kernel still uses the old table. The new table will be used at the next reboot or after you run partprobe(8) or partx(8)
(kibotkali)-[~]
$ sudo partprobe -d /dev/sdb
Show nothing..
I tried gdisk--
(kibotkali)-[~]
$ sudo gdisk /dev/sdb
GPT fdisk (gdisk) version 1.0.8
Partition table scan:
MBR: not present
BSD: not present
APM: not present
GPT: not present
Command (? for help): t
No partitions
Command (? for help): x
Expert command (? for help): v
No problems found. 60437425 free sectors (28.8 GiB) available in 1
segments, the largest of which is 60437425 (28.8 GiB) in size.
Expert command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): 1957FC8B-5119-41E9-BB56-AB7E10C4BFC4
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 60437425 sectors (28.8 GiB)
Command (? for help): n
Partition number (1-128, default 1):
First sector (34-60437458, default = 2048) or {+-}size{KMGTP}:
Last sector (2048-60437458, default = 60437458) or {+-}size{KMGTP}: +100M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 60232625 sectors (28.7 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
Command (? for help): n
Partition number (2-128, default 2):
First sector (34-60437458, default = 206848) or {+-}size{KMGTP}:
Last sector (206848-60437458, default = 60437458) or {+-}size{KMGTP}: +200M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 59823025 sectors (28.5 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
2 206848 616447 200.0 MiB 8300 Linux filesystem
Command (? for help): n
Partition number (3-128, default 3):
First sector (34-60437458, default = 616448) or {+-}size{KMGTP}:
Last sector (616448-60437458, default = 60437458) or {+-}size{KMGTP}: +100M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): n
Partition number (4-128, default 4):
First sector (34-60437458, default = 821248) or {+-}size{KMGTP}:
Last sector (821248-60437458, default = 60437458) or {+-}size{KMGTP}: +100M
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 59413425 sectors (28.3 GiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
2 206848 616447 200.0 MiB 8300 Linux filesystem
3 616448 821247 100.0 MiB 8300 Linux filesystem
4 821248 1026047 100.0 MiB 8300 Linux filesystem
Command (? for help): n
Partition number (5-128, default 5):
First sector (34-60437458, default = 1026048) or {+-}size{KMGTP}:
Last sector (1026048-60437458, default = 60437458) or {+-}size{KMGTP}:
Current type is 8300 (Linux filesystem)
Hex code or GUID (L to show codes, Enter = 8300):
Changed type of partition to 'Linux filesystem'
Command (? for help): p
Disk /dev/sdb: 60437492 sectors, 28.8 GiB
Model: DataTraveler 3.0
Sector size (logical/physical): 512/512 bytes
Disk identifier (GUID): C53B8A6D-87A9-4DDC-A698-ECA77CAB6E22
Partition table holds up to 128 entries
Main partition table begins at sector 2 and ends at sector 33
First usable sector is 34, last usable sector is 60437458
Partitions will be aligned on 2048-sector boundaries
Total free space is 2014 sectors (1007.0 KiB)
Number Start (sector) End (sector) Size Code Name
1 2048 206847 100.0 MiB 8300 Linux filesystem
2 206848 616447 200.0 MiB 8300 Linux filesystem
3 616448 821247 100.0 MiB 8300 Linux filesystem
4 821248 1026047 100.0 MiB 8300 Linux filesystem
5 1026048 60437458 28.3 GiB 8300 Linux filesystem
Command (? for help): w
Final checks complete. About to write GPT data. THIS WILL OVERWRITE EXISTING
PARTITIONS!!
Do you want to proceed? (Y/N): Y
OK; writing new GUID partition table (GPT) to /dev/sdb.
Problem opening /dev/sdb for reading! Error is 6.
The operation has completed successfully.
when i pull out the thumb drive and put back in and run fdisk it shows this....
$ sudo fdisk -l
Disk /dev/sda: 74.53 GiB, 80026361856 bytes, 156301488 sectors
Disk model: FUJITSU MHV2080B
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: 0x8e8b7a62
Device Boot Start End Sectors Size Id Type
/dev/sda1 * 2048 154300415 154298368 73.6G 83 Linux
/dev/sda2 154302462 156301311 1998850 976M 5 Extended
/dev/sda5 154302464 156301311 1998848 976M 82 Linux swap / Solaris
Disk /dev/sdb: 28.82 GiB, 30943995904 bytes, 60437492 sectors
Disk model: DataTraveler 3.0
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes