一般來說在多路對外線路的環境下,發生RouterOS機器上的網路孔不夠用時,可利用Switch切VLAN方式從RoterOS一孔在switch分出多孔使用。這裡以RouterOS之ETH4分出兩孔為例,一孔撥接出兩條PPPoe。
RouterOS設定:
於Interface新增2個vlan介面,VLAN ID分別指定2跟3,介面選擇ETH4,如下圖
之後新增各將兩條PPPoe並將之介面各指定為vlan2跟vlan3
SMC Switch設定:
假設我們RouterOS上的ETH4孔與SMC的Port1孔對接,那SMC的設定方法為
VLAN Membership=>Add VLAN Group 新增VLAN ID 2跟VLAN ID 3
並在VLAN ID 1裡將P1;P2;P3取消打勾。
之後在VLAN ID 2中將P1;P2打勾。
之後在VLAN ID 3中將P1;P3打勾。
以下是SMC原廠關於VLAN說明之官方文件
| Introduction to VLANs |
VLANs (or Virtual LANs) are logical partions of the physical LAN. You can use
VLANs to:
- Increase network performance
- Increase internal network security
If the network has adequate performance and security for your current needs,
it is recommended that you leave the VLAN settings in the default configuration.
The default configuration is as follows:
- All ports are members of VLAN 1
- The switch management interface is on VLAN 1
- All ports have a Port VLAN ID (PVID) of 1
- All ports can send and receive both VLAN-tagged and untagged packets (i.e.
they are "hybrid" ports)
In the default configuration, any port is able to send traffic to any other
port and a PC connected to any port will be able ro reach the management
interface. Broadcast traffic, for example, will be flooded to all ports on the
switch. |
Add VLAN Group |
| Type into the VLAN ID (1-4093) of the VLAN group which you want
to setup. After pressing the ADD button, you will be navigated to a new
page for configuring VLAN membership. Only one VLAN group can be setup per time.
Note: For QinQ application, The number of VLAN groups that would be
setup is equal to the number of customer ports. Each VLAN group consists of two
ports, customer port and network port. The VID equals to PVID of the customer
port. Network port is member of the VLAN of customer port. |
VLAN Group List |
| This table displays all the VLAN groups and they are sorted for
display purposes. Click the radio button which is associated with the VLAN that
is displayed immediately below it and use Modify or Delete button
can modify or delete an existing VLAN group. Modify button will navigate
to a web page for configuring VLAN membership. |
| VLAN Awareness |
|
VLAN aware ports will strip the VLAN tag from received frames and insert the
tag in transmitted frames (except PVID). VLAN unaware ports will not strip the
tag from received frames or insert the tag in transmitted frames.
For QinQ application, customer port should be VLAN unaware and network port
(trunk port) should be VLAN aware.
|
QinQ |
|
QinQ enabled port will accept packets up to 1526 bytes in length, which
means double tag header frames can be accepted.
For QinQ application, the QinQ should be enabled for provider port but not
for customer port.
Note: For QinQ application, customer ports indicate those ports which
are connected to normal VLAN aware switches at the customer network and the
network ports are those which are connected to the service provider network. To
tunnel the packets through MAN, QinQ needs to be enabled on network ports.
|
Packet Type |
- PCs should be connected to ports with Packet
Type set to All. PCs cannot, in
general, send or receive tagged packets.
- Switches should be connected to each other with Packet Type set to Tagged Only.
- If the Packet Type is set to All, the port can accept incoming
tagged and untagged packets. Untagged packets will be associated with the VLAN
identified by the PVID. Tagged packets will be dropped unless the port is a
member of the VLAN identified by the VLAN tag in the packet. Outgoing packets
will be tagged unless the packet's VLAN ID is the same as the PVID.
- If the Packet Type is set to Tagged Only, the port will drop
untagged packets and will only send and receive tagged packets. Tagged packets
will be dropped unless the port is a member of the VLAN identified by the VLAN
tag in the packet. The PVID has no effect in this case.
|
Port VLAN ID |
- The PVID is (Port VLAN ID) is the VLAN ID that is associated with untagged,
ingress packets.
- It is not possible to remove a port from VLAN 1 unless its PVID has been
changed to something other than 1.
- The PVID has no effect on ports that have Packet Type set to Tagged Only.
- Untagged frames received on the port will be classified to this VLAN ID.
Frames classified to this VLAN ID will be sent untagged on the port.
- None is used for trunk port.
- For QinQ application, the PVID for each customer port must be unique.
|
QinQ Application Example |
This example shows how to configure one network port and three
customer ports with the following setup on this switch. Port 1 as network port
and port 2-4 are customer ports.
- Click off VLAN aware enabled checkboxes for port 2-4 and click
VLAN aware enabled checkbox for port 1.
- Clear the QinQ enabled checkboxes for port 2-4 and click QinQ
enabled checkbox for port 1.
- Type PVID 2,3,4 individually for port 2-4. The PVID for each customer port
must be unique.
- In VLAN membership page, add VLAN group 2 with port 1 and port 2 as
members. Add VLAN group 3 with port 1 and port 3 as members. Add VLAN group 4
with port 1 and port 4 as members.
|
沒有留言:
張貼留言