Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 4 May 2024 20:52:58 +0200
From:      Mario Marietto <marietto2008@gmail.com>
To:        "freebsd-net@FreeBSD.org" <freebsd-net@freebsd.org>
Subject:   How to configure the networking on FreeBSD to assign the same IP between host and guest in order to make work CloudFlare Warp on FreeBSD
Message-ID:  <CA%2B1FSijvmDM_54ytL_E2vAUvo9MPWyfTCbDRtpyjbhUdf4_ZEw@mail.gmail.com>

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

Hello.

I've just installed the CloudFlare client + GUI on Ubuntu,that I have
virtualized with bhyve. Cloudflare does not work on FreeBSD. The
instructions that I have followed are located here :

https://youtu.be/4JuOUjCSj44

Installing it in this way,it will run only on the IP assigned to Ubuntu
inside the VM. For me the IP of FreeBSD is different from the IP assigned
to Ubuntu. Configured in this way it's not useful.

I want Cloudflare to take the IP address of FreeBSD.

To achieve this goal,I should change my network configuration,in a way that
I use the same IP for FreeBSD and Ubuntu.

That's what I want to do,but I don't know how to do it. But I'm sure that I
will be able to do it if someone can give me some advice.

I can explain how I have configured my network,so you can explain what I
should change to have the same IP.

For example,to boot Ubuntu with bhyve,I use the following parameter :

-s 13,virtio-net,tap19 \


/etc/rc.conf :

ifconfig_em0="DHCP"
local_unbound_enable="YES"
cloned_interfaces="bridge0 tap0 tap1 tap2 tap3 tap4 tap5 tap6 tap7
tap8 tap9 tap10 tap11 tap12 tap13 tap14 tap15 tap16 tap17 tap18 tap19
tap20 em0"
ifconfig_bridge0="addm em0 addm tap0 addm tap1 addm tap2 addm tap3
addm tap4 addm tap5 addm tap6 addm tap7 addm tap8 addm tap9 addm tap10
addm tap11 addm tap12 addm tap13 addm tap14 addm tap15 addm tap16 addm
tap17 addm tap18 addm tap19 addm tap20"


/boot/loader.conf

if_tap_load="YES"
if_bridge_load="YES"
bridgestp_load="YES"


/etc/sysctl.conf

net.link.tap.up_on_open=1
net.inet.ip.forwarding=1
net.inet.ip.random_id=1


So,ok. I think you have understood what I want to do. Please help me.
Thanks.

-- 
Mario.

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

<div dir=3D"ltr">Hello.<br>
<br><div>
I&#39;ve just installed the CloudFlare client + GUI on Ubuntu,that I have=
=20
virtualized with bhyve. Cloudflare does not work on FreeBSD. The=20
instructions that I have followed are located here :</div><div><br></div><d=
iv><a href=3D"https://youtu.be/4JuOUjCSj44">https://youtu.be/4JuOUjCSj44</a=
></div><div><br></div><div>Installing it in this way,it will run only on th=
e IP assigned to Ubuntu=20
inside the VM. For me the IP of FreeBSD is different from the IP=20
assigned to Ubuntu. Configured in this way it&#39;s not useful.=C2=A0</div>=
<div><br></div><div>I want Cloudflare to take the IP address of FreeBSD.</d=
iv><div><br></div><div>
To achieve this goal,I should change my network configuration,in a way that=
 I use the same IP for FreeBSD and Ubuntu.<br>
</div><div><br></div><div>That&#39;s what I want to do,but I don&#39;t know=
 how to do it. But I&#39;m sure=20
that I will be able to do it if someone can give me some advice. <br></div>=
<div><br></div><div>
I can explain how I have configured my network,so you can explain what I sh=
ould change to have the same IP.<br>
<br>
For example,to boot Ubuntu with bhyve,I use the following parameter :<br>
<br>

=09
=09


<div class=3D"gmail-bbCodeBlock gmail-bbCodeBlock--screenLimited gmail-bbCo=
deBlock--code">
=09
	<div class=3D"gmail-bbCodeBlock-content" dir=3D"ltr">
		<pre class=3D"gmail-bbCodeCode" dir=3D"ltr"><code>-s 13,virtio-net,tap19 =
\</code></pre>
	</div>
</div><br>
/etc/rc.conf :<br>


=09
=09


<div class=3D"gmail-bbCodeBlock gmail-bbCodeBlock--screenLimited gmail-bbCo=
deBlock--code">
=09
	<div class=3D"gmail-bbCodeBlock-content" dir=3D"ltr">
		<pre class=3D"gmail-bbCodeCode" dir=3D"ltr"><code>ifconfig_em0=3D&quot;DH=
CP&quot;
local_unbound_enable=3D&quot;YES&quot;
cloned_interfaces=3D&quot;bridge0 tap0 tap1 tap2 tap3 tap4 tap5 tap6 tap7 t=
ap8 tap9 tap10 tap11 tap12 tap13 tap14 tap15 tap16 tap17 tap18 tap19 tap20 =
em0&quot;
ifconfig_bridge0=3D&quot;addm em0 addm tap0 addm tap1 addm tap2 addm tap3 a=
ddm tap4 addm tap5 addm tap6 addm tap7 addm tap8 addm tap9 addm tap10 addm =
tap11 addm tap12 addm tap13 addm tap14 addm tap15 addm tap16 addm tap17 add=
m tap18 addm tap19 addm tap20&quot;</code></pre>
	</div>
</div>
<br>
/boot/loader.conf<br>


=09
=09


<div class=3D"gmail-bbCodeBlock gmail-bbCodeBlock--screenLimited gmail-bbCo=
deBlock--code">
=09
	<div class=3D"gmail-bbCodeBlock-content" dir=3D"ltr">
		<pre class=3D"gmail-bbCodeCode" dir=3D"ltr"><code>if_tap_load=3D&quot;YES=
&quot;
if_bridge_load=3D&quot;YES&quot;
bridgestp_load=3D&quot;YES&quot;</code></pre>
	</div>
</div>
<br>
/etc/sysctl.conf<br>


=09
=09


<div class=3D"gmail-bbCodeBlock gmail-bbCodeBlock--screenLimited gmail-bbCo=
deBlock--code">
=09
	<div class=3D"gmail-bbCodeBlock-content" dir=3D"ltr">
		<pre class=3D"gmail-bbCodeCode" dir=3D"ltr"><code>net.link.tap.up_on_open=
=3D1
net.inet.ip.forwarding=3D1
net.inet.ip.random_id=3D1</code></pre>
	</div>
</div></div><div><br></div><div>
So,ok. I think you have understood what I want to do. Please help me. Thank=
s.</div><br><span class=3D"gmail_signature_prefix">-- </span><br><div dir=
=3D"ltr" class=3D"gmail_signature" data-smartmail=3D"gmail_signature">Mario=
.<br></div></div>

--0000000000006df51d0617a55aa0--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CA%2B1FSijvmDM_54ytL_E2vAUvo9MPWyfTCbDRtpyjbhUdf4_ZEw>