'connectToMaster()' listen to socket