Cấu hình IP tĩnh Ubuntu Server

Truy cập thư mục:

1#cd /etc/netplan

Sử dụng vi:

1#vi 00-installer-config.yaml

Bấm “i” để chỉnh sửa thông tin IP, chỉnh sửa xong nhấn “Esc” và nhấn :wq! để lưu lại và thoát khung thao tác

# This is the network config written by 'subiquity'

network:

  ethernets:

    eth0:

      dhcp: no

      addresses: [192.168.24.100/24] 

      gateway4: 192.168.24.1

      nameservers:

        addresses: [8.8.8.8]

  version: 2

Sử dụng lệnh:

1# sudo netplan apply

Có thể dùng lệnh để khởi động lại dịch vụ hoặc reboot Server

Kiểm tra lại IP:

1#ip 



Next Post Previous Post
No Comment
Add Comment
comment url





sr7themes.eu.org
How To Get It For Free?

If you want to get this Premium Blogger Template for free, simply click on below links. All our resources are free for skill development, we don't sell anything. Thanks in advance for being with us.