GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
Already on GitHub? Sign in to your account
I need to reptyr badblocks in non-destructive read-write mode after the X server locked up. However I feel this is especially representative of any critical I/O based applications.
I am probably being paranoid, and I've already tested reptyr/badblocks in a virtual machine, and everything appeared fine. But I would probably never notice a single scrambled bad block.
So my question is this: Theoretically, is it possible/plausible for reptyr to scramble the FDs, accidentally write junk to a bad sector, or any other nightmare, that would compromise the reliability of critical applications.
reptyr does attach to the process via ptrace and perform operations in the process' address space, so it is theoretically possible for a bug somewhere to cause memory corruption. That said, I've written it with some care to minimize such risks, and never observed that sort of bug.
I do recommend testing reptyr on a dry-run against any super-critical processes, but if that works, I would be pretty confident that it will fail safely, if it does, rather than by silently corrupting data.