handshake sends client version
fix mkdir bug with existing dir
use real client
improve output
Allow logging to stderr