Skip to content

Instantly share code, notes, and snippets.

@finiteautomata
Last active July 13, 2017 15:31
Show Gist options
  • Save finiteautomata/9b292891f7dcd2bc867b38038909e37c to your computer and use it in GitHub Desktop.
Save finiteautomata/9b292891f7dcd2bc867b38038909e37c to your computer and use it in GitHub Desktop.
Formatting USB Ubuntu Stick

If Ubuntu doesn't format your USB Drive (possibly an Ubuntu USB stick) with an error saying

This partition cannot be modified because it contains a partition table; >please reinitialize layout of the whole device. (udisks-error-quark, 11)

Do this:

sudo dd if=/dev/zero of=/dev/sdb bs=1M

(where /dev/sdb is the device to be formatted)

This will copy zeroes in a low-level way to your USB. After this, you can retry formatting from Nautilus/GParted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment