You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
Due to name length limits in kubernetes resources, the following resourceNameRegexp rule fails to find all possible machine-states. This causes restores to break for clusters due to empty secrets. Other resources in any regexp rules that search for a resource ending with a specific value are also likely to be affected by this issue.
Create a cluster with a machine pool with names such that the sum of their lengths is >= 39 (a lower number of around 30-35 will likely work but this what I tested)
Create a backup
Tear down the rancher cluster and spin up a new one
Restore the cluster from the backup
The downstream cluster will never become healthy after restore and instead show a waiting for machine <project>/<machine_name> driver config to be saved forever.
The rke.cattle.io/machine-state for that node will show 0 keys
Check the backup tar ball and you will see there are no machine-state secrets in the backup.
Expected behavior
The secrets are properly backed up
Additional context
As shown above, this seems to occur because the backup searchss for secrets to backup by name suffixes, not a label or secret type, which tend to get truncated when the name gets too long but still within allowed limits.
The text was updated successfully, but these errors were encountered:
Rancher Server Setup
Describe the bug
Due to name length limits in kubernetes resources, the following resourceNameRegexp rule fails to find all possible machine-states. This causes restores to break for clusters due to empty secrets. Other resources in any regexp rules that search for a resource ending with a specific value are also likely to be affected by this issue.
To Reproduce
Steps to reproduce the behavior:
waiting for machine <project>/<machine_name> driver config to be saved
forever.Expected behavior
The secrets are properly backed up
Screenshots
Screenshot attached
Console output of secrets with 0 keys
Additional context
As shown above, this seems to occur because the backup searchss for secrets to backup by name suffixes, not a label or secret type, which tend to get truncated when the name gets too long but still within allowed limits.
The text was updated successfully, but these errors were encountered: