forbid file recovery


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers forbid file recovery
# 1  
Old 12-24-2008
Question forbid file recovery

Hi there,
When I want to make a file unrecoverable, I use the following command:
Code:
foo:~$ shred -fuz filename

The problem is that I deleted many files using:
Code:
foo:~$ rm -f filename

How can I make those files unrecoverable?
Is there a command that shreds the disk free space?
So that no file can be recovered from the "supposedly" free space.
Thanks for your help.
Santiago
# 2  
Old 12-24-2008
Code:
dd if=/dev/zero of=dummyfile; rm dummyfile

Which just fills all available disk space with zeroes. You might want to follow with
Code:
dd if=/dev/urandom of=dummyfile; rm dummyfile

to overwrite with random data.

Note, if the machine in question is an ssh or https server, you don't want to exhaust the available entropy; consider generating one one machine and piping through ssh onto the other.
Code:
dd if=/dev/urandom | ssh other 'cat >dummyfile; rm dummyfile'

Note also that if this involves the root filesystem or a multi-user system this will cause problems when the disk fills. Think carefully before doing this on critical systems.
# 3  
Old 02-27-2009
Forgot to say thanks.
Maybe not too late?
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Is possible to recovery a deleted file in AIX?

is it possible to recovery a deleted file in AIX? (2 Replies)
Discussion started by: fiyas
2 Replies

2. UNIX for Advanced & Expert Users

File recovery

Hi, Please let me know the way to recover the files deleted from home directory by 'rm*' command . Thanks in advance. (10 Replies)
Discussion started by: ravigupta2u
10 Replies

3. HP-UX

@ character forbid to write in vi.

Hi ALL, I'm encountering this problem on HP Shell (tcsh) environment. Once I enter in vi to edit a file and add my sql script, like this: sqlplus user/pass @promo.sql(tu run my script) the @ character is not possible to write. I push on the key but is not written inside. Also in sqlplus... (3 Replies)
Discussion started by: cicalons
3 Replies

4. Cybersecurity

File Integrity checker with recovery

Hello friends I have an CentosOS 5 box running Apache, I want to Install a powerful File Integrity checker with recovery option to maintain any changes may be happened without my hand Could you help me to recommend such solution Thanks (3 Replies)
Discussion started by: reaky
3 Replies

5. Programming

How forbid use fork() in exec() program.

Hello World! I am writing code in C++ which have to launch another application X using exec(). I would like to set some limits on it using setrlimit etc... My problem is that i don't know how to forbid using fork() and strlimit by application X. How can i do it? (3 Replies)
Discussion started by: kzi
3 Replies

6. Solaris

Password Recovery From /etc/shadow file

Is it possible to reset a normal user password , by editing password field in /etc/shadow file? Thanks (6 Replies)
Discussion started by: ksvaisakh
6 Replies

7. UNIX for Advanced & Expert Users

Recovery Of Passwd File

the file /etc/passwd has corrupted mistakenly.actually the file has saved as "oot:0:0:root:/root/sbin/bash". first r of root has been deleted .. can anyone tell me how can i recover as normal user (2 Replies)
Discussion started by: singh_hackerz
2 Replies

8. Shell Programming and Scripting

forbid the error message

In my system , there is a script seems have a minor problem but I can't find it out , now everytime run the script , it will generate some error message to the system log , is it possible to forbid it generate the error to the system log or put all these message to /dev/null ? thx (3 Replies)
Discussion started by: ust
3 Replies

9. UNIX for Dummies Questions & Answers

shell script: forbid extension

Rather new to unix, so please don't beat me! I'm trying to get a list of files into a variable that I can use throughout the rest of the script. The challenge is that I need to exclude a certain extension from the list, and I'm having trouble with it. For example: item_a item_a.exe... (3 Replies)
Discussion started by: Loriel
3 Replies

10. UNIX for Advanced & Expert Users

How can I forbid a user to go up his home directory

Hi everybody, How can I forbid a user to go up his home directory ? Thanks MarcoW (2 Replies)
Discussion started by: MarcoW
2 Replies
Login or Register to Ask a Question