Issue available disk space while using xdd

Good morning,

I seem to be running into an issue with some drives I have attached to my solaris server. The drives are attached correctly, the partitions are arranged with fdisk, the ext3 filesystem is setup using mkfs, and finally the drive is mounted.

When I use xdd to perform read/write operations, for some reason with writes in particular, the drives seem to lose track of how much space is available. Using df, I can see that there are about 50 GB available on these nearly empty drives but once I begin using a write with xdd, the drive size jumps to 11 TB and the used space jumps up to 11 TB as well.

I feel as though the xdd program may be altering the partition table of some sort and is ruining the tests I'm trying to gather. If anyone has experience with xdd and could lend some assistance it would be greatly appreciated.

The command for xdd I am executing is as follows:

xdd.linux -blocksize 262144 -datapattern random -seek random -reqsize 1 -op write -targets 1 /dev/sdb1 -deletfile -mbytes 10240 -csvout "10_write_ran_256_01.txt"

Thanks for the assistance and if you need more information please ask!

I'm fairly sure you're not supposed to run xdd on a mounted filesystem(or any data you care about)! My suspicions were raised the instant I noticed it took a device file instead of a mount path. The system will let root write to the partition raw with no regard to any filesystems. I've seen similar things happen when I accidentally ran mkswap on a mounted filesystem... Suddenly, minus 64 exabytes free. :wink:

Got it, that would make sense. The data on the drives don't matter at all, these are just throughput tests.

I guess my other question would revolve around testing drives throughput when the drive is full of data and when it is empty. Is there a way to do so with xdd?

The drive will have the same physical performance whether its sectors contain all zeroes, all ones, or random data. 'full' and 'empty' are abstract concepts that don't exist without a filesystem.