简体   繁体   中英

Restoring Laravel's Homestead after critical error

I'm using Homestead via Vagrant for my Laravel environment. When I ran vagrant up today, there was a critical error saying that the box is inaccessible.

One of the instructions that I found on the web suggested unregistering the VM by using its machine uuid, which I did:

> VBoxManage.exe unregistervm [uuid]

After unregistering the status of Homestead box changed from inaccessible to not created .

Next step was to register the box, which I do like this:

> VBoxManage.exe registervm "C:\Users\Rhino\VirtualBox VMs\homestead\box-disk1.vmdk"

However the command above throws the following error:

VBoxManage.exe: error: Start tag expected, '<' not found.
VBoxManage.exe: error: Location: 'C:\Users\Rhino\VirtualBox VMs\homestead\box-disk1.vmdk', line 1 (0), column 1.

What am I doing wrong?

OK, I figured it out. There was probably a step missing in the guide I found - creation. All the steps again:

(1)
Unregister the box with machine uuid. The uuid can be found eg in the .vbox-prev file in your homestead virtual machine folder. Run this when you retrieve the uuid:

C:\Program Files\Oracle\VirtualBox> VBoxManage.exe unregistervm [uuid]

(2)
Create the box with --register flag:

C:\Program Files\Oracle\VirtualBox> VBoxManage.exe createvm --name "C:\Users\Rhino\VirtualBox VMs\homestead\box-disk1.vmdk" --register

(3)
Delete the folder in which your homestead vm is kept (I guess it's by default created in VirtualBox VMs folder)

(4)
Run vagrant up

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM