Solved

mdadm create raid change name

Posted on 2012-03-17
3
741 Views
Last Modified: 2012-03-18
in ubuntu, I created a raid with this command

mdadm -C /dev/md0 --level=raid1 --raid-devices=2 /dev/sdb /dev/sdc

And works fine, but when I reboot the system, the new array are in /dev/md127 (I hope that was in /dev/md0) Why? and how can I fix it to maintain the same pointer /dev/md0 that in the creation command?

Regards
0
Comment
Question by:lnrivera
3 Comments
 
LVL 77

Expert Comment

by:arnold
ID: 37734064
df -k
more /etc/mdadm.conf
more /etc/fstab

your initial setup might be referring or is using /dev/md127 to assemble the two drives you referenced.

There is no information on what you have currently.
0
 
LVL 43

Accepted Solution

by:
ravenpl earned 500 total points
ID: 37734533
This is new kernel "feature".

You need to create proper /etc/mdadm.conf

In Your case execute (as root)
# echo ’DEVICE /dev/sd*[a-z]’ > /etc/mdadm.conf
# mdadm --detail --scan >> /etc/mdadm.conf
edit the /etc/mdadm.conf and change /dev/md127 to /dev/md0
Now either wait for new kernel update, or force rebuilding initramfs
# update-initramfs -u
0
 

Author Closing Comment

by:lnrivera
ID: 37734563
Great!
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
i can not do linux commands in cygwin windows 10 6 75
CentOS 7 Installation 7 73
(Open)LDAP V2.44  search proxy to AD (W2012R2) 37 140
LINUX backups with VEEAM 8 81
The purpose of this article is to show how we can create Linux Mint virtual machine using Oracle Virtual Box. To install Linux Mint we have to download the ISO file from its website i.e. http://www.linuxmint.com. Once you open the link you will see …
Fine Tune your automatic Updates for Ubuntu / Debian
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question