Configuration corrupted after force reboot/shutdown after the saving.
To reproduce
echo 1 | sudo tee /proc/sys/kernel/sysrq set protocols static route 192.0.2.5/32 blackhole commit
Add script:
cat /config/scripts/myscript.sh #!/bin/vbash source /opt/vyatta/etc/functions/script-template configure delete protocols static route 192.0.2.5/32 commit set protocols static route 192.0.2.5/32 dhcp-interface eth2 commit save exit
Execute the script, waiting for the message Saving configuration to '/config/config.boot'...Done
And immediately force reboot of powercut the instance
vyos@r15-left# sudo sg vyattacfg -c /config/scripts/myscript.sh Saving configuration to '/config/config.boot'... Done [edit] vyos@r15-left# echo b | sudo tee /proc/sysrq-trigger b
After the reboot the configuration is corrupted
The configuration after the reboot:
vyos@r15-left:~$ cat /config/config.boot system { conntrack { modules { tftp { } sqlnet { } sip { } pptp { } nfs { } h323 { } ftp { } } } config-management { commit-revisions "200" } } interfaces { ethernet eth0 { hw-id 52:54:00:44:35:57 } ethernet eth1 { hw-id 52:54:00:2f:77:99 } ethernet eth2 { hw-id 52:54:00:8b:59:41 } } vyos@r15-left:~$
Reproduced on VM and baremetal server.