Hi guys - I currently run a command that outputs to a file. I am wondering how to append to the same file if i run a specific command from a different machine? For exam:
grep -i 'SBT' test.txt > myfile.txt
If i run the same grep from a different machine, I would like myfile.txt not to get overwritten but appended with new results..
grep -i 'SBT' test.txt >> myfile.txt
Could you tell me, for instance, what command is used if 'myfile.txt' is on a different machine?
both machines are on same network.
The easiest way would be to share directory that contains myfile.txt on remote machine over NFS, then mount it on the machine that you want to execute grep.
I am not allowed/permissioned to share directories..
Is there a way to run a command that would put the results in a file on a different machine?
Thanks