http___link-university.com_lekcija_Mre_C5_BEni-alati-za-detekciju-i-otklanjanje-problema-u-radu-mre_C5_BEe_4688_1.xml
1.1 1.2 2.1 3.1 3.2 3.3 4.1 5.1 6.1 6.2 6.3 6.4 6.5 7.1 7.2 7.3 7.4 7.5 7.6 9.1 9.2 9.3 9.4 9.5 10.1 11.1 11.2 12.1 13.1 13.2 13.3 13.4 13.5 13.6 13.7 13.8 13.9 13.10 13.11 13.12 13.13 13.14
While troubleshooting a VPN connection over DSL, I ping-ed the destination with parameters to find out what the minimum allowed MTU size was. By ‘telling’ ping not to fragment (using -f), you are forcing the packet to attempt to reach the destination with its size (specified with -l) unaltered. Packet Internet Groper (ping) is a computer network administration utility used to test whether a particular host is reachable across an Internet Protocol (IP) network and to measure the round-trip time for packets send from the local host to a destination computer, including the local host’s own interfaces. Ping operates by sending an Internet Control Message Protocol (ICMP) echo request packets to the target host and waits for an ICMP response, sometimes casually called a pong. In the process it measures the round-trip time and records any packet loss. The results of the test are printed in form of a statistical summary of the response packets received, including the minimum, maximum, and the mean round-trip times, and sometimes the standard deviation of the mean. Here is an example of checking the accepted MTU size between your host and the destination of 192.168.3.1 (comments in green): C:>ping 192.168.3.1 <-- no parameters used, meaning fragmentation is default Pinging 192.168.3.1 with 32 bytes of data: Reply from 192.168.3.1: bytes=32 time=1ms TTL=255 <-- host available and reachable Reply from 192.168.3.1: bytes=32 time=116ms TTL=255 Reply from 192.168.3.1: bytes=32 time=54ms TTL=255 Reply from 192.168.3.1: bytes=32 time=3ms TTL=255 Ping statistics for 192.168.3.1: Packets: Sent = 4, Received = 4, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 1ms, Maximum = 116ms, Average = 43ms C:>ping -f -l 1500 192.168.3.1 <-- attempt a ping with MTU = 1500 Pinging 192.168.3.1 with 1500 bytes of data: Packet needs to be fragmented but DF set. <-- host unreachable, MTU = 1500 too big Packet needs to be fragmented but DF set. Packet needs to be fragmented but DF set. Packet needs to be fragmented but DF set. Ping statistics for 192.168.3.1: Packets: Sent = 4, Received = 0, Lost = 4 (100% loss), C:>ping -f -l 1492 192.168.3.1 <-- attempt a ping with MTU = 1492 Pinging 192.168.3.1 with 1492 bytes of data: Packet needs to be fragmented but DF set. <-- host unreachable, MTU = 1492 still too big! Packet needs to be fragmented but DF set. Packet needs to be fragmented but DF set. Packet needs to be fragmented but DF set. Ping statistics for 192.168.3.1: Packets: Sent = 4, Received = 0, Lost = 4 (100% loss), When is this useful? If – for example – you have difficulties establishing a VPN connection over a DSL. The fragmentation of an encrypted packet may break your VPN connection as DSL needs a smaller size packet in order to “wrap” it in its own envelope. If this is the case, you may need to override and lower the default 1500 MTU size on your network device. Ping-ing with various unfragmented MTU sizes helps you determine the highest packet size that goes through. For a more extensive investigation, in case you need to know the MTU size for every single step in between your host and its destination, read the article Determine MTU values for each hop with mturoute.exe Ping has various command line options depending on the host operating system that enable special operational modes, such as to specify the packet size used as the probe, automatic repeated operation for sending a specified count of probes, time stamping options, or to perform a ping flood. Flood pinging may be abused as a simple form of denial-of-service attack, in which the attacker overwhelms the victim with ICMP echo request packets. Here are the available ping parameters for XP: C:>ping /? Usage: ping [-t] [-a] [-n count] [-l size] [-f] [-i TTL] [-v TOS] [-r count] [-s count] [[-j host-list] | [-k host-list]] [-w timeout] target_name Options: -t Ping the specified host until stopped. To see statistics and continue - type Control-Break; To stop - type Control-C. -a Resolve addresses to hostnames. -n count Number of echo requests to send. -l size Send buffer size. -f Set Don't Fragment flag in packet. -i TTL Time To Live. -v TOS Type Of Service. -r count Record route for count hops. -s count Timestamp for count hops. -j host-list Loose source route along host-list. -k host-list Strict source route along host-list. -w timeout Timeout in milliseconds to wait for each reply.
1.1 1.2 1.3 2.1 2.2 2.3 3.1 4.1 4.2 4.3 5.1 6.1 7.1 8.1 9.1 10.1 11.1 12.1 13.1 14.1 15.1 16.1 17.1 18.1 20.1 21.1 22.1 23.1 24.1 25.1 25.2 25.3 25.4 25.5 25.6 25.7 26.1 27.1 28.1 29.1 30.1 31.1 32.1 33.1 34.1 35.1 36.1 37.1 38.1 39.1 40.1 41.1 42.1 43.1 44.1 45.1 46.1 47.1 48.1 49.1 50.1 51.1 52.1 54.1 55.1 55.2
Metodologija rešavanja problema se sastoji od nekoliko koraka i to: identifikacije problema, analize mogućih rešenja i samog rešavanja problema. Za rešavanje mrežnih problema se koriste određeni programi koji omogućavaju bržu identifikaciju samog problema a potom naravno i njegovo uklanjanje. Neki od programa su: Programi za rešavanje potencijalnih problema u kešu. Najveća prednost ove vrste programa je moguća identifikacija problema a onda na osnovu povratnih informacija koje ti programi šalju sledi moguće rešenje problema. Programi su: Ostali programi koji služe rešavanju problema vezanih za rad mreže i mrežnih servisa su NETSTAT i PING. NETSTAT program služi za pregled aktivnih komunikacionih sesija sa drugim računarima. Ako se pri pokretanju programa ne definiše nikakav argument program će prikazati listu svih aktivnih komunikacionih sesija. Netstat program prikazuje transportni protokol (samo TCP jer UDP protokol ne koristi sesije), zatim lokalnu adresu (ovaj podatak se odnosi na IP adresu ili na ime lokalnog računara) i broj lokalnog porta sa kojeg klijent ostvaruje sesiju, zatim adresu destinacionog računara i broj porta na kojem klijent ostvaruje sesiju i na kraju pokazuje stanje sesije (da li je uspostavljena, na čekanju, itd). Argumenti Netstat programa su: netstat -n = prikaz kroz adrese netstat -5 = prikaz na svakih nekoliko minuta ili sekundi netstat -a = prikaz podataka o svim konekcijama i portovima netstat -b = izvršni fajl procesa sa kojim se ostvaruje veza netstat -e = ethernet statistika netstat -0 = PID proces sa kojim se komunicira netstat -r = tabela rutiranja (takozvani rut print) netstat -s = statistika po protokolu netstat -v = prikaz tačnog imena servisa (-b -v) Prikaz rada Netstat programa sa nekim od argumenata je dat na sledećem primeru: C:\Documents and Settings\User>netstat -e Interface Statistics Received Sent Unicast packets 122612 84096 Non-unicast packets 9310 107 Discards 0 0 Errors 0 0 Unknown protocols 516 PING program je namenjen proveri dostupnosti nekog mrežnog adaptera odnosno računara ili uređaja kome taj mrežni adapter pripada. Radi na principu slanja eho signala ka navedenoj destinaciji. Destinacija je dužna po standardu, ako je dostupna, da odgovori na poslate eho signale. Po standardu Ping program uzastopno šalje 4 eho signala i mora primiti 4 odgovora ako je sve u redu. Kao deo povratne informacije Ping program prikazuje i TTL parametar. Ovim postupkom proveravamo više stvari istovremeno, kao što su dostupnost računara ili rutera, provera konekcije između dva mrežna adaptera, provera ispravnosti mrežnih kablova, itd. Argumenti programa se upisuju ispred tražene adrese ili imena hosta. Argumenti Ping programa su: ping -t = pingovanje destinacije sve dok manuelno ne bude zaustavljeno (ili skriptom) ping -a = razrešavanje adresa u imena hostova ping -n = definisanje broja eho zahteva za slanje ping -l = slanje veličine bafera ping -i = TTL eho zahteva ping -r = snimanje rute ping -s = informacija o vremenu prolaska paketa kroz ruter ping -j = adrese rutera ping -k = putanje svih rutera ping -w = definisanje vremena čekanja na odgovor Prikaz rada Ping programa sa nekim od argumenata je dat na sledećem primeru: C:\Documents and Settings\User>ping -t 127.0.0.1 Pinging 127.0.0.1 with 32 bytes of data: Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Reply from 127.0.0.1: bytes=32 time<1ms TTL=128 Ping statistics for 127.0.0.1: Packets: Sent = 8, Received = 8, Lost = 0 (0% loss), Approximate round trip times in milli-seconds: Minimum = 0ms, Maximum = 0ms, Average = 0ms Control-C Standardni proces dijagnoze korišćenjem Ping programa podrazumeva: Kao zaključak možemo reći da Netstat i Ping program olakšavaju detekciju uzroka problema i pomažu pri njegovom brzom otklanjanju. Oba programa su u praksi u vrlo širokoj upotrebi kao jedan od glavnih alata u radu administratora, programera i ostalih.