LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices



Reply
 
Search this Thread
Old 10-25-2004, 02:07 PM   #1
arobinson74
Member
 
Registered: Nov 2002
Location: Lone Tree, CO
Distribution: Xubuntu Gutsy
Posts: 174

Rep: Reputation: 30
DNS will not resolve non-domain qualified names


Just formatted my RedHat machine and am building it as a Slack10.0 box.

I have named running and my ethernet cards are up, but having a little problem with resolving computer names if they are not qualified.

I resolv.conf set with a search:
search mydomain.net
nameserver 192.168.0.1

I have the zones and named.conf setup.

The following work:
dig localhost
dig somecomp.mydomain.net
dig mycomp.mydomain.net

The following types of queries fail:
dig somecomp
dig mycomp

Event if these (somecomp and mycomp) are defined in /etc/hosts, the dig fails. The dig fails with a "no servers could be reached"

I have 2 NIC cards on this box (eth0 and eth1). eth1 is hard-set to 192.168.0.1 and eth0 is a DHCP assigned IP (eth0 is the way out to the world and eth1 serves my network and protects it with IP tables (which by the way is not setup yet))

eth0 is not working at the moment (unplugged) until I can get this working at add my firewall settings and get iptables up and running.

All reverse lookups work fine (IP->name), it is only the name with no domain that fails.

Shouldn't dig be picking up the "nameserver" line from resolv.conf (indirectly)?
 
Old 10-25-2004, 02:52 PM   #2
scowles
Member
 
Registered: Sep 2004
Location: Texas, USA
Distribution: Fedora
Posts: 620

Rep: Reputation: 31
The "dig" command, by defualt, has never appended the domain name to a query. From the dig man pages:

Code:
       +[no]search
              Use  [do  not  use] the search list defined by the searchlist or
              domain directive in resolv.conf (if any).  The  search  list  is
              not used by default.
So...

dig +search somecomp

Edit addition:

Or you could just alias dig to include the search option:

alias dig='dig +search'
dig mycomp

Last edited by scowles; 10-25-2004 at 03:02 PM.
 
Old 10-25-2004, 05:13 PM   #3
arobinson74
Member
 
Registered: Nov 2002
Location: Lone Tree, CO
Distribution: Xubuntu Gutsy
Posts: 174

Original Poster
Rep: Reputation: 30
Good grief. Guess I should have posted that on the newbie list.

Feeling a bit dumb at the moment...
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
unable to resolve domain names natekris2331 Slackware 9 02-12-2011 01:27 PM
DNS, Linux doesnt resolve domain names for me ikk Linux - Networking 6 08-28-2005 04:35 PM
DNS, Linux doesnt resolve domain names for me ikk Linux - Newbie 6 08-28-2005 04:29 PM
Unable to resolve domain names holdem Linux - Networking 4 02-01-2004 11:50 PM
Fully Qualified Domain Names? MasterC Linux - Networking 7 05-19-2003 02:38 PM


All times are GMT -5. The time now is 11:07 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration