Lost connections to host after changing host name
I'm in the process of updating my computer hardware. I used a temporary host name while setting up the new computer. I then shut down the old computer and renamed the new computer to the old computers name. Now my main application doesn't work. The application is saying:
"The connection was refused when attempting to contact <host ip address>"
Renaming the computer also broke ssh. When logging in from a remote system a message indicated the possibility of a man-in-the-middle attack and aborted the connection. I finally got ssh to work as follows. From a remote system I logged into the new computer using another user's account who had never connected to the old computer. Logging in this way caused caused ssh key initialization to occur. That created a new key in the users known_hosts(?) file. I then coped that key into my own known_hosts file. That fixed that problem, at least for me. But the main application on the new computer still doesn't work.
I can also no longer use xdm from another host into the new computer. Also I can't telnet into the new computer either (please, no lecture about telnet I'm on an internal network). Anyway, there's apparently something on the new host that's blocking connections. I don't know what it is.