How can I know if netcat & dd are working?

Send the dd process a USR1 signal:

$ dd if=/dev/urandom of=/dev/null &
[1] 977
$
$ kill -USR1 977
274647+0 records in
274646+0 records out
140618752 bytes (141 MB) copied, 17.3286 s, 8.1 MB/s
$

¿have you tried pv? http://www.ivarch.com/programs/pv.shtml

dd bs=16M if=/dev/sda|bzip2 -c| pv | nc serverB.example.net 19000
nc -l -p 19000| pv | bzip2 -d| dd bs=16M of=/dev/sdb

good luck!


Find the PID of the process that you want to check the I/O for in your case the dd on server b would be a good place to look then

cat /proc/<PID>/io

look at the value for wchar which should be the bytes written value.

For future reference you can insert pv into one (or both) of the pipes and it will tell you how much data has passed through it.

dd bs=16M if=/dev/sda|bzip2 -c|pv|nc serverB.example.net 19000
225MB 0:04:48 [ 799kB/s] [                    <=>                            ]