VirtualBox

Opened 14 years ago

Closed 14 years ago

Last modified 13 years ago

#6097 closed defect (fixed)

"Current state" is changed right after taking snapshot

Reported by: Winchester Owned by: umoeller
Component: virtual disk Version: VirtualBox 3.1.2
Keywords: current state changed Cc:
Guest type: Windows Host type: Linux

Description

"Current state" is changed right after taking snapshot

Scenario to reproduce the problem:
1) Power on a virtual machine and boot an OS in it.
2) Shutdown the machine cleanly.
3) Take snapshot of "Current State" and name it, for example as "Snapshot 1".
Problem: you will get the result as follows:
Snapshot 1 (1 second ago)

Current State (changed)

It incorrect that "Current state" is changed right after the snapshot is taken when the machine is turned off. I use VirtualBox 3.1.2, host OS is Linux Ubuntu 9.04, Guest OS is Windows XP SP3. Virtual disk image file format is VDI.
I also could reproduce the problem on another 2 PCs with host OSs Windows Vista SP2 and Linux Mandriva 2010 and different guest OSs. So it seems it does not matter which host and guest OSs are.
The problem did not exist on VirtualBox 3.0.12. In that version "Current state" remains identical to the state saved in snapshot until the machine is powered on again.
I am not sure but probably this is the reason of virtual disk corruption described in #6023 (with more steps like taking another snapshot and removing a previous one). I could also reproduce the problem from #6023 on my systems.

Attachments (1)

VBox.log.1 (58.8 KB ) - added by Winchester 14 years ago.

Download all attachments as: .zip

Change History (5)

by Winchester, 14 years ago

Attachment: VBox.log.1 added

comment:1 by umoeller, 14 years ago

Owner: set to umoeller
Status: newassigned

comment:2 by Raf Schietekat, 14 years ago

Confirmed for VirtualBox 3.1.8 on Ubuntu 10.04. I suspect it does not matter whether the client system was shut down inside or just its state saved. Here's another way to consistently reproduce this: "Power off the machine" with "Restore current snapshot 'NameOfSnapshot'", "Snapshots" shows "Current State", select it and "Take Snapshot of Virtual Machine", "Snapshots" now shows "Current State (changed)". At first sight the logs are only about the sessions and don't include information about taking a snapshot at such time.

After some research, my assumption is an incorrect use of "SaveS_ResetCurStateModified" from inside Vbox/Main/SnapshotImpl.cpp, but this seems to have been corrected in revision/changeset 27644, on "2010-03-23 17:07:49 (2 months ago)", which may be after 3.1.8, without updating this bug report? I propose that somebody with 2 test machines tests 3.1.8 and 3.2.0 next to each other to verify, and then marks this as fixed.

comment:3 by aeichner, 14 years ago

Resolution: fixed
Status: assignedclosed

I can verify that this was fixed. With 3.1.8 "Current state" has "changed" appended right after the snapshot was taken. This was fixed with 3.2.0. Thanks for the report!

comment:4 by matthew72, 13 years ago

maybe it's not a big issue but... fixed? it's still so in 4.0.4! but then, even #6023 is "fixed"...

Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use