Remote deferred deletion

The remote bridge could be registered with remote deferred deletion enabled. This feature will enable a user in Cluster A to unexport and set remote snapshots for deferred deletion in Cluster B.

Note

This feature is available for both multi-cluster and multi-site configurations. Note that the minimumDeleteDelay flag (see Minimum deletion delay) is per bridge, not per location. Thus, all bridges to a remote location should be (re)registered with the setting.

Example

Here is an example for the case without deferred deletion enabled:

  • Cluster_A and Cluster_B are two StorPool clusters in locations A and B connected with a bridge.

  • A volume named volume1 in Cluster_A has two backup snapshots in Cluster_B called volume1@281 and volume1@294.

digraph G {
  graph [nodesep=0.5, ranksep=1]
  rankdir=LR;
  compound=true;
  image=svg;
  subgraph cluster_a {
    style=filled;
    color=lightgrey;
    node [
        style=filled,
        color=white,
        shape=square,
        label="Bridge A",
    ];
    bridge0;
    node [
        shape=rectangle,
    ]
    v1 [label=volume1]
    {rank=same; bridge0 v1}
    label = "Cluster A";
  }

  subgraph cluster_b {
    style=filled;
    color=grey;
    node [
        style=filled,
        color=white,
        shape=square,
        label="Bridge B"
    ];
    bridge1;
    node [
        shape=circle,
    ]
    v1s [label="volume1@281"]
    v2s [label="volume1@294"]
    v1s -> v2s [dir=back]
    {rank=same; bridge1 v1s v2s}
    label = "Cluster B";
  }
  bridge0 -> bridge1 [color="red", lhead=cluster_b, ltail=cluster_a];
  bridge1 -> bridge0 [color="blue", lhead=cluster_a, ltail=cluster_b];
}

The remote snapshots could be unexported from Cluster_A with the deleteAfter flag, but it will be silently ignored in Cluster_B.

Procedure

To enable remote deferred deletion, the following steps would have to be completed in the remote bridge for Cluster_A:

  1. The bridge in Cluster_A should be registered with minimumDeleteDelay in Cluster_B.

  2. Deferred snapshot deletion should be enabled in Cluster_B; for details, see Management configuration.

This will enable setting up the deleteAfter parameter on an unexport operation in Cluster_B initiated from Cluster_A.

With the above example volume and remote snapshots, a user in Cluster_A could unexport the volume1@294 snapshot and set its deleteAfter flag to 7 days from the unexport with:

user@hostA # storpool snapshot remote location_b locationAId.aId.q unexport deleteAfter 7d
OK

After the completion of this operation the following events will occur:

  1. The volume1@294 snapshot will immediately stop being visible in Cluster_A.

  2. The snapshot will get a deleteAfter flag with timestamp a week from the time of the unexport call.

  3. A week later the snapshot will be deleted, however only if deferred snapshot deletion is still turned on.