In this tutorial we will learn how to manually fail a device used in raid and how to add a new to device to existing raid. we will also learn how to use spare device and how to stop and remove software raid completely from our linux machine. But before we starting removing any devices from existing raid device first check the built topology of created raid.check the number of disk and name of disk used in raid as active device and find out the device name used as spare device using below linux command line tools.
hence now its completely clear from the above output which device is used as active device and which one is spare device.
Step1:Now i am going to fail one of device active in raid-1 named /dev/sdb3 manually and analysie what will happen after one disk failure.
Let's see how to manually fail and remove active devices from raid device.
Just after above command i have run below command and you can see spare device is taking place of failed device.
I HAVE CROSS CHECK IT ONCE AGAIN USING DIFFERENT COMMAND BUT I FOUND THE SAME RESULT.
Step2:Now if you want to remove faulty spare device from raid device use below command.
Above method is also know as hot removal method.
Let's check the output again after hot removal of faulty spare device(/dev/sdb3) from raid.
you can clearly see there is no /dev/sdb3 device anywhere.
Step4:Now let's learn how to manually add any disk to existing raid so that it can be used as a spare disk.
Now check whether /dev/sdb3 is added to raid device as a spare device or not.
You can clearly see now /dev/sdb3 is being used as spare device.
you must follow this step to delete a raid device cleanly from your linux machine.
first unmount then stop the raid device and then remove it.
Check whether unmounted or not using df -h command.
Now STOP the RAID DEVICE FIRST.
Then Remove the RAID Device.
Now check whether raid is deleted or not.
so you can clearly see there is no active raid.
It means we have successfully deleted software raid from our linux machine.
Now you can delete partitions used in raid using fdisk command or you can use those partitions for different use. It's all up to you know.
this is one of the best site i have ever seen. the content is perfect, the theme is perfect and the style of writing is awesome. very impressive. i have also started writing please check it out https://thevtechblog.wordpress.com/.
How secure is payment by scanning Paytm QR code to merchants?