tee read stdin and write stdout | telnet localhost 999 2>&1 | tee -a log
[root@localhost tmp]# telnet localhost 999 2>&1 | tee -a log
telnet: connect to address ::1: Connection refused
telnet: connect to address 127.0.0.1: Connection refused
Trying ::1...
Trying 127.0.0.1...
[root@localhost tmp]# cat log
telnet: connect to address ::1: Connection refused
telnet: connect to address 127.0.0.1: Connection refused
Trying ::1...
Trying 127.0.0.1...
telnet: connect to address ::1: Connection refused
telnet: connect to address 127.0.0.1: Connection refused
Trying ::1...
Trying 127.0.0.1...
[root@localhost tmp]# cat log
telnet: connect to address ::1: Connection refused
telnet: connect to address 127.0.0.1: Connection refused
Trying ::1...
Trying 127.0.0.1...
Comments
Post a Comment