I’m trying to stream a device log over SSH while saving to file on my local machine for long running tests or debug sessions. My feeling is this will avoid filling up the RAM on the target module with log files.
I have tried the command ssh root@192.168.2.2 logread -f | tee <filename> | grep <search value>
and I keep getting 'sh: logread: not found`
Is there a better way to do this?