You are on page 1of 26

Module 21 Connecting to a Network

Objectives
Upon completion of this module, you will be able to do the following:
Physically connect an HP-UX machine to an existing LAN
!on"gu#e a host name using set_parms o# $A%
!on"gu#e an &P add#ess using set_parms o# $A%
!on"gu#e a default #oute using set_parms o# $A%
!on"gu#e a host as a 'N$ client using set_parms o# $A%
!on"gu#e a host as an N&$ client using set_parms o# $A%
(est connecti)ity with ping and nslookup o# $A%
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-1
Module 21
Connectin to a !etwork
211. SLID! Setting an I" #ddress and Subnet Mask
Student Notes
$%at Is an I" address&
*ach machine on a local a#ea netwo#+ ,LAN-, whethe# it is a lase# p#inte#,
wo#+station, o# se#)e#, is assigned a uni.ue &nte#net p#otocol ,&P- add#ess *)e#y
pac+et of data sent ac#oss the netwo#+ contains a destination &P add#ess which
dete#mines the #ecipient of that pac+et of data, and the #oute ta+en to #each
that destination
An &P add#ess consists of fou# dot ,- sepa#ated intege#s in the #ange /-011
I" #ddress 'a()les
201342056
2165347
0202265
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-2
$etting an &P Add#ess and $ubnet %as+
208220 208226 208225
&P add#esses
9 Assigned to each netwo#+ node
: %ust be uni.ue
: 'e"ne )ia $A% o# set;pa#ms
Module 21
Connectin to a !etwork
<ou# netwo#+ administ#ato# o# &$P should assign you an &P add#ess, o# multiple &P
add#esses if you ha)e multiple LAN inte#face ca#ds in you# machine
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-3
Module 21
Connectin to a !etwork
$%at Is a Subnet Mask&
%any companies these days ha)e la#ge netwo#+s that a#e di)ided into
=subnetwo#+s= 'i)iding a la#ge# netwo#+ into smalle# =subnets= can g#eatly
imp#o)e pe#fo#mance and #eliability on la#ge LANs &f you# company has a
subnetted netwo#+, you# netwo#+ manage# will assign you a =subnet mas+= (he
subnet mas+, in con>unction with you# &P add#ess, dete#mines which subnet you
a#e attached to, and you# uni.ue host add#ess on that subnet &n o#de# to
successfully communicate with othe# nodes on the LAN, you must de"ne the
subnet mas+ fo# you# machine
Subnet Mask 'a()les
011011//
011011011/
011011015/
Setting an I" #ddress and Subnet Mask wit% set*)ar(s
?hen you connect you# node to the LAN, you# &$P o# netwo#+ manage# will
assign you# host a uni.ue &P add#ess acco#ding to the add#ess scheme
implemented in you# shop <ou should also be gi)en a subnet mas+ ?hen you
boot you# system fo# the "#st time, the set_parms utility automatically p#ompts
fo# an &P add#ess and se)e#al othe# netwo#+ pa#amete#s <ou can explicitly #un
set_parms any time to change you# netwo#+ pa#amete#s by typing:
# set_parms initial
Setting an I" #ddress and Subnet Mask wit% S#M
$A% also p#o)ides an intuiti)e inte#face fo# setting o# changing you# &P add#ess
and subnet mas+:
# sam --> Networking & Communications
--> Network Interface Cards
(Select an interface card)
Actions --> Configure
$A% displays a list of you# system@s LAN ca#ds including the LAN ca#d type,
name, ha#dwa#e path, status, and &P add#ess (o change you# subnet mas+ o# &P
add#ess, select the inte#face ca#d to change, select Actions --A !on"gu#e, and
answe# the .uestions in the dialog box that follows
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-4
Module 21
Connectin to a !etwork
212. SLID! Setting a De+ault ,oute
Student Notes
$%at Is a De+ault ,oute&
?ithout any fu#the# con"gu#ation, HP-UX should be able to deli)e# data to any
node on you# local netwo#+ once you# &P add#ess and subnet mas+ ha)e been
set Howe)e#, if you wish to access nodes beyond you# local netwo#+, you#
machine must ha)e access to a router A #oute# is a de)ice that is able to #oute
data to othe# netwo#+s
<ou# netwo#+ manage# should p#o)ide you with the &P add#ess of a #oute# on you#
LAN <ou# host should pass all data destined to othe# netwo#+s th#ough the
default #oute# speci"ed by you# netwo#+ manage#
De-ning a De+ault ,oute
(he default #oute# add#ess may be set )ia eithe# set_parms o# $A% Note that
$A% uses the te#m default gateway inte#changeably with default router:
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-%
$etting a 'efault Boute
9 Hosts can locally deli)e# data to nodes on own LAN
9 Boute is #e.ui#ed to #oute data to othe# LANs
9 'e"ned )ia $A% o# set;pa#ms
208220 208226 208225
LAN
Boute#
208222
(he &nte#net:Cthe# Netwo#+s
Module 21
Connectin to a !etwork
# set_parms initial
# sam --> Networking & Communications
--> osts
--> !ocal osts "ile
Actions --> Configure #efault $atewa%
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-6
Module 21
Connectin to a !etwork
21.. SLID! Setting a S/ste( 0ostna(e
Student Notes
$%at Is a 0ostna(e&
$ince many use#s "nd it diDcult to #emembe# &P add#esses, most machines a#e
also assigned a =hostname= A hostname is simply a uni.ue alphanume#ic
=nic+name= assigned to each host on the netwo#+ Hostnames a#e assigned
based on any of the following:
the pu#pose of the node
the p#ima#y use# of the node
any othe# naming con)ention chosen by the netwo#+ manage#
Setting 1our S/ste( 0ostna(e
<ou# netwo#+ manage# will assign you a hostname, which must be de"ned on
you# machine using set_parms o# $A%:
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-&
$etting a $ystem Hostname
Hostnames
9 %nemonic name assigned to each node
9 !an be based on
: Pu#pose of node
: P#ima#y use#s of node
: Any othe# naming con)ention
9 'e"ned )ia set;pa#ms
208220
,mic+ie-
208226
,minnie-
208225
,donald-
LAN
Module 21
Connectin to a !etwork
# set_parms initial
# sam --> Networking & Communications
--> !an Interface Cards
Actions --> &odif% S%stem Name
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-'
Module 21
Connectin to a !etwork
212. SLID! ,esolving 0ostna(es to I" #ddresses
Student Notes
Although hostnames a#e mo#e memo#able than &P add#esses, a #oute# must +now
a pac+et@s &P add#ess to successfully deli)e# data to a destination Eo# this
#eason, if a use# o# application speci"es a pac+et@s destination as a hostname,
the system must t#anslate the destination hostname to a destination &P add#ess

(he#e a#e th#ee ways to #esol)e hostnames to &P add#esses on an HP-UX system:
)ia the /etc/hosts "le
)ia the 'omain Name $e#)ice ,'N$-
)ia the Netwo#+ &nfo#mation $e#)ice ,N&$-
?e will conside# each method in the pages that follow
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-(
Besol)ing Hostnames to &P Add#esses
9 *)e#y outgoing pac+et #e.ui#es an &P add#ess
9 (h#ee ways to #esol)e hostnames to &P add#esses
' /etc/hosts "le
: 'omain Name $e#)ice ,'N$-
: Netwo#+ &nfo#mation $e#)ice ,N&$-
telnet mickie
208220
ftp minnie
208226
Module 21
Connectin to a !etwork
213. SLID! Con-guring /etc/hosts
Student Notes
$%at Is t%e 4etc4%osts 5ile&
&f you need to communicate only with hosts on you# local netwo#+, you# netwo#+
manage# may #ecommend using the /etc/hosts "le to #esol)e hostnames to &P
add#esses (he /etc/hosts "le is a con"gu#ation "le maintained locally on each
host to #esol)e hostnames to &Ps
*ach line in the /etc/hosts "le contains an &P add#ess in the fa# left "eld,
followed by the hostname associated with that &P add#ess in the second "eld &n
the example on the slide, hostname donald #esol)es to &P add#ess 208225
Hostname minnie #esol)es to &P add#ess 208226
<ou may optionally de"ne one o# mo#e aliases fo# each &P add#ess, too An alias
is simply anothe# name by which an &P can be #efe#enced &n the example on the
slide, both mailsvr and mickie #esol)e to &P 208220
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-10
!on"gu#ing /etc/hosts
9 %aps: &P add#esses hostnames
9 %aintained on each indi)idual host
9 Usually used to #esol)e hostnames on small LANs
9 'e"ne )ia $A% o# copy f#om anothe# host
$ample /etc/hosts:
208222 mic+ie mails)#
208220 minnie
208226 donald
Module 21
Connectin to a !etwork
*ach line in /etc/hosts can contain a comment p#eceded by a # sign as well
Con-guring /etc/hosts
(he /etc/hosts "le must be modi"ed anytime an &P add#ess o# hostname
changes Note that /etc/hosts is maintained locally on each host, so changes
must be p#opagated to all hosts if you wish to maintain consistency ac#oss all
machines on you# netwo#+

<ou can modify /etc/hosts se)e#al diFe#ent ways:
%odify the local hosts "le using $A%
%odify the local hosts "le di#ectly with )i
E(P an up-to-date /etc/hosts "le f#om anothe# host
(o get to the $A% inte#face fo# modifying you# hosts "le, select
# SA& --> Networking and Communications
--> osts
--> !ocal osts "ile
Actions --> Add(&odif%()emo*e
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-11
Module 21
Connectin to a !etwork
216. SLID! Con-guring a DNS Client
Student Notes
$%at Is DNS&
Although the /etc/hosts "le is ade.uate fo# hostname #esolution on small
netwo#+s, you# netwo#+ manage# will li+ely #ecommend using the 'omain Name
$e#)ice ,'N$- fo# name #esolution if you wish to access the outside &nte#net o#
othe# netwo#+s within you# company

&nstead of #efe#encing a locally sto#ed /etc/hosts "le that .uic+ly becomes
outdated, hosts using 'N$ send name #esolution #e.uests to a specially
con"gu#ed DNS name server <ou# netwo#+ manage# can p#o)ide the &P
add#esses of a 'N$ name se#)e# that you# host uses
&n addition to de"ning you# local name se#)e#@s add#ess, you need to de"ne you#
host's DNS domain (he slide shows hosts in two domains:
hp.com
acme.com
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-12
!on"gu#ing a 'N$ !lient
9 Used to #esol)e hostnames on la#ge# netwo#+s
9 !lients #e.uest loo+ups f#om 'N$ se#)e#s
9 (o p#e)ent duplicate names, each host assigned to a GdomainH
9 %ust de"ne the following )ia $A% o# set;pa#ms
: <ou# 'N$ se#)e# add#ess
: <ou# 'N$ GdomainH name
'N$ name
se#)e#
w
w
w
acm
ecom
I
210568
w
w
w
h
pco
m
I
21
6
2
0
320
Module 21
Connectin to a !etwork
*ach host on the &nte#net can be uni.uely identi"ed by the concatenation of the
host@s hostname and domain &f two hosts ha)e the same hostname, the domain
name appended to the end of the hostname dete#mines which host you wish to
#efe#ence
(he example on the slide shows two hosts with hostname www (he two a#e
diFe#entiated f#om one anothe# by the hp.com and acme.com domain names
appended afte# www
S)eci+/ing a DNS Na(eserver
!on"gu#ing you# host to use 'N$ is most easily accomplished )ia $A% Jo to:
# SA& --> #NS (+IN#)
--> #NS )esol*er
Actions --> Specif% Name Ser*ers
Up to th#ee 'N$ namese#)e#s may be de"ned &f one namese#)e# is una)ailable,
you# system will automatically t#y anothe# Use the name se#)e# &P add#esses
p#o)ided by you# netwo#+ manage#
S)eci+/ing a DNS Do(ain Searc% List
?hile in $A%, you should also de"ne you# 'N$ domain <ou may optionally list
up to ")e othe# 'N$ domains to sea#ch when #esol)ing hostnames 'e"ning
additional sea#ch domains sa)es you# use#s the t#ouble of typing long and
cumbe#some domain names
'a()le
?ithout a domain sea#ch list de"ned, use#s in the hp.com domain may need to
type:
# telnet corp,acme,com
Adding acme.com to the domain sea#ch list allows use#s to access
corp.acme.com by simply typing:
# telnet corp
$A% p#o)ides an intuiti)e inte#face fo# de"ning you# own domain and a domain
sea#ch list:
# SA& --> #NS (+IN#)
--> #NS )esol*er
Actions --> Set #efault #omain
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-13
Module 21
Connectin to a !etwork
217. SLID! Con-guring an NIS Client
Student Notes
UN&X hosts a#e con"gu#ed )ia a se#ies of con"gu#ation "les in the /etc di#ecto#y
(hese "les must be constantly updated Adding a new host on the netwo#+ may
#e.ui#e an additional line in e)e#y host@s /etc/hosts "le Adding a new use#
may #e.ui#e an additional ent#y in e)e#y host@s /etc/passwd "le &n la#ge
netwo#+ en)i#onments, maintaining these "les on multiple hosts becomes
tedious and time consuming
(he Netwo#+ &nfo#mation $e#)ice ,N&$- simpli"es con"gu#ation "le updates
signi"cantly &nstead of managing copies of the system con"gu#ation "les on
e)e#y host, N&$ ma+es it possible to manage /etc/passwd, /etc/hosts, and
othe# con"gu#ation "les f#om a single N&$ se#)e# N&$ clients, then, simply
fo#wa#d use# and host loo+up #e.uests to the N&$ se#)e# (hus, N&$ p#o)ides a
cent#al point of administ#ation fo# common con"gu#ation "les, and p#ese#)es
consistency of these con"gu#ation "les ac#oss all hosts on the netwo#+
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-14

!on"gu#ing an N&$ !lient


9 !ent#aliKed maintenance of con"gu#ation "les
9 !lients send host, use#, g#oup loo+ups to N&$ se#)e#
9 %ust de"ne the following )ia $A% o# set_parms
: N&$ domain
: N&$ se#)e# add#ess
N&$
se#)e#
uid fo# use#2I
uid
L 2/2
&P
fo
# m
ails)#
&P
L
2
08
220
/etc/hosts
/etc/passwd
/etc/group
.
.
.
Module 21
Connectin to a !etwork
Must one piece of info#mation is #e.ui#ed to con"gu#e an N&$ client: the NIS
Domain Name An N&$ domain is a logical g#ouping hosts that sha#e a common
set of con"gu#ation "les Eo# example, all hosts in the ma#+eting depa#tment
may be placed in the ma#+eting domain, while hosts in the accounting
depa#tment may be placed in the accounting domain &f you# o#ganiKation uses
N&$, you will need to obtain you# N&$ domain name f#om you# o#ganiKation@s N&$
administ#ato#
Con-guring an NIS Client
?hen you "#st boot a newly-installed system, set_parms p#o)ides an
oppo#tunity to de"ne the N&$ domain name
<ou can also con"gu#e N&$ client functionality )ia $A%:
# sam --> Networking & Communications
--> NIS
Actions --> Set #omain Name
Actions --> -na.le Client
(o lea#n how to con"gu#e an N&$ se#)e#, #etu#n fo# $ystem N Netwo#+
Administ#ation &&O
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-1%
Module 21
Connectin to a !etwork
218. SLID! C%oosing a Look9:) Service
Student Notes
?e@)e seen that hostnames may be #esol)ed )ia the local /etc/hosts "le, 'N$
o# N&$ How does the system decide, then, which sou#ce to useI (he
/etc/nsswitch.conf "le dete#mines which sou#ce should be used fo# loo+-ups
(his "le can be edited manually, o# can be con"gu#ed )ia $A%:
# sam --> Networking and Communications
--> Name Ser*ice Switc/
(Select a lookup t%pe)
Actions --> Configure Name Ser*ice Switc/
(he sample system that p#o)ided the sc#een shot below is con"gu#ed to use 'N$
as the p#ima#y sou#ce fo# hostname #esolution &f the 'N$ se#)e# doesn@t #espond
o# isn@t con"gu#ed, the system #eso#ts to using the local /etc/hosts "le instead
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-16

!hoosing a Loo+-Up $e#)ice
P: ?he#e do & loo+ up hostnamesI
A: !onsult /etc/nsswitch.conf
&
DNS
/etc/hosts
NIS
Module 21
Connectin to a !etwork
$A% Name $e#)ice $witch
$A% also lets you change the loo+up sou#ce o#de# Eo# instance, to fo#ce you#
system to #esol)e hostnames "#st f#om /etc/hosts, then f#om 'N$, select the
hosts line f#om the ob>ect list and clic+ Actions --> Configure Name Service
Switch (he sc#een that follows lets you dete#mine which se#)ice is used when
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-1&
Module 21
Connectin to a !etwork
$A% !on"gu#e Name $e#)ice $witch

(he /etc/nsswitch.conf "le is used to con"gu#e the sou#ce o#de# fo# passwo#d,
g#oup, and othe# types of loo+-ups as well, if you ha)e access to a netwo#+
info#mation se#)ice ,N&$- se#)e#
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-1'
Module 21
Connectin to a !etwork
21;. SLID! <roubles%ooting <ools
Student Notes
Afte# con"gu#ing you# netwo#+ connection, chec+ to ensu#e you# con"gu#ation
wo#+ed using ping!m" and nslookup!"
C%ecking Connectivit/ wit% )ing
(he ping command is used to test connecti)ity to any &P add#ess
'a()les
# ping 012,0,0,3
# ping 012,0,0,4
ping sends a se#ies of test pac+ets to the speci"ed &P and waits fo# a #esponse
Afte# a few seconds, hit !(BL Q c and chec+ to ensu#e that the pac+et loss
shows a )alue of / (#y se)e#al pings:
2 ping you#self
0 ping anothe# host on you# local netwo#+
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-1(
(#oubleshooting (ools
!hec+ connecti)ity
# ping !#$.!.!.%
# ping !#$.!.!.&
!hec+ hostname #esolution
# nslookup minnie
# nslookup donald
Module 21
Connectin to a !etwork
6 ping you# default #oute#
5 ping a host on anothe# netwo#+
&f ping fails, chec+ the following:
&s the LAN ca#d installed p#ope#lyI
&s the LAN cable connected p#ope#lyI
'id you set you# &P p#ope#lyI
'id you con"gu#e a default gatewayR#oute#I
'id you con"gu#e you# subnet mas+ p#ope#lyI
C%eck 0ostna(e ,esolution wit% nslookup
(he nslookup utility can be used to ensu#e that you# host is #esol)ing hostnames
p#ope#ly Ji)en a hostname as an a#gument, nslookup #esponds with the
co##esponding &P add#ess nslookup also notes the sou#ce p#o)iding the &P
add#ess
'a()le =on a %ost using t%e local /etc/hosts -le>
# nslookup minnie
5sing (etc(/osts on mickie
looking up "I!-S
Name6 minnie
Address6 012,0,0,3
&f nslookup #esponds with an inco##ect &P add#ess, chec+ the following:
2 'id you con"gu#e the name se#)ice switch p#ope#lyI
0 &f you a#e using 'N$, is the name se#)e# &P add#ess co##ectI
6 &f you a#e using N&$, is the N&$ domain name co##ectI
5 &f you a#e using /etc/hosts, is the /etc/hosts "le ent#y co##ectI
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-20
Module 21
Connectin to a !etwork
211?. L#@! Connecting to t%e Network
Directions
&n the exe#cise that follows, you will ha)e an oppo#tunity to explo#e the
set_parms and $A% sc#eens used to set netwo#+ pa#amete#s on you# system
Sac+ in you# shop, you# &( depa#tment o# &$P should p#o)ide you with you# basic
netwo#+ing pa#amete#s Eo# this lab exe#cise, you# inst#ucto# will p#o)ide the
add#esses you need:
ostname6
I7 address6
Su.net mask6
#ef, )outer($atewa% I7 address6
#NS domain6 (optional)
#NS ser*er address6 (optional)
Secondar% #NS ser*er address6 (optional)
(he#e should be a shell sc#ipt on you# system called /la's/clo''ernet.sh Bun
the sc#ipt (he sc#ipt clobbe#s you# netwo#+ con"gu#ation "les and #eboots you#
machine ?hen you# machine comes bac+ up again, it will automatically #un the
set_parms utility, >ust as it would if you had >ust installed the ope#ating system
"art I! Con-guring an I" #ddress and 0ostna(e
2 set;pa#ms "#st as+s if you want to connect to the netwo#+ Eo# this lab
exe#cise, we do want to connect to the netwo#+, so clic+ =CT=

0 Next, set_parms as+s if you wish to obtain you# netwo#+ pa#amete#s )ia
'H!P 'H!P is a se#)ice that can automatically p#o)ide you# machine with an
&P add#ess and hostname, if a 'H!P se#)e# exists on you# netwo#+ Eo# this
exe#cise, clic+ =NC=
6 Answe# the p#ompts in the sc#eens that follow to set you# hostname, time
Kone info#mation, and &P add#ess ?hen as+ed if you wish to set additional
netwo#+ info#mation ,fo# example, a default gateway, netmas+, and 'N$ and
N&$ info#mation-, answe# NC ?e will con"gu#e these pa#amete#s late# )ia
$A%
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-21
Module 21
Connectin to a !etwork
Note &f you ma+e a mista+e while ente#ing any of the netwo#+
pa#amete#s, you can #un set_parms again any time by typing
set_parms initial
"art II! C%ecking 1our I" #ddress and Setting 1our Net(ask
2 Afte# #unning set_parms and logging in, go to:
$A% --A Netwo#+ing and !ommunications --A Netwo#+ &nte#face !a#ds
to ensu#e that you# &P is set co##ectly ?hat ha#dwa#e slot numbe# is you# lan/
ca#d installed inI &s lan/ enabled fo# useI ?hat is lan/@s &P add#essI A#e the#e
any othe# LAN ca#ds on you# machineI

0 ?hile still at the Netwo#+ &nte#face !a#d sc#een, set you# subnet mas+
?ithout the subnet mas+, you may not be able to communicate with othe#
nodes on you# LAN $et you# subnet mas+ fo# lan/ )ia $A%
*ach machine on a netwo#+, #ega#dless of the numbe# of LAN inte#face ca#ds,
has a single hostname &f you ha)e multiple LAN ca#ds on a host, $A%
#e.ui#es you to con"gu#e a uni.ue =Host Name Alias= fo# each LAN ca#d (his
is useful in t#oubleshooting situations whe#e you may wish to access a
speci"c LAN ca#d on a ta#get machine #athe# than the gene#al hostname &f
$A% as+s you to set an alias, simply use you# hostname with an =a=
appended to the end
"art III! <esting 1our Network Connection
2 (#y pinging you# own &P add#ess to see if you# &P add#ess is set p#ope#ly 'id
this wo#+I
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-22
Module 21
Connectin to a !etwork
0 Next, t#y pinging a couple of neighbo#ing machines@ &P add#esses 'id this
wo#+I
6 Next, t#y pinging a neighbo#ing machine using its hostname !an you guess
why this failsI ,Hint: Loo+ in the /etc/hosts "le-

"art IA! Con-guring /etc/hosts
<ou won@t be able to access othe# hosts by hostname until you add ent#ies fo#
those machines to you# /etc/hosts "le $A% oFe#s the easiest method fo#
)iewing and modifying you# hosts "le Use $A% to answe# the .uestions that
follow
2 ?hich hosts@ ent#ies a#e con"gu#ed so fa#I

0 Add ent#ies in you# hosts "le fo# the othe# machines in you# #ow
6 (#y pinging you# neighbo#s by hostname again 'oes this wo#+I
"art A =O)tional>! Con-guring a De+ault Batewa/ and DNS
&f you want to be able to access othe# netwo#+s o# the &nte#net, you will ha)e to
de"ne a default gateway and 'N$ se#)e# add#ess Soth of these add#esses can
be con"gu#ed )ia $A%
2 Use $A% to con"gu#e you# default gateway
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-23
Module 21
Connectin to a !etwork
0 Use $A% to con"gu#e you# default 'N$ domain name 'on@t con"gu#e any
=Cthe# 'omains to $ea#ch=
6 Now use $A% to con"gu#e the &P add#esses of you# 'N$ namese#)e#s
"art AI =O)tional>! Con-gure t%e Na(e Service Switc%
2'id you# 'N$ con"gu#ation wo#+I &f 'N$ is con"gu#ed p#ope#ly on you#
machine, and the 'N$ se#)e# is functioning, you should be able to loo+up
hostnames of machines outside you# local netwo#+ (#y an nsloo+up on
wwwhpcom ?hat happensI
0Loo+ ca#efully at the output f#om the nsloo+up you did in the p#e)ious exe#cise
!an you explain why you we#e unable to "nd an &P add#ess fo# wwwhpcomI
,Hint: ?hat loo+up sou#ce is nsloo+up using at this pointI-
6!on"gu#e the name se#)ice switch )ia $A% to ensu#e that you# system
consults the 'N$ se#)e# if a hostname isn@t found in the local RetcRhosts "le
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-24
Module 21
Connectin to a !etwork
5Afte# changing the namese#)ice switch, $A% #eboots you# machine Afte# the
#eboot, do an nsloo+up on wwwhpcom again A#e you able to #esol)e
wwwhpcom nowI
http://education.hp.com H3064S B.00
2000 Hewlett-Packard Company
21-2%
Module 21
Connectin to a !etwork
H3064S B.00 "ttp#$$education."p.com
2000 Hewlett-Packard Company
21-26

You might also like