Ubuntu change Network config using netplan

 1. Open file and edit:  /etc/netplan/00-installer-config.yaml


 example:

root@ran:~# cat /etc/netplan/00-installer-config.yaml

# This is the network config written by 'subiquity'

network:

  ethernets:

    ens160:

      dhcp4: no

      addresses: [169.7.33.52/16]

      routes :

       - to: default

         via: 169.7.33.1

      nameservers:

        addresses: [172.1.1.1]

  version: 2

  renderer: networkd


root@ran:~#


2)verify the yaml format and apply with below command:

#netplan apply

above command gives error if any format issues.


No comments:

Post a Comment

how to unlink a NIC from a esxi vSwitch

  List the vSwitches from ESXI using CLI:          esxcli network vswitch standard list  output example: vSwitch0    Name: vSwitch0    Class...