2

I have the following values set to my velero configuration that was installed using helm.

    schedules:
      my-schedule:
        schedule: "5 * * * *"
        template:
          includeClusterResources: true
          includedNamespaces:
          - jenkins
          includedResources:
          - 'pvcs'
          storageLocation: backups
          snapshotVolumes: true
          ttl: 24h0m0s

I had a PVC (and an underlying PV that had been dynamically provisioned) which I manually deleted (alongside with the PV).

I then performed a velero restore (pointing to a backup taken prior to PV/PVC deletions of course) as in:

velero restore create --from-backup velero-hourly-backup-20201119140005 --include-resources persistentvolumeclaims -n extra-services

extra-services is the namespace where velero is deployed btw.

Although the logs indicate the restore was successful:

▶ velero restore logs velero-hourly-backup-20201119140005-20201119183805 -n extra-services
time="2020-11-19T16:38:06Z" level=info msg="starting restore" logSource="pkg/controller/restore_controller.go:467" restore=extra-services/velero-hourly-backup-20201119140005-20201119183805
time="2020-11-19T16:38:06Z" level=info msg="Starting restore of backup extra-services/velero-hourly-backup-20201119140005" logSource="pkg/restore/restore.go:363" restore=extra-services/velero-hourly-backup-20201119140005-20201119183805
time="2020-11-19T16:38:06Z" level=info msg="restore completed" logSource="pkg/controller/restore_controller.go:482" restore=extra-services/velero-hourly-backup-20201119140005-20201119183805

I see the following error in the restore description:

Name:         velero-hourly-backup-20201119140005-20201119183805
Namespace:    extra-services
Labels:       <none>
Annotations:  <none>

Phase:  PartiallyFailed (run 'velero restore logs velero-hourly-backup-20201119140005-20201119183805' for more information)

Started:    2020-11-19 18:38:05 +0200 EET
Completed:  2020-11-19 18:38:07 +0200 EET

Errors:
  Velero:   error parsing backup contents: directory "resources" does not exist
  Cluster:    <none>
  Namespaces: <none>

Backup:  velero-hourly-backup-20201119140005

Namespaces:
  Included:  all namespaces found in the backup
  Excluded:  <none>

Resources:
  Included:        persistentvolumeclaims
  Excluded:        nodes, events, events.events.k8s.io, backups.velero.io, restores.velero.io, resticrepositories.velero.io
  Cluster-scoped:  auto

Namespace mappings:  <none>

Label selector:  <none>

Restore PVs:  auto

Any ideas?

Does this having to do with me deleting PV/PVC? (after all I tried to simulate a disaster situation)

I have both backupsEnabled and snapshotsEnabled set to true.

pkaramol
  • 16,451
  • 43
  • 149
  • 324

0 Answers0