Adding more backup room

MikeC

Renowned Member
Jan 11, 2016
73
0
71
Bay Area, California
Hello, all.
I have a 5.4.13 node running that has a rather small 'local' directory that can have backups, templates and ISO images.
I added a 1T storage called local-lvm, and 2T disk set called local2, but those only accept Disk Image and Container content.
I need to ceate more room for dump files, but it looks like I can't edit local-lvm or local2 to accept dump files.
How can I go about doing so?

Screen Shot 2019-12-05 at 9.21.39 PM.png

Screen Shot 2019-12-05 at 9.22.39 PM.png
 
You can create a LV on that, mount it and add it as directory storage:
Code:
lvcreate -n data -L100% local2
mkfs.ext4 /dev/local2/data

mkdir /mnt/big
mount /dev/local2/data /mnt/big

Then add a fstab entry to auto-mount this on boot and add a directory storage in PVE with the "/mnt/big" as path.
 
Or yes, if you just plan to use it as filesystem anyway, then Wolfgang is right: just purge it and create a directory storage (the latter can be done over WebGUI).
 
Thanks. the LVM is already in use for containers, so are the methods above destructive?

Not if you do not use 100% (even then it shouldn't be, but just to be sure): From your screenshot I see that you have a lot of free space, so if you want to use a big chunk for that, but ensuring some left-over is there for CTs (you can always increase size later one, if one gets full and you still have physical space). Let's use 1 TB as a starter for your FS based storage on the LVM:

Code:
# create LV (non-destructive), then formate it as EXT4 filesystem
lvcreate -n data -L1T local2
mkfs.ext4 /dev/local2/data

mkdir /mnt/data
mount /dev/local2/data /mnt/data
# make mount persistent for next boot
echo '/dev/local2/data /mnt/data ext4 defaults 0 1' >> /etc/fstab

# add as PVE directory storage:
pvesm add dir data -path /mnt/data