testdisk icon indicating copy to clipboard operation
testdisk copied to clipboard

Missing /cmd argument in Photorec 7.2?

Open q2dg opened this issue 2 months ago • 3 comments

I've seen https://www.cgsecurity.org/testdisk_doc/scripted_run.html#automating-recovery-using-photorec but when I've tried this feature in Photorec I've seen every command I was trying it always showed a standard help message, as if "/cmd" argument wasn't recognized at all. In fact, this help message (nor man page) lists available Photorec arguments but it does'nt mention /cmd !! (see below)

PhotoRec 7.2, Data Recovery Utility, February 2024
Christophe GRENIER <[email protected]>
https://www.cgsecurity.org
Usage: photorec [/log] [/debug] [/d recup_dir] [file.dd|file.e01|device]
       photorec /version
/log          : create a photorec.log file
/debug        : add debug information
PhotoRec searches for various file formats (JPEG, Office...). It stores files
in the recup_dir directory.

So, my question is...is documentation obsolete and just explains a removed argument? Thanks!

PS: I'm using precompiled version from official Fedora 43 repository

q2dg avatar Nov 16 '25 22:11 q2dg

Well, I've seen this related issue: https://github.com/cgsecurity/testdisk/issues/150

q2dg avatar Nov 16 '25 22:11 q2dg

/cmd is implemented as described in https://www.cgsecurity.org/wiki/Scripted_run but it's not advertised in the man page or in the command line help.

cgsecurity avatar Nov 17 '25 08:11 cgsecurity

Well, this wiki page needs some care: there's no explanation of "select" or "everything" keywords (as shown in examples); there's no explanation of "options" keyword, it isn't clear is Testdisk's keywords are valid for Photorec too or not...

q2dg avatar Nov 17 '25 10:11 q2dg