Bpi and gateway with wire

(Frank W.) #21

it is slow because of packet-drops…every dropped packet have to requested and sent again


compiled Package:

backup your old uImage before overwriting. you have to change kernel-var in uEnv.txt if using another name than “uImage” for kernel

but something is strange in your system/with your r2

made test from my client over r2 (forwarding+nat/pat) to internet

--- www.google.com ping statistics ---
533 packets transmitted, 533 received, 0% packet loss, time 532747ms
rtt min/avg/max/mdev = 14.064/28.386/1037.457/90.110 ms, pipe 2

have you looked on soldering-points of ethernet-ports? there were some bad ones on sata of some people here…maybe your ethernet-ports are affected with same issue

(Troumad) #22

The welds seem normal, How did you see the welding problems? My BPI-R2 is in a box : https://e.banana-pi.fr/2165-thickbox_default/boitier-acrylique-pour-le-routeur-banana-pi-bpi-r2.jpg

Why backup my kernel ? If it’s don’t run I make a new sd-card. With a new config, first only for forwarding+nat/pat to internet. Start from nothing… And try now…

Now, I run with the new kernel…

The bpi-r2 is in the network (wan with lan0) and I can not communicate with the bridge.

No time now…

(Troumad) #23

Error… I can’t remove this.

(Frank W.) #24

You have a usb2serial-cable?

You have copied uImage to first partition in bananapi/bpi-r2/linux and modules to second partition (/lib/modules)?

Basicly folder-structure inside the archive

(Troumad) #25

I don’t have some time… But I have do test.

I think that’s bridge do not run. hdmi do not run. I have a usb2serial-cable, but I don’t remember who :disappointed_relieved:

--- www.google.fr ping statistics ---
137 packets transmitted, 116 received, 15% packet loss, time 136595ms
rtt min/avg/max/mdev = 23.458/24.050/24.996/0.266 ms

(Frank W.) #26

if you use lan0 as wan and bridging lan1-3 why not using wan as management-interface with fixed address?

(Troumad) #27

Hello I come back !

I think that’s I have not welding problems. I have try all lan and the wan in the network.

root@bpi-r2:~# cat /etc/network/interfaces
source-directory /etc/network/interfaces.d

auto eth1
iface eth1 inet manual
  pre-up ip link set $IFACE up
  post-down ip link set $IFACE down

auto eth0
iface eth0 inet manual
  pre-up ip link set $IFACE up
  post-down ip link set $IFACE down

auto wan
allow-hotplug wan
  iface wan inet dhcp
  pre-up ip link set $IFACE address 32:D1:55:7D:03:39 up

auto lan0
allow-hotplug lan0
  iface lan0 inet dhcp

auto lan1
allow-hotplug lan1
  iface lan1 inet dhcp

auto lan2
allow-hotplug lan2
  iface lan2 inet dhcp

auto lan3
allow-hotplug lan3

iface lan3 inet dhcp

All the lan0-3 have the same mac address ! I was connected in the bpi-r2 by the WiFi and try all the wired port : I my computer I test ping to wan. stop it. And in the bpi-r2, I do :

ifdown wan
ifdown lan0
ifup lan0

I deconnect the wire of wan and put it at lan0 and test ping with lan0.

--- ping statistics ---
2705 packets transmitted, 2700 received, 0% packet loss, time 2768924ms
rtt min/avg/max/mdev = 0.250/0.325/0.515/0.033 ms

No problem I think.

(Frank W.) #28

DSA-User-ports (wan,lanx) getting mac-address from CPU-port (ethx). Currently i’m testing to set fixed mac (default is random) without compiling full kernel.

You have no more problem with pingdrops?

(Troumad) #29

No problem with this test. But it’s not the config that I need.

(Frank W.) #30

You tested each port? If now all it’s ok you can move to your config step by step. But do not bridge wan+lan or ap0 with lan/wan

(Troumad) #31

Before this hollyday, I have tested a bridge with lan0-3 only. It don’t work. I test no bridge (only lan0 zum bispiel) when I can.

(Troumad) #32

I have try to have a DHCP in my bridge :

auto br0
  iface br0 inet dhcp
  pre-up ip link set $IFACE address 32:D1:55:7D:03:39 up
  bridge_ports lan0 lan1 lan2 lan3
  bridge_fd 5
  bridge_stp no
  up /etc/init.d/firewall start

It don’t work. The bridge need have a public address !

(Frank W.) #33

i don’t think this is possible, all your clients need a public ip too. why not connect your ISP to wan and your clients to lan-bridge? thats the normal setup and r2 can do what it is designed for…routing :slight_smile:

bridging your lan to public internet is a very bad idea

(Troumad) #34

I think that’s I have do this with the BPI-R2 and ubuntu. The PBI-R2 has work als a swith.

(Troumad) #35

Today I have a little time to test…

I don’t nothing understand. Before the test I have :

auto wan
  iface wan inet dhcp
  pre-up ip link set $IFACE address 32:D1:55:7D:03:39 up
  up /etc/init.d/firewall start

Before today I have never see problem with this. But today I have rbbot my BPI-R2 and after I have this :

--- ping statistics ---
2260 packets transmitted, 2173 received, 3.84956% packet loss, time 2545ms
rtt min/avg/max/mdev = 0.347/0.484/0.587/0.044 ms

I have the problem I had with the bridge br0 :I can’t run vi with a big file.

I try it :

auto lan0
  iface lan0 inet dhcp
  pre-up ip link set $IFACE address 32:D1:55:7D:03:39 up
  up /etc/init.d/firewall start

and I have no problem.

--- ping statistics ---
111 packets transmitted, 111 received, 0% packet loss, time 748ms
rtt min/avg/max/mdev = 0.349/0.487/0.607/0.052 ms

After this reboot I have a problem with the https server. It answers with, but it don’t answers with a public name (I use ovh for my domaine). The name is good “ssh mein_mane” is good but it’s redirect to a other computer. When it’s redirect to the BPI-R2, it’s don’t run.
And I don’t see any problem in /var/log.

(Troumad) #36

The problem with https redirection was due to the interfaces file
Now, I test the ping.

Have you a good configuration for a bridge ?

(Troumad) #37

The ping :

--- ping statistics ---
1146 packets transmitted, 1144 received, 0.17452% packet loss, time 1681ms
rtt min/avg/max/mdev = 0.329/0.422/0.558/0.053 ms