Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > alt.os.linux > #56175

Re: Can crypsetup --type plain destroy a previous written partition?

From "J.O. Aho" <user@example.net>
Newsgroups alt.os.linux
Subject Re: Can crypsetup --type plain destroy a previous written partition?
Date 2019-05-11 09:40 +0200
Message-ID <gjncjmFtfb4U1@mid.individual.net> (permalink)
References (2 earlier) <qb449g$1ifr$1@gioia.aioe.org> <gjlo21FiqioU1@mid.individual.net> <qb4akm$foe$1@gioia.aioe.org> <gjma47Fmil5U1@mid.individual.net> <qb5eba$1ch1$1@gioia.aioe.org>

Show all headers | View raw


On 11/05/2019 05.08, Paulo da Silva wrote:
> Às 22:52 de 10/05/19, J.O. Aho escreveu:
>> On 10/05/2019 18.59, Paulo da Silva wrote:
>>> Às 17:43 de 10/05/19, J.O. Aho escreveu:
>>>> On 10/05/2019 17.10, Paulo da Silva wrote:
>>>>> Às 06:02 de 10/05/19, J.O. Aho escreveu:
>>>>>> On 09/05/2019 22.14, Paulo da Silva wrote:
> ...
> 
>>
>> To avoid duplication you first send your oldest snapshot
>>
>>
>> btrfs send /mnt/send/oldestsnashot | btrfs receive /mnt/recv/
>>
>> and then you send the diff between the oldest and next oldest
>>
>> btrfs send -p /mnt/send/oldestsnapshot /mnt/send/nextoldestsnapshot |
>> btrfs receive /mnt/recv
>>
>> And you do this for each snapshot, then you just get the changes, which
>> leads to that less data is moved around.
>>
>> This can be used if you want to make a backup of a volume. First time
>> you do a full backup, you make a snapshot of the volume, you send the
>> snapshot to your backup device.
>> Next time you make an incremental backup by making a new snapshot, you
>> send the diff between the first snapshot and the new one, when finished
>> you can delete the oldest snapshot. When you make the next incremental
>> backup, you take a third snapshot, send the diff of the second and third
>> snapshot, delete the second snapshot.
>>
>> When the backup media starts to fill up, just delete the oldest
>> snapshot. No data is duplicated on the backup media. This is how I do
>> backups and the nice thing is that you can do it between computers too
>> with help of ssh too
>>
>> btrfs send /mnt/send/oldestsnapshot | ssh root@remote-server "btrfs
>> receive /mnt/recv"
> 
> I thought of doing something like that but using rsync.
> I.e.: rsync, snapshot, rsync, ...
> I didn't do it because I needed to write a script for that. It's in my
> agenda, however.
> Does that incremental backup "work" at block level or file level?
> rsync --inplace seems to just update the changed blocks.

The incremental backup with btrfs is on "block level", as the same file 
will occupy the same block regardless of snapshot. The only issue with 
btrfs as I see it today is when you balance a volume, then the blocks 
won't change for the snapshots and you suddenly have duplicated your 
data. I hope they will go back to how it was before.

> In general I have scripts for everything and when things are working I
> tend to be a little conservative :-)

Yeah, if it works don't break :)


> But I really need to look at send/receive as future solution especially
> for backups.

Another thing you can look at is snappy, opensuse's script to make it 
simpler to handle snapshots, don't use it at home, but at work it saves 
me from remembering the btrfs syntax.

-- 

  //Aho

Back to alt.os.linux | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Can crypsetup --type plain destroy a previous written partition? Paulo da Silva <p_s_d_a_s_i_l_v_a_ns@netcabo.pt> - 2019-05-09 21:14 +0100
  Re: Can crypsetup --type plain destroy a previous written partition? "J.O. Aho" <user@example.net> - 2019-05-10 07:02 +0200
    Re: Can crypsetup --type plain destroy a previous written partition? Paulo da Silva <p_s_d_a_s_i_l_v_a_ns@netcabo.pt> - 2019-05-10 16:10 +0100
      Re: Can crypsetup --type plain destroy a previous written partition? "J.O. Aho" <user@example.net> - 2019-05-10 18:43 +0200
        Re: Can crypsetup --type plain destroy a previous written partition? Paulo da Silva <p_s_d_a_s_i_l_v_a_ns@netcabo.pt> - 2019-05-10 17:59 +0100
          Re: Can crypsetup --type plain destroy a previous written partition? "J.O. Aho" <user@example.net> - 2019-05-10 23:52 +0200
            Re: Can crypsetup --type plain destroy a previous written partition? Paulo da Silva <p_s_d_a_s_i_l_v_a_ns@netcabo.pt> - 2019-05-11 04:08 +0100
              Re: Can crypsetup --type plain destroy a previous written partition? "J.O. Aho" <user@example.net> - 2019-05-11 09:40 +0200
                Re: Can crypsetup --type plain destroy a previous written partition? Paulo da Silva <p_s_d_a_s_i_l_v_a_ns@netcabo.pt> - 2019-05-11 18:50 +0100
  Re: Can crypsetup --type plain destroy a previous written partition? [EXLAINED] Paulo da Silva <p_s_d_a_s_i_l_v_a_ns@netcabo.pt> - 2019-05-10 16:00 +0100

csiph-web