Linux, FreeBSD, Juniper, Cisco / Network security articles and troubleshooting guides

It is currently Sat Oct 23, 2021 10:31 am

Message body:
Enter your message here, it may contain no more than 60000 characters. 

:D :) ;) :( :o :shock: :? 8-) :lol: :x :P :oops: :cry: :evil: :twisted: :roll: :!: :?: :idea: :arrow: :| :mrgreen: :geek: :ugeek:
Font size:
Font colour
BBCode is ON
[img] is ON
[flash] is OFF
[url] is ON
Smilies are ON
Disable BBCode
Disable smilies
Do not automatically parse URLs
Confirmation code
Confirmation code:
In an effort to prevent automatic submissions, we require that you enter both of the words displayed into the text field underneath.

Topic review - Mdadm - How can i destroy or delete an array
Author Message
Post subject: Mdadm - How can i destroy or delete an array  |  Post Posted: Tue May 18, 2010 9:52 am
So, you created an array and you messed up something? Now you would like to delete it?
Please note: all data will be lost with this operation!

1. Stop the array
# mdadm -S /dev/md0

2. Remove the disks from the array (in my example md0 is a raid5 array with 3 disks)
# mdadm /dev/md0 -r /dev/sda
# mdadm /dev/md0 -r /dev/sdb
# mdadm /dev/md0 -r /dev/sdc

3. Destroy the array configuration from each disk (this will destroy all the data from your disks)
# dd if=/dev/zero of=/dev/sda bs=1M count=1024
# dd if=/dev/zero of=/dev/sdb bs=1M count=1024
# dd if=/dev/zero of=/dev/sdc bs=1M count=1024

4. Remove the mdadm.conf file (if any)
# rm /etc/mdadm/mdadm.conf

Now you can try to create a new array as you wish or as you were suposed to...
Jump to:  
cronNews News Site map Site map SitemapIndex SitemapIndex RSS Feed RSS Feed Channel list Channel list

Delete all board cookies | The team | All times are UTC - 5 hours [ DST ]