-
Senior Member
registered user
Re: Customizing to wipe drives at boot.

Originally Posted by
kevo
I would like to create a customized image that will do the following and I am not even sure if it is possible.
I would like the image to boot and immediately determine the number of installed drives ide/scsi/raid and use the dd if=/dev/random of=/dev/hdX command to wipe each one of these drives and display a message when completed indicating sucess or failure.
Then I would like to upon some kind of user intervention keystroke ect. show a listing of the installed hardware like:
processor type
processor speed
amount of ram
hard drives and sizes
network cards
optical drives
sound card type
video card type.
I have investigated it somewhat and think that I probably have to run a script at init and that is about all I have learned. The command for wiping the hard drives seems to be a unterminated perl loop so I was interested in how/if that could be used to automatically move to the next drive when the first has completed?
Can anyone point me to sample scripts or help me understand if it is possible to do before I spend time testing only to be disappointed.
I work for a recycling company that refurbishes computers and has to destroy lots of data and would like to do it with Linux not a shredder. We have a dos based solution that works great but would like more flexibility that linux offers.
Thanks in advance
Kevo
It is easily possible:
BE CAREFUL WITH THE SCRIPT THAT FOLLOWS!
Just add a knoppix.sh as follows to:
/cdrom/KNOPPIX/knoppix.sh:
#!/bin/bash
DISKS=$(cat /proc/partitions | awk '{ if ($4!="name") { print $4 } }' | egrep -v "[0-9]$");
for i in $DISKS;
do
[ -f "/proc/ide/$i/model" ] && MODEL="$(cat /proc/ide/$i/model)" || MODEL=$"model unknown"
cat /proc/partitions | awk '{ if ($4=="'$i'") { printf("Wiping %s / '"$MODEL"' (%s GB) ...",$4,($3*1024/1000/1000/1000))}}'
#dd of=/dev/random if=/dev/$i
echo "Done"
done
Thats it. (Well there is a hidden mistake; sorry code is to dangerous to post it 100% working)
Don't try this at home kids!
cu
Fabian
Similar Threads
-
By lstein in forum Laptops
Replies: 22
Last Post: 05-16-2004, 12:01 PM
-
By stardactyl in forum Customising & Remastering
Replies: 1
Last Post: 04-15-2004, 08:17 PM
-
By freeballer in forum The Lounge
Replies: 3
Last Post: 12-25-2003, 04:21 PM
-
By sn0wflake in forum General Support
Replies: 4
Last Post: 12-05-2003, 04:15 AM
-
By pap2003 in forum Customising & Remastering
Replies: 1
Last Post: 06-05-2003, 08:47 PM
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules

Yealink T48S VoIP/SIP Phone, 2 x Gigabit Ports PoE 7" Color SIP-T48S | TESTED
$34.95

Cisco IP Phone CP-8821 No Battery C2-F3
$185.00

SIM Bank 32 SIM Card Slots Ethernet SIM Server for GoIP
$400.00

Poly CCX 400 Desktop Business Media Phone VoIP 2200-49700-019
$49.99

Yealink SIP-T33G IP Phone 4-LineSpeakerphone VoIP Desk Phone Black w/ Power Sply
$25.00

Yealink SIP-T44W VoIP Phone 12-Line Gigabit Speakerphone RJ-45 Gray/Black
$44.00

5 Allworx Verge 9312 VoIP IP Phone 12-Line Speakerphone Black RJ-45 MPN 8113120
$999.00

Yealink T53W Black IP Phone Verizon VoIP LOT OF 4 Business Desk Phone
$150.00

Grandstream WP810 Portable Cordless Wi-Fi IP Phone
$49.28

NEW Cisco Mitel 6930 IP Phone VoIP Business Phone Black Sealed
$89.99