Skip to main content

Ubuntu Server Cloning

Clone VM Template



Check current hostname

hostnamectl
hostname

Change the Hostname (Permanently)


sudo nano /etc/hostname



sudo nano /etc/hosts



Apply Changes


sudo systemctl restart systemd-logind
sudo reboot

hostnamectl

Assign static IP in UDM SE


ip a


Reboot


sudo reboot

Assign Static IP

Login to the new cloned Ubuntu VM and run the following commands to assign a static IP address.


[OPTIONAL]

sudo ls /etc/netplan
sudo vim /etc/netplan/50-cloud-init.yaml

:%d [ENTER]

network:
  version: 2
  ethernets:
    enp6s18:
      dhcp4: no
      addresses:
        - 192.168.8.xx/22
      gateway4: 192.168.8.1
      nameservers:
        addresses:
          - 192.168.8.4
          - 1.1.1.1
          - 8.8.8.8
sudo netplan apply