0

I've been searching through the internet for a while now. And trying things. I can't get this to work.

I setup two VM's with virtualbox bridged to eth0 interface. One running Ubuntu Sever and the other running Ubuntu Desktop. Both version 14.

I am trying to set it up for ipv6.

Server:

auto vlan80
iface vlan80 inet6 static
address 2001:aaaa:bbbb:1::1
netmask 64
vlan-raw-device eth0


auto vlan90
iface vlan90 inet6 static
address 2001:aaaa:cccc:1::1
netmask 64
vlan-raw-device eth0

I setted ipv6 forwarding to 1 on sysctl.conf in the server.

I have two vlans. VLAN 80 and VLAN 90. Ubuntu server is acting like a ROUTER, it is the gateway for both vlans. There is communication inside the vlans. Hosts in the vlan can communicate with each other, and they can ping their gateway. Both VLANS are DIRECTLY connected to the router.

But there is NO communication between different vlans. The router is not forwarding packets between vlans. I cannot ping from interface vlan80 to interface vlan90 using the command "ping -I vlan80 2001:aaaa:cccc:1::1". It says the network is unreachable.

Screenshot of ifconfig and the ping i am trying to achieve. https://i.stack.imgur.com/x0Tdg.jpg

Cholax
  • 31
  • 5
  • @Terrance i did what it says here: https://wiki.ubuntu.com/vlan – Cholax Apr 06 '18 at 17:00
  • Removing all my previous comments. You need to add that info to your question that you can ping from one to the other "But i cannot ping from Host A to Host B. Nor from Host A to Gateway B, nor Host B to Gateway A." – Terrance Apr 06 '18 at 17:59
  • It is there, maybe not clear enough. ill try to make it simpler. Thanks. – Cholax Apr 06 '18 at 18:01
  • @Cholax The question is the VLAN part. It might be best to make a diagram of how things're configured, so we can understand how the systems / virtual switches / etc. are all set up as well. – Thomas Ward Apr 06 '18 at 18:02
  • @ThomasWard For now i just want to be able to ping from one interface to the another. And both interfaces are on the same machine. I added a screenshot. – Cholax Apr 06 '18 at 18:21
  • Your interface names are wrong. You have `vlan80` and `vlan90` and these should be `eth0.80` and `eth0.90`. This was also shown in the document you linked. – Michael Hampton Apr 06 '18 at 18:26
  • @MichaelHampton It works the same. At first i used eth0.80 but i saw you could put vlan80 and it would work the same. So i did it. – Cholax Apr 06 '18 at 19:20
  • I am adding one more comment here as I am out of ideas on the issue you are having, but have you set up iptables forwarding? See: https://askubuntu.com/questions/590920/ubuntu-14-04-as-a-gateway-router-and-a-firewall That is all I have. – Terrance Apr 07 '18 at 13:01
  • @Terrance I think i found the problem. I checked the ipv6 routes in the client and it is not configuring the gateway for vlan80 and vlan90 for some reason. So there's no way to ping other networks if there is no gateway. I am using network manager and there the gateways are setup but for some reason ubuntu desktop is not configuring them. – Cholax Apr 07 '18 at 19:06
  • Solved. Ubuntu server was forwarding. Problem was network manager in the client wasn't adding the corresponding gateways to the vlans, so i manually added them. – Cholax Apr 07 '18 at 19:53
  • @Cholax You might want to add this as an answer. – Thomas Ward Apr 09 '18 at 16:34

1 Answers1

0

Ubuntu server was forwarding. Problem was network manager in the client wasn't adding the corresponding gateways to the vlans.

To solve I manually added the corresponding gateways to the vlans.

Stephen Rauch
  • 1,156
  • 6
  • 14
  • 20
Cholax
  • 31
  • 5