-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Add more user-friendly log messages on map creation #15629
Comments
If we recreate maps, then we lose the contents. In this case, it's the metrics map so not a big deal if it's gone, but other maps, this might be a more sensitive situation. So it might make sense to make the metrics map not fatal on this error, but others probably keep the fatal. |
When does this happen? On upgrade from v1.9 to master? Why didn't the K8sUpdates test catch it? |
IIRC was when switching the |
There is small window of commits (after the switch to |
If that's all there is to it, maybe we can just delete the map when it happens? I doubt it's worth a full map migration. |
Not sure what you are referring to 🤔 |
I thought I saw that discussed as a potential solution last time we discussed it on Slack, but can't find it again 😞 |
Ah, I think I know what you are referring to now 👍 (different issue 🙂) |
This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com>
This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com>
This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com>
This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com>
This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com>
[ upstream commit f56cc5c ] This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com> Signed-off-by: Martynas Pumputis <m@lambda.lt>
[ upstream commit f56cc5c ] This commit updates the OpenOrCreate() method of the ebpf package to gracefully handle the case of a pinned map that is incompatible with the map's spec passed to the method. Rather than just returning the error returned by NewMapWithOptions(), we now log a warning and try to delete and recreate the pinned map. This mimics the behaviour of the old OpenOrCreate() method of the bpf package. Fixes: #15629 Signed-off-by: Gilberto Bertin <gilberto@isovalent.com> Signed-off-by: Martynas Pumputis <m@lambda.lt>
From Joe:
There is a cilium_metrics map already with flags configured with the value 0, looks like on startup the daemon attempted to reuse the map but since the flags value was different from what it expected the flags to be (1), it took exception to this and failed out.
Fataling out here seems like a bit extreme, normally I would expect such maps just to be recreated with the new map flags and log a big angry warning
The text was updated successfully, but these errors were encountered: