Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

my /etc/resolv.conf use and all 3 dig below answers without a A reocrd

dig @
dig @

but if i ping i end up pinging my server, thats not even at the same ISP as this computer, only connection i know is that this computers hostname is a subdomain of my server.

Where is ping and other softwhere geting the IP adresses from unregistered domains?

some relevant output:

puggan@rito ~ $ uname -a
Linux 2.6.38-gentoo-r6 #2 SMP Thu Jul 14 14:36:14 CEST 2011 i686 AMD Athlon(tm) II X2 245 Processor AuthenticAMD GNU/Linux

puggan@rito ~ $ dig @

; <<>> DiG 9.7.3 <<>> @
; (1 server found)
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NXDOMAIN, id: 8080
;; flags: qr rd ra; QUERY: 1, ANSWER: 0, AUTHORITY: 0, ADDITIONAL: 0

;    IN      A

;; Query time: 0 msec
;; WHEN: Fri Dec  2 15:51:31 2011
;; MSG SIZE  rcvd: 44

puggan@rito ~ $ ping -c 1
PING ( 56(84) bytes of data.
64 bytes from ( icmp_req=1 ttl=52 time=34.4 ms

--- ping statistics ---
1 packets transmitted, 1 received, 0% packet loss, time 0ms
rtt min/avg/max/mdev = 34.406/34.406/34.406/0.000 ms

puggan@rito ~ $ egrep "^(#|$)" -v /etc/resolv.conf
share|improve this question

migrated from Dec 2 '11 at 16:34

This question came from our site for professional and enthusiast programmers.

Anything in /etc/hosts? – Matti Virkkunen Dec 2 '11 at 15:16
nothing relevant: egrep "^(#|$)" -v /etc/hosts localhost ::1 localhost mrzoom-egotripp – Puggan Se Dec 2 '11 at 15:17
Marc B: yes, but dig should be catched to then, as opendns do, if i ran "dig @" i get a false A record – Puggan Se Dec 2 '11 at 15:18
up vote 2 down vote accepted
  1. You are not using fully-qualified domain names;
  2. your domain search path for converting names to FQDNs includes; and
  3. there is a wildcard at * that matches and that has a cname resource record set pointing to

Use fully-qualified domain names if you don't want to use the search path behaviour that you have configured in your DNS client library.

Further reading

share|improve this answer

Some ISPs intercept DNS requests and redirect them to their own, and serve up bad answers (e.g. their own spamvertising sites) in the hopes of making a few pennies off nonexistent/mis-typed domains.

As well, whoever's running the .se TLD can also have a wildcard *.se DNS entry to catch all non-existent .se domain lookups as well. For .se, this seems to be "":

$ nslookup -type=soa

Non-authoritative answer:
        primary name server =
        responsible mail addr =
        serial  = 2004000000
        refresh = 10800 (3 hours)
        retry   = 1800 (30 mins)
        expire  = 1209600 (14 days)
        default TTL = 900 (15 mins)     nameserver =     nameserver =    internet address =    internet address =</strike>

ok... should've picked a way more random/non-existent domain for this particular test. nslookup does return no-such-host.

share|improve this answer
nslookup -type=soa Server: Address: ** server can't find NXDOMAIN – Puggan Se Dec 2 '11 at 15:21 is a reigistred doamin, owned by HENRIK FORSELL – Puggan Se Dec 2 '11 at 15:22
for dig and nslookup give no a record, and ping gives me the same ip as my server – Puggan Se Dec 2 '11 at 15:31
ping should be using the system resolver settings, so ping/telnet/traceroute/ssh/etc... should all get the same IP when they look it up. – Marc B Dec 2 '11 at 15:46
they all have the same problem, but programs like dig and nslookup don't, and they use /etc/resolv.conf, so what backup plan are the system resolver using, i guess its using my hostname somehow, and i want to turn it off – Puggan Se Dec 3 '11 at 17:26

Got same problem again, forgot to write my soulution last time.

to turn off search domain i added search . in /etc/dhcpcd.conf (gentoo)

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.