1

I struggled to title this so if you have a better title please edit or request a change.

Trying to dual-boot windows and Ubuntu. I used mkusb to create a bootable Ubuntu disk, installed it, then went to create a bootable Windows disk in the same manner. Ran mkusb, selected dus, install, clone iso file. The process failed (I think because you're meant to use a different option for Windows isos), I don't have the error message.

Now whenever I try to use mkusb I get: No suitable target device found. This also happens if I try to use the mkusb restore option.

Full mkusb terminal output: target device is /dev/sdb.

---------------------------------------------------------------------
Usage: mkusb [input-file]      # optional parameter
---------------------------------------------------------------------
d:  dus , guidus, mkusb-dus    - Classic, easy to use
p: Plug,   mkusb-plug          - New, easy to use
n: NoX,    sudo mkusb-nox      - original text mode
b: Bas,    sudo mkusb-bas      - basic text mode for old/basic linux
e: Eleven, sudo -H mkusb-11    - Old user interface
q: Quit
---------------------------------------------------------------------
Select version of mkusb (d/p/n/b/e/q) d
 dus 12.5.7 
live system or temporary superuser permissions
clean if necessary and return
Drive that contains source file: /dev/sda
Live drive, that is booted from: /dev/sda
lsblk: /dev/sdb: not a block device
 No suitable target device found 
p_target: target=/dev/
No target device or bad target device
clean if necessary and return
clean if necessary and return
clean if necessary and quit

$: sudo fdisk -l does not list /dev/sdb.

I tried using gparted to wipe the partition table and create a new one, however gparted displays the 16GB drive as ~8GB:

enter image description here

I proceeded with formatting the available space and creating a new msdos partition table, this is the format shown in the gparted screen above. The warning associated with the partition reads:

5.52 GiB of unallocated space within the partition. To grow the filesystem to fill the partition, select the partition and choose the menu item: Partition --> Check.

Running Partition --> Check results in Could not detect file system. at the terminal and fails.

If I open up gnome-disks I get this information: enter image description here

Which looks completely different to the partition breakdown given by gparted. Note, the partition sizes were the same before I modified things in gparted, the only difference was the first partition was an Ubuntu image with a different format. Before running gparted I tried zeroing the drive with dd which stopped after ~8GB and appeared to have no effect.

In short, I have no clue what's going on with the partition table on this drive.

Questions:

  1. What have I done to the partition table?
  2. Can I fix it? I still need to install Windows and I would like to recover the drive afterwards.

Bonus round:

  1. I'm aware mkusb "uses the whole drive" but I know I've lost at least one drive to the same problem. What causes it to royally screw up the drives it targets?
  2. Why is it so finicky to restore the partition table after using mkusb?

I'd like to understand what's going on here as well as how to resolve the issue.

Thank you

  • I will try to help you, and in that process I need some feedback from you. I suggest that you start by reading [**this link**](https://askubuntu.com/questions/144852/cant-format-my-usb-drive-i-have-already-tried-with-mkdosfs-and-gparted/933035#933035) (to my answer to another AskUbuntu question), and after that reboot your computer and try with mkusb to wipe the first mibibyte of the problematic drive (if mkusb can see it). Please let me know the result. – sudodus Jul 03 '20 at 13:00
  • 1
    How, in the name of all that is Holy did that work? I restarted my laptop and suddenly mkusb can see the drive properly. Granted it sees it as a 14GB but this is consistent with the pre-ubuntu state. I was able to restore the flash drive and then write the Windows image. – R. Mitchell Jul 03 '20 at 16:01
  • Sometimes it helps to reboot the computer, if there is 'confusion' about the partition table. I'm glad that you can use your USB drive again :-) Most of the time it helps with a shortcut, `sudo partprobe` to re-read the partition table and update the linux kernel's notion about it, but `sudo reboot` is more likely to do the trick. (`sudo partprobe` is called by mkusb, but did not help this time.) – sudodus Jul 03 '20 at 18:10

0 Answers0