bug-ddrescue
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-ddrescue] block device & outfile safety checks


From: Antonio Diaz Diaz
Subject: Re: [Bug-ddrescue] block device & outfile safety checks
Date: Tue, 27 Mar 2018 22:53:29 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.9.1.19) Gecko/20110420 SeaMonkey/2.0.14

Hi Raphaël,

Thanks for your suggestions.

Raphaël wrote:
1) check that infile, if it's a block device, is not mounted
2) check that outfile does not belong to the same mount point that the
    device intended to be rescued.

I'm not sure how portably these two can be implemented because posix does not cover the concept of mounting. Maybe they'll need to be compiled conditionally.

I think 1 implies 2. I.e., if infile is not mounted, outfile can't "belong to the same mount point".


3) warning/confirmation if intending to reuse a mapfile specifying a
    non-existing outfile

This one is easy. Maybe should be enabled by --ask.


4) ideally, warning/confirmation if device changed since the previous
    run (eg: store/check a couple of smart metadata?)

The only portable, more or less reliable metadata I can think of is size. And even this can change after a reboot. Also the change of device may be intended. For example when continuing the rescue of a CDROM from another drive. I'm not sure how this could be implemented without causing more confusion than good.

I'll work at least on 1 and 3 for the next version of ddrescue.


Best regards,
Antonio.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]