DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD Installation and Upgrading

OpenBSD Installation and Upgrading Installing and upgrading OpenBSD.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 11th January 2020
bceverly bceverly is offline
Shell Scout
 
Join Date: Mar 2015
Posts: 88
Question Wiping a softraid0 encrypted drive

Hi,

I recall there is a magic dd incantation that will wipe out both the original gpt partition table and the backup at the end of the drive so I don't have to write /dev/zero to every block on the drive if I want to start over and repartition my encrypted drive.

Unfortunately my Google-fu has failed me. Would someone mind giving me a nudge to how I can whack the drive quickly and start over again? I get that the old data will still be there unless I wipe it but I'm just messing around to figure out how I eventually want to config this machine (Thinkpad T440p with Coreboot/Tianocore).

Thanks!
Reply With Quote
  #2   (View Single Post)  
Old 11th January 2020
CiotBSD CiotBSD is offline
c107:b5d::
 
Join Date: Jun 2019
Location: Under /
Posts: 175
Default

Perhaps:

Code:
dd if=/dev/urandom of=/dev/rsd1c bs=1m count=1
you can use too `/dev/zero`

But, for the end, I dont known!
Reply With Quote
  #3   (View Single Post)  
Old 11th January 2020
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,977
Default

For me, just zeroing the first sectors has always been enough. I don't know anything about a "backup at the end of the drive."


As an example, to zero the first 100 sectors of sd5, I would just # dd if=/dev/zero of=/dev/rsd5c count=100
Reply With Quote
  #4   (View Single Post)  
Old 12th January 2020
shep shep is offline
Real Name: Scott
Arp Constable
 
Join Date: May 2008
Location: Dry and Dusty
Posts: 1,503
Default

Some drives will backup a gpt table at the end of the drive and restore it on the next boot. The google 'foo' is to add 'seek' to your search terms.
https://serverfault.com/questions/78...ta-from-a-disk

An alternative is to use gdisk which is available in the gparted live disk
https://www.rodsbooks.com/gdisk/wipegpt.html
Reply With Quote
  #5   (View Single Post)  
Old 12th January 2020
Head_on_a_Stick's Avatar
Head_on_a_Stick Head_on_a_Stick is offline
Real Name: Matthew
Bitchy Nerd Elitist
 
Join Date: Dec 2015
Location: London
Posts: 461
Default

If it's a solid state drive then blkdiscard(8) will wipe it in an instant but it's a Linux program (from the util-linux package) so you'd have to load a live image.
__________________
Are you infected with Wetiko?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How the NSA can break trillions of encrypted Web and VPN connections J65nko News 0 15th October 2015 06:45 PM
Help on getting WEP-Encrypted Network on OpenBSD chicago OpenBSD General 24 18th May 2011 05:15 AM
Encrypted == secure? passthejoe OpenBSD Security 13 9th November 2010 05:45 PM
Creating USB flash drive drive image from FreeBSD disc1.iso FBSD Guides 1 10th February 2010 04:42 PM
Encrypted disk compatibility issue TheLogicInverter FreeBSD Security 3 30th January 2009 02:59 PM


All times are GMT. The time now is 07:03 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick