On 11/3/23 18:14, Andrew M.A. Cater wrote:
On Fri, Nov 03, 2023 at 12:27:19PM -0400, gene heskett wrote:
Greetings all;
As usual, the man page may as well be written in swahili. The NDE syndrome,
meaning No D-----d Examples.
I have those 2 2T SSD's with a gpt partition table on both, allocated as
sdc1 and sdk1, formatted to ext4, named and labeled as lvm1 and lvm2.
Temp mounted as sdc1 and sdk1 to /mnt/lvm1 and /mnt/lvm2
How big is your /home - is it bigger than 2T?
Do you need both drives to provide redundant storage - or is it just
a temporary storage place for /home while you get the rest of the RAID
devices sorted out?
If I were you, I wouldn't start from here :)
Don't mount them as individual drives.
pvcreate to initialise each physical drive as a drive reserved for lvm
pvcreate /dev/sdc1
pvcreate /dev/sdk1
vgcreate to create a logical volume
vgcreate HomeVolgroup /dev/sdc1 /dev/sdk1
Then use lvcreate to create the logical volume itself.
I'v got to the above point but the first example that looked good
created a 100% allocated, no free space "homevol"
So I used gparted to delete the partitions & reformat them to ext4 again,
pvcreated them again an vgcreateded it again, getting:
gene@coyote:~$ sudo vgs -v
VG Attr Ext #PV #LV #SN VSize VFree VG UUID
VProfile
HomeVolGroup wz--n- 4.00m 2 0 0 <3.73t <3.73t
tdHtLW-95wJ-rLk5-fTiS-ILfV-kRD7-xqkClP
But now 2 puzzles:
1, there is zero explanation in the vgs man page telling me what this
is. What does the < tell me?, and I don't see a break between VG and
UUID, word wrapped here by tbird, is that whole string of gibberish the
VG's UUID?
2, the lvcreate man page doesn't appear to have a way to specify using
the whole max capacity of the empty but formatted to ext4 pair of
drives, the extremely copious example list doesn't seem to address that
condition.
3a, what would the cmd to mount it to /mnt/lvm2 so rsync can copy /home
to it look like?
3b, what would the line in fstab that mounts it look like?
See also https://wiki.archlinux.org/title/LVM
Which also assumes an innate familiarity with all this that I don't have
any experience with since this screwed me up and drove me out of the
redhat camp 2 decades ago, I was tired of being the always sick and
dying lab rat for redhat.
Use lvm to do this: that's *exactly* what it's designed for - to allow you
to add volumes and extend disk sizes.
This is exactly how partman does it when you install. (In fact, you could do
this quite well by rebooting to recovery and using that method to reformat
the drives).
How do I create a single managed volume of labels lvm1 and lvm2 of these to
make a single volume that I can then rsynch /home to it, then switch fstab
See above:
All the very best, as ever,
Andy
[amaca...@debian.org]
Sorry to need so much hand holding Andy, but my only previous experience
with logical volumes 20 years ago cost me dearly in terms of lost,
irreplaceable data, like the only pictures of my first wife who had a
stroke and died in '68 after 10 glorious years and 3 children. Who have
also now passed. A man doesn't normally outlast his git.
Thank you Andy
Cheers, Gene Heskett.
--
"There are four boxes to be used in defense of liberty:
soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author, 1940)
If we desire respect for the law, we must first make the law respectable.
- Louis D. Brandeis