mdadm.conf file needed? How to create and where?












0















I'm running ubuntu mate 18.04. My system is on an nvme. I had a 4TB HD with all my back ups along with my plex media. I got a second identical HD for Christmas and used it to create a raid1 array with missing (the original HD), then copied the data from orig. HD to the raid, then added the orig.HD to the raid and it is building/repairing the raid currently.



I used the DISKS GUI to mark the array for auto mount.. that created an entry if fstab. The only thing I can think of I am unsure about is the mdadm.conf file. The many guides I have read show creating it using: mdadm --detail --scan --verbose >> /etc/mdadm.conf. When the program was installed it created its own mdadm.conf file as /etc/mdadm/mdadm.conf but all I see in it are comment lines.



A few examples I have read show creating the file in the mdadm directory but most show creating it in etc not the mdadm sub-directory. That's the history.. my questions... I assume the file is needed (even though I think the array would mount on reboot) in case it ever needs to repair. Do I create it using the "mdadm --detail --scan --verbose >> /etc/mdadm.conf" command? Does it matter if the file is in etc or the sub-directory of mdadm? Should I remove or rename the existing mdadm.conf file to prevent conflicts? Thanks for the insight.










share|improve this question

























  • This may be a slight variation from the normal Linux setup on Ubuntu so I would suggest you use that subfolder. See here manpages.ubuntu.com/manpages/bionic/man5/mdadm.conf.5.html

    – George Udosen
    Dec 31 '18 at 13:37


















0















I'm running ubuntu mate 18.04. My system is on an nvme. I had a 4TB HD with all my back ups along with my plex media. I got a second identical HD for Christmas and used it to create a raid1 array with missing (the original HD), then copied the data from orig. HD to the raid, then added the orig.HD to the raid and it is building/repairing the raid currently.



I used the DISKS GUI to mark the array for auto mount.. that created an entry if fstab. The only thing I can think of I am unsure about is the mdadm.conf file. The many guides I have read show creating it using: mdadm --detail --scan --verbose >> /etc/mdadm.conf. When the program was installed it created its own mdadm.conf file as /etc/mdadm/mdadm.conf but all I see in it are comment lines.



A few examples I have read show creating the file in the mdadm directory but most show creating it in etc not the mdadm sub-directory. That's the history.. my questions... I assume the file is needed (even though I think the array would mount on reboot) in case it ever needs to repair. Do I create it using the "mdadm --detail --scan --verbose >> /etc/mdadm.conf" command? Does it matter if the file is in etc or the sub-directory of mdadm? Should I remove or rename the existing mdadm.conf file to prevent conflicts? Thanks for the insight.










share|improve this question

























  • This may be a slight variation from the normal Linux setup on Ubuntu so I would suggest you use that subfolder. See here manpages.ubuntu.com/manpages/bionic/man5/mdadm.conf.5.html

    – George Udosen
    Dec 31 '18 at 13:37
















0












0








0








I'm running ubuntu mate 18.04. My system is on an nvme. I had a 4TB HD with all my back ups along with my plex media. I got a second identical HD for Christmas and used it to create a raid1 array with missing (the original HD), then copied the data from orig. HD to the raid, then added the orig.HD to the raid and it is building/repairing the raid currently.



I used the DISKS GUI to mark the array for auto mount.. that created an entry if fstab. The only thing I can think of I am unsure about is the mdadm.conf file. The many guides I have read show creating it using: mdadm --detail --scan --verbose >> /etc/mdadm.conf. When the program was installed it created its own mdadm.conf file as /etc/mdadm/mdadm.conf but all I see in it are comment lines.



A few examples I have read show creating the file in the mdadm directory but most show creating it in etc not the mdadm sub-directory. That's the history.. my questions... I assume the file is needed (even though I think the array would mount on reboot) in case it ever needs to repair. Do I create it using the "mdadm --detail --scan --verbose >> /etc/mdadm.conf" command? Does it matter if the file is in etc or the sub-directory of mdadm? Should I remove or rename the existing mdadm.conf file to prevent conflicts? Thanks for the insight.










share|improve this question
















I'm running ubuntu mate 18.04. My system is on an nvme. I had a 4TB HD with all my back ups along with my plex media. I got a second identical HD for Christmas and used it to create a raid1 array with missing (the original HD), then copied the data from orig. HD to the raid, then added the orig.HD to the raid and it is building/repairing the raid currently.



I used the DISKS GUI to mark the array for auto mount.. that created an entry if fstab. The only thing I can think of I am unsure about is the mdadm.conf file. The many guides I have read show creating it using: mdadm --detail --scan --verbose >> /etc/mdadm.conf. When the program was installed it created its own mdadm.conf file as /etc/mdadm/mdadm.conf but all I see in it are comment lines.



A few examples I have read show creating the file in the mdadm directory but most show creating it in etc not the mdadm sub-directory. That's the history.. my questions... I assume the file is needed (even though I think the array would mount on reboot) in case it ever needs to repair. Do I create it using the "mdadm --detail --scan --verbose >> /etc/mdadm.conf" command? Does it matter if the file is in etc or the sub-directory of mdadm? Should I remove or rename the existing mdadm.conf file to prevent conflicts? Thanks for the insight.







raid mdadm mirrors






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Dec 31 '18 at 13:48









George Udosen

20.7k94569




20.7k94569










asked Dec 31 '18 at 13:26









D SongwriterD Songwriter

32




32













  • This may be a slight variation from the normal Linux setup on Ubuntu so I would suggest you use that subfolder. See here manpages.ubuntu.com/manpages/bionic/man5/mdadm.conf.5.html

    – George Udosen
    Dec 31 '18 at 13:37





















  • This may be a slight variation from the normal Linux setup on Ubuntu so I would suggest you use that subfolder. See here manpages.ubuntu.com/manpages/bionic/man5/mdadm.conf.5.html

    – George Udosen
    Dec 31 '18 at 13:37



















This may be a slight variation from the normal Linux setup on Ubuntu so I would suggest you use that subfolder. See here manpages.ubuntu.com/manpages/bionic/man5/mdadm.conf.5.html

– George Udosen
Dec 31 '18 at 13:37







This may be a slight variation from the normal Linux setup on Ubuntu so I would suggest you use that subfolder. See here manpages.ubuntu.com/manpages/bionic/man5/mdadm.conf.5.html

– George Udosen
Dec 31 '18 at 13:37












1 Answer
1






active

oldest

votes


















0














The little I know it appears that Ubuntu is different when it comes to where the mdadm file is placed. I have also seen the /etc/ location suggested in Linux Foundation documentations but when running on Ubuntu I discovered that it has it's own stored in the location /etc/mdadm subfolder.



So I would suggest you use that location and seen in this document, where Ubuntu location is different. The command would be



sudo mdadm --detail --scan --verbose >> /etc/mdadm/mdadm.conf





share|improve this answer


























  • This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

    – D Songwriter
    Jan 1 at 14:17













Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1105829%2fmdadm-conf-file-needed-how-to-create-and-where%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














The little I know it appears that Ubuntu is different when it comes to where the mdadm file is placed. I have also seen the /etc/ location suggested in Linux Foundation documentations but when running on Ubuntu I discovered that it has it's own stored in the location /etc/mdadm subfolder.



So I would suggest you use that location and seen in this document, where Ubuntu location is different. The command would be



sudo mdadm --detail --scan --verbose >> /etc/mdadm/mdadm.conf





share|improve this answer


























  • This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

    – D Songwriter
    Jan 1 at 14:17


















0














The little I know it appears that Ubuntu is different when it comes to where the mdadm file is placed. I have also seen the /etc/ location suggested in Linux Foundation documentations but when running on Ubuntu I discovered that it has it's own stored in the location /etc/mdadm subfolder.



So I would suggest you use that location and seen in this document, where Ubuntu location is different. The command would be



sudo mdadm --detail --scan --verbose >> /etc/mdadm/mdadm.conf





share|improve this answer


























  • This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

    – D Songwriter
    Jan 1 at 14:17
















0












0








0







The little I know it appears that Ubuntu is different when it comes to where the mdadm file is placed. I have also seen the /etc/ location suggested in Linux Foundation documentations but when running on Ubuntu I discovered that it has it's own stored in the location /etc/mdadm subfolder.



So I would suggest you use that location and seen in this document, where Ubuntu location is different. The command would be



sudo mdadm --detail --scan --verbose >> /etc/mdadm/mdadm.conf





share|improve this answer















The little I know it appears that Ubuntu is different when it comes to where the mdadm file is placed. I have also seen the /etc/ location suggested in Linux Foundation documentations but when running on Ubuntu I discovered that it has it's own stored in the location /etc/mdadm subfolder.



So I would suggest you use that location and seen in this document, where Ubuntu location is different. The command would be



sudo mdadm --detail --scan --verbose >> /etc/mdadm/mdadm.conf






share|improve this answer














share|improve this answer



share|improve this answer








edited Dec 31 '18 at 13:53

























answered Dec 31 '18 at 13:46









George UdosenGeorge Udosen

20.7k94569




20.7k94569













  • This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

    – D Songwriter
    Jan 1 at 14:17





















  • This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

    – D Songwriter
    Jan 1 at 14:17



















This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

– D Songwriter
Jan 1 at 14:17







This was a clear answer to my question. Thank you. When I ran the command as sudo it came up with a permissions error. During my research I had watched the "031 Creating a RAID 1 array with mdadm" on youtube by Sistem Odasi which addressed this problem. I did a chmod 777 on the mdadm.conf file and afterwards this command worked.

– D Songwriter
Jan 1 at 14:17




















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1105829%2fmdadm-conf-file-needed-how-to-create-and-where%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

mysqli_query(): Empty query in /home/lucindabrummitt/public_html/blog/wp-includes/wp-db.php on line 1924

How to change which sound is reproduced for terminal bell?

Can I use Tabulator js library in my java Spring + Thymeleaf project?