このところVagrantが不調で、以下のエラーが頻繁に出る。
1 2 3 4 5 6 7 8 9 10 11 12 |
$ vagrant up Bringing machine 'default' up with 'virtualbox' provider... ==> default: Checking if box 'puphpet/centos65-x64' is up to date... ==> default: Clearing any previously set forwarded ports... There was an error while executing `VBoxManage`, a CLI used by Vagrant for controlling VirtualBox. The command and stderr is shown below. Command: ["modifyvm", "<vm-uuid>", "--natpf1", "delete", "ssh"] Stderr: VBoxManage: error: The machine 'xxxxx_default_1510770391814_44801' is already locked for a session (or being unlocked) VBoxManage: error: Details: code VBOX_E_INVALID_OBJECT_STATE (0x80bb0007), component MachineWrap, interface IMachine, callee nsISupports VBoxManage: error: Context: "LockMachine(a->session, LockType_Write)" at line 507 of file VBoxManageModifyVM.cpp |
とりあえずロックを解除するには以下のコマンドを実行すれば良い。
1 |
$ vboxmanage startvm <vm-uuid> --type emergencystop |
参考サイト
VM in virtualbox is already locked for a session (or being unlocked) – Stack Overflow
https://stackoverflow.com/questions/35169724/vm-in-virtualbox-is-already-locked-for-a-session-or-being-unlocked