LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices

Reply
 
Search this Thread
Old 03-16-2007, 04:42 PM   #1
cnts-student
LQ Newbie
 
Registered: Mar 2007
Posts: 6

Rep: Reputation: 0
error unknown host given when trying to ping FQDN


Hello me and my fellow classmates at our local college are running Linux Fedora Core 2. We have two computers connected together by D-link hubby. One computer is our server and the other is our client.

In a lab given to us by our instructor we are having some problems and we are hoping someone may be able to help us. When we get to step 7 in our lab we are able to use our client to ping our server however we are unable to ping it using its FQDN and recieve the error messsage "ping: unknown host www.linuxdomain.ca"

Anyone able to help us solve this problem would be most appreciated.


This is the lab posted below:

Step 1:

Set your current working directory to: /var/named
Determine if a directory exist called: chroot
If the above directory does not exist then create it: mkdir chroot
Move to the directory chroot cd chroot
Create a directory under chroot called: etc
Create a directory under chroot called: var
Create a directory under var called named

When you have finished the above exercise you should have the following directory structure

/var/named/chroot/var/named

/var/named/chroot/etc


Verified: _______


Please note
• For your DNS server to function properly the above directory must exist exactly as shown
• The “chroot” directory is used to create a fake root
• DO NOT continue until the above has been verified



Step 2:

The following are the required files and their location:

You will be required to create the following files to properly configure DNS. These files should exist in the /etc folder and may be copied to the directory should below.


Location Files

/var/named/chroot/etc named.conf
rndc.conf
rndc.keys


Note: Copy these file from: /etc

• The configuration file “named.conf” has a pointer to /var/named to local all configuration files.
• rndc.key: file should exist on the DNS Server
• rndc.conf: this file should exist on each client




Step 3:

This step will identify the required file names and their locations:

/var/named/chroot/var/named named.ca
/var/named/chroot/var/named teamxxx.hosts *
/var/named/chroot/var/named teamxxx.local *
/var/named/chroot/var/named named.local ***
/var/named/chroot/var/named localhost.zone ***

* You must create these files from the information found later in this lab

*** These files should already exist and may be found in /var/named if so copy these files to the
above location

Do not change the location of any of the files

All files identified above should have the following permissions set: 755



When creating configuration notice that some examples have a period (.) at the beginning or the ending of certain entries.

Make sure you have coded this properly as shown



Step 4:

named.conf

 The configuration file is called named.conf should be found in /etc.
 If there is not one you may create one using a text editor.
 This is the primary file used by BIND
 A sample file is provided

 This file points to a number of other files for the DNS Configuration

named.ca
teamxxx.hosts
teamxxx.local
localhost.zone
named.local

 Note: in most DNS configuration you will have more configuration files than provided in this lab
 Change the highlighted entries to match the Host name, Domain Name, FQDN, and IP address for your installation






named.conf if named.conf does not exist use the following:

// generated by named-bootconf.pl
options {
directory "/var/named";
/*
* If there is a firewall between you and nameservers you want
* to talk to, you might need to uncomment the query-source
* directive below. Previous versions of BIND always asked
* questions using port 53, but BIND 8.1 uses an unprivileged
* port by default.
*/
// query-source address * port 53;
};
//
// a caching only nameserver config
//
controls {
inet 127.0.0.1 allow { localhost; } keys { rndckey; };
};
zone “localhost” IN {
type master;
file “localhost.zone”;
allow-update { none; };
};

zone “0.0.127.in-addr.arpa” IN {
type master;
file “named.local”;
allow-update { none: };
};

zone "." IN {
type hint;
file "named.ca";
};
zone "yourdomain.ca" {
type master;
file "teamxxx.hosts";
};
zone "x.16.172.in-addr.arpa" IN {
type master;
file "teamxxx.local";
allow-update { none; };
};
include "/etc/rndc.key";

Step 5:

The following file should exist on your server so just move it to the proper location. If it does not exist or is different from the file below, use the file provided next.

named.ca

; This file holds the information on root name servers needed to
; initialize cache of Internet domain name servers
; (e.g. reference this file in the "cache . <file>"
; configuration file of BIND domain name servers).
;
; This file is made available by InterNIC
; under anonymous FTP as file /domain/named.cache
; on server FTP.INTERNIC.NET
;
; last update: Nov 5, 2002
; related version of root zone: 2002110501
;
; formerly NS.INTERNIC.NET
;
. 3600000 IN NS A.ROOT-SERVERS.NET.
A.ROOT-SERVERS.NET. 3600000 A 198.41.0.4
;
; formerly NS1.ISI.EDU
;
. 3600000 NS B.ROOT-SERVERS.NET.
B.ROOT-SERVERS.NET. 3600000 A 128.9.0.107
;
; formerly C.PSI.NET
;
. 3600000 NS C.ROOT-SERVERS.NET.
C.ROOT-SERVERS.NET. 3600000 A 192.33.4.12
;
; formerly TERP.UMD.EDU
;
. 3600000 NS D.ROOT-SERVERS.NET.
D.ROOT-SERVERS.NET. 3600000 A 128.8.10.90
;
; formerly NS.NASA.GOV
;
. 3600000 NS E.ROOT-SERVERS.NET.
E.ROOT-SERVERS.NET. 3600000 A 192.203.230.10
;
; formerly NS.ISC.ORG
;
. 3600000 NS F.ROOT-SERVERS.NET.
F.ROOT-SERVERS.NET. 3600000 A 192.5.5.241
;
; formerly NS.NIC.DDN.MIL
. 3600000 NS G.ROOT-SERVERS.NET.
G.ROOT-SERVERS.NET. 3600000 A 192.112.36.4
;
; formerly AOS.ARL.ARMY.MIL
;
. 3600000 NS H.ROOT-SERVERS.NET.

H.ROOT-SERVERS.NET. 3600000 A 128.63.2.53
;
; formerly NIC.NORDU.NET
;
. 3600000 NS I.ROOT-SERVERS.NET.
I.ROOT-SERVERS.NET. 3600000 A 192.36.148.17
;
; operated by VeriSign, Inc.
;
. 3600000 NS J.ROOT-SERVERS.NET.
J.ROOT-SERVERS.NET. 3600000 A 192.58.128.30
;
; housed in LINX, operated by RIPE NCC
;
. 3600000 NS K.ROOT-SERVERS.NET.
K.ROOT-SERVERS.NET. 3600000 A 193.0.14.129
;
; operated by IANA
;
. 3600000 NS L.ROOT-SERVERS.NET.
L.ROOT-SERVERS.NET. 3600000 A 198.32.64.12
;
; housed in Japan, operated by WIDE
;
. 3600000 NS M.ROOT-SERVERS.NET.
M.ROOT-SERVERS.NET. 3600000 A 202.12.27.33
; End of File


Step 6:

Next you will create the DNS files for your lab network

Note:

Replace the “xx” with the subnet number
Replace the “xxx” with the machine number located on the front of your server

If you do not have or do not know the team number ask your professor

The file names: teamxxx.hosts and teamxxx.local can vary depending on the required of
the Installation

For this installation I want everyone to use the same type of file naming convention


teamxxx.local

 in the following file change the xx in the $ORIGIN to your subnet number
 change “servername” to the server name you chose above
 change “yourdomain” to the domain name you chose above

$ORIGIN xx.16.172.in-addr.arpa.
$TTL 86400
@ IN SOA servername.yourdomain.ca. root.yourdomain.ca. (
1997022700 ; Serial
28800 ; Refresh
14400 ; Retry
3600000 ; Expire
86400 ) ; Minimum
IN NS servername.yourdomain.ca.

1 IN PTR servername.yourdomain.ca.


teamxxx.hosts

 in the following file change the xx.xx to the subnet number and IP address of your server
 change “servername” to the server name you chose above
 change “yourdomain” to the domain name you chose above


@ IN SOA servername.yourdomain.ca. root.yourdomain.ca. (
2000050201 ; serial number
10800 ; refresh 3 hours
3600 ; retry 1 hour
432000 ; expire 1 week
86400) ; minimum 1 day
IN NS servername.yourdomain.ca.
IN A 172.16.xx.xx
localhost IN A 127.0.0.1
servername IN A 172.16.xx.xx
www IN CNAME servername
ftp IN CNAME servername
alpha IN CNAME servername

Step 7:

Testing DNS

 Check resolv.conf to make sure you are pointing to your DNS Server
 Once all files have been created and properly configured and you have made sure the files are in the proper locations start your DNS Server
 To start your DNS server issue the following command:

service named restart


IMPORTANT:
If when starting your server you had errors, or your server is not functioning properly. Check the message file for errors or configuration problems.

cat /var/log/messages


 To test your server perform the following:
On your server ping your IP address first, then ping your FQDN if this does not work then you have problems with your server which you must correct before continuing
If your pings work continue with the next step


 Use the following command to check DNS: nslookup www
 Use the hub to physically connect your Server and Client
 Start your Client and ensure it can see your server use ping Verified: _____
 From your client ping the server using the FQDN selected
 If the ping is successful then your DNS Server is functioning correctly
 If the ping is not successful then you must return and check each configuration file for the proper entries
 Additional help can be found at the RedHat Web site.

Verified: _____



Reconfigure DNS

 Add to your DNS configuration to have the name w3.yourdomain.xxx as a
FQDN

Verified: _____
 
Old 03-16-2007, 05:51 PM   #2
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 728Reputation: 728Reputation: 728Reputation: 728Reputation: 728Reputation: 728Reputation: 728
You won!!! The record for the longest post.
Seriously, I don't know anyone here that is going to read all that---especially since it is homework.

If you cannot ping by domain name, then try the IP. If that works, then you have a DNS issue.
 
Old 03-18-2007, 01:17 PM   #3
cnts-student
LQ Newbie
 
Registered: Mar 2007
Posts: 6

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by pixellany
You won!!! The record for the longest post.
Seriously, I don't know anyone here that is going to read all that---especially since it is homework.

If you cannot ping by domain name, then try the IP. If that works, then you have a DNS issue.
Yeah i figured no one was going to read through a whole entire lab but I figured might as well since alot of people were having issues in our class with this lab.

Everyone was following the steps in the lab. I just wanted to know if maybe there was something we did wrong in one of the steps or if there was something we didn't do.

As it turns out the problem was both client and machine had their firewalls turned on. I feel so silly.

Well thanks for the help. Next time ill make sure that i win the smallest post in all history
 
  


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
ping: unknown host www.google.com tcma Linux - Networking 7 03-02-2012 11:47 PM
Slackware 10.2 - ping: unknown host TBomb Linux - Networking 4 04-17-2006 06:50 PM
ping: unknown host www.google.com juanjavier_xxx Debian 8 01-02-2006 01:47 PM
ping: unknown host in local intranet linuxjustin Linux - Networking 3 04-04-2004 02:03 PM
Unknown Host <Linuxmachinename> / Unable to ping by host name nishi_k_79 Linux - Networking 4 11-01-2003 01:24 PM


All times are GMT -5. The time now is 12:19 PM.

Main Menu
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