mdadm

All posts tagged mdadm

If you have a NETGEAR Readynas NAS and you want to migrate your data to a bigger disk, there is not too much information in the Netgear Forum about how to do it. Here is how you can do it. You will require an external Linux machine (a Raspberry PI or Banana PI/Pro can do the trick) First, you have the RAID 1 set up with (i.e) 2x 2Tb disks. Attach the new disk to one of the available USB ports in the NAS. Sync the entire 2tb disk onto the new (i.e) 5Tb disk with: # dd if=/dev/sda Read more...
Scan and assemble: # mdadm --assemble --scan Scan to update mdadm.conf # mdadm -Es >> /etc/mdadm/mdadm.conf   If not md device has been found, or you have only one disk from two of the RAID1, you can force to re-create the md device. The important parameter is "missing", that will make mdadm to create the mirror with only one member:   # mdadm --create /dev/md127 --assume-clean --level=mirror --verbose --raid-devices=2 /dev/sda missing mdadm: /dev/sda appears to be part Read more...
If you have an issue booting your xen 5 because you have loose MBR information, here is how you can restore it very quickly. Proceed booting your server with a live cd distribution, like wifiSlax, and run the next commands. mount the necessary partitions in your harddisk to have / and /boot mounted. Let's say you have sda1 assigned to boot and sda2 to root partition. # mount /dev/sda2 /mnt # mount /dev/sda1 /mnt/boot or like in my case, mount your RAID1 partitions to access to yor root Read more...
Nowadays the hardisks are almost cheaper so creating a RAID1 is a good way to keep your data safe without waste too much money. If you have two disks with same size use them to create mirrored Storage Repository in XEN with the help of mdadm raid software, by default installed in a XEN distribution. SATA is always the best option to have a good I/O but as a test system IDE disks will be valid as well. Let's start. First, create the md devices in /dev # cd /dev # MAKEDEV md now create a RAID1 Read more...
Basic Commands Checking status of drive/arrays, displaying all raids and basic information # cat /proc/mdstat  Detailed status of array # mdadm --detail /dev/md2 Creating raid device # mdadm --create --verbose /dev/mdX --level=RAID5--raid-devices=2 /dev/sdj /dev/sdk  Stoping raid device # mdadm --stop /dev/md2  Adding a drive: # mdadm /dev/md2 -a /dev/sdm  Marking a drive as failed (This will break things if your not careful) # mdadm --manage --set-faulty Read more...