ubuntu20.04 set static IP (wired connection and unlimited connection two setting methods)

ubuntu20.04 set static IP (wired connection and unlimited connection two setting methods)

1. Wired connection

Open the terminal and type: ip addrview card, wired LAN: enp1s0Wireless LAN: wlp2s0
Insert picture description here
enter the catalog: cd /etc/netplan/,
Insert picture description here
terminal input: sudo vi 01-network-manager-all.yamledit
Insert picture description here

:wq

Save and exit, apply the settings, enter in the terminal:sudo netplan apply

2. Wireless connection

Configure a static IP address on the Ubuntu desktop

In the "Activity" screen, search for "Settings" and click the icon. This will open the GNOME settings window. According to the interface to be modified, click on the "Network" or "Wi-Fi" tab. To open the interface settings, click the gear icon next to the interface name.

In the "IPV4" method tab, select "Manual" and then enter your static IP address, netmask and gateway. When finished, click the "Apply" button.
Insert picture description here
Insert picture description here
Done!
Hope to help you!

Guess you like

Origin blog.csdn.net/qq_43030934/article/details/112985399