Sample Header Ad - 728x90

Exclude the output from ssh and only log the error if found

0 votes
2 answers
2080 views
typeset -f | sshpass -e ssh -o StrictHostKeyChecking=no user@${IPADDRESS} " $(cat); IFERROR=$(checkscript); echo "$IFERROR"" > ${SSHTEMPFILE} 2>&1 This line...I can't exclude the "user authorized" message from the ssh...IFERROR returns the values I need to track, but also, the "!!! AUTHORIZED USE ONLY !!!" horrible message from the ssh... Already tried something like this, but its not working: typeset -f | sshpass -e ssh -o StrictHostKeyChecking=no user@${IPADDRESS} " $(cat); IFERROR=$(checkscript); echo "$IFERROR"" | grep -v "AUTHORIZED" > ${SSHTEMPFILE} 2>&1
Asked by Vianymoon (1 rep)
Apr 21, 2015, 07:24 PM
Last activity: Mar 28, 2025, 09:01 PM