Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Restic doesn't work with schedule #488

Closed
AlwaySummit opened this issue Aug 7, 2023 · 3 comments
Closed

Restic doesn't work with schedule #488

AlwaySummit opened this issue Aug 7, 2023 · 3 comments
Labels

Comments

@AlwaySummit
Copy link

What steps did you take and what happened:
Create a schedule with defaultVolumesToFsBackup enabled and manually trigger a backup from the schedule.
/velero backup create --from-schedule velero-backup-metering
It turns out no restic backup triggered but only velero-native snapshots:
Velero-Native Snapshots: 1 of 1 snapshots completed successfully (specify --details for more information)

What did you expect to happen:
This is the output with /velero backup create test807-2 --default-volumes-to-fs-backup

restic Backups (specify --details for more information):
  Completed:  20

And everything looks fine. I would expect the same result when creating backup from schedule.

The output of the following commands will help us better understand what's going on:
This is the description of the backup from schedule:

Phase:  Completed


Namespaces:
  Included:  *
  Excluded:  kube-system, kube-public, kube-node-lease, velero-restore-test, velero

Resources:
  Included:        pv, pvc
  Excluded:        <none>
  Cluster-scoped:  auto

Label selector:  k8s-app in (metering)

Storage Location:  default

Velero-Native Snapshot PVs:  auto

TTL:  48h0m0s

CSISnapshotTimeout:    10m0s
ItemOperationTimeout:  1h0m0s

Hooks:  <none>

Backup Format Version:  1.1.0

Started:    2023-08-07 08:08:18 +0000 UTC
Completed:  2023-08-07 08:09:04 +0000 UTC

Expiration:  2023-08-09 08:08:18 +0000 UTC

Velero-Native Snapshots:  1 of 1 snapshots completed successfully (specify --details for more information)

Anything else you would like to add:
The schedule is:

spec:
  schedule: 0 0 * * *
  template:
    defaultVolumesToFsBackup: true
    excludedNamespaces:
    - kube-system
    - kube-public
    - kube-node-lease
    - velero-restore-test
    - velero
    hooks: {}
    includedNamespaces:
    - '*'
    includedResources:
    - pv
    - pvc
    labelSelector:
      matchExpressions:
      - key: k8s-app
        operator: In
        values:
        - metering
    ttl: 48h0m0s

Environment:

  • helm version (use helm version): v3.6.3
  • helm chart version and app version (use helm list -n <YOUR NAMESPACE>): non-relevant
  • Kubernetes version (use kubectl version): 1.25.10
  • Kubernetes installer & version: non-relevant
  • Cloud provider or hardware configuration: openstack
  • OS (e.g. from /etc/os-release): Debian GNU/Linux 11 (bullseye)
@AlwaySummit
Copy link
Author

AlwaySummit commented Aug 7, 2023

Feel free to correct me if I put it in wrong repo. Another ticket was created in velero repository. vmware-tanzu/velero#6613 in case.

@AlwaySummit AlwaySummit reopened this Aug 8, 2023
@AlwaySummit
Copy link
Author

AlwaySummit commented Aug 8, 2023

I just happen to find that defaultVolumesToFsBackup is not compatible with

includedResources:
    - pv
    - pvc

After removing includedResources, restic works as expected.
I'm not sure if it's supposed to be like that or just a bug.

@AlwaySummit
Copy link
Author

Already answered in vmware-tanzu/velero#6613.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants