|
S E Ç Õ E S |
|
|
B U S C A |
|
|
|
D E S T A Q U E |
|
|
 |
|
|
 |
|
|
 |
|
E N Q U E T E |
|



|
- 2001
Todos os direitos reservados
|
|
|
H O W T O
|

|
|
|
|
08/11/01 18:59 - IPV6 no FreeBSD, habilitando e usando
Mauro Dias Ribeiro Junior
Bom, pra quem ainda nao conhece eu vo apresentar ele, o IPV6.
O IPv6 nasceu em 97, foi criado para substituir o IPv4 (atualmente usado).
Neste HOWTO vo tentar explicar como instala-lo em sua maquina.
**** MUITO IMPORTANTE PARA MAIORES DETALHES LEIA www.ipv6.org ****
IP = Internet Protocol.
Vamos la intao. primeira coisa vamos habilitar o suporte a ipv6 na sua
kernel (kernel GENERIC ja tem suporte).
# cd /usr/src/sys/i386/conf
# $EDITOR sua.kernel
Adicione as sequintes linhas na sua kernel.
options INET6 #Protocolo de Comunicacao do IPV6
pseudo-device gif #Ipv6 sobre IPv4 Tunnel
pseudo-device faith 1 #Tradutor de IPv6 para ipv4
pseudo-device stf #Encapsulacao de Ipv6 para ipv4
(Caso voce use Firewall e deseja ja testar o suporte a firewall com ipv6,
adicione mais as linhas)
options IPV6FIREWALL
options IPV6FIREWALL_VERBOSE
options IPV6FIREWALL_VERBOSE_LIMIT=100
options IPV6FIREWALL_DEFAULT_TO_ACCEPT
Agora salve o arquivo.
# config sua.kernel
# cd ../../compile/sua.kernel
# make clean depend all install
Reinicie o computador agora. e espere sua nova kernel com suporte a IPv6 :)
Ate ia tudo bem voce ja habilitou o suporte a ipv6 agora temos q usalo
certo ?
ai eh a parte legal.
Como o ipv6 ainda nao eh o padrao nos vamos usar um tunnel(que vai
transformar ipv6 em ipv4) que eh fornecido pela freenet6.
Voce deve baixar o freenet6 para unix no seguinte endereco:
http://www.freenet6.net/cgi-bin/download.cgi?fn=freenet6-0.9.3.tgz
Abra esta pagina com seu navegador (lynx, netscape, opera, qualquer coisa..)
Leia o termo de licensa aceite e clique no botao la.. que vc vai baixar o
arquivo.
depois que baixar faca assim:
# tar -zxvf freenet6-0.9.3.tgz
# cd freenet6-0.9.3/
Se voce usa FreeBSD 4.3 ou versoes anteriores
digite
# make freebsd4
se vc ja esta usando 4.4
digite
# make freebsd44
agora digite
# cd bin
vc tera q fazer o tspc.conf
o meu esta assim:
#-----------------------------------------------------------------------------
# tspc.conf
#-----------------------------------------------------------------------------
#
# tsp client version
#
tsp_version=1.0.0
tsp_dir=/root/freenet6-0.9.3
#
# auth_method=any|supported mechanism
# if any is specified, the first mechanism that is supported by both the
# server and the client will be picked. The order of precedence is the
# mechnism list shown by the output of -h. supprted mechanism is one of
# the token shown by th output of -h (case sensitive).
auth_method=any
#
# client_v4=auto|1.1.1.1 (valid ip address)
# if auto is specified, if_source or -s cmd line option must be specified.
client_v4=auto
# userid=anonymous
# the userid can be anonymous or any alphanumeric value that is dns legal.
userid=anonymous
passwd=
# template=target
# template tells which configuration script needs to be run for interface
# setup.
# Normally you only need to put your osname in the value.
# You can also use "checktunnel" if you only want the tunnel info print out.
#template=checktunnel
template=freebsd44
server=tsps1.freenet6.net
#server=localhost
if_tunnel=gif0
# end of tspc.conf
#-----------------------------------------------------------------------------
eu recomendo vc entrar em www.freenet6.net e se cadastrar para ter um
userid/passwd proprio. (Eh Gratuito) eu tenhu o meu :)
mais isto eh para depois, agora vamos testar. Rode o tspc
# ./tspc
Logo em seguida ele mostrar umas menssages eh normal ele demorar um
pouco...
Agora digite:
# /sbin/ifconfig gif0
o meu fica assim:
gif0: flags=8051 mtu 1280
tunnel inet 200.158.34.36 --> 206.123.31.114
inet6 fe80::2e0:7dff:fe99:9db%gif0 prefixlen 64 scopeid 0x8
inet6 3ffe:b80:2:1b16::2 --> 3ffe:b80:2:1b16::1 prefixlen 128
o seu deve ficar parecido..
deixa eu explicar isto ai.. agora para vcs.
gif0: flags=8051 mtu 1280
(1) tunnel inet 200.158.34.36 --> 206.123.31.114
(2) inet6 fe80::2e0:7dff:fe99:9db%gif0 prefixlen 64 scopeid 0x8
(3) inet6 3ffe:b80:2:1b16::2 --> 3ffe:b80:2:1b16::1 prefixlen 128
(1)
tunnel inet 200.158.34.36 --> 206.123.31.114
cria um caminho do seu ip para o 206.123.31.114 (pode variar este ip) que
eh o do servidor da FreeNET6
(2)
inet6 fe80::2e0:7dff:fe99:9db%gif0 prefixlen 64 scopeid 0x8
endereco local de ipv6 da gif0 :)
(3)
(agora o melhor de tudo)
inet6 3ffe:b80:2:1b16::2 --> 3ffe:b80:2:1b16::1 prefixlen 128
seu ip eh o 3ffe:b80:2:1b16::2 (mentira q este eh o meu :)) e o seu
gatewayv6 q eh 3ffe:b80:2:1b16::1
como eu disse no comeco do texto vc deve ler o www.ipv6.org para entender
melhor a nova versao do IP.
testanto seu ipv6.
traceroute:
# traceroute6 6bone.net
traceroute6 to 6bone.net (3ffe:b00:c18:1::10) from 3ffe:b80:2:1b16::2, 30
hops max, 12 byte packets
1 3ffe:b00:c18:1:2a0:c9ff:fefc:1feb 229.461 ms 231.888 ms 233.559 ms
2 www.6bone.net 208.582 ms 206.27 ms 229.521 ms
#
-> Por que o traceroute6?
<- porque eh a versao do traceroute para ipv6 :))
ping:
# ping6 6bone.net
PING6(56=40+8+8 bytes) 3ffe:b80:2:1b16::2 --> 3ffe:b00:c18:1::10
16 bytes from 3ffe:b00:c18:1::10, icmp_seq=0 hlim=62 time=205.587 ms
16 bytes from 3ffe:b00:c18:1::10, icmp_seq=1 hlim=62 time=202.951 ms
16 bytes from 3ffe:b00:c18:1::10, icmp_seq=2 hlim=62 time=204.28 ms
16 bytes from 3ffe:b00:c18:1::10, icmp_seq=3 hlim=62 time=205.214 ms
^C
--- 6bone.net ping6 statistics ---
4 packets transmitted, 4 packets received, 0% packet loss
round-trip min/avg/max = 202.951/204.508/205.587 ms
-> neste caso tb usando o ping6 :)
e mais outros programas como o whois, se vc rodar ele com a opcao -6 para
procurar dominios ja registrado sobre ipv6.
mais uma coisa.. resolvendo nomes em ipv6
facinhu :)))
# nslookup -q=aaaa 6bone.net
Server: server.mdrjr.net
Address: 192.168.0.1
Non-authoritative answer:
6bone.net IPv6 address = 3ffe:b00:c18:1::10
o -q=aaaa
q eh para o nslookup requisitar o AAAA do nameserver (bind9 ja tem
suporte a ipv6) que seria algo tipo o IN A do ipv4 :)
Valeu Pessoal :)
Espero ter ajudado.
Mauro Dias Ribeiro Junior
Mauro Dias Ribeiro Junior
|
|