1 |
On Monday, 24 June 2019 18:00:29 BST Peter Humphrey wrote: |
2 |
> On Monday, 24 June 2019 16:59:08 BST Grant Taylor wrote: |
3 |
|
4 |
> > > On this box, which does need lvm for RAID-1 on two SSDs: |
5 |
> > Do you /need/ LVM? Or is it extra that comes with device-mapper? |
6 |
> |
7 |
> No, I do actually use lvm to base a raid-1 file system on. I haven't |
8 |
> considered raid-1 without lvm; is that feasible? |
9 |
|
10 |
Almost totally. They two are separate functions with synergistic interaction. |
11 |
RAID 1 offers redundancy by mirroring data between two block devices. LVM |
12 |
offers a flexible partitioning scheme where you can add space, move, snapshot, |
13 |
etc. data using a logical software layer to manage their storage across |
14 |
partitions and physical disks. I've put together RAID 1 disks with no LVM and |
15 |
used LVM with no RAID. |
16 |
|
17 |
NOTE: To confuse things you can instead use LVM's built in 'RAID |
18 |
functionality' - see below. |
19 |
|
20 |
I recall reading somewhere that SSDs are better used with LVM's natively |
21 |
configured RAID functionality, rather than a separate RAID layer, which in a |
22 |
mirrored RAID it will cause accelerated wear due to the way RAID metadata are |
23 |
mirrored between block devices. I don't think I've ever used LVM's RAID |
24 |
capability, but it would probably boil down to running: |
25 |
|
26 |
lvcreate --mirrors 1 --type raid 1 -n LV_myRAID VG_blah-blah |
27 |
|
28 |
Others more knowledgeable in these technologies could chime in to correct me |
29 |
no doubt. |
30 |
|
31 |
PS. LVM-RAID uses the kernel's mdraid, but with less tools to manage the RAID |
32 |
configuration than mdadm offers: |
33 |
|
34 |
https://unix.stackexchange.com/questions/150644/raiding-with-lvm-vs-mdraid-pros-and-cons |
35 |
-- |
36 |
Regards, |
37 |
|
38 |
Mick |