Open thiagosantos346 opened 5 years ago
root@root: ~# traceroute google.com.br.
root@root:~# traceroute google.com.br traceroute to google.com.br (172.217.162.99), 30 hops max, 60 byte packets 1 gateway (10.0.2.2) 0.344 ms 0.414 ms 0.643 ms 2 192.168.9.1 (192.168.9.1) 0.892 ms 0.902 ms 0.625 ms 3 cisco1.ufg.br (200.137.192.1) 0.859 ms 0.853 ms 0.930 ms 4 pop-e01-core-ufg-embrapa.metrogyn.pop-go.rnp.br (200.137.224.73) 6.962 ms 6.945 ms 6.922 ms 5 go-lango.bkb.rnp.br (200.143.255.221) 1.491 ms 1.481 ms 1.463 ms 6 * 7 170.79.213.5 (170.79.213.5) 21.675 ms 21.546 ms 21.515 ms 8 as15169.saopaulo.sp.ix.br (187.16.218.58) 23.501 ms 22.874 ms 170.79.215.3 (170.79.215.3) 34.961 ms 9 74.125.243.65 (74.125.243.65) 34.076 ms 34.013 ms 34.021 ms 10 209.85.255.14 (209.85.255.14) 34.597 ms 216.239.50.113 (216.239.50.113) 23.022 ms 209.85.250.128 (209.85.250.128) 23.342 ms 11 gru14s07-in-f3.1e100.net (172.217.162.99) 22.830 ms 22.468 ms 22.431 ms
root@root:~# traceroute --help
Usage:
traceroute [ -46dFITnreAUDV ] [ -f first_ttl ] [ -g gate,... ] [ -i device ] [ -m max_ttl ] [ -N squeries ] [ -p port ] [ -t tos ] [ -l flow_label ] [ -w waittime ] [ -q nqueries ] [ -s src_addr ] [ -z sendwait ] [ --fwmark=num ] host [ packetlen ]
Options:
-4 Use IPv4
-6 Use IPv6
-d --debug Enable socket level debugging
-F --dont-fragment Do not fragment packets
-f first_ttl --first=first_ttl
Start from the first_ttl hop (instead from 1)
-g gate,... --gateway=gate,...
Route packets through the specified gateway
(maximum 8 for IPv4 and 127 for IPv6)
-I --icmp Use ICMP ECHO for tracerouting
-T --tcp Use TCP SYN for tracerouting (default port is 80)
-i device --interface=device
Specify a network interface to operate with
-m max_ttl --max-hops=max_ttl
Set the max number of hops (max TTL to be
reached). Default is 30
-N squeries --sim-queries=squeries
Set the number of probes to be tried
simultaneously (default is 16)
-n Do not resolve IP addresses to their domain names
-p port --port=port Set the destination port to use. It is either
initial udp port value for "default" method
(incremented by each probe, default is 33434), or
initial seq for "icmp" (incremented as well,
default from 1), or some constant destination
port for other methods (with default of 80 for
"tcp", 53 for "udp", etc.)
-t tos --tos=tos Set the TOS (IPv4 type of service) or TC (IPv6
traffic class) value for outgoing packets
-l flow_label --flowlabel=flow_label
Use specified flow_label for IPv6 packets
-w waittime --wait=waittime
Set the number of seconds to wait for response to
a probe (default is 5.0). Non-integer (float
point) values allowed too
-q nqueries --queries=nqueries
Set the number of probes per each hop. Default is
3
-r Bypass the normal routing and send directly to a
host on an attached network
-s src_addr --source=src_addr
Use source src_addr for outgoing packets
-z sendwait --sendwait=sendwait
Minimal time interval between probes (default 0).
If the value is more than 10, then it specifies a
number in milliseconds, else it is a number of
seconds (float point values allowed too)
-e --extensions Show ICMP extensions (if present), including MPLS
-A --as-path-lookups Perform AS path lookups in routing registries and
print results directly after the corresponding
addresses
-M name --module=name Use specified module (either builtin or external)
for traceroute operations. Most methods have
their shortcuts (-I' means
-M icmp' etc.)
-O OPTS,... --options=OPTS,...
Use module-specific option OPTS for the
traceroute module. Several OPTS allowed,
separated by comma. If OPTS is "help", print info
about available options
--sport=num Use source port num for outgoing packets. Implies
-N 1' --fwmark=num Set firewall mark for outgoing packets -U --udp Use UDP to particular port for tracerouting (instead of increasing the port per each probe), default port is 53 -UL Use UDPLITE for tracerouting (default dest port is 53) -D --dccp Use DCCP Request for tracerouting (default port is 33434) -P prot --protocol=prot Use raw packet of protocol prot for tracerouting --mtu Discover MTU along the path being traced. Implies
-F -N 1'
--back Guess the number of hops in the backward path and
print if it differs
-V --version Print version info and exit
--help Read this help and exit
Arguments:
traceroute ufg.br traceroute to ufg.br (200.137.192.17), 30 hops max, 60 byte packets 1 gateway (10.0.2.2) 0.123 ms 0.220 ms 0.098 ms 2 192.168.9.1 (192.168.9.1) 0.444 ms 0.556 ms 0.436 ms 3 ns.ufg.br (200.137.192.17) 0.688 ms 0.795 ms 0.763 ms
b) São 3 Hosts até ufg.br;
c) São 11 saltos até google.com. traceroute google.com traceroute to google.com (216.58.202.206), 30 hops max, 60 byte packets 1 gateway (10.0.2.2) 0.233 ms 0.136 ms 0.214 ms 2 192.168.9.1 (192.168.9.1) 0.736 ms 0.695 ms 0.615 ms 3 cisco1.ufg.br (200.137.192.1) 1.464 ms 1.390 ms 1.308 ms 4 pop-e01-core-ufg-embrapa.metrogyn.pop-go.rnp.br (200.137.224.73) 6.846 ms 5.163 ms 6.027 ms 5 go-lango.bkb.rnp.br (200.143.255.221) 1.433 ms 1.356 ms 1.308 ms 6 * 7 170.79.213.5 (170.79.213.5) 23.422 ms 23.376 ms 23.290 ms 8 as15169.saopaulo.sp.ix.br (187.16.218.58) 22.812 ms as15169.saopaulo.sp.ix.br (187.16.216.55) 22.934 ms as15169.saopaulo.sp.ix.br (187.16.218.58) 22.807 ms 9 108.170.245.129 (108.170.245.129) 22.253 ms 108.170.245.161 (108.170.245.161) 23.455 ms 108.170.245.129 (108.170.245.129) 22.137 ms 10 72.14.238.23 (72.14.238.23) 22.742 ms 72.14.239.25 (72.14.239.25) 22.868 ms 216.239.50.110 (216.239.50.110) 23.764 ms 11 72.14.238.23 (72.14.238.23) 22.817 ms gru06s31-in-f206.1e100.net (216.58.202.206) 22.919 ms 23.112 ms
raceroute google.com.br -m 5 traceroute to google.com.br (216.58.202.195), 5 hops max, 60 byte packets 1 gateway (10.0.2.2) 0.307 ms 0.235 ms 0.192 ms 2 192.168.9.1 (192.168.9.1) 0.755 ms 0.816 ms 0.915 ms 3 cisco1.ufg.br (200.137.192.1) 0.863 ms 1.003 ms 1.066 ms 4 pop-e01-core-ufg-embrapa.metrogyn.pop-go.rnp.br (200.137.224.73) 2.622 ms 3.150 ms 3.114 ms 5 go-lango.bkb.rnp.br (200.143.255.221) 13.986 ms 13.950 ms 1.976 ms traceroute [options] host [packetsize] [Options: -d -f n -F -g addr -i interface -I -m max_ttl -n -p port -q n -r -s src_addr -t tos -v -w wait -x -z msecs]
N- squeries Especifica o número de pacotes de análise enviados simultaneamente. O envio de várias sondas ao mesmo tempo pode acelerar consideravelmente o traceroute . O valor padrão é 16. Observe que alguns roteadores e hosts podem usar a aceleração de taxa de ICMP. Em tal situação, especificar um número muito grande pode levar à perda de algumas respostas.
root@root:~# traceroute google.com -n 6 traceroute to google.com (172.217.28.238), 30 hops max, 28 byte packets 1 10.0.2.2 0.211 ms 0.147 ms 0.203 ms 2 192.168.9.1 1.065 ms 1.033 ms 0.980 ms 3 200.137.192.1 0.931 ms 1.026 ms 0.971 ms 4 200.137.224.73 4.138 ms 2.084 ms 2.288 ms 5 200.143.255.221 1.301 ms 1.302 ms 1.276 ms 6 7 170.79.213.5 21.630 ms 22.434 ms 21.509 ms 8 170.79.215.3 22.308 ms 23.250 ms 23.113 ms 9 74.125.243.65 24.354 ms 74.125.243.1 22.253 ms 10 209.85.250.51 23.897 ms 23.419 ms 209.85.246.137 23.563 ms 11 172.217.28.238 23.184 ms 22.120 ms 23.366 ms
traceroute google.com 1400 -m 100 -q 3 traceroute to google.com (216.58.202.142), 100 hops max, 1400 byte packets 1 gateway (10.0.2.2) 0.157 ms 0.062 ms 0.085 ms 2 192.168.9.1 (192.168.9.1) 0.924 ms 0.861 ms 0.807 ms 3 cisco1.ufg.br (200.137.192.1) 1.213 ms 1.499 ms 1.427 ms 4 pop-e01-core-ufg-embrapa.metrogyn.pop-go.rnp.br (200.137.224.73) 2.625 ms 3.480 ms 2.955 ms 5 go-lango.bkb.rnp.br (200.143.255.221) 2.409 ms 2.337 ms 2.265 ms 6 7 170.79.213.5 (170.79.213.5) 22.241 ms 22.842 ms 22.093 ms 8 170.79.215.3 (170.79.215.3) 23.240 ms as15169.saopaulo.sp.ix.br (187.16.218.58) 24.121 ms 170.79.215.3 (170.79.215.3) 23.043 ms 9 10 gru06s29-in-f14.1e100.net (216.58.202.142) 23.774 ms 209.85.248.72 (209.85.248.72) 23.874 ms 216.239.50.110 (216.239.50.110) 23.984 ms
a) O mtr não vem instalado por padrão em algumas distribuições linux, portanto, é necessário realizar sua instalação antes de continuar as atividades abaixo.
aluno@PT649456:~$ mtr -help usage: mtr [--help] [--version] [-4|-6] [-F FILENAME] [--report] [--report-wide] [--xml] [--gtk] [--curses] [--raw] [--csv] [--split] [--no-dns] [--show-ips] [-o FIELDS] [-y IPINFO] [--aslookup] [-i INTERVAL] [-c COUNT] [-s PACKETSIZE] [-B BITPATTERN] [-Q TOS] [--mpls] [-a ADDRESS] [-f FIRST-TTL] [-m MAX-TTL] [--udp] [--tcp] [-P PORT] [-Z TIMEOUT] [-M MARK] HOSTNAME See the man page for details.
aluno@PT649456:~$ mtr -rw kyoto-u.ac.jp Start: Wed Mar 27 21:28:09 2019
aluno@PT649456:~$ mtr -rw kyoto-u.ac.jp Start: Wed Mar 27 21:28:09 2019 HOST: PT649456 Loss% Snt Last Avg Best Wrst StDev
1:30:30 2019 HOST: PT649456 Loss% Snt Last Avg Best Wrst StDev 1.|-- 2001:12f0:c0b:812::1 0.0% 10 0.6 0.6 0.5 0.7 0.0 2.|-- ??? 100.0 10 0.0 0.0 0.0 0.0 0.0 3.|-- 2001:12f0:c00:c2::1 0.0% 10 2.1 2.7 2.0 4.7 0.7 4.|-- 2001:12f0:0:ff::dd 0.0% 10 1.2 1.2 1.0 1.6 0.0 5.|-- ??? 100.0 10 0.0 0.0 0.0 0.0 0.0 6.|-- 2001:12f0:ffff:0:201:0:20 0.0% 10 21.9 21.5 21.2 21.9 0.0 7.|-- as15169.saopaulo.sp.ix.br 0.0% 10 23.1 23.5 23.1 25.1 0.3 8.|-- 2001:4860:0:9d::1 0.0% 10 23.7 23.5 23.3 24.2 0.0 9.|-- 2001:4860:0:1::2497 0.0% 10 23.1 23.1 23.0 23.3 0.0 10.|-- 2800:3f0:4001:80f::200e 0.0% 10 23.0 23.2 22.9 23.8 0.0 aluno@PT649456:~$ mtr --report kyoto-u.ac.jp Start: Wed Mar 27 21:31:27 2019 HOST: PT649456 Loss% Snt Last Avg Best Wrst StDev
c) Após executar o mtr é possível identificar alguma diferença em relação ao traceroute?
Sim é mostrado a perda de pacotes;
Algumas ferramentas de rede, medição de atrasos, perdas, captura de pacotes.