linux-lvm.redhat.com archive mirror
 help / color / mirror / Atom feed
* [linux-lvm] CoW under the hood
@ 2018-12-03  6:17 Far Had
  2018-12-03 11:39 ` Zdenek Kabelac
  0 siblings, 1 reply; 2+ messages in thread
From: Far Had @ 2018-12-03  6:17 UTC (permalink / raw)
  To: linux-lvm

[-- Attachment #1: Type: text/plain, Size: 1001 bytes --]

Hi,
I'm trying to understand how LVM thick snapshots work under the hood. I can
see that when new write requests are comming to the original volume that
has a snapshot, the current contents of storage blocks copy to the snapshot
space then the new data overwrites on the volume. No problem so far.
the question is when I delete a file on a volume that has snapshot, the
content is gone on the volume so the pointer which points from volume
object to that certain blocks on the volume should now point to empty
blocks. On the other hand I can see that the contents of deleted parts from
the original volume did not copy to the snapshot space, meaning that the
snapshot pointers that were pointing to that blocks on the original volume,
still point that direction.
In other words the pointers from both snapshot and original volume are
pointing to the same blocks on the storage media but they don't show the
same contents when you mount them on the filesystem.
Please enlighten me about this situation

[-- Attachment #2: Type: text/html, Size: 1071 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [linux-lvm] CoW under the hood
  2018-12-03  6:17 [linux-lvm] CoW under the hood Far Had
@ 2018-12-03 11:39 ` Zdenek Kabelac
  0 siblings, 0 replies; 2+ messages in thread
From: Zdenek Kabelac @ 2018-12-03 11:39 UTC (permalink / raw)
  To: LVM general discussion and development, Far Had

Dne 03. 12. 18 v 7:17 Far Had napsal(a):
> Hi,
> I'm trying to understand how LVM thick snapshots work under the hood. I can 
> see that when new write requests are comming to the original volume that has a 
> snapshot, the current contents of storage blocks copy to the snapshot space 
> then the new data overwrites on the volume. No problem so far.
> the question is when I delete a file on a volume that has snapshot, the 
> content is gone on the volume so the pointer which points from volume object 
> to that certain blocks on the volume should now point to empty blocks. On the 
> other hand I can see that the contents of deleted parts from the original 
> volume did not copy to the snapshot space, meaning that the snapshot pointers 
> that were pointing to that blocks on the original volume, still point that 
> direction.
> In other words the pointers from both snapshot and original volume are 
> pointing to the same blocks on the storage media but they don't show the same 
> contents when you mount them on the filesystem.
> Please enlighten me about this situation

Hi

I assume going through some info from this page might put some light into it:

http://people.redhat.com/agk/talks/


In particular http://people.redhat.com/agk/talks/FOSDEM_2005/
from slide 15  there is some info about snapshots you might find useful.

Regards

Zdenek

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2018-12-03 11:39 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-03  6:17 [linux-lvm] CoW under the hood Far Had
2018-12-03 11:39 ` Zdenek Kabelac

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).