Fixed missing parens, full pathname for subprocess, wrong config dir info; replaced int-based ip generation code with socket-primative-based approach