Warning after restoring relay keys

I reinstalled two relays and restored the key files “ed25519_master_id_secret_key” and “secret_id_key”. The relays seem to be restored and the original fingerprint is displayed, but I get the following warning:

*http status 400 (“Looks like your keypair has changed? This authority previously recorded a different RSA identity for this Ed25519 identity (or vice versa.) Did you replace or copy some of your key files, but not the others? You should either restore the expected keypair, or delete your keys and restart Tor to start your relay with a new identity.”) response from dirserver . Please correct

Are there other files needed to restore the relay? I followed this guide I want to upgrade/move my relay. How do I keep the same key? | Tor Project | Support

1 Like

I’ve done this twice recently, and each time I’ve just copied across the entire “keys” directory to the new relay. After making sure the permisions and owner was correct I didn’t have any problems starting up the relay. I’m not 100% sure if all files are needed, but it sounds like more are needed than what’s described in that guide.

Perhaps someone with more experience can provide further details.

1 Like

I’ve done this multiple times and I have always just copied the whole data directory over to the new machine.

2 Likes

I just restored a relay with only these two files that are mentioned in the instructions and it worked.

1 Like

I had the same issue after re-installing Ubuntu on my VPS.
I think it occurred because I tried to restore the old keys before my tor installation had a chance to talk to the tor network / servers…?

The error occurred when I did the following:

  • installed tor
  • set: “ORPort 9001 IPv4Only” in my torrc
  • forgot to open port 9001 in UFW
  • restored the keys
  • restarted tor
  • realised I forgot to open port 9001
  • opened it and restarted tor again
  • see the mentioned error: "*http status 400 (“Looks like your keypair has changed? "

To fix:

  • uninstalled tor
  • opened port 9001 in UFW
  • reinstalled tor, gave it a few minutes
  • set: “ORPort 9001 IPv4Only” in my torrc (with the same Nickname and ContactInfo as my old installation)
  • re started tor, gave it a few minutes
  • restored the 2 keys as mentioned
  • restarted tor

fixed

1 Like