added ip lookup and safe rm