VM - cannot find where to change IP address?

ShaunG

Member
Jul 12, 2022
37
2
11
I have a VM that has been running for years, I've just changed my network to setup some VLANs, so I want to change this static IP which is still on the 192.168. network.

This VM via console has no /etc/network/interfaces file, the network option in the UI just says "virtio", so where is the IP assigned??
 
It's 22.04, /etc/network/interfaces doesn't even exist, never has done since setup it seems.
 

I haven't changed anything, I'm not asking how to set up a new connection from scratch, the VM is connected to my switch on an IP that would have been configured I'm assuming using the UI during creation.

How can I change this IP? There is no interfaces file, there is no UI option that shows the IP that I've assigned, so where it is being set??
 
How can I change this IP? There is no interfaces file, there is no UI option that shows the IP that I've assigned, so where it is being set??
From the linked article:
Code:
From core20 onwards, network-manager been modified to use a YAML backend that’s based on libnetplan functionality.

The YAML backend replaces the keyfile format used by Network Manager with /etc/Netplan/*.yaml.

The default configuration, for example, can be output by running the cat sudo cat /etc/netplan/00-snapd-config.yaml to produce show following output:

# This is the network config written by 'console-conf'
network:
  ethernets:
    enp0s2:
      dhcp4: true
  version: 2



Blockbridge : Ultra low latency all-NVME shared storage for Proxmox - https://www.blockbridge.com/proxmox
 
  • Like
Reactions: ShaunG