4

I've got a KVM Virtual Machine in my local PC, and I'd like to copy it to a Proxmox server. According to the docs, I just have to create a new VM on Proxmox and add the existing disk image to it, but how do I upload the image to the server? In the admin panel, if I click in MyStorage -> Content -> Upload, it just give me options to upload ISOs, VZDump backup files or OpenVZ templates. Would it be enough with a copy using scp? In that case, in which folder?

8

Is your storage not set to allow image files? Go to Datacenter -> Storage tab, select your storage and edit. Under "Content", make sure that "Images" is selected.

I just checked mine and am seeing the same thing as the OP. I would scp the file up and then manually edit the VM's .conf file.

Local storage on proxmox is in /var/lib/vz. There should be an "images" subdirectory with a directory there for each VM (named by the VM number). You can scp the files directly there.

For adding the existing file to the VM, I've had good luck editing the VM's .conf file directly. Look in /etc/pve/qemu-server/ for a file with the VM number followed by .conf.

It's a good idea to create a second test VM so you can refer to it's .conf file to make sure you get the syntax right.

-- adding text from a comment below

I think you can scp the file up. You probably want to look at /var/lib/vz/images/{VMID}/ for the destination. Then maybe look at /etc/pve/qemu-server/{VMID}.conf and add a line for the storage.

3
  • I checked it, and Images, ISO, Templates and Containers are selected. However, when I go to MyStorage -> Content -> Upload, I just can choose between ISOs, VZDump backup files or OpenVZ templates
    – davids
    Oct 24 '12 at 8:42
  • 1
    Hmmm, mine says the same. I think you can scp the file up. You probably want to look at /var/lib/vz/images/{VMID}/ for the destination. Then maybe look at /etc/pve/qemu-server/{VMID}.conf and add a line for the storage.
    – jlp
    Oct 24 '12 at 22:52
  • 1
    please, in order to accept your answer, edit it adding your last comment, as it is exactly what I ended up doing.
    – davids
    Jan 4 '13 at 9:58
2

According to the developers on there forums it's not supported via GUI as large file uploads with the browser are not reliable.

Create a new VM and overwrite the image with scp. The local VM storage on the host is usually in /var/lib/vz/images/{vmid}.

To make PVE recognize the changes (e.g. size of the image) do a

qm rescan

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.