Howto erase your files/partition with shred in linux
if you want to erase a file use just the command
shred -v filename
its ok if you erase your file one time. if you want to erase your file multi times use the -n parameter.
you overrite with the command the file 2 times.
shred -v -n 2 filename
to erase your partition use fdisk to show your partition
rex@linux:~$ sudo fdisk -l
Platte /dev/sda: 1500.3 GByte, 1500301910016 Byte
255 Köpfe, 63 Sektoren/Spuren, 182401 Zylinder
Einheiten = Zylinder von 16065 × 512 = 8225280 Bytes
Disk identifier: 0x00000001
Gerät boot. Anfang Ende Blöcke Id System
/dev/sda1 * 1 13 102400 7 HPFS/NTFS
Partition 1 endet nicht an einer Zylindergrenze.
/dev/sda2 13 16708 134102016 7 HPFS/NTFS
Partition 2 endet nicht an einer Zylindergrenze.
/dev/sda3 16709 182401 1330922880 5 Erweiterte
Partition 3 endet nicht an einer Zylindergrenze.
/dev/sda5 16709 17316 4876168+ 82 Linux Swap / Solaris
/dev/sda6 17316 35552 146482528+ 83 Linux
/dev/sda7 35553 182401 1179564088+ 7 HPFS/NTFS
Platte /dev/sdf: 82.3 GByte, 82348277760 Byte
255 Köpfe, 63 Sektoren/Spuren, 10011 Zylinder
Einheiten = Zylinder von 16065 × 512 = 8225280 Bytes
Disk identifier: 0x46894688
Gerät boot. Anfang Ende Blöcke Id System
/dev/sdf1 * 1 6530 52452193+ 7 HPFS/NTFS
/dev/sdf2 6531 10010 27953100 f W95 Erw. (LBA)
/dev/sdf5 6531 10010 27953068+ 7 HPFS/NTFS
The computer has 2 Harddisks
sda - 1500 GB
sdf - 80 GB
to erase the whole disk use:
sudo shred -v -n 2 /dev/sdf
to erase the first partition use
sudo shred -v -n 2 /dev/sd1
Similar entries
- How to mount shared Folder in VirtualBox and Ubuntu Linux
- Howto duplicate (clone) Virtualbox VM in Ubuntu Linux
- Creating linux ext3 file-system for a disk
- Server Crash - "isc_socket_create: fcntl/reserved: Too many open files" [Howto Fix]
- Secure USB Stick / External Drive
- Comparison of HDGuard, DeepFreeze, Dr-Kaiser and SteadyState
- Howto duplicate (clone) VirtualBox image in Windows 7
- search for files and create an archive with them (tar,find,linux)
- Using "Linux Find" command to get human readable directory sizes in public_html
- Packet Sniffing and Monitoring with Tshark / Wireshark
- Page generation time and http-referers with PHP
- Update / overwrite files and directories recursively with Linux mv - cp commands
- Iframe Trojan / Virus of Alcobro.net
- [Howto Fix] Table './eximstats/sends' is marked as crashed and should be repaired
- Howto install dig in Debian 5 (Lenny)
- howto cp images, mp3 from multiple directory to one directory (find, exec, cp)
- Howto install Volatility (RAM / Memory Forensic Framework) in Windows
- Why tableless design, DIV vs. TABLE
- Redirect webpages with HTML, PHP, .htaccess, Java+Script, CGI-Perl, ASP.NET and ColdFusion
- How do I secure my web site?

Comments
Post new comment