简体   繁体   中英

Query with mv linux command

I used the following linx command :

mv RegisteredOutputs.msg registered_outputs.tcl 

My intention was to achieve the following :

mv RegisteredOutputs.msg registered_outputs.msg

The directory in which I issued the command already had a file named registered_outputs.tcl .

So by far you might have figured out what my issue is. registered_outputs.tcl got overwritten. Is there any way of recovering it ?

First thing you always do: Boot a live CD/USB so that your partition is mounted read-only, to avoid those spaces on the drive being re-used. Once another file uses that platter space, the data is gone.

Because of how Linux ext3 file system works, it actually zeroes out inode data on delete, making recovery impossible. This is for delete however, and I don't know if the same could apply to overwriting existing files. Hope you're feeling lucky.

See this guide on how to recover deleted files on ext3

source:

recovery of overwritten file

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM