I would like to assign a fixed IP to a virtual machine running in Virtualization Station 4 .
Is it possible and if yes, where to enter this IP?
Kind regards,
In the machine itself, set an IP in whatever OS you are running
Done and it works. . Yann.
Been asked same question so leave a note here and someone may copy-paste the solution later.
In Ubuntu 22 the way to setup a static IP from CLI seems changed.
First, check which yaml is controlling the IP configuration. It can be located by
ls /etc/netplan/
Than using a text editor to change the yaml file, for example: 00-installer-config.yaml
sudo nano /etc/netplan/00-installer-config.yaml
And with the contents
network:
version: 2
renderer: networkd
ethernets:
ens3:
dhcp4: no
addresses:
- 192.168.50.10/24 #Static IP
nameservers:
addresses:
- 8.8.8.8
- 1.1.1.1
routes:
- to: 0.0.0.0/0
via: 192.168.50.1 #Gateway IP
then check the configuration is correct
sudo netplan try
As everything goes fine, the system should return “Configuration accepted.”
And the last step, apply formal setting
sudo netplan apply