Hi,
I've been trying for some time now to upload an iso to use for cloud-config, in an attempt to automate VM deployment. However, both using curl and SCP the transfer times out, with the SCP action resulting in a partially copied file in the destination folder and curl not having copied anything.
I have tried these things with curl so far:
- Export the root CA pem so curl works with a secure connection. (Skip -k or --insecure)
- Set a different mtu on the source device (1492)
The curl command I use is this:
curl --verbose --cacert <root-ca-pem> --cookie <cookiefile> --csrftoken <csrftokenfile> -X POST https://<proxmoxip>:8006/api2/json/nodes/<nodename>/storage/<storageclustername>/upload -H 'Content-Type: multipart/form-data' --form content='iso' --form 'filename=<isofilename.iso>'
Omitting -H doesn't change anything. What's interesting though is the fact that a small, malformed iso copies over fine. I have tried generating ISO files in two ways:
- dd if=<folder or file> of=<isofilename.iso>, resulting in an iso no larger than 480 bytes
- genisoimage -o <isofilename.iso> <folder or file to pack up in an iso>
The Proxmox environment is a shared environment where a different project successfully copies auto-generated .iso files to the destination folder without issues, but it's written in Java. Their .iso files are ~366kb in size, while mine are ~358kb in size. The destination storage consists of SSD drives.
I'd really appreciate help troubleshooting this. I hope I provided enough context of the situation.
I've been trying for some time now to upload an iso to use for cloud-config, in an attempt to automate VM deployment. However, both using curl and SCP the transfer times out, with the SCP action resulting in a partially copied file in the destination folder and curl not having copied anything.
I have tried these things with curl so far:
- Export the root CA pem so curl works with a secure connection. (Skip -k or --insecure)
- Set a different mtu on the source device (1492)
The curl command I use is this:
curl --verbose --cacert <root-ca-pem> --cookie <cookiefile> --csrftoken <csrftokenfile> -X POST https://<proxmoxip>:8006/api2/json/nodes/<nodename>/storage/<storageclustername>/upload -H 'Content-Type: multipart/form-data' --form content='iso' --form 'filename=<isofilename.iso>'
Omitting -H doesn't change anything. What's interesting though is the fact that a small, malformed iso copies over fine. I have tried generating ISO files in two ways:
- dd if=<folder or file> of=<isofilename.iso>, resulting in an iso no larger than 480 bytes
- genisoimage -o <isofilename.iso> <folder or file to pack up in an iso>
The Proxmox environment is a shared environment where a different project successfully copies auto-generated .iso files to the destination folder without issues, but it's written in Java. Their .iso files are ~366kb in size, while mine are ~358kb in size. The destination storage consists of SSD drives.
I'd really appreciate help troubleshooting this. I hope I provided enough context of the situation.