-
Notifications
You must be signed in to change notification settings - Fork 10
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
Loading startup-config shows OK despite error detected #429
Comments
Initial analysis shows that The documentation states:
We understand this, and agree that it's too late to deny any changes, yet we firmly believe that calling A patch to sysrepo has been added to the v2.2.105-kkit branch of sysrepo in kernelkit/sysrepo@49b5580. This will be included in the next patch release of Infix, v24.04.2. |
This local patch of sysrepo adds support for detecting non-zero return code from sysrepo callbacks during SR_EV_DONE, which upstream sysrepo currently, as of v2.2.105, discards. With this change failure to load startup-config results in the system detecting the failure applying failure-config instead. Fixes #429 Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
With the sysrepo patch from the previous commit, we can now properly detect if a callback failed to apply its changes in SR_EV_DONE. When this occurs the system may be in an undefined state, so we must try to recover it before loading failure-config. This patch tries to perform a factory-default RPC, which is an Infix specifc RPC that does "copy factory-config running-config". We give sysrepocfg some time to clean up any stale SHM connections before we do a hard scratch of the db state and restart sysrepo-plugind. Fixes #429 Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
This local patch of sysrepo adds support for detecting non-zero return code from sysrepo callbacks during SR_EV_DONE, which upstream sysrepo currently, as of v2.2.105, discards. With this change failure to load startup-config results in the system detecting the failure applying failure-config instead. Fixes #429 Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
With the sysrepo patch from the previous commit, we can now properly detect if a callback failed to apply its changes in SR_EV_DONE. When this occurs the system may be in an undefined state, so we must try to recover it before loading failure-config. This patch tries to perform a factory-default RPC, which is an Infix specifc RPC that does "copy factory-config running-config". We give sysrepocfg some time to clean up any stale SHM connections before we do a hard scratch of the db state and restart sysrepo-plugind. Fixes #429 Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
With the sysrepo patch from the previous commit, we can now properly detect if a callback failed to apply its changes in SR_EV_DONE. When this occurs the system may be in an undefined state, so we must try to recover it before loading failure-config. This patch tries to perform a factory-default RPC, which is an Infix specifc RPC that does "copy factory-config running-config". We give sysrepocfg some time to clean up any stale SHM connections before we do a hard scratch of the db state and restart sysrepo-plugind. Fixes #429 Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
While debugging issue #428 the root cause turned out to be a system error which was not reported back to the console while loading
startup-config
.The expected output:
The text was updated successfully, but these errors were encountered: