cut command seems not to work in a pipe
Every space counts towards the field number, even leading and consecutive ones. Hence, you need to use -f9
instead of -f2
. Alternatively, you can use awk '{ print $2 }'
in place of the cut command entirely.