Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 20 Jan 2024 09:23:22 +0300
From:      Mark <markbsdmail2023@gmail.com>
To:        freebsd-virtualization@freebsd.org
Subject:   Move VMs from vmswitch to vether0?
Message-ID:  <CAMW11TY1HPOXtggG0hjUrgXSJn39hZg6h=3BU37ViEbCqEE7hQ@mail.gmail.com>

next in thread | raw e-mail | index | archive | help
--000000000000bc80f6060f5aa28a
Content-Type: text/plain; charset="UTF-8"

Hi all, today I've learned and been reading about VETHER(4). Virtual
ethernet interface on FreeBSD, wanted to try it for my VMs networking.

My VMs currently are networking through vm-vmswitch with a set of private
IP block; 192.168.2.1/29 (PF - NAT involved);

# vm switch list
NAME      TYPE      IFACE        ADDRESS         PRIVATE  MTU  VLAN  PORTS
vmswitch  standard  vm-vmswitch  192.168.2.1/29  no       -    -     -

My question is;
Is it possible to not use any virtual switch at all, but create a vether0
on the host, and assign it private IPs and aliases (thinking each alias IP
would be for each VM of mine), and make VMs communicate with each other
host machine through vether0 and its IP aliases?

In order to try these all above, on my OpenBSD VM, I;
Added in its conf file: network0_device="vether0"
Started it, defined it's static IP as; 10.0.0.2 (vether0 alias), and
gateway as 10.0.0.1 (vether0 IP).

That didn't work. Any clue?

Regards.

--000000000000bc80f6060f5aa28a
Content-Type: text/html; charset="UTF-8"
Content-Transfer-Encoding: quoted-printable

<div dir=3D"ltr">Hi all, today I&#39;ve learned and been reading about VETH=
ER(4). Virtual ethernet interface on FreeBSD, wanted to try it for my VMs n=
etworking.<div><br></div><div>My VMs currently are networking through vm-vm=
switch with a set of private IP block; <a href=3D"http://192.168.2.1/29">19=
2.168.2.1/29</a> (PF - NAT involved);<br></div><div><br></div><div># vm swi=
tch list<br>NAME =C2=A0 =C2=A0 =C2=A0TYPE =C2=A0 =C2=A0 =C2=A0IFACE =C2=A0 =
=C2=A0 =C2=A0 =C2=A0ADDRESS =C2=A0 =C2=A0 =C2=A0 =C2=A0 PRIVATE =C2=A0MTU =
=C2=A0VLAN =C2=A0PORTS<br>vmswitch =C2=A0standard =C2=A0vm-vmswitch =C2=A0<=
a href=3D"http://192.168.2.1/29">192.168.2.1/29</a>; =C2=A0no =C2=A0 =C2=A0 =
=C2=A0 - =C2=A0 =C2=A0- =C2=A0 =C2=A0 -<br></div><div><br></div><div>My que=
stion is;<br>Is it possible to not use any virtual switch at all, but creat=
e a vether0 on the host, and assign it private IPs and aliases (thinking ea=
ch alias IP would be for each VM of mine), and make VMs communicate with ea=
ch other host machine through vether0 and its IP aliases?<br></div><div><br=
></div><div>In order to try these all above, on my OpenBSD VM, I;<br>Added =
in its conf file: network0_device=3D&quot;vether0&quot;<br>Started it, defi=
ned it&#39;s static IP as; 10.0.0.2 (vether0 alias), and gateway as 10.0.0.=
1 (vether0 IP).<br><br>That didn&#39;t work. Any clue?<br><br>Regards.<br><=
/div></div>

--000000000000bc80f6060f5aa28a--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAMW11TY1HPOXtggG0hjUrgXSJn39hZg6h=3BU37ViEbCqEE7hQ>