"drum(dot)lucas(at)gmail(dot)com" <drum(dot)lucas(at)gmail(dot)com> writes:
> I'm doing a copy (pg_dump) from a slave server to a test server.
> The DB size is 1,7 TB, and I get the error at 1,4 TB.
Since you're using ssh, I wonder if this is a renegotiation problem.
Try changing your sshd configuration to disable renegotiation.
regards, tom lane