Jump to content

Weird gethostby*.getanswer Error


Recommended Posts

I get this error constantly:

 

unRAID python: gethostby*.getanswer: asked for "htpc.gateway.2wire.net IN AAAA", got type "A"

 

I have no idea what the heck this is or how to fix it. htpc is the name of my, well HTPC (a win7 machine running XBMC). I have a 2wire gateway as my router/modem.

 

Does anybody know what this is all about????

Link to comment

AAAA and A records are DNS-specific records. AAAA is for IPv6 and A for the (old) IPv4.

 

'asked AAAA and got type A' means 'somebody asked for an IPv6 address but instead received an IPv4 address'

Since IPv6 and IPv4 are not compatible, this can be a problem if you only have an IPv6-only system. Fortunatly, almost everything that supports IPv6 also supports IPv4, so it is more a warning, than an error.

 

Also see http://en.wikipedia.org/wiki/AAAA_record

Link to comment

AAAA and A records are DNS-specific records. AAAA is for IPv6 and A for the (old) IPv4.

 

'asked AAAA and got type A' means 'somebody asked for an IPv6 address but instead received an IPv4 address'

Since IPv6 and IPv4 are not compatible, this can be a problem if you only have an IPv6-only system. Fortunatly, almost everything that supports IPv6 also supports IPv4, so it is more a warning, than an error.

 

Also see http://en.wikipedia.org/wiki/AAAA_record

 

Well that's kind of what I thought. But I don't really know WHY I'm getting this error. That being said, I think I resolved it. I changed Sickbeard to use an IP address rather than the machine name for communication. The error has since stopped.

 

Not sure why that fixes things, but don't argue with success I guess...

Link to comment

It comes down to either the DNS server not being configured correctly, or the DNS-record for that address not having correct configuration.

Since you changed it to an IP-address, it doesn't ask the DNS-server to translate the name to an address, and the DNS-server doesn't consult its records or ask another DNS-server for the records. So whatever of the two is happening, is what you're avoiding.

Remember that IP-addresses can change, if domains are moved for example, so if you do get errors, see if the IP-address from that name have changed.

Since it's related to the DNS-server, and you probably aren't running your own, you could always change to another one, or just wait for the dns-record to be corrected by whoever is responsible for that record, if that is the issue.

Link to comment

The problem is your gateway, since you're trying to connect to htpc, but it goes through the gateway (gateway.2wire.net) which isn't an actual internet-website, but your router.

 

Also, you can test if you do have IPv6 and if it is working correctly, by going to the website http://test-ipv6.com/

 

It will run some tests, and tell you if there are any issues, and you can drill down to the results to see more by going 'show info' at the bottom, and then at the bottom 'show technical details' which will show what tests it has run.

 

I don't have IPv6, so for me it shows 10/10 for IPv4 but 0/10 for IPv6. It is possible it will show the same for you, because almost nobody runs Ipv6 yet.

If you do use Ipv6 for your home network, then you do have problems, because your gateway is not handling it correctly, because Ipv4 and Ipv6 are different systems. It's like when you move house, you rent a truck to move your stuff, and when it arrives, you get a car.

 

If you don't want the error in your logs, there's really only three things you can do.

 

One is to use the IP-address and so not ask the gateway anymore

 

Two is to set up your own DNS server. Normally you could go around a bad DNS server like this when the one from your ISP isn't working by setting your own, for example by using the OpenDNS one or Google's or something, but that doesn't help here because it is a local address.

 

Three is to use the hosts-file, which is easiest. Every computer has it, just the location is different. It is used to look up the names before it asks the dns-system.

For example, if your unraid server is called tower and is set to the static IP at 192.168.0.100, you could put in your hosts file '192.168.0.100 tower' in your windows or mac-hosts fileand it would automaticly resolve that and not ask your gateway anymore.

 

So, it would be best to set your htpc to a static IP-address, and then add it to your unraid-hosts-file. Windows can do that, but if you don't want to, as long as you can look it up, that's usually fine, because most of the time, your router will give out the same address to the same computer.

Then, you can add it automaticly to your hosts file when unraid starts, for example if your IP-address to your HTPC is 192.168.0.100 by adding to your 'go' file:

echo 192.168.0.100 htpc >>/etc/hosts

 

and restart your server.

 

After that, since your unraid-server won't ask your gateways DNS anymore, the error will disappear. Or should, at least.

 

If your HTPC IP address does change after adding that, but you don't want to edit your go file and restart your unraid-server, you can also login to it, and edit the /etc/hosts file directly with the new IP-address

 

Link to comment

Yes, pretty much every internet-capable operating system has a hosts-file, including linux which unraid uses.

 

And, the issue is not sickbeard, but your internet standard-defying gateway, so it's not really a solution, but a work-around. Which fixes it for you, so that makes it a solution. (wait... what?)

 

You can edit the hosts file of the unraid computer yourself, but if you restart the unraid computer, those changes are lost. So, it's easiest to let it change it by itsself each time.

 

To do that, edit your 'go' file on the unraid-usb-stick, you'll find it in the 'config' folder.

 

With a new unraid installation, it would have:

 

#!/bin/bash

# Start the Management Utility

/usr/local/sbin/emhttp &

 

For you, it is probably different, because you have other things installed too, so make sure to be careful.

Because we'll want to change stuff like this as soon as possible, we'll make it the first instruction, that way when it gets to the other stuff like sickbeard, it'll work.

 

You'll have to add one line to that file, assuming the  IP-address to your HTPC is 192.168.0.100 you would add to the file below the /bin/bash line

 

echo 192.168.0.100 htpc >>/etc/hosts

 

so it would become something like

 

#!/bin/bash

echo 192.168.0.100 htpc >>/etc/hosts

# Start the Management Utility

/usr/local/sbin/emhttp &

 

Now, every time your server starts, it'll automaticly add the entry to the hosts file, and not give the error anymore.

Don't forget to get the actual IP address from your HTPC and put it where it says 192.168.0.100!

Link to comment
  • 2 weeks later...

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...