You are on page 1of 6

I HC QUC GIA TP.

HCM
TRNG I HC BCH KHOA
Khoa in in t
..0O0..

TRUYN S LIU V MNG


Bi tp s 10 - DNS

Ging vin: TS. Lu Thanh Tr


Hc vin: Chu i Dng
M s hc vin: 13461236
Lp: Cao hc vin thng-2013- t 2

Yu cu :
Ci t 1 DNS server trn linux gi ci bind.
a. ci t tn min abc.com
b.Dng DNS lookup trc tip vo server ang ci
c. Ci webserver ln my o khc. Dng firefox trn my bt k truy cp
http://www.abc.com xut hin
HELLO CLASS
BAI TAP DNS
TN SV
d. Dng wireshark phn tch qu trnh DNS khi s dng trnh duyt
Thc hin:
Ci t DNS server trn linux gi ci bind:
yum install bind-chroot
kim tra trng thi dch v dns:
Service named status:
[root@centos1 ~]# service named status
version: 9.8.2rc1-RedHat-9.8.2-0.23.rc1.el6_5.1
CPUs found: 1
worker threads: 1
number of zones: 21
debug level: 0
xfers running: 0
xfers deferred: 0
soa queries in progress: 0
query logging is OFF
recursive clients: 0/0/1000
tcp clients: 0/100
server is up and running
named (pid 1597) is running...
Sau khi kim tra dch vu named chy ri, tin hnh cu hnh ci t tn min.
a. Ci t tn min abc.com
Cu hnh file /etc/named.conf:
zone "abc.com" IN {
type master;
file "abc.com";
allow-update { none; };
};

Bi tp s 10- Truyn s liu v Mng

HV: Chu i Dng

Cu hnh file /var/named/abc.com


y cu hnh IP 192.168.175.134 lm primary DNS server, v 192.168.175.137 l
webserver.

b.
t DNS server cho my DNS l chnh n:

Tin hnh DNS lookup webserver:

Mail server:

Bi tp s 10- Truyn s liu v Mng

HV: Chu i Dng

c. Truy cp web tn min www.abc.com


Truy xut t my c IP : 192.168.175.1

d. Bt gi phn tch:
Phi clear DNS cache trc lc bt gi: windows dng lnh # ipconfig /flushdns.
My 192.168.175.1 gi DNS querry tn min www.abc.com

DNS server tr li:


IP ca domain trn l 192.168.175.137

Bi tp s 10- Truyn s liu v Mng

HV: Chu i Dng

Sau khi nhn c IP t DNS server. Client s thc hin qu trnh bt tay ba bc thit lp
kt ni TCP ti webserver (192.168.175.137):

Sau qu trnh bt tay ba bc CLIENT gi request yu cu get d liu t webserver: server


gi tr bn tin ni dung l file index.html .

Ni dung bn tin tr v nm trong trng line based text data ca giao thc HTTP:

Bi tp s 10- Truyn s liu v Mng

HV: Chu i Dng

You might also like