Hi all,
Firstly, thanks for all the forum posts where people explained how to use SD Cards for logging. I now have this set up and logging away on a CCR1009.
[admin@gw1.mil1] > /system logging export
# may/24/2016 12:18:58 by RouterOS 6.35.2
# software id = MFHS-RP2M
#
/system logging action
set 1 disk-file-count=5 disk-file-name=badgerlog
add comment="SD card NAT logging" disk-file-count=64 disk-file-name=/disk1/newlog disk-lines-per-file=2048 name=microSD target=disk
/system logging
add action=microSD topics=firewall
Unfortunately I can’t view these logs without SFTP or Winbox. Can anyone suggest how to view SD Card logs using the CLI?
It looks like you could use
/log print follow file=<filename>
to print the file, but instead that exports the memory logs to that file.
Using the CLI is my preferred option (there are jump servers in the way, limiting ports to ssh only) so if anyone knows please put me out of my misery.
Update:
When I reached the end of the CGNAT RFC 7422 guide http://wiki.mikrotik.com/wiki/Manual:IP/Firewall/NAT#Carrier-Grade_NAT_.28CGNAT.29_or_NAT444 I realised the whole point is that I don’t need any src NAT logging because the source ports are deterministic. Duh ![]()
Note: source NAT logging records the source port prior to NAT and port modification, rather than after NATting. This means it wouldn’t log anything useful for RFC 7422.
Thanks
Ben
Love Hz | http://love-hz.com