I am executing below unix command.
====================
nc -zv google.com 8015
Ncat: version ..
Ncat: Connected to 10.20.43.84:805
I wanted to read the output string “Connected” from the output printed.
I tried nc -zv google.com 8015 >> file.txt
BUT not able to read.please help me how to read the output of the nc command mentioned above