|
Hi, Thanks to all who help me setup my MIPv6 testbed. I’ve written a howto document with all the steps I
followed to have this setup running, the problems I had, and how I solved them.
I stored the document along with my configuration files at: http://www.geocities.com/rodolk/sourcecode.html I’m copying here the document. I hope it could help
somebody new to USAGI MIPv6 as I am. If you think there is any error please
tell me. Thanks, Rodolfo. Mobile IPv6 very basic howto ---------------------------- This howto provides all the
steps to have a very basic setup of USAGI Mobile IPv6 stack in Linux and a
testbed with one MN, one HA and an IPv6 CN (with no Mobility) from which you
can run a ping6 against the MN when it is in a visited network. The first problem I had was
to find out which is the "official" MIPv6 project. I found out there
are two web sites and a number of cooperating projects. The projects are USAGI,
KAME, WIDE and MIPL (Go-Core). The two web sites I found are: -www.linux-ipv6.org (USAGI) -www.mobile-ipv6.org I still don't have
everything clear but I took the USAGI project as the official one and I took
its web site as the primary one: www.linux-ipv6.org Here I'm describing the
steps I followed but there are many other ways. You could choose different
versions, different commands to run, etc. I did all in a Fedora 6
distribution. The first step is to choose
the correct kernel version. I read at
www.linux-ipv6.org/umip-0.3-ann.html.en that there is a kernel patch for linux
version 2.6.21-rc5. Then I acted accordingly. You have to go to
www.kernel.org and download kernel 2.6.20 (the last stable version with a
3-part version number smaller than the patch). Install the source code at
/usr/src/linux (it can be a soft link) Once you downloaded and
untared it (tar -xvf ...), you have to apply kernel prepatch rc5 with the patch
command: -Download patch-2.6.21.5.bz2 -Apply the patch to the
kernel source code. Now you have to apply the
kernel patch for mobile IPv6: patch-2.6.21-rc5-mip6.prepatch I downloaded it from
directory ftp://ftp.linux-ipv6.org/pub/usagi/patch/mipv6/umip-0.3/kernel/patch/all-in-one To apply the patches you
have to copy them into the root of the kernel code: /usr/src/linux and then run
command patch < [kernel patch] Use the option --dry-run to
test the patch before actually applying it. Now you have to configure,
compile, and install the new kernel: When you configure the
kernel there are a number of features you need to enable as part of the kernel
in the IP networking section. I enabled all related to IP (see my .config
file). Then run make, make
modules_install, make install. Reboot using the new kernel. You must use the new kernel
in every node that needs MIPv6. Now you have the kernel
ready you must compile and execute the MIPv6 Daemon. MIPv6 has one small part
implemented in the kernel and most of it is implemented as a daemon running in
user space. You must get the daemon from
the GIT repository, from one of the latest branches. I'm new in GIT so there
might be better ways to do this. If you don't have GIT installed you must
download and install it. You must clone the
repository: git-clone
git://git.linux-ipv6.org/gitroot/mipv6-daemon.git This will create your local
git repository in directory mipv6-daemon. As of 23-Jul-2007, you must
not use the master branch, you must use branch umip-20070428 or later. To see all remote branches: git branch -r To work on a specific branch
(or head), like umip-20070428, in your local repository, you create a local
branch. From the root git directory use the command: get checkout -b mycopy
origin/umip-20070428 Now you have the intended
branch instead of the master and you can compile. Run the commands in the
following sequence: aclocal autoreconf -i CPPFLAGS='-isystem
/usr/src/linux/include' ./configure --enable-vt make make install The flag --enable-vt enables
a virtual terminal to get information from the binding cache and others. Read
the existing documentation to learn more. Now you have the correct
patched kernel and the daemon installed. The next step is to copy the
configuration files mip6d.conf into directory /usr/local/etc This file configures the
node to run as MN, HA, or CN. It also set other configuration parameters. I'm
including my own configuration files for MN and HA. You must download and
install radvd in your HA node. I installed radvd 0.9.1 Beyond this point everything
depends on your specific testbed. My tesbed: 2 networks: Net1: Prefix
3ffe:2620:6:1::/64 (Home Network) Net2: Prefix
3ffe:2621:6:1::/64 3 Nodes: MN in network Net2 HA in network Net1 on the
router A CN with only IPv6 in Net1 MN Home Address: 3ffe:2620:6:1::1234/64 HA Address: 3ffe:2620:6:1::1/64
_____
_____
_____ |
|eth0
eth2|
|eth0
eth0| | |
|---------------------| |---------------------| |
-----
-----
-----
MN
HA
CN
3ffe:2621:6:1::/64
3ffe:2620:6:1::/64 Commands in HA: ifconfig eth2 add
3ffe:2621:6:1::5/64 ifconfig eth0 add
3ffe:2620:6:1::1/64 (HA Address, do not forget /64 otherwise the MIPv6 daemon
will stop as soon as you start it) (Static forwarding routes) route -A inet6 add
3ffe:2621:6:1::/64 dev eth2 route -A inet6 add
3ffe:2620:6:1::/64 dev eth0 You may have problems with
IP6TABLES. I just flushed them: ip6tables -F radvd configuration file
must be modified. Specifically indicate that HA is in eth0. I'm including mine. echo "1" >
/proc/sys/net/ipv6/conf/all/forwarding echo "1" >
/proc/sys/net/ipv6/conf/all/proxy_ndp (for proxy neighbor dicovery for MN in
foreign networks) radvd -d5 mip6d -d10 (interactive for
debug info) Commands in the MN: route -A inet6 add
3ffe:2620:6:1::/64 gw 3ffe:2621:6:1::5 mip6d -d10 Commands in CN: (After the MN registered
into its HA) ping6 -I eth0
3ffe:2620:6:1::1234 (The MN HoA) This lets you run a ping6
against a MN in a visited network. Important references: GIT User Manual: www.kernel.org/pub/software/scm/git/docs/user-manual.html USAGI Project: www.linux-ipv6.org www.linux-ipv6.org/umip-0.3-ann.html.en
(info on versions to use) MIPv6 daemon repository: git://git.linux-ipv6.org/gitroot/mipv6-daemon.git |