LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Manjaro
User Name
Password
Manjaro This forum is for the discussion of Manjaro Linux. Note: This forum does not have any official participation.

Notices


Reply
  Search this Thread
Old 06-05-2019, 12:36 PM   #1
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Rep: Reputation: 153Reputation: 153
Manjaro does not recognize LVM PV on top of mdadm RAID 1


I am a long time Fedora user who has just installed Manjaro KDE in a multi-boot arrangement. I have run into one issue. I have an mdadm RAID 1 with an LVM PV on top. It contains a volume group and is divided into several data partitions. With Fedora everything is recognized at boot.

Code:
$ cat /etc/fedora-release 
Fedora release 29 (Twenty Nine)
$ uname -r
5.0.17-200.fc29.x86_64

$ cat /proc/mdstat
Personalities : [raid1] 
md0 : active raid1 sdd1[0] sde1[1]
      2930263928 blocks super 1.2 [2/2] [UU]
      
unused devices: <none>

$ sudo lvm
lvm> pvs
  PV         VG          Fmt  Attr PSize    PFree  
  /dev/md0   vg_raid1    lvm2 a--    <2.73t  <1.27t
  /dev/sda3  vg_server47 lvm2 a--   <55.41g      0 
  /dev/sdb10 vg_samsung  lvm2 a--  <125.41g <70.41g
lvm> vgs
  VG          #PV #LV #SN Attr   VSize    VFree  
  vg_raid1      1   3   0 wz--n-   <2.73t  <1.27t
  vg_samsung    1   3   0 wz--n- <125.41g <70.41g
  vg_server47   1   1   0 wz--n-  <55.41g      0 
lvm> pvscan
  PV /dev/sdb10   VG vg_samsung      lvm2 [<125.41 GiB / <70.41 GiB free]
  PV /dev/md0     VG vg_raid1        lvm2 [<2.73 TiB / <1.27 TiB free]
  PV /dev/sda3    VG vg_server47     lvm2 [<55.41 GiB / 0    free]
  Total: 3 [<2.91 TiB] / in use: 3 [<2.91 TiB] / in no VG: 0 [0   ]
However with Manjaro :

Code:
$ cat /etc/manjaro-release 
Manjaro Linux
$ uname -r
4.19.28-1-MANJARO

$ cat /proc/mdstat
Personalities : [raid1] 
md127 : active (auto-read-only) raid1 sdd1[0] sde1[1]
      2930263928 blocks super 1.2 [2/2] [UU]
      
unused devices: <none>

$ sudo pvs
  PV         VG          Fmt  Attr PSize    PFree  
  /dev/sda3  vg_server47 lvm2 a--   <55.41g      0 
  /dev/sdb10 vg_samsung  lvm2 a--  <125.41g <70.41g

$ sudo pvscan
  PV /dev/sdb10   VG vg_samsung      lvm2 [<125.41 GiB / <70.41 GiB free]
  PV /dev/sda3    VG vg_server47     lvm2 [<55.41 GiB / 0    free]
  Total: 2 [180.81 GiB] / in use: 2 [180.81 GiB] / in no VG: 0 [0   ]
  
$ sudo vgs
  VG          #PV #LV #SN Attr   VSize    VFree  
  vg_samsung    1   3   0 wz--n- <125.41g <70.41g
  vg_server47   1   1   0 wz--n-  <55.41g      0
With Manjaro the RAID is recognized as read-only, the /dev/md PV is missing and the pvscan command doesn't find it.
 
Old 06-05-2019, 07:08 PM   #2
berndbausch
LQ Addict
 
Registered: Nov 2013
Location: Tokyo
Distribution: Mostly Ubuntu and Centos
Posts: 6,316

Rep: Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002Reputation: 2002
auto-read-only seems to be a normal intermediate status when assembling an array. Which is what you are doing - your system boots, finds MD array superblocks and assembles the array. See also https://unix.stackexchange.com/quest...resync-pending.

A few suggestions for getting more information about your problem:
Code:
mdadm --detail /dev/mdwhatever
mdadm --detail --scan
lsblk    # list all block devices; should show the array
blkid    # identifies UUIDs and LABELs on block devices; should show MD UUIDs
dmesg
You could also try to help your system assemble the array with ARRAY and DEVICE directives in /etc/mdadm.conf. See the mdadm.conf man page for how to do that.

Did you create the array on the Manjaro system or did you migrate it there from Fedora? Has the Manjaro box ever recognized the PV?

EDIT: Example for mdadm.conf:
Code:
# cat /etc/mdadm.conf
ARRAY /dev/md/bb metadata=1.2 spares=1 name=lsna112:bb UUID=13adcd45:f7f073d8:9039774c:55c8684a
DEVICE /dev/sdb1 /dev/sdc1 /dev/sdd1 /dev/sde1
I would also be curious what happens when I stop the array, then re-assemble it manually:
Code:
mdadm --stop /dev/mdwhatever 
mdadm --assemble --scan
or
mdadm --assemble /dev/mdwhatever --name mydeararray /dev/sdd1 /dev/sde1
More info: The md section on kernel.org, in particular the long article about mdadm.

Last edited by berndbausch; 06-05-2019 at 07:21 PM.
 
Old 06-05-2019, 10:10 PM   #3
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Original Poster
Rep: Reputation: 153Reputation: 153
Quote:
Did you create the array on the Manjaro system or did you migrate it there from Fedora?
I never had a 'Manjaro system' until yesterday. I am a 17 year user of Fedora (since FC5) and more recently CentOS. Before I installed Manjaro yesterday I had a Fedora 29, Fedora 28 (now EOL), and Centos 7 triple boot system. I now have a quadruple boot system with one being EOL. This is my first attempt to install anything other than Fedora/CentOS in 17 years of Linux use. Since this is the same computer the term 'migrate' isn't applicable.

I was drawn to try another distribution as RH deprecated KDE and KDE soon stopped working when I 'updated' Centos 7. I like KDE Plasma and wanted to try another distribution where KDE is officially supported. I was drawn to Manjaro specifically by positive comments made on FedoraForum by several people one of whom is a forum moderator.

Quote:
Has the Manjaro box ever recognized the PV?
Given the above explanation no as my desktop was never a Manjaro box.

I created the array in summer 2016 when I bought two 3TB WD drives, assembled them into a RAID1 mirror and then put LVM on top. The creation went perfectly and it worked immediately. It was all created with Centos 7 but worked perfectly with Fedora 24,28 and now 29. Everything was assembled at boot and the volume group and all of the LVs inside were visible and mountable after boot. Two of the LVs are mounted in my fstab on Fedora and Centos as well the swap partition is on this array to reduce wear on the SSD.

Thank you for your reply. I will try your suggestions.

I now realize that despite what flaws it may have Fedora is quite powerful.
 
Old 06-05-2019, 10:53 PM   #4
syg00
LQ Veteran
 
Registered: Aug 2003
Location: Australia
Distribution: Lots ...
Posts: 21,145

Rep: Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124Reputation: 4124
Manjaro is (or was) based on Arch - so you'd need to make sure the appropriate modules are;
i) in the initrd, and
ii) in the correct order.

Normally for data partitions it shouldn't matter, but it probably will for swap. As with all things Arch, see the wiki - amongst the best doco around.
FWIW I found Manjaro "difficult" to adopt after years of Fedora - and although I also did KDE (for digikam) I still hate it.
That machine only gets used for photo processing - but I use btrfs for RAID, not mdadm.
 
Old 10-07-2019, 01:07 PM   #5
tofino_surfer
Member
 
Registered: Aug 2007
Posts: 483

Original Poster
Rep: Reputation: 153Reputation: 153
A late reply. The problem eventually went away with a few more boots. It was intermittent at first occurring on some boots and not others but eventually went away for good. I now mount data partitions on these LVs on top of the RAID1 in Manjaro with no problems.
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] LVM on top of mdadm RAID 1 Gerard Lally Slackware 6 09-24-2015 08:35 AM
Will Manjaro Linux Net edition act like Manjaro or a base install of Arch? punchy71 Linux - Newbie 4 06-28-2014 08:05 AM
Raid + LVM add new raid device to LVM, problem request Linux - Server 3 08-15-2012 04:06 AM
[SOLVED] How to migrate from raid 6 to raid 5 using mdadm and LVM haerta Linux - General 5 04-20-2012 06:16 PM
MDADM screws up the LVM partitions? Can't mount the LVMs after mdadm stopped alirezan1 Linux - Newbie 3 11-18-2008 04:42 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Manjaro

All times are GMT -5. The time now is 08:08 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