Skip to content

Commit

Permalink
remove restic in docs (vmware-tanzu#5499)
Browse files Browse the repository at this point in the history
Signed-off-by: Lyndon-Li <[email protected]>
  • Loading branch information
Lyndon-Li authored Nov 1, 2022
1 parent 76d3321 commit e6ba774
Show file tree
Hide file tree
Showing 22 changed files with 94 additions and 99 deletions.
1 change: 1 addition & 0 deletions changelogs/unreleased/5499-lyndon
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
After Pod Volume Backup/Restore refactor, remove all the unreasonable appearance of "restic" word from documents
4 changes: 2 additions & 2 deletions site/content/docs/main/api-types/backup.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ spec:
# a default value of 30 days will be used. The default can be configured on the velero server
# by passing the flag --default-backup-ttl.
ttl: 24h0m0s
# Whether restic should be used to take a backup of all pod volumes by default.
defaultVolumesToRestic: true
# whether pod volume file system backup should be used for all volumes by default.
defaultVolumesToFsBackup: true
# Actions to perform at different times during a backup. The only hook supported is
# executing a command in a container in a pod using the pod exec API. Optional.
hooks:
Expand Down
4 changes: 2 additions & 2 deletions site/content/docs/main/api-types/schedule.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ spec:
# a default value of 30 days will be used. The default can be configured on the velero server
# by passing the flag --default-backup-ttl.
ttl: 24h0m0s
# Whether restic should be used to take a backup of all pod volumes by default.
defaultVolumesToRestic: true
# whether pod volume file system backup should be used for all volumes by default.
defaultVolumesToFsBackup: true
# The labels you want on backup objects, created from this schedule (instead of copying the labels you have on schedule object itself).
# When this field is set, the labels from the Schedule resource are not copied to the Backup resource.
metadata:
Expand Down
2 changes: 1 addition & 1 deletion site/content/docs/main/basic-install.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Velero supports storage providers for both cloud-provider environments and on-pr

### Velero on Windows

Velero does not officially support Windows. In testing, the Velero team was able to backup stateless Windows applications only. The restic integration and backups of stateful applications or PersistentVolumes were not supported.
Velero does not officially support Windows. In testing, the Velero team was able to backup stateless Windows applications only. The File System Backup and backups of stateful applications or PersistentVolumes were not supported.

If you want to perform your own testing of Velero on Windows, you must deploy Velero as a Windows container. Velero does not provide official Windows images, but its possible for you to build your own Velero Windows container image to use. Note that you must build this image on a Windows node.

Expand Down
2 changes: 1 addition & 1 deletion site/content/docs/main/build-from-source.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ Optionally, set the `$VERSION` environment variable to change the image tag or `
```bash
make container
```
_Note: To build build container images for both `velero` and `velero-restic-restore-helper`, run: `make all-containers`_
_Note: To build build container images for both `velero` and `velero-restore-helper`, run: `make all-containers`_

### Publishing container images to a registry

Expand Down
4 changes: 2 additions & 2 deletions site/content/docs/main/code-standards.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,13 @@ Example:

We use a package to generate mocks for our interfaces.

Example: if you want to change this mock: https://github.com/vmware-tanzu/velero/blob/main/pkg/restic/mocks/restorer.go
Example: if you want to change this mock: https://github.com/vmware-tanzu/velero/blob/main/pkg/podvolume/mocks/restorer.go

Run:

```bash
go get github.com/vektra/mockery/.../
cd pkg/restic
cd pkg/podvolume
mockery -name=Restorer
```

Expand Down
6 changes: 3 additions & 3 deletions site/content/docs/main/contributions/ibm-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,9 +71,9 @@ velero install \

Velero does not have a volume snapshot plugin for IBM Cloud, so creating volume snapshots is disabled.

Additionally, you can specify `--use-restic` to enable [restic support][16], and `--wait` to wait for the deployment to be ready.
Additionally, you can specify `--use-node-agent` to enable [File System Backup][16], and `--wait` to wait for the deployment to be ready.

(Optional) Specify [CPU and memory resource requests and limits][15] for the Velero/restic pods.
(Optional) Specify [CPU and memory resource requests and limits][15] for the Velero/node-agent pods.

Once the installation is complete, remove the default `VolumeSnapshotLocation` that was created by `velero install`, since it's specific to AWS and won't work for IBM Cloud:

Expand All @@ -98,4 +98,4 @@ Uncomment `storageClassName: <YOUR_STORAGE_CLASS_NAME>` and replace with your `S
[5]: https://cloud.ibm.com/docs/containers/container_index.html#container_index
[14]: http://docs.aws.amazon.com/IAM/latest/UserGuide/introduction.html
[15]: ../customize-installation.md#customize-resource-requests-and-limits
[16]: ../restic.md
[16]: ../file-system-backup.md
6 changes: 3 additions & 3 deletions site/content/docs/main/contributions/minio.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ If you encounter issues with installing or configuring, see [Debugging Installat

## Prerequisites

* Access to a Kubernetes cluster, version 1.7 or later. **Note:** restic support requires Kubernetes version 1.10 or later, or an earlier version with the mount propagation feature enabled. Restic support is not required for this example, but may be of interest later. See [Restic Integration][17].
* Access to a Kubernetes cluster, version 1.7 or later. **Note:** File System Backup support requires Kubernetes version 1.10 or later, or an earlier version with the mount propagation feature enabled. File System Backup support is not required for this example, but may be of interest later. See [File System Backup][17].
* A DNS server on the cluster
* `kubectl` installed
* Sufficient disk space to store backups in Minio. You will need sufficient disk space available to handle any
Expand Down Expand Up @@ -83,7 +83,7 @@ These instructions start the Velero server and a Minio instance that is accessib

This example assumes that it is running within a local cluster without a volume provider capable of snapshots, so no `VolumeSnapshotLocation` is created (`--use-volume-snapshots=false`). You may need to update AWS plugin version to one that is [compatible](https://github.com/vmware-tanzu/velero-plugin-for-aws#compatibility) with the version of Velero you are installing.

Additionally, you can specify `--use-restic` to enable restic support, and `--wait` to wait for the deployment to be ready.
Additionally, you can specify `--use-node-agent` to enable File System Backup support, and `--wait` to wait for the deployment to be ready.

This example also assumes you have named your Minio bucket "velero".

Expand Down Expand Up @@ -289,7 +289,7 @@ In this case:
[1]: #expose-minio-with-service-of-type-nodeport
[3]: ../customize-installation.md
[17]: ../restic.md
[17]: ../file-system-backup.md
[18]: ../debugging-restores.md
[26]: https://github.com/vmware-tanzu/velero/releases
[30]: https://godoc.org/github.com/robfig/cron
Expand Down
12 changes: 6 additions & 6 deletions site/content/docs/main/contributions/tencent-config.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,13 +39,13 @@ aws_secret_access_key=<SecretKey>

You need to install the Velero CLI first, see [Install the CLI](https://velero.io/docs/v1.5/basic-install/#install-the-cli) for how to install.

Follow the Velero installation command below to create velero and restic workloads and other necessary resource objects.
Follow the Velero installation command below to create velero and node-agent workloads and other necessary resource objects.

```bash
velero install --provider aws --plugins velero/velero-plugin-for-aws:v1.1.0 --bucket <BucketName> \
--secret-file ./credentials-velero \
--use-restic \
--default-volumes-to-restic \
--use-node-agent \
--default-volumes-to-fs-backup \
--backup-location-config \
region=ap-guangzhou,s3ForcePathStyle="true",s3Url=https://cos.ap-guangzhou.myqcloud.com
```
Expand All @@ -60,9 +60,9 @@ Description of the parameters:

- `--secret-file`: Access tencent cloud COS access credential file for the "credentials-velero" credential file created above.

- `--use-restic`: Back up and restore persistent volume data using the open source free backup tool [restic](https://github.com/restic/restic). However, 'hostPath' volumes are not supported, see the [restic limit](https://velero.io/docs/v1.5/restic/#limitations) for details), an integration that complements Velero's backup capabilities and is recommended to be turned on.
- `--use-node-agent`: Enable Velero node-agent daemonset. At present, Velero File System Backup requires this daemonset, so if you are using File System Backup, it needs to be turned on. For the usage and limitation of File System Backup, See [File System Backup](../file-system-backup.md).

- `--default-volumes-to-restic`: Enable the use of Restic to back up all Pod volumes, provided that the `--use-restic`parameter needs to be turned on.
- `--default-volumes-to-fs-backup`: Enable the use of File System Backup to back up all Pod volumes, provided that the `--use-node-agent`parameter needs to be turned on.

- `--backup-location-config`: Back up the bucket access-related configuration:

Expand All @@ -78,7 +78,7 @@ After executing the installation commands above, the installation process looks

{{< figure src="/docs/main/contributions/img-for-tencent/9015313121ed7987558c88081b052574.png" width="100%">}}

After the installation command is complete, wait for the velero and restic workloads to be ready to see if the configured storage location is available.
After the installation command is complete, wait for the velero and node-agent workloads to be ready to see if the configured storage location is available.

Executing the 'velero backup-location get' command to view the storage location status and display "Available" indicates that access to Tencent Cloud COS is OK, as shown in the following image:

Expand Down
56 changes: 28 additions & 28 deletions site/content/docs/main/customize-installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,17 +17,17 @@ By default, `velero install` expects a credentials file for your `velero` IAM ac

If you are using an alternate identity mechanism, such as kube2iam/kiam on AWS, Workload Identity on GKE, etc., that does not require a credentials file, you can specify the `--no-secret` flag instead of `--secret-file`.

## Enable restic integration
## Enable file system backup

By default, `velero install` does not install Velero's [restic integration][3]. To enable it, specify the `--use-restic` flag.
By default, `velero install` does not install Velero's [File System Backup][3]. To enable it, specify the `--use-node-agent` flag.

If you've already run `velero install` without the `--use-restic` flag, you can run the same command again, including the `--use-restic` flag, to add the restic integration to your existing install.
If you've already run `velero install` without the `--use-node-agent` flag, you can run the same command again, including the `--use-node-agent` flag, to add the file system backup to your existing install.

## Default Pod Volume backup to restic
## Default Pod Volume backup to file system backup

By default, `velero install` does not enable the use of restic to take backups of all pod volumes. You must apply an [annotation](restic.md/#using-opt-in-pod-volume-backup) to every pod which contains volumes for Velero to use restic for the backup.
By default, `velero install` does not enable the use of File System Backup (FSB) to take backups of all pod volumes. You must apply an [annotation](file-system-backup.md/#using-opt-in-pod-volume-backup) to every pod which contains volumes for Velero to use FSB for the backup.

If you are planning to only use restic for volume backups, you can run the `velero install` command with the `--default-volumes-to-restic` flag. This will default all pod volumes backups to use restic without having to apply annotations to pods. Note that when this flag is set during install, Velero will always try to use restic to perform the backup, even want an individual backup to use volume snapshots, by setting the `--snapshot-volumes` flag in the `backup create` command. Alternatively, you can set the `--default-volumes-to-restic` on an individual backup to to make sure Velero uses Restic for each volume being backed up.
If you are planning to only use FSB for volume backups, you can run the `velero install` command with the `--default-volumes-to-fs-backup` flag. This will default all pod volumes backups to use FSB without having to apply annotations to pods. Note that when this flag is set during install, Velero will always try to use FSB to perform the backup, even want an individual backup to use volume snapshots, by setting the `--snapshot-volumes` flag in the `backup create` command. Alternatively, you can set the `--default-volumes-to-fs-backup` on an individual backup to to make sure Velero uses FSB for each volume being backed up.

## Enable features

Expand All @@ -43,15 +43,15 @@ velero install --features=EnableCSI

Another example is enabling the support of multiple API group versions, as documented at [- -features=EnableAPIGroupVersions](enable-api-group-versions-feature.md).

Feature flags, passed to `velero install` will be passed to the Velero deployment and also to the `restic` daemon set, if `--use-restic` flag is used.
Feature flags, passed to `velero install` will be passed to the Velero deployment and also to the `node-agent` daemon set, if `--use-node-agent` flag is used.

Similarly, features may be disabled by removing the corresponding feature flags from the `--features` flag.

Enabling and disabling feature flags will require modifying the Velero deployment and also the restic daemonset. This may be done from the CLI by uninstalling and re-installing Velero, or by editing the `deploy/velero` and `daemonset/restic` resources in-cluster.
Enabling and disabling feature flags will require modifying the Velero deployment and also the node-agent daemonset. This may be done from the CLI by uninstalling and re-installing Velero, or by editing the `deploy/velero` and `daemonset/node-agent` resources in-cluster.

```bash
$ kubectl -n velero edit deploy/velero
$ kubectl -n velero edit daemonset/restic
$ kubectl -n velero edit daemonset/node-agent
```

### Enable client side features
Expand Down Expand Up @@ -87,20 +87,20 @@ the config file setting.

## Customize resource requests and limits

At installation, Velero sets default resource requests and limits for the Velero pod and the restic pod, if you using the [restic integration](/docs/main/restic/).
At installation, Velero sets default resource requests and limits for the Velero pod and the node-agent pod, if you using the [File System Backup][3].

{{< table caption="Velero Customize resource requests and limits defaults" >}}
|Setting|Velero pod defaults|restic pod defaults|
|Setting|Velero pod defaults|node-agent pod defaults|
|--- |--- |--- |
|CPU request|500m|500m|
|Memory requests|128Mi|512Mi|
|CPU limit|1000m (1 CPU)|1000m (1 CPU)|
|Memory limit|512Mi|1024Mi|
{{< /table >}}

Depending on the cluster resources, especially if you are using Restic, you may need to increase these defaults. Through testing, the Velero maintainers have found these defaults work well when backing up and restoring 1000 or less resources and total size of files is 100GB or below. If the resources you are planning to backup or restore exceed this, you will need to increase the CPU or memory resources available to Velero. In general, the Velero maintainer's testing found that backup operations needed more CPU & memory resources but were less time-consuming than restore operations, when comparing backing up and restoring the same amount of data. The exact CPU and memory limits you will need depend on the scale of the files and directories of your resources and your hardware. It's recommended that you perform your own testing to find the best resource limits for your clusters and resources.
Depending on the cluster resources, you may need to increase these defaults. Through testing, the Velero maintainers have found these defaults work well when backing up and restoring 1000 or less resources and total size of files is 100GB or below. If the resources you are planning to backup or restore exceed this, you will need to increase the CPU or memory resources available to Velero. In general, the Velero maintainer's testing found that backup operations needed more CPU & memory resources but were less time-consuming than restore operations, when comparing backing up and restoring the same amount of data. The exact CPU and memory limits you will need depend on the scale of the files and directories of your resources and your hardware. It's recommended that you perform your own testing to find the best resource limits for your clusters and resources.

Due to a [known Restic issue](https://github.com/restic/restic/issues/2446), the Restic pod will consume large amounts of memory, especially if you are backing up millions of tiny files and directories. If you are planning to use Restic to backup 100GB of data or more, you will need to increase the resource limits to make sure backups complete successfully.
You may need to increase the resource limits if you are using File System Backup, see the details in [File System Backup][3].

### Install with custom resource requests and limits

Expand All @@ -112,17 +112,17 @@ velero install \
--velero-pod-mem-request <MEMORY_REQUEST> \
--velero-pod-cpu-limit <CPU_LIMIT> \
--velero-pod-mem-limit <MEMORY_LIMIT> \
[--use-restic] \
[--default-volumes-to-restic] \
[--restic-pod-cpu-request <CPU_REQUEST>] \
[--restic-pod-mem-request <MEMORY_REQUEST>] \
[--restic-pod-cpu-limit <CPU_LIMIT>] \
[--restic-pod-mem-limit <MEMORY_LIMIT>]
[--use-node-agent] \
[--default-volumes-to-fs-backup] \
[--node-agent-pod-cpu-request <CPU_REQUEST>] \
[--node-agent-pod-mem-request <MEMORY_REQUEST>] \
[--node-agent-pod-cpu-limit <CPU_LIMIT>] \
[--node-agent-pod-mem-limit <MEMORY_LIMIT>]
```

### Update resource requests and limits after install

After installation you can adjust the resource requests and limits in the Velero Deployment spec or restic DeamonSet spec, if you are using the restic integration.
After installation you can adjust the resource requests and limits in the Velero Deployment spec or node-agent DeamonSet spec, if you are using the File System Backup.

**Velero pod**

Expand All @@ -133,16 +133,16 @@ kubectl patch deployment velero -n velero --patch \
'{"spec":{"template":{"spec":{"containers":[{"name": "velero", "resources": {"limits":{"cpu": "1", "memory": "512Mi"}, "requests": {"cpu": "1", "memory": "128Mi"}}}]}}}}'
```

**restic pod**
**node-agent pod**

Update the `spec.template.spec.containers.resources.limits` and `spec.template.spec.containers.resources.requests` values in the restic DeamonSet spec.
Update the `spec.template.spec.containers.resources.limits` and `spec.template.spec.containers.resources.requests` values in the node-agent DeamonSet spec.

```bash
kubectl patch daemonset restic -n velero --patch \
'{"spec":{"template":{"spec":{"containers":[{"name": "restic", "resources": {"limits":{"cpu": "1", "memory": "1024Mi"}, "requests": {"cpu": "1", "memory": "512Mi"}}}]}}}}'
kubectl patch daemonset node-agent -n velero --patch \
'{"spec":{"template":{"spec":{"containers":[{"name": "node-agent", "resources": {"limits":{"cpu": "1", "memory": "1024Mi"}, "requests": {"cpu": "1", "memory": "512Mi"}}}]}}}}'
```

Additionally, you may want to update the the default Velero restic pod operation timeout (default 240 minutes) to allow larger backups more time to complete. You can adjust this timeout by adding the `- --restic-timeout` argument to the Velero Deployment spec.
Additionally, you may want to update the the default File System Backup operation timeout (default 240 minutes) to allow larger backups more time to complete. You can adjust this timeout by adding the `- --fs-backup-timeout` argument to the Velero Deployment spec.

**NOTE:** Changes made to this timeout value will revert back to the default value if you re-run the Velero install command.

Expand All @@ -152,15 +152,15 @@ Additionally, you may want to update the the default Velero restic pod operation
kubectl edit deploy velero -n velero
```

1. Add `- --restic-timeout` to `spec.template.spec.containers`.
1. Add `- --fs-backup-timeout` to `spec.template.spec.containers`.

```yaml
spec:
template:
spec:
containers:
- args:
- --restic-timeout=240m
- --fs-backup-timeout=240m
```
## Configure more than one storage location for backups or volume snapshots
Expand Down Expand Up @@ -380,7 +380,7 @@ If you get an error like `complete:13: command not found: compdef`, then add the
[1]: https://github.com/vmware-tanzu/velero/releases/latest
[2]: namespace.md
[3]: restic.md
[3]: file-system-backup.md
[4]: on-premises.md
[6]: velero-install.md#usage
[7]: https://github.com/vmware-tanzu/velero/issues/2077
Expand Down
Loading

0 comments on commit e6ba774

Please sign in to comment.