I'd like an automated way of backing up my configuration file *only* when it has changed. I was planning on doing that with the md5sum command. However, it appears that the compiled version included in the latest Shibby build doesn't provide any ability outside of creating checksums. I validated on the BusyBox site that the md5sum command should support a -c option for checking hashes, and it does indeed work as expected on my centos and ubuntu environments, but not on the RT-AC66U w/ Shibby 121.
root@funkmato:/cifs1# md5sum 20140717_1344.cfg >20140717_1344.cfg.md5 root@funkmato:/cifs1# md5sum -c 20140717_1344.cfg.md5 md5sum: can't open '-c': No such file or directory 935c24bc17a770b3cc56728298b015e6 20140717_1344.cfg.md5 root@funkmato:/cifs1# md5sum --help BusyBox v1.21.1 (2014-07-09 13:23:23 CEST) multi-call binary. Usage: md5sum [FILE]... Print MD5 checksums root@funkmato:/cifs1#
and on the ubuntu box…
sfunk1x@sfunk1x-desktop:/media/sfunk1x/BackupDisk1/router_save$ md5sum -c 20140717_1344.cfg.md5 20140717_1344.cfg: OK sfunk1x@sfunk1x-desktop:/media/sfunk1x/BackupDisk1/router_save$
I'm guessing that this was intentional behavior, and the checking code made md5sum too large a command to include in the distro? Or was this unintentional? I realize the md5sum code is also most likely not exactly the same (different distros), but I'm basing my assumptions on the BusyBox documentation as far as expected functionality.
Either way, I can work around this by using netcat outside of the router - if hashing the configs, checking for dupes then saving actually makes practical sense. I know it's probably overkill, but I'm weird and in this instance, I think it would be better to have only the changed configs saved rather than just a bunch of identical config files.