Example of configuring network device commands on Linux

Source: Internet
Author: User

If you have installed the VLAN kernel module and the Administrative Tools Vconfig,tap/tun Device Management tool TUNCTL, you can set up the relevant network device using the following command:

    • Create Bridge:brctl ADDBR [Bridge NAME]
    • Delete Bridge:brctl Delbr [Bridge NAME]
    • Attach device to Bridge:brctl addif [Bridge name] [device name]
    • From bridge Detach device: Brctl Delif [Bridge name] [device name]
    • Check Bridge situation: Brctl Show
    • To create a VLAN device: vconfig Add [PARENT device NAME] [VLAN ID]
    • Remove VLAN device: vconfig REM [VLAN device NAME]
    • Set VLAN devices flag:vconfig Set_flag [VLAN device NAME] [flag] [VALUE]
    • To set VLAN device QoS:

Vconfig Set_egress_map [VLAN DEVICE NAME] [skb_priority] [Vlan_qos]

Vconfig Set_ingress_map [VLAN DEVICE NAME] [skb_priority] [Vlan_qos]

    • Query VLAN device Condition: Cat/proc/net/vlan/[vlan device NAME]
    • Create VETH device pair: IP link Add [device NAME0] Type VETH peer name [device NAME1]
    • Create tap device: tunctl-p-T [tap device NAME]
    • Delete tap device: tunctl-d [tap device NAME]
    • Create namespace: IP netns Add [name space]
    • Assign the associated device to the namespace: IP link set [DEVICE NAME] netns [name space]
    • Query all two-tier devices in the system, including VETH/TAP devices: IP link Show
    • Remove normal two-tier device: IP link Delete [device NAME] type [type]

Example of configuring network device commands on Linux

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.