Quote:
Originally Posted by MinskyBA
Can someone explain exactly what snapshot is for, what it does, how it works, and what happens when it breaks?
|
A snapshot is like a snapshot, hence the name. That is, it is a record of what is in the filesystem at one point in time.
Now, the implications of this depend somewhat on the technology. Conventionally, you would think that if you took 5 snapshots (over a period of time) of a 100G filesystem (100G +/- a small amount for changes) that would need another 500G of storage space and would cause a lot of traffic as that data gets copied around.
However, if you use the CoW mechanism (copy on write) to provide the snapshot you don't save extra copies of the data, you have a base data set and (effectively) a set of deltas, and you can still reconstruct the data set at any of the snapshot instants. And, perhaps as important, because you aren't physically copying data around, you aren't causing the extra traffic.
Filesystems like ZFS and the forthcoming BTRFS use CoW and are thus able to do snapshotting particularly efficiently. My guess is that you probably don't have one of those, and are probably doing snapshotting the 'brute force and ignorance' way.