checking connection between remote n origin