Packaging windows vm force shuts down if running

54 views
Skip to first unread message

Ben Hines

unread,
Jun 2, 2014, 6:12:22 PM6/2/14
to vagra...@googlegroups.com
When using 'vagrant package' to package a windows vm which is running in Virtualbox vagrant force
shuts down the VM.

It should check for/ try to use WinRM to shut down the vm (as well as ssh) if it detects a windows vm.

This is a vm which was spun up by vagrant, and i'm attempting to repackage it as a basebox:

[bhines@sm-bhines-764:[~/
Documents/Code/sms/vagrant] [0]$ vagrant package --base vagrant_recap_1401745583866_68047
==> vagrant_recap_1401745583866_68047: Attempting graceful shutdown of VM...
    vagrant_recap_1401745583866_68047: Guest communication could not be established! This is usually because
    vagrant_recap_1401745583866_68047: SSH is not running, the authentication information was changed,
    vagrant_recap_1401745583866_68047: or some other networking issue.
Vagrant will force halt, if
    vagrant_recap_1401745583866_68047: capable.
==> vagrant_recap_1401745583866_68047: Forcing shutdown of VM...
==> vagrant_recap_1401745583866_68047: Clearing any previously set forwarded ports...
==> vagrant_recap_1401745583866_68047: Exporting VM...

-Ben

Shawn Neal

unread,
Jun 3, 2014, 11:39:58 AM6/3/14
to vagra...@googlegroups.com
I would expect that it should only attempt to use the communicator type you have configured. In your example, which communicator type are you using, SSH or WinRM?

Ben Hines

unread,
Jun 3, 2014, 2:01:16 PM6/3/14
to vagra...@googlegroups.com
 vagrant package doesn't have any connection with a VM definition in a Vagrantfile. It's just packaging a running virtualbox VM into a .box file. This VM happens to be a Windows VM, which supports WinRM and could be shut down that way, but vagrant does not try to. (it only tries ssh)

-Ben

Shawn Neal

unread,
Jun 3, 2014, 2:19:42 PM6/3/14
to vagra...@googlegroups.com
I didn't realize that. You should submit a bug report.


--
You received this message because you are subscribed to a topic in the Google Groups "Vagrant" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/vagrant-up/gZYBxheS0Ng/unsubscribe.
To unsubscribe from this group and all its topics, send an email to vagrant-up+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Ben Hines

unread,
Jun 3, 2014, 2:38:47 PM6/3/14
to vagra...@googlegroups.com
For that matter i'm not sure what ssh credentials it's trying.. maybe the default vagrant/vagrant? In this case it will work since i'm repackaging a vagrant vm back to a box file.

I'll put in a bug.

thanks-

-Ben
Reply all
Reply to author
Forward
0 new messages