When setting up "Router on a Stick" interVLAN routing, the steps I have seen only covered creating sub-interfaces for each VLAN and assigning an IP address to each of these sub-interfaces. However, there is no mention about assigning an IP address to the physical interface of the router, i.e. the parent interface.
I have several questions regarding this:
- Would there be any problems if no IP address is assigned to that physical interface of the router?
- Are there any possible use-cases for me to assign it an IP address?
- Can the physical interface also be assigned a VLAN and treated just like a sub-interface?
EDIT: From the two answers received and this question, my understanding is that:
The router's physical interface can optionally be configured as default gateway for the native VLAN on the switch that it is connected to (by assigning the physical interface an IP address and if the native VLAN exists and is allowed on the trunk port of the switch).
- The physical interface on the router cannot be used for any other VLANs apart from native VLAN
- The native VLAN (if configured), can choose to use either the physical interface or another sub-interface
If there are any errors please feel free to correct me thanks.