ubuntu16.04 set static ip

Recently in class, many students reported that when setting up the environment, the virtual machine IP often changes, so the web services we configured may not be available. Let's talk about how to set static ip on ubuntu

1 : First, we confirm the version of ubuntu###

I am here ubuntu16.04

2 : Set the virtual machine's network connection mode to bridge

3 : Ipconfig to view the ip information of Host###

4 : Ifconfig view system network card information###

5 : Manually set static ip

vim /etc/network/interfaces

**# Add the following **

**auto ens33iface ens33 inet staticaddress 192.168.1.131 #The gateway must be consistent with the host netmask 255.255.255.0gateway 192.168.1.1 #The gateway must be consistent with the host **dns-nameserver 8.8.8.8 #dns information must be configured

# Configure dns information

sudo vi /etc/systemd/resolved.conf

6 : All the above configuration is completed, then restart the ubuntu system

Recommended Posts

ubuntu16.04 set static ip
ubuntu 18.04 set static ip method
ubuntu 17.10 set solid IP
How to set static IP in ubuntu14.04
How to set static IP on Ubuntu 18.04 Server
How to set static IP on Ubuntu 18.04 Server
Explain how to set static IP on ubuntu14.04
[Quick Start with Ubuntu] Two, Ubuntu set static IP
Set static IP under Centos
Set static IP for CentOS in VMware
Summary of CentOS method to set static IP
ubuntu16.0.4 method to set a fixed IP address
ubuntu 14.04 configure 3-wire 3IP
ubuntu set Chinese font
How to set a fixed IP based on Ubuntu 16.04
ubuntu modify and configure ip address
How to set up Gogs on Ubuntu 14.04
Set UTF-8 encoding for MySQL5.7 in Ubuntu 16.04
How to set up R on Ubuntu 14.04