Skip to contentSkip to conversation

Snapshot and mount scripts

DISCUSSION John Huttley 2 participants 5 messages Oct 13, 2008 – Oct 15, 2008 4 messages not in the archive NILFS2 filesystem

lore
Share & tools
lore
#0 lore raw

Hi

I've just discovered nilfs, which is great for its snapshot capability.

Since the purpose of having a snapshot is to mount it, I was surprised that the utilities do not
have a snapshot-and-mount and unmount-and-delete ability.

Has anyone made a script to do this?

Regards,

john

A message that is not in the archive (sent off-list or not yet received): 48F3C04B.7000300-jE24nFfhqzU3hwNNidygWXTaI6DYlTYJ@public.gmane.org

#2 lore raw

Hi,

Quoted 9 lines · John Huttley

Hi

I've just discovered nilfs, which is great for its snapshot capability.

Since the purpose of having a snapshot is to mount it, I was surprised that the utilities do not
have a snapshot-and-mount and unmount-and-delete ability.

Has anyone made a script to do this?

Thank you for your interest in NILFS.

How about making every checkpoint mountable ?
Does it differ from what you want?

It seems to be possible to enhance mount.nilfs2 and umount.nilfs2 to allow changing given checkpoint to snapshot just before mounting, and restoring the state on unmount. (This is not a polite way but seems enough for most cases)

Regards,
Ryusuke

A message that is not in the archive (sent off-list or not yet received): [email protected]

#4 lore raw

Hi Ryusuke,

My point is that I don't actually care about cp's or snapshots.

They are a means to an end and not an end in themselves.

For the purpose of making a backup, if we can snapshot-and-mount, then they can be anonymous.
If they are anonymous, we don't have to worry about old snapshots filling up the system. Unmount and they are gone. That covers the biggest use of snapshots-- making a consistent backup.

If you want to change a cp to a ss on mount, you still have to provide the cp number, which is hard to script.

The other use would be to do a roll back if required. Perhaps rollback to a checkpoint as well as a snapshot. That's useful but it can wait.

Quoted 24 lines · Ryusuke Konishi

Hi,

Quoted 9 lines · John Huttley

Hi

I've just discovered nilfs, which is great for its snapshot capability.

Since the purpose of having a snapshot is to mount it, I was surprised that the utilities do not
have a snapshot-and-mount and unmount-and-delete ability.

Has anyone made a script to do this?

Thank you for your interest in NILFS.

How about making every checkpoint mountable ?
Does it differ from what you want?

It seems to be possible to enhance mount.nilfs2 and umount.nilfs2 to allow changing given checkpoint to snapshot just before mounting, and restoring the state on unmount. (This is not a polite way but seems enough for most cases)

Quoted 9 lines

Regards,
Ryusuke
_______________________________________________
users mailing list
[email protected]
https://www.nilfs.org/mailman/listinfo/users

_______________________________________________
users mailing list
[email protected]
https://www.nilfs.org/mailman/listinfo/users

A message that is not in the archive (sent off-list or not yet received): 48F59E90.9060404-jE24nFfhqzU3hwNNidygWXTaI6DYlTYJ@public.gmane.org

#6 lore raw

Hi John,

Quoted 5 lines · John Huttley

Hi Ryusuke,

My point is that I don't actually care about cp's or snapshots.

They are a means to an end and not an end in themselves.

I agree with this.

Note, however, that the difference between cp's and snapshots is fundamental for nilfs2 because it provides they are temporary or persistent. Users should at least understand this semantics.

Quoted 8 lines

For the purpose of making a backup, if we can snapshot-and-mount, then they can be anonymous.
If they are anonymous, we don't have to worry about old snapshots filling up the system. Unmount and they are gone.
That covers the biggest use of snapshots-- making a consistent backup.

If you want to change a cp to a ss on mount, you still have to provide the cp number, which is hard to script.

Actually, the primitive version of nilfs2 had a support of the ``anonymous'' snapshot mount but it was disabled before the first formal release.

Users could mount snapshots just with a readonly option as follows:

 # mount -t nilfs2 /dev/sdb1 /nilfs
 ...
 # mount -t nilfs2 -r /dev/sdb1 /backup

And this was convenient for (consistent) online backup as you say. Unfortunately, NILFSv2 cannot do this due to race problems of GC. (It is possible on NILFS version 1, which does not have GC).

If you like this anonymous snapshot mount, I'll try to bring it back.

With regards,
Ryusuke Konishi

A message that is not in the archive (sent off-list or not yet received): [email protected]

#8 lore raw

Hi Ryusuke,

Ryusuke Konishi wrote:
<snip>

Quoted 10 lines

Actually, the primitive version of nilfs2 had a support of the ``anonymous'' snapshot mount but it was disabled before the first formal release.

Users could mount snapshots just with a readonly option as follows:

 # mount -t nilfs2 /dev/sdb1 /nilfs
 ...
 # mount -t nilfs2 -r /dev/sdb1 /backup
Quoted 7 lines

And this was convenient for (consistent) online backup as you say. Unfortunately, NILFSv2 cannot do this due to race problems of GC. (It is possible on NILFS version 1, which does not have GC).

If you like this anonymous snapshot mount, I'll try to bring it back.

I'm sure that would be a very useful feature!

Regards,

john

Quoted 5 lines

With regards,
Ryusuke Konishi