# Hostname Lookup Failures

## Enfield

Hello all,

I am having trouble with my connection at the moment - over wifi and direct connection. When I run emerge --sync it will come up with '!!! getaddrinfo failed for 'rsync.uk.gentoo.org': [Errno -2] Name or service not known' but will sync anyway.

Most of the time I can download via portage, but occasionally it will fail to find the server. Also, if I try to browse through konq I get a lot of an 'unknown host' errors. This does not happen at all via chromium which I suspect (perhaps wrongly) that it's because it uses a web service to help resolve navigation errors.

I have tried various different configurations with my hosts and net file with no joy.

My /etc/resolv.conf is as follows:

```
domain home

nameserver 192.168.1.254
```

/etc/hosts

```
127.0.0.1              gaz-pc.home gaz-pc
```

/etc/conf.d/net

```
config_wlp10s1="dhcp"

config_enp12s0="dhcp"
```

Any ideas?

----------

## lexflex

Hi,

What does ifconfig give ?

Also, can you try to resolve a webname from the commandline, for example by using ping google.com ?

Alex.

----------

## Enfield

Hello Good Sir,

I think I may have jinxed myself; Chromium is starting to suffer. Either that or it's these forums.

I can ping www.google.co.uk

```
gaz@gaz-pc ~ $ ping -c3 www.google.co.uk

PING www.google.co.uk (173.194.41.184) 56(84) bytes of data.

64 bytes from lhr08s04-in-f24.1e100.net (173.194.41.184): icmp_seq=1 ttl=52 time=16.9 ms

64 bytes from lhr08s04-in-f24.1e100.net (173.194.41.184): icmp_seq=2 ttl=52 time=17.9 ms

64 bytes from lhr08s04-in-f24.1e100.net (173.194.41.184): icmp_seq=3 ttl=52 time=17.0 ms

--- www.google.co.uk ping statistics ---

3 packets transmitted, 3 received, 0% packet loss, time 2000ms

rtt min/avg/max/mdev = 16.975/17.320/17.977/0.488 ms

```

```
gaz@gaz-pc ~ $ ifconfig

enp12s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500

        ether 00:25:22:cc:c7:c8  txqueuelen 1000  (Ethernet)

        RX packets 0  bytes 0 (0.0 B)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 0  bytes 0 (0.0 B)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

        device interrupt 17  

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536

        inet 127.0.0.1  netmask 255.0.0.0

        inet6 ::1  prefixlen 128  scopeid 0x10<host>

        loop  txqueuelen 0  (Local Loopback)

        RX packets 26  bytes 1612 (1.5 KiB)

        RX errors 0  dropped 0  overruns 0  frame 0

        TX packets 26  bytes 1612 (1.5 KiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wlp10s1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500

        inet 192.168.1.89  netmask 255.255.255.0  broadcast 192.168.1.255

        inet6 fe80::20e:2eff:fee6:4e71  prefixlen 64  scopeid 0x20<link>

        ether 00:0e:2e:e6:4e:71  txqueuelen 1000  (Ethernet)

        RX packets 118859  bytes 160564316 (153.1 MiB)

        RX errors 0  dropped 1474  overruns 0  frame 0

        TX packets 63660  bytes 6945396 (6.6 MiB)

        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
```

----------

## lexflex

I remember having a similar problem myself some months ago. 

I think this link solved it : https://forums.gentoo.org/viewtopic-t-952646-highlight-wget+resolve.html

Basically, if not using IPv6, emerge wget with ipv6 disabled. But the same might hold for other applications...

Alex.

----------

## Enfield

I've just tried emerge --sync again after compiling it without ipv6 support and it still produces the same error.

Could it be anything to do with my kernel?

gaz@gaz-pc ~ $ cat /usr/src/linux/.config | grep "IPV6"

CONFIG_IPV6=y

# CONFIG_IPV6_PRIVACY is not set

# CONFIG_IPV6_ROUTER_PREF is not set

# CONFIG_IPV6_OPTIMISTIC_DAD is not set

# CONFIG_IPV6_MIP6 is not set

CONFIG_IPV6_SIT=y

# CONFIG_IPV6_SIT_6RD is not set

CONFIG_IPV6_NDISC_NODETYPE=y

# CONFIG_IPV6_TUNNEL is not set

# CONFIG_IPV6_GRE is not set

# CONFIG_IPV6_MULTIPLE_TABLES is not set

# CONFIG_IPV6_MROUTE is not set

CONFIG_NF_DEFRAG_IPV6=y

CONFIG_NF_CONNTRACK_IPV6=y

CONFIG_IP6_NF_MATCH_IPV6HEADER=y

I have also noticed that dhcpcd is run like so:

```
/sbin/dhcpcd -h gaz-pc --noipv4ll wlp10s1
```

 could that have anything to do with it? I am running wicd by the way.

----------

