Re: Intercepting system calls

From: Wojciech Zygmunt Porczyk
Date: Wed Dec 28 2011 - 08:03:47 EST


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Fri, Dec 23, 2011 at 10:33:45PM +0530, Gaurav Saxena wrote:
> I am trying to write an application which would create a backup for
> the system so that it could be restored as it is. For example I create
> a backup using my application. I just do nothing at time of backup so
> it would be fast. Now whenever I see any deletion I would save that
> file so that I could restore it.

You almost certainly wan't to research LVM(-like) snapshots. They are
operating in block layer, so you can restore fs "as it was", with COW
feature they do "nothing" at creation and just save overwritten data
somewhere else.

See: lvcreate(8), xfs_freeze(8). Maybe btrfs(8) ("btrfs subvolume
snapshot") but btrfs is not really production-ready, so get lvm2+xfs.

- --
regards
WZJP
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.18 (GNU/Linux)

iEYEARECAAYFAk77Ef8ACgkQDgvLOJe6jMmQuACfassIV+vXCTmvMCTUqa81wgFf
lBcAoLwYdPf59FEJ7sl/lzyHLLo4pG2r
=Zt0G
-----END PGP SIGNATURE-----
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/