Multiple VLAN on the LAN port, how?
Posted: 10 Nov 2013, 10:55
Hi all,
I would like to have two separate netwokrs at home but my ISP only give me one public IP adress. My thinking on how to solve this was to add a VLAN on the B3 LAN port and have a switch divide the networks.
I created the VLAN using by adding the following to /etc/network/interfaces
After a restart the ifconfig command gave my this output
To enable DHCP on the new interface I also updated the /etc/dnsmasq.conf with the following line
and then restarted dnsmasq using
In the switch I split the networks on two different port, when connecting my computer to the "eth1" port I get DHCP from my B3 and I have internet connection. When connecting to the "eth1.20" port I do not get any IP adress assigen to me.
What is missing to get this working?
I have checked and doubble checked my switch configuration and it looks correct. Should I continute checking the switch configuration or is there something more that needs to be done to enable DHCP on the VLAN interface?
Edit: Firewall.
I Now also made the following additions to the Firewall configuration (guessing wild)
And then run the command
No difference 
Best Regards,
Morgan
I would like to have two separate netwokrs at home but my ISP only give me one public IP adress. My thinking on how to solve this was to add a VLAN on the B3 LAN port and have a switch divide the networks.
I created the VLAN using by adding the following to /etc/network/interfaces
Code: Select all
auto eth1.20
iface eth1.20 inet static
address 10.69.20.1
netmask 255.255.255.0
Code: Select all
eth1.20 Link encap:Ethernet HWaddr 00:22:02:00:15:55
inet addr:10.69.20.1 Bcast:10.69.20.255 Mask:255.255.255.0
inet6 addr: fe80::222:2ff:fe00:1555/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:0 frame:0
TX packets:152 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:0 (0.0 B) TX bytes:27462 (26.8 KiB)
Code: Select all
dhcp-range=10.69.20.50,10.69.20.100,12h
Code: Select all
/etc/init.d/dnsmasq restart
What is missing to get this working?
I have checked and doubble checked my switch configuration and it looks correct. Should I continute checking the switch configuration or is there something more that needs to be done to enable DHCP on the VLAN interface?
Edit: Firewall.
I Now also made the following additions to the Firewall configuration (guessing wild)
Code: Select all
-A INPUT -i eth1.20 -j ACCEPT
-A FORWARD -i eth1.20 -j ACCEPT
Code: Select all
iptables-restore < firewall.conf

Best Regards,
Morgan