Open ghost opened 3 years ago
@AkhilaGarlapally moving the conversation to the right place, you can get more logs setting PACKER_LOG=1
. Then you can share the output logs with us here.
Hi @AkhilaGarlapally,
It looks like you have vlan_tag
as an integer
. It should be a string
as seen in the documentation https://www.packer.io/docs/builders/proxmox/iso#vlan_tag
Your second error (drive formatting) is difficult to diagnose without knowing the value of the user variables. In particular, you should look at proxmox_storage_format
and verify it meets the possible values from the documentation https://www.packer.io/docs/builders/proxmox/iso#format.
the VM will not boot without the ks.cfg
file provided via the http_directory
file. Unfort. the ks.cfg
appears in the docs, but is not part of this repository.
This issue was originally opened by @AkhilaGarlapally as hashicorp/packer#11071. It was migrated here as a result of the Packer plugin split. The original body of the issue is below.
When filing a bug, please include the following headings if possible. Any example text in this template can be deleted.
Overview of the Issue
facing error as proxmox: Error creating VM: Error creating VM: 400 Parameter verification failed., error status: {"errors":{"net0":"invalid format - unable to parse network options\n","scsi0":"invalid format - unable to parse drive options\n"},"data":null} (params: map[agent:0 boot: cores:2 cpu:kvm64 description:Packer ephemeral build VM hotplug: ide2:local:iso/CentOS-8.3.2011-x86_64-dvd1.iso,media=cdrom kvm:false memory:2048 name:packer-60be4925-9e43-cbc6-b9d2-3266279a731c net0:e1000=D2:08:62:1A:5F:E2,bridge=vmbr0,tag=10,firewall=false numa:false onboot:false ostype:l26 scsi0:vmpool:8,iothread=false scsihw:lsi sockets:1 tags: vmid:106])
Reproduction Steps
Steps to reproduce this issue
Packer version
I'm using packer 1.7.2
Simplified Packer Buildfile
I have taken the sample template from a github and have modified the variable according to our environment. Below is the input json file "builders": [ { "type": "proxmox", "username": "{{user text ks=http://{{ .HTTPIP }}:{{ .HTTPPort }}/ks.cfg"
],
"network_adapters": [
{
"bridge": "vmbr0",
"model": "e1000",
"vlan_tag": 10
}
],
"disks": [
{
"type": "scsi",
"disk_size": "8G",
"storage_pool": "{{user
proxmox_username
}}", "password": "{{userproxmox_password
}}", "proxmox_url": "{{ userproxmox_url
}}", "insecure_skip_tls_verify": true, "node": "{{userproxmox_node
}}", "os": "l26", "boot_command": [ "proxmox_storage_pool
}}", "storage_pool_type": "{{userproxmox_storage_pool_type
}}", "format": "{{userproxmox_storage_format
}}", "cache_mode": "none" } ], "scsi_controller": "lsi", "iso_file": "{{userproxmox_iso_pool
}}/{{usercentos_image
}}", "boot_wait": "10s", "cores": "2", "memory": "2048", "http_directory": "centos7", "ssh_username": "root", "ssh_password": "Packer", "ssh_port": 22, "ssh_timeout": "15m", "unmount_iso": true, "template_name": "{{usertemplate_name
}}", "template_description": "{{usertemplate_description
}}", "qemu_agent": false, "disable_kvm": true], "provisioners": [ { "type": "shell", "inline": [ "yum install -y cloud-init qemu-guest-agent cloud-utils-growpart gdisk", "shred -u /etc/ssh/_key /etc/ssh/_key.pub", "rm -f /var/run/utmp", ">/var/log/lastlog", ">/var/log/wtmp", ">/var/log/btmp", "rm -rf /tmp/ /var/tmp/", "unset HISTFILE; rm -rf /home//.history /root/.history", "rm -f /root/ks", "passwd -d root", "passwd -l root" ], "only": ["proxmox"] } ] }
Operating system and Environment details
we are using proxmox 4.1 version and i'm trying to build centos