automatically get local ip addr