lost and found ( for me ? )

Ubuntu 18.04 : netplan : how to configure vlans with netplan

root@gw:~# cat /etc/netplan/eth2-vlan.yaml
network:
    version: 2
    ethernets:
        eth2: {}

    vlans:
        vlan.10:
            id: 10
            link: eth2
            addresses: [10.0.0.254/24]
        vlan.20:
            id: 20
            link: eth2
            addresses: [172.16.2.254/24]
        vlan.30:
            id: 30
            link: eth2
            addresses: [172.16.1.254/24]
        vlan.40:
            id: 40
            link: eth2
            addresses: [172.16.3.254/24]
        vlan.50:
            id: 50
            link: eth2
            addresses: [172.16.0.254/24]
        vlan.60:
            id: 20
            link: eth2
            addresses: [10.1.1.254/24]


root@gw:~# netplan apply



No comments:

Post a Comment

Note: Only a member of this blog may post a comment.