Update TCP port number and fix mysql check
Small rewrite directory creation
resolved merge conflict