Laravel comes with Homestead. When updating Laravel, you sometimes need to update Homestead as well.
What is missing in the upgrade guide of Laravel is to backup essential information from Homestead, like SSH-keys and database information.
Although, Homestead sites are meant to be complete with Laravel Migrations and Database Seeding, you still sometimes might have some relevant database data that you will like to access.
After updating / upgrading Homestead, the previous box is not available anymore.
Check Time Machine Backup
If you are on a Mac and use Time Machine, often old Homestead boxes are stored on your Mac.
Go to Finder => Your Home Directory => Virtual Box VMs. Then click in the top right corner on the Time Machine icon and click on “Activate Time Machine”.
You can click on the homestead directory and the “Restore” button.
This will give a box that you can open with Virtualbox.
If you navigate in Finder to the Virtual VMs folder and to the imported old homestead box, you will find a file named: homestead.vbox or something like homestead-7.vbox . If you open this file with Virtualbox it will be imported.
You can then start the old Homestead box in Virtualbox itself. So not in terminal.
Starting the old Homestead Ubuntu Box
You do not need to open Homestead via the command line with “vagrant up”.
Just go to Virtualbox, start the instance and when the terminal screen pops up, you can login with:
username: virtualbox
password: virtualbox
If correct, you can now access the Ubuntu box and you should also be able to connect to the database.
Note: this is only a guide to temporarily restore Homestead for backup purposes. Use at your own risk.
This guide was written for macOS.