try { Registry ourRegistry = LocateRegistry.createRegistry(OUR_PORT); Registry preexistingRegistry = LocateRegistry.getRegistry(1099); preexistingRegistry.rebind("secondary registry", ourRegistry); } catch (RemoteException ignored) { }