New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
To LVM or not to LVM
Situation: I got a dedicated server. I want to setup KVM’s on it. Probably using VirtFusion, haven’t yet completely decided.
Issue: Do I LVM or do I not LVM? The disk sizes won’t change. I have two NVMe’s that I’ll configure in software RAID 1. If LVM, only the VM directory or the whole thing except for /boot?
Thanked by 1admax
To LVM or not to LVM
- Here it comes61 votes
- LVM: YES40.98%
- LVM: NO59.02%
Comments
Summer or fall launch?
That will help make an accurate vote
@barbaros get your take in here instead of DM’ing about Calin
@FAT32 @maverick @darkimmortal get your smart takes in here
PRIVATE USE
⠀̵̨̨̡̢̧̧̭̳͖̗̭̝͚̳͈̜̭̞͕͚̹͇̣͈͍̣̭͕̳̲̙̭̗̖̻̟̰̬͓͉̮̭̞̠̠͙̫̜̜̦͈͔͈̱̖̓́̋̈̂̍̕͜͜⠀̶̧̡̢̡̢̘̤̜͇̠̻͈̠̖̖̙̦͉̹̳̣̳̗͍̜͍͕͔̤̜̟͓͇̗͕̫̟̻̖̈̅͐̓͂͊͂̿̓́͋́̾̏͠͠ͅ⠀̸̨̨̡̧̛͖͎̼̜̗̲̪͓͚̬̥̦̺̠͇̼̜͎̰̠̦͔̥͔̘͉̼̻̺̤̤͉͓̯̯̳̬͔̤̺̮͊͑̿́̋̄̊͆͋̀̆͂̈́͋̅̋́͂͋̅̂̉́̋̈̃̒́̏͌̀̌̓̓͌̑̚̚͘͜͜͝͝͝͝͝͝⠀̴̢̢̢̡̢̦̯͚̱̯̲̣̠̣̝̙̻̫̺͎̪̠̹͉̙̦̩̹̯̘͖̭̠̫̰͈̹̰͍͓̱͙̍̉̽́͆̋̑̇̀̎̓̏̍̿̋̚͝ͅͅ⠀̸̨̡̧̛̻̤̺͍̜̜̗͖͙͕̖̦̻̮̩͕̣̥̭̪̝͖̰̮̰̳̭̣̻͕͇̪̣͇̬̜̜̼͍̮̈̊́͗́̃̈̽̑͆͗́̈́̀̇̋͐͆̈́̄͒̏̈́̈́̂̅̊́͂͆͒͆̾̀̂̾̀̿͐̑̅̈́̈̔̂͒̈́̀̏̆̂͊̐̾̾̇̅͛̑͊̾̆͛͋̔̂̀̈́̑̽̚̕̕͘͝ͅͅ⠀̴̨̨̢̡̢̧̰̦̯̹̖͈̭̰̯̤̜̣̣̳̼̬̣̟̼̙̖̲̳̻̥̗̣̫̮̰̩̺͇̗̘͕͍̙̞͓̼̥̖̥̗̲̱̜̬̱͔͖͈̳̲̱̥̟̫̹̝̺̝̙̠́͋̈́̊͘͜ͅͅ⠀̵̡̻̲̙̙̝̖̲̟̬̮͔̳̱̣̲̤̣̘͚̣̹̝̠̜̫̭̗͙̺̝̑̀̿͊̀̇́̈́̃̂͠⠀̷̨̢̧̨̧̧̛͉̺͕̟̘̭̖̼͔̠̮͙͙͍̝͍͍̞͖͕̠̮̯̫̗̺̥͓̗͋̐͌̾̾͂̑̅́̑͆͂̀̀̆̓̽͂̀̇̾̐̒̇̃͋̈́̌̈́̕̕͘̕͠͝ͅͅͅ⠀̷̨̡̡̨̡̢̡̨̢̨̧̧̢̛̛̬̖̲̮̺̜̻̠͚͖̦̖͎͈̤̲͉̮͕͖̪̲̦̩̱͇̣̩̥͕̰̮̘̻̤̭̟̱̯͙͚̦̞̲̩̳̱̻̻͔͎͈̖͔̤͈̜̙̯̖̗̲̱͔̻̬̯͎̹̬̄̀͒̓͗̂̾̉̿͋̓̄̐̿͂̏̉͒̿̓̃̐̌̇̀̂͗̓̓͒̃͌̃́̐̽̓̈́̄͂̋̑͗̕̕̕͜͜͝͝͝͠͠ͅͅ⠀̴̡̨̧̢̻̯̠̰̹̟̪͍͔͇̠̫̩͈͖̣̙̣̔̏̀͂́̒̏̽̍́̄̒̀͆̈̚̚͘̕͝ͅͅ⠀̵̧̧̧̙̖̱͔̱̹͓͎͖̹̬͙͈̙̥̒͑̃̄͋̿͌̆̾̓̀̇̂͘̚̕͠ͅ⠀̵̨̧̛̛̛̛͙͔͓̲̖̜̣͔̗͕̣̠̝͑̈́̂̇̿̊̂̈́̋̎̄̀̀̒̐̇̈̎̀̊͌̌̍̍̆̾̊́̈́̈́́̊͘̕͠⠀̵̢̡̛̦͓̲̗̤̯͙̦͖̜͇̰̼̠̠̞̜̩̗̜̞̮̜̩̣̞̰̥̝͕̝͉̟͉̠̯̳̟͇̻̹̩͖̘̯̝͉̪̔̎̌̔͌̎̓̉̎͗̀̐̀͋̓̂́͆̀́̅͛͌̉͒̐̃̂̂̈͂͛̿̀̕͘̕͘̕͜͝͠͝͝ͅ⠀̷̛̛͗͛̀͋̓̽͘̕̕
Yes. Private use of customers. We get it.
Do not LVM
Reguards
RatNerd™
Thank you for your contribution.
Why not?
What is this shit?
Swedish
A haunted comment.
I feel like every take that’s ”do not LVM” without further motivation is from someone like me who doesn’t really understand what it is at a deep down level and therefore avoids it
If you won't expand storage in the future, there's no use for LVM, just needless complication. KISS (read: no LVM).
Ok thanks papa Maverick
true facts
it has messed up on me so many times I just avoid it at all costs.
Story time please
Mentally strong people give each VM a dedicated NVMe drive through PCI passthrough.
Also as seen above I don’t mins this thread becoming a megathread lite so long as some comments are useful
Yeah but physically strong chads don’t use IPv6 so there’s that
but its @emgh . Lets not go there
fkin scuffed gif, smh
Nvm, night boys.
brief one but in my old days I used Ubuntu and let itself auto partition (which enables LVM by default), never had any issue, until it did, and my whole school project got ruined because the VM wouldn't boot
Funny part is that it happened to me multiple times lol, didn't learn from my mistakes.
Could've probably saved it, but didn't bother. For that and many other reasons, I use Debian without LVM now
And I don't realistically have any scenario where I'll need to make the disk bigger.
LVM*
Glad to hear you’ve learned by now
And yeah, my OVH dedi(s) can’t be modified anyway so disk expansion won’t ever occur
Yes, but it's more nuanced. Always LVM because then you can easily change your mind later and shrink or grow partitions without massive headaches moving partitions around.
My first experiments with having KVMs were all done using LVM.
I then got a bunch of decent sized VPSs that I could run VMs on, but the provided templates came as one big partition, so I used qcow2.
My biggest dedi I use VM for normal partitions, and mount the images directory on an LVM and grow it as needed.
I much prefer having an LVM partition per instance, it's really clean. Resizing the image is easy with
lvextend
and then a reboot andcloud-init
handles the guest-side resizing. The problem is that you allocate all the disk space up front. Personally, I like that because I know I can't suddenly run out later on, but can waste a lot if you're generous with size when creating the VMs.The qcow ones are sparse images, so great for having e.g. 100GB disk that only takes up 2GB on disk. But you can easily get into a situation where it's full and nothing can grow and everything hangs / gets corrupted. Somewhat sub-optimal. Also good if you figure out how to use qcow properly as then you end up with duplicated blocks across all your installations that correspond to the base template image and you can save around 2GB per VM that way. It's much easier to accidentally delete the wrong disk image with qcow files compared to LVM.
The only other disadvantage with LVMs is that when you destroy an LVM partition and recreate it again, it can detect the GPT header at the start and try to re-use the old disk image rather than creating a new one. You can use an option in lvremove to zero out the start to avoid that. Or keep it as a kind of safety net. But it's kind of annoying if you destroy one VM and then the next one you create tries to reuse the disk image and so doesn't cloud-init properly.
If you start with LVM and don't allocate the entire disk, you can try both approaches and see what you like best. Even after running both ways on different machines for over 2 years, I still haven't decided which I prefer.
Talking of which, I just got an email from @SilverCreek asking me to rate the provisioning of the server last week. In Swedish. Not sure what I did to offend him!