Using USB Hard Drive as Storage (type: Directory) for Proxmox

Kristoff

New Member
Aug 28, 2014
2
0
1
Hi,
This is my first post here :).

I have a small, simple Proxmox environment - a few servers, no clusters, no shared storage.

On one of the servers I'm running out of space on local disks. The upgrade is planned, but before it happens, I need to "survive" somehow.

My idea was to use a 2TB USB 3.0 Hard Drive, and add it as a storage for keeping vms.
For a reason (too complicated to explain), the hard drive is formatted with NTFS.

So what I did was:

-connected the usb hdd,
then:
mkdir /mnt/usb
mount -t ntfs-3g /mnt/usb /dev/sdc1


So far, so good. Got into the Proxmox GUI and used "add Storage" option to add mounted storage as Type: Directory (I need to store vmdk machines, that's why directory and not lvm)
The usb hdd was added, I could see how much space is available, and everything seemed to be fine.

Started moving disks of one virtual machine from local storage to added usb hdd storage. The move went well.

The problem starts here: After moving the disk to usb hdd storage, I tried to start the vm and got the following error:

kvm: -drive file=/mnt/usb/images/132/vm-132-disk-2.vmdk,if=none,id=drive-virtio0,format=vmdk,aio=native,cache=none: could not open disk image /mnt/usb/images/132/vm-132-disk-2.vmdk: Invalid argument
TASK ERROR: start failed: command '/usr/bin/kvm -id 132 -chardev 'socket,id=qmp,path=/var/run/qemu-server/132.qmp,server,nowait' -mon 'chardev=qmp,mode=control' -vnc unix:/var/run/qemu-server/132.vnc,x509,password -pidfile /var/run/qemu-server/132.pid -daemonize -name APP-TEST -smp 'sockets=1,cores=1' -nodefaults -boot 'menu=on' -vga cirrus -cpu kvm64,+x2apic,+sep -k en-us -m 1024 -device 'piix3-usb-uhci,id=uhci,bus=pci.0,addr=0x1.0x2' -device 'usb-tablet,id=tablet,bus=uhci.0,port=1' -device 'virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3' -drive 'if=none,id=drive-ide2,media=cdrom,aio=native' -device 'ide-cd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2,bootindex=200' -drive 'file=/mnt/usb/images/132/vm-132-disk-2.vmdk,if=none,id=drive-virtio0,format=vmdk,aio=native,cache=none' -device 'virtio-blk-pci,drive=drive-virtio0,id=virtio0,bus=pci.0,addr=0xa,bootindex=100' -netdev 'type=tap,id=net0,ifname=tap132i0,script=/var/lib/qemu-server/pve-bridge,vhost=on' -device 'virtio-net-pci,romfile=,mac=8E:FE:AC:32:DD:63,netdev=net0,bus=pci.0,addr=0x12,id=net0'' failed: exit code 1

Can somebody help me out with that?
 
Hello Kristoff

the hard drive is formatted with NTFS.

So what I did was:

-connected the usb hdd,
then:
mkdir /mnt/usb
mount -t ntfs-3g /mnt/usb /dev/sdc1

How did your "mount" command work? I tried with ntfs and it lasted extremely long. And afterwards using it as storage did not work at all (timeout).

With linux ext3 at the same device (an usb external drive) I had no problems.

In other words: ntfs does not seem to be a good idea in proxmox hosts (at least at usb, but ntfs at sata drive drive I will never use in a linux system).

However - if you don´t have these problems, try to read the vmdk directly with vmware-mount and check it´s integrity.

vmware-mount can be downloaded within vmware-player (does not disturb proxmox, just install it, not necessary to start it as a whole, say just "vmware-mount" then) from here: https://my.vmware.com/web/vmware/free#desktop_end_user_computing/vmware_player/3_0 (it´s not the newest version, but contains a working vmware-mount utility)

Kind regards

Mr.Holmes
 
Last edited:
  • Like
Reactions: Paul Cosma

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!