Import disk to temporary location non root - similar question to "Where are VMs stored?"

eugenevdm

Active Member
Dec 13, 2020
57
12
28
53
We have four disks:

local, local-lvm, raid1, raid0

I need to import a large file to raid1.

The idea is create new directory, e.g. /root/vm.import.temp, and get the job done.

Problem is /root volume is too small but there is a lot of space on the other volumes.

I can't figure out if it's possible to `cd` to the bigger volumes. The `mount` command doesn't show me where to look. `fdisk` looks weird. I'm so out of my depth.

Any tips? Output of `lsblk` and /etc/pve/storage.cfg

Code:
# cat /etc/pve/storage.cfg
dir: local
    path /var/lib/vz
    content backup,vztmpl,iso

lvmthin: local-lvm
    thinpool data
    vgname pve
    content images,rootdir

lvmthin: raid1
    thinpool raid1
    vgname raid1
    content rootdir,images
    nodes proxmox1

lvmthin: raid0
    thinpool raid0
    vgname raid0
    content rootdir,images
    nodes proxmox1


Code:
# lsblk
NAME                         MAJ:MIN RM  SIZE RO TYPE MOUNTPOINT
sda                            8:0    0  1.8T  0 disk
├─sda1                         8:1    0 1007K  0 part
├─sda2                         8:2    0  512M  0 part
└─sda3                         8:3    0  1.8T  0 part
  ├─pve-swap                 253:6    0    8G  0 lvm  [SWAP]
  ├─pve-root                 253:7    0   96G  0 lvm  /
  ├─pve-data_tmeta           253:8    0 15.8G  0 lvm 
  │ └─pve-data-tpool         253:10   0  1.6T  0 lvm 
  │   ├─pve-vm--103--disk--1 253:4    0  150G  0 lvm 
  │   ├─pve-data             253:11   0  1.6T  0 lvm 
  │   └─pve-vm--100--disk--0 253:12   0  700G  0 lvm 
  └─pve-data_tdata           253:9    0  1.6T  0 lvm 
    └─pve-data-tpool         253:10   0  1.6T  0 lvm 
      ├─pve-vm--103--disk--1 253:4    0  150G  0 lvm 
      ├─pve-data             253:11   0  1.6T  0 lvm 
      └─pve-vm--100--disk--0 253:12   0  700G  0 lvm 
sdb                            8:16   0  3.7T  0 disk
├─raid1-raid1_tmeta          253:0    0 15.8G  0 lvm 
│ └─raid1-raid1-tpool        253:2    0  3.6T  0 lvm 
│   ├─raid1-raid1            253:3    0  3.6T  0 lvm 
│   ├─raid1-vm--102--disk--0 253:5    0   20G  0 lvm 
│   ├─raid1-vm--104--disk--0 253:13   0  250G  0 lvm 
│   └─raid1-vm--105--disk--1 253:20   0   20G  0 lvm 
└─raid1-raid1_tdata          253:1    0  3.6T  0 lvm 
  └─raid1-raid1-tpool        253:2    0  3.6T  0 lvm 
    ├─raid1-raid1            253:3    0  3.6T  0 lvm 
    ├─raid1-vm--102--disk--0 253:5    0   20G  0 lvm 
    ├─raid1-vm--104--disk--0 253:13   0  250G  0 lvm 
    └─raid1-vm--105--disk--1 253:20   0   20G  0 lvm 
sdc                            8:32   0  3.7T  0 disk
├─raid0-raid0_tmeta          253:14   0 15.8G  0 lvm 
│ └─raid0-raid0-tpool        253:16   0  3.6T  0 lvm 
│   ├─raid0-raid0            253:17   0  3.6T  0 lvm 
│   └─raid0-vm--101--disk--0 253:18   0    3T  0 lvm 
└─raid0-raid0_tdata          253:15   0  3.6T  0 lvm 
  └─raid0-raid0-tpool        253:16   0  3.6T  0 lvm 
    ├─raid0-raid0            253:17   0  3.6T  0 lvm 
    └─raid0-vm--101--disk--0 253:18   0    3T  0 lvm
 
I need to import a large file to raid1.
What kind of file? What do you need to do with it? A disk image that should be used in a VM? If so, have a look at the qm importdisk command which might make the whole procedure easier for you.


Otherwise, you could create a manual logical Volume in either raid1 or raid0, format it and mount it to place the file there.