Page MenuHomeVyOS Platform

Uncaught configtree error allows ntp migration 1-to-2 to fail silentlly on config.boot.default
Closed, ResolvedPublicBUG

Description

On a fresh installation of 1.4, the migration script ntp/1-to-2 will fail silently; consequently, the setting for ['system', 'ntp'] in config.boot.default will not be migrated to ['service', 'ntp'] and will be dropped during boot-config. The root cause is a subtle point in config.copy + an unreported error in configtree (vytree).
(1) configtree.py copy will not recursively create a non-existent path. In this case, config.boot.default has no path ['service']
(2) the binding copy_node of libvyosconfig does not catch the error raised in vyos1x-config, hence it is not reported in configtree.py

Both (1) and (2) are easy fixes: (1) will be addressed immediately by adding a check/set to the migration script to add the path ['service']; (2) will be tested before adding.

One can consider the more general question of a recursive copy in vyos1x-config, though evaluation is needed.

Details

Difficulty level
Easy (less than an hour)
Version
vyos-1.4
Why the issue appeared?
Will be filled on close
Is it a breaking change?
Perfectly compatible
Issue type
Bug (incorrect behavior)

Event Timeline

jestabro created this task.
jestabro created this object in space S1 VyOS Public.
jestabro lowered the priority of this task from High to Normal.EditedJan 26 2023, 7:39 PM

migration script modified in current; lower task priority to test error reporting from libvyoconfig.

jestabro moved this task from Need Triage to Finished on the VyOS 1.4 Sagitta board.