Inter-Vlan done right finally! or is it? :)
Hi,
I finally managed to setup inter-vlan in my tp-link t1700g-28tq switch successfully and wanted to share my settings here. I didn't understand the logic fully so i may have questions. I set it up by trial and error and thanks to helpfull people in this forum. I hope it may help other newbies like me trying to set up their own vlans and don't hesitate to correct me anywhere.
To be honest, i didnt need inter-vlan in my house as i didnt have that many machines. I bought this switch as it have 4 spf+ ports with port truncating features but as i am curious about learning new things i said why not learn some new things about networking.
My current network is like below:
So for the people like me who are new to networking world and its terminology, inter-vlan is a concept about connecting computers in different sub nets like 192.168.1.150 to 192.168.10.150.
For example i can ping my laptop with a ip of 192.168.20.100 from my computer (my ip: 192.168.10.70 with a subnet mask of 255.255.255.0) and each computer can access the internet from different subnets.
First here is my vlan configuration below: ( L2 Features \ Vlan \ 802.1-Q Vlan )
My router is connected through port 2 of the switch so i made sure port 2 and other unused ports are at vlan 1, My computer and truenas server are at ports 26 and 28, proxmox server is at port 24 (tagged) both of these 3 are vlan 10 and my laptop is at port 17 at vlan 20. Also i removed port 2 from all other interfaces, i dont know if it is related or not or good practice.
Then i created 3 interfaces like below: ( L3 Features \ Interface )
The key point of this while creating these interfaces one of them should be in the same subnet of your router. For example my router was 192.168.1.1 and i made one of these interfaces with a ip of 192.168.1.2. I've seen some ppl disregarding this and successfully making this work but how much i try i couldnt succeed. This interface is making sure my network is working by connecting to my router.
Then i created only 1 static route, next hop should be your router's ip
Finally my routing table looked like this:
And finally i added 2 static routes to my router like below to be able to communicate with my switch. Gateways of these routes should be the one which you setup at the switch with the same subnet of router. I tried adding these routes through switch's interface but it didnt work.
I hope these settings help someone like me. Please let know if you saw anything wrong with these settings or something like "you dont need to do this" or "doing that should be better"