1 | <?xml version="1.0" encoding="UTF-8"?>
|
---|
2 | <!DOCTYPE topic
|
---|
3 | PUBLIC "-//OASIS//DTD DITA Topic//EN" "topic.dtd">
|
---|
4 | <topic xml:lang="en-us" id="snapshots-take-restore-delete">
|
---|
5 | <title>Taking, Restoring, and Deleting Snapshots</title>
|
---|
6 |
|
---|
7 | <body>
|
---|
8 | <p>There are three operations related to snapshots, as follows: </p>
|
---|
9 | <ol>
|
---|
10 | <li>
|
---|
11 | <p><b outputclass="bold">Take a snapshot.</b> This makes a copy of the machine's current state,
|
---|
12 | to which you can go back at any given time later. </p>
|
---|
13 | <ul>
|
---|
14 | <li>
|
---|
15 | <p>If your VM is running: </p>
|
---|
16 | <p>Select <b outputclass="bold">Take Snapshot</b> from the <b outputclass="bold"
|
---|
17 | >Machine</b> menu in the VM window. </p>
|
---|
18 | <p>The VM is paused while the snapshot is being created. After snapshot creation, the VM
|
---|
19 | continues to run as normal. </p>
|
---|
20 | </li>
|
---|
21 | <li>
|
---|
22 | <p>If your VM is in either the Saved or the Powered Off state, as displayed next to the VM
|
---|
23 | name in the machine list: </p>
|
---|
24 | <p>Display the Snapshots window and do one of the following: </p>
|
---|
25 | <ul>
|
---|
26 | <li>
|
---|
27 | <p>Click <b outputclass="bold">Take</b> in the Snapshots window toolbar. </p>
|
---|
28 | </li>
|
---|
29 | <li>
|
---|
30 | <p>Right-click the <b outputclass="bold">Current State</b> item in the list and
|
---|
31 | select <b outputclass="bold">Take</b>. </p>
|
---|
32 | </li>
|
---|
33 | </ul>
|
---|
34 | </li>
|
---|
35 | </ul>
|
---|
36 | <p>A dialog is displayed, prompting you for a snapshot name. This name is purely for reference
|
---|
37 | purposes, to help you remember the state of the snapshot. For example, a useful name would be <i>Fresh
|
---|
38 | installation from scratch, no Guest Additions</i>, or <i>Service Pack 3 just installed</i>. You can also add
|
---|
39 | a longer text description in the <b outputclass="bold">Snapshot Description</b> field. </p>
|
---|
40 | <p>Your new snapshot will then appear in the snapshots list. Underneath your new snapshot, you
|
---|
41 | will see an item called <b outputclass="bold">Current State</b>, signifying that the current state of your VM
|
---|
42 | is a variation based on the snapshot you took earlier. If you later take another snapshot, you will see that
|
---|
43 | they are displayed in sequence, and that each subsequent snapshot is derived from an earlier one. </p>
|
---|
44 | <p><ph conkeyref="vbox-conkeyref-phrases/product-name"/> imposes no limits on the number of
|
---|
45 | snapshots you can take. The only practical limitation is disk space on your host. Each snapshot stores the
|
---|
46 | state of the virtual machine and thus occupies some disk space. See <xref
|
---|
47 | href="snapshots-contents.dita#snapshots-contents"/> for details on what is stored in a snapshot. </p>
|
---|
48 | </li>
|
---|
49 | <li>
|
---|
50 | <p><b outputclass="bold">Restore a snapshot.</b> In the Snapshots window, select the snapshot
|
---|
51 | you have taken and click <b outputclass="bold">Restore</b> in the toolbar. By restoring a snapshot, you go
|
---|
52 | back or forward in time. The current state of the machine is lost, and the machine is restored to the exact
|
---|
53 | state it was in when the snapshot was taken. </p>
|
---|
54 | <note>
|
---|
55 | <p>Restoring a snapshot will affect the virtual hard drives that are connected to your VM, as
|
---|
56 | the entire state of the virtual hard drive will be reverted as well. This means also that all files that
|
---|
57 | have been created since the snapshot and all other file changes <i>will be lost. </i>In order to prevent
|
---|
58 | such data loss while still making use of the snapshot feature, it is possible to add a second hard drive in
|
---|
59 | <i>write-through</i> mode using the <userinput>VBoxManage</userinput> interface and use it to store your
|
---|
60 | data. As write-through hard drives are <i>not</i> included in snapshots, they remain unaltered when a
|
---|
61 | machine is reverted. See <xref href="hdimagewrites.dita#hdimagewrites"/>. </p>
|
---|
62 | </note>
|
---|
63 | <p>To avoid losing the current state when restoring a snapshot, you can create a new snapshot
|
---|
64 | before the restore operation. </p>
|
---|
65 | <p>By restoring an earlier snapshot and taking more snapshots from there, it is even possible to
|
---|
66 | create a kind of alternate reality and to switch between these different histories of the virtual machine.
|
---|
67 | This can result in a whole tree of virtual machine snapshots. </p>
|
---|
68 | </li>
|
---|
69 | <li>
|
---|
70 | <p><b outputclass="bold">Delete a snapshot.</b> This does not affect the state of the virtual
|
---|
71 | machine, but only releases the files on disk that <ph conkeyref="vbox-conkeyref-phrases/product-name"/> used
|
---|
72 | to store the snapshot data, thus freeing disk space. To delete a snapshot, select the snapshot name in the
|
---|
73 | Snapshots window and click <b outputclass="bold">Delete</b> in the toolbar. Snapshots can be deleted even
|
---|
74 | while a machine is running. </p>
|
---|
75 | <note>
|
---|
76 | <p>Whereas taking and restoring snapshots are fairly quick operations, deleting a snapshot
|
---|
77 | can take a considerable amount of time since large amounts of data may need to be copied between several
|
---|
78 | disk image files. Temporary disk files may also need large amounts of disk space while the operation is in
|
---|
79 | progress. </p>
|
---|
80 | </note>
|
---|
81 | <p>There are some situations which cannot be handled while a VM is running, and you will get an
|
---|
82 | appropriate message that you need to perform this snapshot deletion when the VM is shut down. </p>
|
---|
83 | </li>
|
---|
84 | </ol>
|
---|
85 | </body>
|
---|
86 |
|
---|
87 | </topic>
|
---|