LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 01-10-2013, 04:12 AM   #1
fakie_flip
Senior Member
 
Registered: Feb 2005
Location: San Antonio, Texas
Distribution: Gentoo Hardened using OpenRC not Systemd
Posts: 1,495

Rep: Reputation: 85
mdadm: cannot open /dev/md/0: No such file or directory


I had just created an mdadm raid and installed Linux Mint to it. I've seen this error about /dev/md/0 a few times. I have a:

/dev/md0
and
/dev/md0p1 (had to create or Linux Mints installer would not install to the raid)

So I went to generate an /etc/mdadm/mdadm.conf file with mdadm --detail --scan, but I wanted to check the output first before redirecting it to the conf file.

Code:
bullshark@mint /etc/mdadm $ sudo /sbin/mdadm --detail --scan
sudo: unable to resolve host mint
mdadm: cannot open /dev/md/0: No such file or directory
I checked for an existing mdadm.conf. First glance, I thought it was an example and all commented out. Second glance, I found out it wasn't and it contained the line:

Code:
ARRAY /dev/md/0 metadata=1.2 UUID=a193044d:832a36d7:990196e7:a143ef21 name=mint:0
So I thought I had found the source of the /dev/md/0 error. I made a backup and then blanked out the file. I ran the above command again. It is still looking for a /dev/md/0. I have no idea why, or if that file was to exist, why it would.
 
Old 01-10-2013, 05:42 PM   #2
smallpond
Senior Member
 
Registered: Feb 2011
Location: Massachusetts, USA
Distribution: Fedora
Posts: 4,140

Rep: Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263Reputation: 1263
Looks like the hostname was not the same when the array was created as when you later try to assemble it. This is one of those "helpful" features that protects you from doing what you want to do. See the HOMEHOST section of the man page for mdadm.conf. Use mdadm to update the name when you assemble the array.

/dev/md0p1 typically means you didn't partition the disks before creating the RAID, which means the disks don't have labels. I like to always create the RAID on partitions but either way will work.

/dev/md/0 should be a symbolic link to /dev/md0 (or possibly to /dev/md0p1). The mdadm scan is getting the UUID and name information from the RAID superblock. It should not rewrite the mdadm.conf file unless you redirect the command output.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
cannot open dev modem no such file or directory Cakyla Linux - Software 6 03-20-2009 11:44 AM
mdadm says "mdadm: /dev/md1 not identified in config file" when booting FC7 raffeD Linux - Server 1 08-11-2008 11:47 AM
[SOLVED] cdrecord: No such file or directory. Cannot open '/dev/pg0'. Cannot open SCSI driver. procfs Linux - Software 5 01-18-2008 10:06 AM
xf86OpenConsole: Cannot open /dev/tty0 (No such file or directory) souhakubunn Linux - Software 1 10-04-2007 07:11 AM
v4l: open /dev/video0: No such file or directory mdkusr Linux - Hardware 1 11-08-2006 09:40 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 05:14 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration