0

I started copying some files to a USB flash drive on Ubuntu. I was in rush, while the writing process is still running I unplugged the USB flash.

When I opened it on windows, the files I was trying to copy were missing and the drive was marked as read-only file system. I tried many option to format it but nothing worked.

I plugged into Ubuntu and tried to format it using the "Format Volume" command in "Files". I got the following error message.

Error wiping device: Failed to open the device'/dev/sdc1' (udisks-error-quark, 0)

Error message while formatting volume

I made a wide research with this error message, I tried many options:

Commands that I tried

As you can see, this didn't solve the problem.

I also tried to format it with "GParted 0.30.0". GParted exclamation mark

As you can see in the picture there is a red exclamation mark near the partition name.

I proceeded to format, then I got this message:

Libparted Error

Can't write to dev/sdc, because it's opened read-only.

Error message while formatting with GParted

When the next windows appeared, I expanded the error message I got this:

Error message details

I appreciate your help, to solve this issue and to prevent it form happening in the future.

Thanks in advance.

1

Assuming you don't mind losing anything on the affected disk, you should:

  1. Unmount /dev/sdc
  2. create a partition table on the disk in gparted (available from the Device tab). If you are not sure what type of table to use, go with the default (usually GPT or msdos).
  3. you will now see unallocated space on the disk. In this space, make a new partition,
  4. change the filesystem drop down to the filesystem of your choice (from your screenshots, it appears you want NTFS).

If this goes well, you should then be able to use your flash drive again.

  • I tried to change the partition table via GParted, but this didn't work. I got this error message: Can't write to /dev/sdc, because it's opened read-only. Any way thanks for your suggestion. – Abdelkrim Ibrahim Sep 3 at 21:19
  • @AbdelkrimIbrahim see edit. – Fabby Sep 5 at 21:53
  • 1
    @Fabby Thank you for improving my answer! – Daniel Massey Sep 7 at 6:54
0

Put your USB-Stick onto a windowsmaschine.

The best way to fix errors on a ntfs filesystem.

Make sure that windows is complete poweroff after repair.

  • I tried many options on windows but nothing worked. I tried to format it with windows explorer and cmd. I used the check for errors option. I even tried windows disk manager. I get always the same message: write only file system. – Abdelkrim Ibrahim Sep 3 at 21:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.