init, initRemote refactored