Allow generation with non-updated filters when internet is unreachable
Currently, if a node is broken in a way which doesn't provide internet connectivity, it's impossible to regenerate a pathvector config which requires irr/other database lookups. This is quite frustrating when you're in a situation where a config change is required to restore connectivity.
If there was a cache of the last generated filter config when the node was online, there could be a pathvector generate option to use those filter lists when regenerating the config.
This sounds like a use for config snapshots! Here's how I imagine this might work:
After a successful config generation (passing BIRD config validation), store the pathvector config, the full generated output (/etc/bird/*.conf), and associated metadata (pathvector version, snapshot name/description, etc) in a config snapshot directory.
Add a few new commands to interact with snapshots (they only move files around for convenience, they don't need to do anything intelligent):
- [ ]
pathvector snapshot ls(list snapshot directories and parse metadata for a nice table) - [ ]
pathvector snapshot apply [name/id](rm /etc/bird/.conf && mv /foo/snapshots/example/.conf /etc/bird && birdc conf, then update a reference to where the current snapshot is) - [ ]
pathvector snapshot rename [name](edit metadata file)
I'm preparing a v7 release so this might be able to make it in before then.
Config snapshots are nice, but on occasion I have needed to add an option that has not been in the config before to restore connectivity. This is why I suggested being able to cache filter info as a solution: it allows you any config mutation which doesn't add more filters which depend on external DBs.