Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 14 Nov 2016 07:53:29 +0000
From:      Matthew Seaman <matthew@FreeBSD.org>
To:        freebsd-questions@freebsd.org
Subject:   Re: zfs send/receive as dump/restore alternative
Message-ID:  <1bf448ae-a011-8c69-b199-17d71f4053c3@FreeBSD.org>
In-Reply-To: <20161114054657.GA66229@admin.sibptus.transneft.ru>
References:  <20161114054657.GA66229@admin.sibptus.transneft.ru>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--qCGj6cNDwlkJRaFf7FfoH6b4QQrfJpxdr
Content-Type: multipart/mixed; boundary="JxLXpq0qjqQnRXLA2HHOxHElFqpfvsB2B";
 protected-headers="v1"
From: Matthew Seaman <matthew@FreeBSD.org>
To: freebsd-questions@freebsd.org
Message-ID: <1bf448ae-a011-8c69-b199-17d71f4053c3@FreeBSD.org>
Subject: Re: zfs send/receive as dump/restore alternative
References: <20161114054657.GA66229@admin.sibptus.transneft.ru>
In-Reply-To: <20161114054657.GA66229@admin.sibptus.transneft.ru>

--JxLXpq0qjqQnRXLA2HHOxHElFqpfvsB2B
Content-Type: text/plain; charset=windows-1252
Content-Transfer-Encoding: quoted-printable

On 14/11/2016 05:46, Victor Sudakov wrote:
> How would you restore a) a single dataset or b) a single file from a
> replication stream package? I really need this mode of operation for
> undeleting users' files etc.

You have to 'zfs recv' your datastream and expand it out as a
filesystem.  Then you can simply copy individual files back to your live
system, or you can do a zfs send / zfs recv of a single dataset to
restore that.

You can easily 'zfs recv' the datastream into a different root directory
than it came from -- so you won't end up overwriting onesystem with the
backup of another.

There are scripts to do this in ports, but here's some I wrote myself:

https://github.com/infracaninophile/zfs-backup

I never did get round to writing a 'zfs-restore' script though.

	Cheers,

	Matthew



--JxLXpq0qjqQnRXLA2HHOxHElFqpfvsB2B--

--qCGj6cNDwlkJRaFf7FfoH6b4QQrfJpxdr
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQJ8BAEBCgBmBQJYKW2AXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w
ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ2NTNBNjhCOTEzQTRFNkNGM0UxRTEzMjZC
QjIzQUY1MThFMUE0MDEzAAoJELsjr1GOGkATeDgQAJKtd+AQCIHrBvhNlOJXMOOr
+/7BYC6VE+E7hOiHzVKI1WewZXcnJY6ayx/IYvs6rU1qEXBxmM/4//NFfOAVbqQH
Go+sdSqdhsppWkTDvp2oe95dNvvCDyjJu0WHtlPfu6nX6VIWGcA5J8RWTZydsC0J
NK8m67E6Wnku6nlYAvB7NTiqVbdtK+JfO7/WrZ2/0FkyMxN/1sjQx0fQu/dsNCyv
zfqvXZS69p7u88EHGn2naeeDE3fDun9ZE+QhViyPFwxPxHEV2zcfh60QW1bz13Ia
QOHfRt+B9bUwb/DrdTXT2r5N6tws/o7rQ3BPQ6+2T98vdt9xvPVdvulKaerXwJEr
N8/P3NPMH6WhLEFzIQi/UXApmJNFecn7BOaFVadCJhR9uwLzaEfciyVctOqiAFvr
YXn56vLillPmAEMb8jAoXfAR0OVCxrzzlzwcCGm58AdvT4JO1VorYo/m7u1JI9V9
Elr/vS6m31QERSTsmJT8gei820MkhkYmhdh1/a9n4evDCKShn3Z9OTz4h/Mrki2p
sQgoY3n7eOdXYJeqBQfac//6P+WiF0FwhXHWceLqilLvzYjrFFWUvsp+EsqOHuBK
ABHSvybDb01frdf59ptkm3bWJnOetgSDk8PFon0i/MlCGIJvFYUzAH59AIvf6BSS
792GEEeLoY4xYNJd7ysw
=6I+0
-----END PGP SIGNATURE-----

--qCGj6cNDwlkJRaFf7FfoH6b4QQrfJpxdr--



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?1bf448ae-a011-8c69-b199-17d71f4053c3>