Ask Your Question

how do I get rid of an xfs partition?

asked 2017-08-31 00:13:30 -0500

toddandmargo gravatar image

updated 2017-09-01 20:17:03 -0500

Hi All,

Fedora 26

I have a SATA backup drive formatted gpt, one partition, xfs. I went into gparted, erased the partition, recreated the partition as ext4 and formatted it as ext4 as well.

Then I mounted it as ext4, copied some files to it, unmounted it. When I went to remount it, mount told me there was something wrong with ext4. So I mounted it as xfs AND IT WORKED! I repeated with the same result. The drive thinks it is ext4 until the second mount.

Out of shear frustration, I did a dd /dev/zero overwrite of the stinker and left it running overnight. If this doesn't remove xfs: AAAHHHH!!!!

What is the official way to rig myself of an xfs partition?

Many thanks, -T

Follow up: I asked Fedora to include a disk wipe option in gparted:

Here are some of the work around I came up with:

1) dd /dev/zero over the front of the drive. (did not always work)

2) dd /dev/zero over the entire drive (always worked, but took FOREVER)

3) In bios, throw the drive into an RSTe raid pair, which blanks the drive, then break it from the pair. (always worked).

4) wipefs, which was spotty if the drive was weird.

edit retag flag offensive close merge delete


What is the output of fdisk -llsblk And I suppose you are on uefi system

alextheoto gravatar imagealextheoto ( 2017-08-31 03:26:09 -0500 )edit

eufi give me hives. I have the bios set for "Legacy"

# fdisk -l lsblk
fdisk: cannot open lsblk: No such file or directory

This is after overwriting the thing with /dev/zero

# ls -l /dev/sdd1
brw-rw----. 1 root disk 8, 49 Aug 30 22:05 /dev/sdd1

and after gparted

# fdisk -l /dev/sdd
Disk /dev/sdd: 1.8 TiB, 2000398934016 bytes, 3907029168 sectors
Device     Start        End    Sectors  Size Type
/dev/sdd1   2048 3907028991 3907026944  1.8T Linux filesystem

Running out of space, will continue on next comment

toddandmargo gravatar imagetoddandmargo ( 2017-08-31 12:45:00 -0500 )edit

And now it is working again. Shheees, do I have to dd overwrite the other four drives???

toddandmargo gravatar imagetoddandmargo ( 2017-08-31 12:57:41 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted

answered 2017-08-31 14:03:42 -0500

toddandmargo gravatar image

The folks over at confirmed that this sometimes happens and told me how to solve it:

1) overwrite the first 512 byes of the drive or 2) wipefs

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2017-08-31 00:13:30 -0500

Seen: 250 times

Last updated: Sep 01 '17