throw exception if socket not found