arista-eosplus / packer-ztpserver

Packer.io set up of ZTP server
18 stars 9 forks source link

packer fails because "Guest not running" #2

Closed advornic closed 9 years ago

advornic commented 9 years ago
==> virtualbox-iso: Starting the virtual machine...

    virtualbox-iso: WARNING: The VM will be started in headless mode, as configured.

    virtualbox-iso: In headless mode, errors during the boot sequence or OS setup

    virtualbox-iso: won't be easily visible. Use at your own discretion.

==> virtualbox-iso: Waiting 3s for boot...

==> virtualbox-iso: Typing the boot command...

==> virtualbox-iso: Error sending boot command: VBoxManage error: VBoxManage: error: Guest not running

==> virtualbox-iso: Unregistering and deleting virtual machine...

==> virtualbox-iso: Deleting output directory...

Build 'virtualbox-iso' errored: Error sending boot command: VBoxManage error: VBoxManage: error: Guest not running

==> Some builds didn't complete successfully and had errors:

--> virtualbox-iso: Error sending boot command: VBoxManage error: VBoxManage: error: Guest not running

==> Builds finished but no artifacts were created.
advornic commented 9 years ago

I actually got past this by setting "headless=False" in the JSON file. Once I did that, I could see the problem in VirtualBox - vboxnet2 was missing.

The fix was to go into the Settings of VirtualBox and add one NAT interface and 3 vboxnets: 0, 1 and 2.

Might be a good idea to address this in the docs as troubleshooting tips.

advornic commented 9 years ago

I guess it applies to packet-veos repo as well.

phil-dileo commented 9 years ago

There's a section labeled "IMPORTANT" in the directions that says: IMPORTANT: Regarding VMware virtual networks: The default setup places eth1 on vmnet2. This might not be created in your VMware environment. Therefore, you may wish to run the setup-fusion.sh script to help create this virtual network for you (VMware Fusion only). Once you have downloaded the script, ensure that is is executable, chmod +x setup-fusion.sh and then run it using sudo setup-fusion.sh

I can try and make that more visible and add these troubleshooting tips to the bottom section.

advornic commented 9 years ago

True, and I should have seen it - that was my bad.

phil-dileo commented 9 years ago

I'll try and create a shell script that does a pre-flight check to make sure we don't hit this.