Transcript
Hálózatok konfigurálása
Bevezetés(mit és hogyan állítsak, hogy elérjem az
Internetet otthon)
OSI és az Internet
Application
Presentation
Session
Process/Application
Transport Host to Host
Network Internetwork
Data Link
Physical
Network
Access
TCP/IP protokoll architektúra
OSI Layer 4(Transport)
TCP UDP
ICMP routing SNMPOSI Layer 3(Network)
IP Filtering IP NAT IP
OSI Layer 2(Data Link)
ARP RARP PPP PPPoE LCP
802.3 802.11 ATM . . .OSI Layer 1(Physical)
10/100 Ethernet CableModem
WirelessLAN
xDSL Modem
Microsoft Network Protokoll Architektúra
NETBIOS
NetBIOS overTCP/IP
Windows Sockets
TDI (Transport Driver Inteface)
NWLink NetBEUI (NBF) TCP/IP
NDIS (Network Driver Interface Specification)
Adapter drivers
Network adapters
Dokumentáció, információ, help
• RFC
• man
• /usr/doc directory
• help
• fórumok
• google és más keresők
Hálózat konfigurálása
• Network Access: – általában automatikus
• Internetwork: – manuális– DHCP (Dynamis Host Configuration)
• Host to Host és felette:– igény szerint… most nem foglalkozunk vele
Tipikus „Network access” otthon:
• Telefon modem (PPP)
• ADSL (PPPoE)
• Cable modem
• MicroWave, Wireless
• IrDA, Bluetooth
• Ethernet (Coax, UTP)
• Egyéb más megoldások
Fontosabb hálózati parancsok
• ipconfig, ifconfig,• ping,• traceroute, tracert,• route,• nslookup, host,• arp,• NET (Windows NT, 2K, stb.)• grafikus adminisztrátori programok
(W2K) > ipconfig /all
Windows 2000 IP Configuration
Host Name . . . . . . . . . . . . : oasis1
Primary DNS Suffix . . . . . . . :
Node Type . . . . . . . . . . . . : Broadcast
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No
DNS Suffix Search List. . . . . . : inf.u-szeged.hu
Ethernet adapter Local Area Connection:
Connection-specific DNS Suffix . : inf.u-szeged.hu
Description . . . . . . . . . . . : SMC EZ Card 10/100 (SMC1255TX)
Physical Address. . . . . . . . . : 00-04-E2-1F-A6-EC
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
IP Address. . . . . . . . . . . . : 160.114.37.21
Subnet Mask . . . . . . . . . . . : 255.255.254.0
Default Gateway . . . . . . . . . : 160.114.37.254
DHCP Server . . . . . . . . . . . : 160.114.37.205
DNS Servers . . . . . . . . . . . : 160.114.37.205
160.114.51.3
Lease Obtained. . . . . . . . . . : Friday, March 12, 2004 1:14:45 AM
Lease Expires . . . . . . . . . . : Friday, March 12, 2004 1:24:45 AM
(Debian)> ifconfig
eth0 Link encap:Ethernet HWaddr 00:04:E2:1F:A6:1C
inet addr:160.114.37.205 Bcast:160.114.37.255 Mask:255.255.254.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:141009687 errors:2740 dropped:0 overruns:2740 frame:2740
TX packets:148590695 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:1221478403 (1.1 GiB) TX bytes:2052918402 (1.9 GiB)
Interrupt:18 Base address:0xe800
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:2090944 errors:0 dropped:0 overruns:0 frame:0
TX packets:2090944 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:446367543 (425.6 MiB) TX bytes:446367543 (425.6 MiB)
(W2K)> ping amadea.inf.u-szeged.hu
Pinging amadea.inf.u-szeged.hu [160.114.37.193] with 32 bytes of data:
Reply from 160.114.37.193: bytes=32 time=16ms TTL=255
Reply from 160.114.37.193: bytes=32 time<10ms TTL=255
Reply from 160.114.37.193: bytes=32 time<10ms TTL=255
Ping statistics for 160.114.37.193:
Packets: Sent = 3, Received = 3, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 16ms, Average = 5ms
(Debian) > ping amadea.inf.u-szeged.hu
PING amadea.inf.u-szeged.hu (160.114.37.193): 56 data bytes
64 bytes from 160.114.37.193: icmp_seq=0 ttl=255 time=1.1 ms
64 bytes from 160.114.37.193: icmp_seq=1 ttl=255 time=0.6 ms
64 bytes from 160.114.37.193: icmp_seq=2 ttl=255 time=0.6 ms
--- amadea.inf.u-szeged.hu ping statistics ---
3 packets transmitted, 3 packets received, 0% packet loss
round-trip min/avg/max = 0.6/0.7/1.1 ms
(W2K) > tracert www.depo.hu
Tracing route to www.depo.hu [195.228.75.30]
over a maximum of 30 hops:
1 16 ms <10 ms 16 ms swarp0.inf.u-szeged.hu [160.114.37.254]
2 16 ms <10 ms <10 ms 160.114.120.81
3 <10 ms 16 ms <10 ms 160.114.120.61
4 <10 ms <10 ms 16 ms 195.111.97.241
5 <10 ms 32 ms <10 ms c6513-tengbeth5-1.vh.hbone.hu [195.111.97.242]
6 <10 ms 16 ms 15 ms ge2-10.osr0-vhugo.matav.net [145.236.89.193]
7 15 ms 16 ms <10 ms g4-3-0.core0-ip2.matav.net [145.236.85.13]
8 <10 ms 15 ms 16 ms vlan9.6509-1-msfc2.adatpark.hu [145.236.89.6]
9 <10 ms 16 ms <10 ms web1.hirekmedia.hu [195.228.75.30]
Trace complete.
(amadea) > traceroute www.depo.hu
traceroute to www.depo.hu (195.228.75.30), 30 hops max, 20 byte packets
1 swarp0 (160.114.37.254) 2 ms 2 ms 3 ms
2 160.114.120.81 (160.114.120.81) 7 ms 15 ms 7 ms
3 160.114.120.61 (160.114.120.61) 8 ms 7 ms 9 ms
4 195.111.97.241 (195.111.97.241) 10 ms 9 ms 16 ms
5 c6513-tengbeth5-1.vh.hbone.hu (195.111.97.242) 9 ms 8 ms 8 ms
6 ge2-10.osr0-vhugo.matav.net (145.236.89.193) 11 ms 9 ms 9 ms
7 g4-3-0.core0-ip2.matav.net (145.236.85.13) 9 ms 11 ms 9 ms
8 vlan9.6509-1-msfc2.adatpark.hu (145.236.89.6) 12 ms 11 ms 10 ms
9 web1.hirekmedia.hu (195.228.75.30) 11 ms 10 ms 10 ms
(W2K) > route print
. . .
Active Routes:
Network Destination Netmask Gateway Interface Metric
0.0.0.0 0.0.0.0 160.114.37.254 160.114.37.21 1
127.0.0.0 255.0.0.0 127.0.0.1 127.0.0.1 1
160.114.36.0 255.255.254.0 160.114.37.21 160.114.37.21 1
160.114.37.21 255.255.255.255 127.0.0.1 127.0.0.1 1
160.114.255.255 255.255.255.255 160.114.37.21 160.114.37.21 1
169.254.0.0 255.255.0.0 169.254.218.201 169.254.218.201 1
169.254.218.201 255.255.255.255 127.0.0.1 127.0.0.1 1
169.254.255.255 255.255.255.255 169.254.218.201 169.254.218.201 1
192.168.17.0 255.255.255.0 192.168.17.1 192.168.17.1 1
192.168.17.1 255.255.255.255 127.0.0.1 127.0.0.1 1
192.168.17.255 255.255.255.255 192.168.17.1 192.168.17.1 1
224.0.0.0 224.0.0.0 160.114.37.21 160.114.37.21 1
224.0.0.0 224.0.0.0 169.254.218.201 169.254.218.201 1
224.0.0.0 224.0.0.0 192.168.17.1 192.168.17.1 1
255.255.255.255 255.255.255.255 169.254.218.201 169.254.218.201 1
Default Gateway: 160.114.37.254
. . .
(Debian) > /sbin/route
Kernel IP routing table
Destination Gateway Genmask Flags Metric Ref Use Iface
160.114.36.0 * 255.255.254.0 U 0 0 0 eth0
default swarp0.inf.u-sz 0.0.0.0 UG 0 0 0 eth0
(W2K) > nslookup
> set qtype=ANY
> inf.u-szeged.hu
Server: rgai.inf.u-szeged.hu
Address: 160.114.37.205
inf.u-szeged.hu MX preference = 100, mail exchanger = orion.fwall.u-szeged.hu
inf.u-szeged.hu MX preference = 200, mail exchanger = eos.fwall.u-szeged.hu
inf.u-szeged.hu MX preference = 300, mail exchanger = amadea.inf.u-szeged.hu
u-szeged.hu nameserver = dns.cc.u-szeged.hu
u-szeged.hu nameserver = ns2.sztaki.hu
u-szeged.hu nameserver = dns1.szote.u-szeged.hu
u-szeged.hu nameserver = huni6.cc.u-szeged.hu
orion.fwall.u-szeged.hu internet address = 160.114.120.249
eos.fwall.u-szeged.hu internet address = 160.114.120.248
amadea.inf.u-szeged.hu internet address = 160.114.37.193
dns.cc.u-szeged.hu internet address = 160.114.8.21
ns2.sztaki.hu internet address = 193.225.86.1
dns1.szote.u-szeged.hu internet address = 160.114.103.224
huni6.cc.u-szeged.hu internet address = 160.114.8.16
(RH) > host amadea.inf.u-szeged.hu
amadea.inf.u-szeged.hu has address 160.114.37.193
(W2K) > arp -a
Interface: 160.114.37.21 on Interface 0x1000005
Internet Address Physical Address Type
160.114.37.193 00-60-b0-59-0d-7c dynamic
160.114.37.204 00-10-dc-23-7d-38 dynamic
160.114.37.206 00-10-dc-23-7d-1f dynamic
160.114.37.254 00-01-e7-97-c9-00 dynamic
(RH) > arp –a
nokiaa.inf.u-szeged.hu (160.114.37.74) at 00:40:07:02:01:A3 [ether] on eth1
oasis1.inf.u-szeged.hu (160.114.37.21) at 00:04:E2:1F:A6:EC [ether] on eth1
Fontosabb hálózati file-ok
• hosts,
• services,
• protocols,
• dhcpd.conf
• samba/smb.conf
(W2K) > Dir C:\WINNT\system32\drivers\etc
Volume in drive C has no label.
Volume Serial Number is 3031-B4D4
Directory of c:\WINNT\system32\drivers\etc
05/13/2002 05:58p <DIR> .
05/13/2002 05:58p <DIR> ..
10/17/2003 09:33p 2,410 hosts
07/26/2000 01:00p 3,683 lmhosts.sam
07/26/2000 01:00p 407 networks
07/26/2000 01:00p 799 protocol
07/26/2000 01:00p 7,116 services
5 File(s) 14,415 bytes
2 Dir(s) 1,025,839,104 bytes free
(RH) > ls \etc
. . .
(amadea) > cat hosts
. . .
127.0.0.1 localhost loopback
160.114.37.113 ihp01.inf.u-szeged.hu ihp01
160.114.37.114 ihp02.inf.u-szeged.hu ihp02
160.114.37.115 ihp03.inf.u-szeged.hu ihp03
160.114.37.116 ihp04.inf.u-szeged.hu ihp04
160.114.37.117 ihp05.inf.u-szeged.hu ihp05
160.114.37.118 ihp06.inf.u-szeged.hu ihp06
. . .
(amadea) > cat services
. . .
daytime 13/udp #
qotd 17/tcp quote # Quote of the Day
chargen 19/tcp ttytst source # Character Generator
chargen 19/udp ttytst source #
ftp-data 20/tcp # File Transfer Protocol (Data)
ftp 21/tcp # File Transfer Protocol (Control)
ssh 22/tcp # Secure Shell Protocol (telnet)
ssh 22/udp # Secure Shell Protocol (telnet)
telnet 23/tcp # Virtual Terminal Protocol
smtp 25/tcp # Simple Mail Transfer Protocol
time 37/tcp timeserver # Time
time 37/udp timeserver #
rlp 39/udp resource # Resource Location Protocol
whois 43/tcp nicname # Who Is
domain 53/tcp nameserver # Domain Name Service
domain 53/udp nameserver #
bootps 67/udp # Bootstrap Protocol Server
. . .
(amadea) > cat protocols
. . .
ip 0 IP # internet protocol, pseudo protocol number
icmp 1 ICMP # internet control message protocol
igmp 2 IGMP # internet group management protocol
ggp 3 GGP # gateway-gateway protocol
tcp 6 TCP # transmission control protocol
egp 8 EGP # exterior gateway protocol
pup 12 PUP # PARC universal packet protocol
udp 17 UDP # user datagram protocol
hmp 20 HMP # host monitoring protocol
xns-idp 22 XNS-IDP # Xerox NS IDP
rdp 27 RDP # "reliable datagram" protocol
. . .
(Debian) > cat /etc/dhcpd.conf
. . .
# rtx5 - rgai
#host rtx5 {
# hardware ethernet 00:00:A7:12:76:71;
# fixed-address 160.114.37.20;
#}
# Felfoldi Laszlo (15) - rgai
host oasis1 {
hardware ethernet 00:04:E2:1F:A6:EC;
fixed-address 160.114.37.21;
}
# Toth Laszlo (20) - rgai
host oasis2 {
hardware ethernet 00:0C:6E:A4:FC:73;
fixed-address 160.114.37.22;
}
. . .
top related