After building ONL, there are 2 installer files available in these directories (example for AMD64 arch, Debian 9):
~/OpenNetworkLinux/builds/amd64/installer/installed/builds/stretch -> installer that burns rootFS to flash (installed installer)
~/OpenNetworkLinux/builds/amd64/installer/swi/builds/stretch -> installer that uses overlay for rootFS ( swi installer)
Or more generic
~/OpenNetworkLinux/builds/<arch>/installer/installed/builds/<deb version>
~/OpenNetworkLinux/builds/<arch>/installer/swi/builds/<deb version>
"
To discard the changes when reboot machine
" you need to install the 'swi installer'. The installer file is named something like:
ONL-. . ._SWI_INSTALLER
Follow
https://opennetlinux.org/doc-deploy-amd.html to install *SWI_INSTALLER from ONIE.
Thanks,
Diego