Project

General

Profile

Actions

Support #220

closed

Sharing internet connection with batman-adv

Added by Santiago Alvarez over 9 years ago. Updated almost 8 years ago.

Status:
Rejected
Priority:
High
Assignee:
-
Target version:
-
Start date:
07/06/2015
Due date:
% Done:

0%

Estimated time:

Description

Hello,

I’me trying to share interenet connection with batman-adv. I can do that, but I’m experiencing an extreme low speed and I don’t know where the problem can be.

I managed to configure batman-adv in two Beaglebone Black running Ubuntu 12.04.
The first one is connected to my router via ethernet and has a wifi adapter. I configured batman-adv over the wifi interface and after that I bridged eth0 with bat0. The process is as follows:
#iwconfig wlan0 mode ad-hoc essid "mesh" channel 1 key "0123456789" mtu 1532
#modprobe batman-adv
#batctl if add wlan0
#ifconfig wlan0 up
#brctl addbr mesh-bridge
#brctl addif mesh-bridge eth0
#brctl addif mesh-bridge bat0
#ifconfig eth0 0.0.0.0 up
#ifconfig bat0 0.0.0.0 up
#ifconfig mesh-bridge 192.168.2.153 up
#batctl gw_mode server 10mbit/2mbit

Notice that 192.168.2.153 was the ip that I previously had in my eth0 interface.
With this configuration I can ping any internet site without problems.
Now, I have a second Beaglebone. I use a direct ethernet connection between my pc and Beaglebone. In fact, I'm using ssh to connect to my beaglebone from my pc. This one also has a wireless adapter. For this one I'm using this configuration
#iwconfig wlan0 mode ad-hoc essid "mesh" channel 1 key "0123456789" mtu 1532
#modprobe batman-adv
#batctl if add wlan0
#ifconfig wlan0 up
#ifconfig bat0 up
Doing this I'm connected to the mesh network via batman-adv. I can ping the other node with "batctl ping".
Now, in order to have internet access from the second node, I need to do a few things:
1. Tell the second node it is a gateway client:
#batctl gw_mode client
2. Update route table with the correct gateway. To do this, first I have to asign a new ip to the bat0 interface:
#ifconfig bat0 192.168.2.154
#route add default gw 192.168.2.1 bat0
Just after doing this last operation, I can successfully execute:
root@ubuntu-armhf:/home/ubuntu# ping google.com
PING google.com (178.60.128.57) 56(84) bytes of data.
64 bytes from cache.google.com (178.60.128.57): icmp_req=1 ttl=59 time=4.55 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=2 ttl=59 time=6.30 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=3 ttl=59 time=5.09 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=4 ttl=59 time=5.98 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=5 ttl=59 time=6.16 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=6 ttl=59 time=5.15 ms
As you can see, times are not bad, but... there are almost 60 seconds between the reception of a packet and the next one.
Any clue about what can be happening? Maybe I'm forgetting any configuration...
Thank you in advance!

Actions #1

Updated by Antonio Quartulli over 9 years ago

I have not fully understood your setup, but before digging into that, could you explain where the output below says that there are 60 seconds between one packet and the other?

Santiago Alvarez wrote:

root@ubuntu-armhf:/home/ubuntu# ping google.com
PING google.com (178.60.128.57) 56(84) bytes of data.
64 bytes from cache.google.com (178.60.128.57): icmp_req=1 ttl=59 time=4.55 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=2 ttl=59 time=6.30 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=3 ttl=59 time=5.09 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=4 ttl=59 time=5.98 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=5 ttl=59 time=6.16 ms
64 bytes from cache.google.com (178.60.128.57): icmp_req=6 ttl=59 time=5.15 ms
As you can see, times are not bad, but... there are almost 60 seconds between the reception of a packet and the next one.
Any clue about what can be happening? Maybe I'm forgetting any configuration...
Thank you in advance!

Thanks!

Actions #2

Updated by Santiago Alvarez over 9 years ago

Thank you for your anser.

The output doesn’t say there are 60 seconds between packets but, it expend about 30-60 seconds between one ping packet result line appearing in the screen and the next one. However ping times of 4 to 6 ms seems to be fine.

Tell me what you don't understand from my problem and I'll do my best to explain.

Regards,

Santiago A.

Actions #3

Updated by Antonio Quartulli over 9 years ago

Thanks for clarifying this doubt.

At this point I'd suggest you to write to the mailing list where other people can join the discussion and help understanding where the issue is coming from.

This tracker is only for batman-adv specific bugs.

Thanks!

Actions #4

Updated by Marek Lindner over 9 years ago

  • Status changed from New to Closed

Closing ticket as discussion will move to the mailing list.

Actions #5

Updated by Sven Eckelmann almost 8 years ago

  • Status changed from Closed to Rejected
Actions

Also available in: Atom PDF