'Failed looking up Host'

You can get help here if Freeciv doesn't start on your computer, or if you keep getting fatal errors while playing etc.
Post Reply
OndePyrat
Posts: 2
Joined: Wed May 22, 2013 8:19 pm

'Failed looking up Host'

Post by OndePyrat »

Hey all,

I've been trying to run a game for my friends and I to play on that I can hopefully save, and I'm having troubles setting up a server. I'm on windows and I've been launching it like this "freeciv-server -meta" via CMD and it shows up on LAN games and the metaserver but nobody can join it, it keeps saying 'Failed looking up host'. I've even tried portforwarding and making sure that it was working by using canyouseeme.org while the server was running and it said that it was allowing connection. I need help!
User avatar
JTN
Elite
Posts: 473
Joined: Wed Jan 30, 2013 12:15 am

Re: 'Failed looking up Host'

Post by JTN »

Guess: perhaps the reverse DNS for your IP address is broken?

The server you're running sends its idea of its own hostname to the metaserver. It looks like the metaserver does a name->IP DNS lookup, and if the resulting IP address is not the one the metaserver saw the message come from (or lookup fails), then the metaserver ignores your server's specified hostname and does an IP->name lookup, and publishes that name. (And if you're on a home Internet connection, your server's idea of its own hostname is probably wrong in this way.)

If your ISP has messed things up so that your IP->name lookup results in a name that doesn't then resolve to your IP address (or to anything...) then I guess people will see the symptoms you describe.

The canyouseeme.org site you mentioned connects to you by IP address, so bypasses all of this.

You can override the hostname that will be sent to the metaserver explicitly with the --identity option to the server. If you can find a hostname that resolves to your IP address (or make one by using a dynamic DNS service), you can specify that and maybe things will work better. Let us know.
(BTW, "-meta" isn't quite the right syntax; you should use "--meta" or just "-m". However, it seems to work.)

I could try and check the specifics of your IP address / hostname; if you don't want to publish it here, PM me.

(The metaserver arrangements aren't as good as they could be at diagnosing the various sorts of problems that are typical when hosting a server on today's Internet; the FAQ covers some of these, although it looks like you got over the NAT hurdle, which is the usual one.)
cazfi
Elite
Posts: 3077
Joined: Tue Jan 29, 2013 6:54 pm

Re: 'Failed looking up Host'

Post by cazfi »

JTN wrote:The canyouseeme.org site you mentioned connects to you by IP address, so bypasses all of this.
You could test bypassing making the game publicly known in metaserver, and try to connect directly with the IP address.

--identity should accept numeric IP address too as parameter.
OndePyrat
Posts: 2
Joined: Wed May 22, 2013 8:19 pm

Re: 'Failed looking up Host'

Post by OndePyrat »

JTN wrote: You can override the hostname that will be sent to the metaserver explicitly with the --identity option to the server. If you can find a hostname that resolves to your IP address (or make one by using a dynamic DNS service), you can specify that and maybe things will work better. Let us know.
(BTW, "-meta" isn't quite the right syntax; you should use "--meta" or just "-m". However, it seems to work.)
I changed the hostname/identity to my IP address like you said and it worked perfectly. I have yet to test a game still when I have my friends available. Thank you so much! I also figured out how to create a simple batch file that would automatically launch the server for me rather than manually typing in the commands to get to the install folder and launch it with the right parameters.
amptcat
Posts: 1
Joined: Wed Apr 22, 2015 12:02 am

Re: 'Failed looking up Host'

Post by amptcat »

How exactly do I change my host name?
Post Reply