How to restore .vbox file ?

Discussions related to using VirtualBox on Solaris hosts.

How to restore .vbox file ?

Postby svartalf » 31. Mar 2018, 18:38

Hi,

I've got a problem with one of my VMs which appears to be due to a corrupt .vbox file.

I have a .vbox-prev and also ZFS snapshots available but every time I copy an old .vbox file into place, it mysteriously gets overwritten and the original restored.

I have other VMs running which are fine, it is just one that won't start and in the VirtualBox Manager GUI it complains about a missing attribute.

I'm guessing that a VBox process is holding the bad file open and reverting my attempts to overwrite it.

So my question is - is there a procedure for restoring an old .vbox file in an attempt to recover my VM?

Thanks,

Richard
svartalf
 
Posts: 4
Joined: 31. Mar 2018, 18:32

Re: How to restore .vbox file ?

Postby ChipMcK » 31. Mar 2018, 19:11

know nothing about solaris, but

as I recall the .vbox files are maintained in storage (ram) and are written out during close-down of Vbox.


Vbox needs to be down (not opened) like 20 seconds to flush secondary tasks/jobs.
ChipMcK
Volunteer
 
Posts: 1096
Joined: 20. May 2009, 02:17
Location: U S of A
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Windows, OSX

Re: How to restore .vbox file ?

Postby svartalf » 31. Mar 2018, 19:44

Thanks. I thought it might be something like that.
Any ideas on how to stop the VirtualBox processes?
I can halt the other VMs but processes are still left running. I'm guessing there must be a more elegant way then sending a kill signal.
svartalf
 
Posts: 4
Joined: 31. Mar 2018, 18:32

Re: How to restore .vbox file ?

Postby ChipMcK » 1. Apr 2018, 00:59

Quit / Exit
VirtualBox
.
ChipMcK
Volunteer
 
Posts: 1096
Joined: 20. May 2009, 02:17
Location: U S of A
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Windows, OSX

Re: How to restore .vbox file ?

Postby svartalf » 1. Apr 2018, 13:42

All headless VMs stopped.
/application/virtualbox/zoneaccess disabled.
GUI not running.

I copy the .vbox file into place. Also copy into .vbox-prev just to make double sure.

Then I start VirtualBox and the files get reverted immediately.
There's something in the GUI which recreates or restores these files.

This is a bit annoying. I'm starting to thing I should just recreate the VM.
svartalf
 
Posts: 4
Joined: 31. Mar 2018, 18:32

Re: How to restore .vbox file ?

Postby mpack » 1. Apr 2018, 16:30

svartalf wrote:There's something in the GUI which recreates or restores these [.vbox] files.

Of course. The vbox file stores the VM settings. It gets resaved every session, with the old file renamed to ".vbox-prev".
mpack
Site Moderator
 
Posts: 29944
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP

Re: How to restore .vbox file ?

Postby svartalf » 1. Apr 2018, 20:18

Odd that both files revert when the GUI is started. Not sure how to workaround this.
svartalf
 
Posts: 4
Joined: 31. Mar 2018, 18:32

Re: How to restore .vbox file ?

Postby mpack » 2. Apr 2018, 09:29

It's impossible for them to "revert" using any feature of VirtualBox, since VirtualBox has no access to data needed to do that. However both files will change :-

Code: Select all   Expand viewCollapse view
   old.vbox_prev --> deleted.
   old_.vbox --> new.vbox_prev.
   new_.vbox --> created.
mpack
Site Moderator
 
Posts: 29944
Joined: 4. Sep 2008, 17:09
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Mostly XP


Return to VirtualBox on Solaris Hosts

Who is online

Users browsing this forum: Majestic-12 [Bot] and 1 guest