Short answer: check if you're connecting with the wrong network alias through SSMS
For example, your server might accessible as both:
- MyDataServer
- MyDataServer.Company.Com
When a replication publication/subscription is created it gets associated with the name used to connect to the server at the time, if you connect using the different alias or fully qualified name it gives you the error stated on the question.
Details:
I just ran into this, the answers about changing the @@servername helped me understand the issue, but I didn't have to do that.
Consider this:
The sql server box was setup as {my_system_name}.local.domain
In our network we have a network alias such that {my_system_alias} allows us to reach the server and avoiding having to enter the fully qualified domain name (FQDN).
Sql Server was installed and also a local replication publication was set up while being connected using the {my_system_alias} name.
I then connected to the server using SSMS specifying the FQDN, if I right click on properties for this existing Replication -> Local Publication I get the error: "Sql Server replication requires the actual server name".
All I had to do: reconnect to the server in SSMS using the alias (or the other way around) and it will allow me to see the Replication Publication details.
PS: Phill's comment in another answer is also an alternative, making a hosts file entry that matches the name you need to use for the connection.