Just like the regular interface you are using:

create sub-interfaces eth0 181
set interface state eth0.181 up
set interface ip address eth0.181 18.1.0.141/24
ip route add 0.0.0.0/0 via 18.1.0.1 eth0.181

Note there is some performance penalty using vlan sub-intf. As I can see on my 
setup, > 10% on ip4 forwarding case. Therefore, we should avoid vlan sub-intf 
if possible. This might be improved by Damjan's patch 
https://gerrit.fd.io/r/#/c/16173/. I haven't tested it, but I know he is 
keeping improving it.

Regards,
Kingwel

From: vpp-dev@lists.fd.io <vpp-dev@lists.fd.io> On Behalf Of 
wangchuan...@163.com
Sent: Monday, January 14, 2019 11:28 AM
To: vpp-dev <vpp-dev@lists.fd.io>
Subject: [vpp-dev] the way of using sub-interface

Hi all,
    How can I use the sub-interface after creating ?
#create sub-interfaces GigabitEthernet2/0/0 11
Does it means the VLAN ID ?


I want to let GigabitEthernet2/0/0 && GigabitEthernet2/0/0 to be same VLAN 
(ID:11).
How should I do?
Thanks.

________________________________
wangchuan...@163.com<mailto:wangchuan...@163.com>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11909): https://lists.fd.io/g/vpp-dev/message/11909
Mute This Topic: https://lists.fd.io/mt/29076170/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to