If a new machine is brought into the Windows domain, it automatically registers itself in the DNS server so that we can call it by name rather than the IP address. I was connecting one PC to my office domain but it was not registering itself in the DNS Server. I checked if the network connection was set to automatically register in the DNS or not. The option was checked but still it was not updating in the DNS records.
When I issued the command ipconfig /registerdns to manually register the name of the computer in the DNS server, it gave me the RPC Server unavailable error. I never got to the root of the problem but fixed it by selecting Automatically obtain an IP address through the DHCP server. Once the DNS entry was created, I assigned the IP address manually again.
If anybody has a better solution for this problem or knows the reason of this error, kindly share with us in comments.