Tag Info

Hot answers tagged

38

No, it's not. What happens when your filesystem or RAID volume gets corrupted? Or your server gets set on fire? Or someone accidentally formats the wrong array? You lose all your data and the not-real-backups you thought you had. That's why real backups are on a completely different system than the data you're backing up - because backups protect ...


27

When a VM has an active snapshot, its virtual disk I/O is not performed on the VM's actual .VMDK files, but instead they are kept unchanged, and whatever changes in the VM is written to different physical files; this allows for the recovery of the previous VM state, but has three important side effects: Disk I/O for the VM is much slower. Those "delta" ...


17

Most of these snapshots are copy-on-write snapshots, which are really fast and really cheap (storage-wise) on rarely-updated systems. LVM snapshots are COW snapshots, ZFS/BTRFS both have a COW-mode for snapshots, reiserfs doesn't have snapshots natively, Novell's NSS file-system is also COW, as are Shadow Copy volumes for Windows NTFS volumes. Copy-on-write ...


15

You're safe to use the volume once you have triggered the snapshot, even if it's still in a pending state according to AWS - see this post. If you're taking a snapshot for the first time, it probably will take a while as it has to make a full copy to the region-wide S3 bucket, but remember, it's incremental after the first one has been stored so should be a ...


13

Wny not have a look at the snapshots section of the LVM-HOWTO? LVM snapshots are your basic "copy on write" snapshot solution. The snapshot is really nothing more than asking the LVM to give you a "pointer" to the current state of the filesystem and to write changes made after the snapshot to a designated area. LVM snapshots "live" inside the volume group ...


12

LVM snapshots are an example of a copy-on-write snapshot solution, as Evan said. How it works is a bit different from from Evan implied, but not by a whole lot. When you have an LVM volume with no snapshots, writes to the volume happen as you'd expect. A block is changed, and that's it. As soon as you create a snapshot, LVM creates a pool of blocks. This ...


12

KVM has a much better snapshot capability than what's managed by libvirt; but it depends on qcow2 images. if you use them, just do a savevm <name> on the command console (blocked by libvirt) it won't create a new file, it's a snapshot inside the qcow2 file. test it first, because some KVM versions have it broken.


12

Backups serve two functions. First and foremost, they're there to allow you to recover your data if it becomes unavailable. In this sense, snapshots are not backups. If you lose data on the filer (volume deletion, storage corruption, firmware error, etc.), all snapshots for that data are gone as well. Secondly, and far more commonly, backups are used to ...


12

The -F switch comes in handy if you have messed with the destination dataset after it has been received. Once you do any changes to it (including doing something as innocent as a directory listing as this would change atimes), it is no longer in the state it was in after the initial transfer. Trying to run a plain zfs receive from an incremental data stream ...


10

When you create a snapshot, the original disk image is "frozen" in a consistent state, and all write accesses from then on will go to a new differential image. Even worse, as explained here, the differential image has the form of a change log, that records every change made to a file since the snapshot was taken. This means, that read accesses would have to ...


9

No, because snapshots are block-level delta disks so this has no way of working. Think of a snapshot like a "transparency" that goes over the original disk. If the original changes, then the snapshot will make no sense and the machine will be in an inconsistent state. This isn't a small topic, but essentially, when a snapshot is made - from that point ...


9

For on-site backup, snapshot might be good enough, provided that you regularly 'export' your snapshot somewhere else, where it exists as passive data. And, regularly test if your 'shipped snapshot' can be restored. This is how I implemented a quick backup of some of my servers: store the data on ZFS, take a ZFS snapshot, send the delta to another server, ...


9

Some free tools you could use: What Changed 1.06 What Changed is a simple utility that searches for modified files and registry entries. It is useful for checking program installations. There are two steps for using What Changed: First, take a snapshot of the state of the system Second, run What Changed again to see the ...


9

You need to rewrite that snapshot tree. The actual tree looks like this: SnapshotA SnapshotB SnapshotC Current When you took SnapshotA, the main vmdk file was frozen and a new delta file was created. All changes were written to the delta file from that point onwards. When you took SnapshotB, the first delta file was frozen and another delta file ...


8

Is this accurate, and is it fundamentally the same for LVM and KVM snapshots? Yes and yes.


7

Be aware that snapshots are not a replacement for backups! I use snapshots only for creating short-term failback points, e.g. before a server is patched with something that might break it. But I won't keep snapshots for longer than several days, and by no means I would create them on a regular basis, just because I can and might need them later. Please note ...


7

Snapshots aren't really backups per se. They're simply using pointers to point to another set of blocks on the drive. For example, let's say you have a file called, "ServerFault.doc" and it takes up blocks A, B, and C on the hard drive. When you take a snapshot, Snap.0 (my name for the first snapshot) points at blocks A, B, and C. It simply makes a copy ...


7

Ok, I think I have it figured out from re-reading the HOWTO 3.8. Read-only snapshots (like LVM1) contain the block-level differences after the snapshot creation - the original still gets changed, but the snapshot retains a representation of the original. Reading from the snapshot presents the data as it appeared at that time. Read-write snapshots (default ...


7

LVM2 /dm-mapper snapshots merge functionality is available if you are running linux 2.6.33+ and using LVM 2.0.58+ (lvconvert --merge) See this post: http://www.jonnor.com/2010/02/lvm-snapshot-merging-avaliable/ if references http://kernelnewbies.org/Linux_2_6_33 (look at section 5, MD/DM) and LVM changelog at 2.0.58: ...


6

I just tried a snapshot-based upgrade with Ubuntu. And yeah, I needed to reboot several times. First rename the original root-lv to something else, so you can give the snapshot the original name (since an upgrade creates a lot of change and changes are faster on the snapshot than on the original): # lvrename lvm root root-old # lvcreate -n root -s ...


6

There are lots of tools capable of this, Windows 2000 was even shipped with a version of wininstall if I'm not mistaken - anyway, it's available for free these days. The trouble is avoiding false positives - ie changes made by the operating system that was not related to the installer - so some care and manual editing is always needed.


6

When you take a snapshot, VirtualBox stops writing to the .vdi and starts writing to the snapshot file. When you merge, it merges the snapshot file into the original .vdi and you're left with the original .vdi plus the changes. To answer the question explicitly, yes.


6

You may find something like this a little simpler zfs list -t snapshot -o name -s name |grep ^tank@Auto | sed 1,15d | xargs -n 1 zfs destroy -r` Test it with ...|xargs -n 1 echo


6

WHY would you have a 'tree of about 15 snapshot'? I know you can but that doesn't mean it's a smart way of doing things, ever heard of a clone or a backup - they're for keeping longer-term point in time copies of VMs, snapshots are just abused by the untrained as they think they're 'free' - they're not. Either way it's your mess and there's no real way out ...


6

They are a backup, yes. I've personally used them in place of daily incrementals before, but we still did weekly fulls to tape. They protect quite well from any non-netapp (systems accessing volumes) user or admin errors or problems. They do not protect from catastrophic hardware failures of the netapp itself. My understanding is that SnapMirror does copy ...


6

What HopelessN00b said. No. Proper backups are on a separate device than the device being backed up. What happens when you lose two or more drives? What happens when your server room burns down? What happens when someone accidentally destroys your array? (Anecdote alert: I once heard of someone who had PXE set to auto-install the latest Fedora. His ...


5

Yes, it is. It is a perfect way to store backups. Nothing else is needed, heck, even doing ingtegrity checks are just wasted time. Just to confirm - before I give more advice... you work for a competitor of mine, right? You really do, sure? No? Oh. Sorry, NUTS. No, not at all. Sorry, dude. Problem is that you are totally open to any error that happens in ...


5

The number of files and directories involved in a zfs send/recv stream should have no direct impact on its transfer speed. Indirectly, it might, because it is usually true to say that the 'spread' of the dataset across your disks will be higher with more directories/files, depending on the workload that generated them. This matters, because it's far easier ...


5

The Snapshot is part of a chain of images and requires the availability of all snapshots. You can boot off the snapshot, but you must have all the previous images intact as well Having a snapshot chain does degrade performance. Highly loaded server VMs should not be running off of snapshots at all To manage snapshots, you simply try to keep ...


5

This depends entirely on what is taking the snapshot. VMware ESXi will use VMware Tools to quiesce the guest filesystem to make sure you have a consistent snapshot. Hyper-V does a similar operation when the enlightenment tools are installed. I don't know of any virtualization solution that takes inconsistent snaps unless you explicitly tell it not to ...



Only top voted, non community-wiki answers of a minimum length are eligible