For debugging purposes, I want to open a file on a specific predefined block. For instance, if I suspect a specific block is damaged, I want to write and read from it, and I'd rather do that in user mode, while the partition is mounted.
Is there a way to tell Linux, "hey! open this new file on block 4579 if it's free".
Yes, I can edit the block device directly, but that would likely to trash the filesystem if the drive is mounted.
Generic answers are welcomed, but even answer for the ext filesystems families is good enough.