it looks like I have all the components of microcloud up and running as following four commands receive all **online** status from all three nodes(all arm64 running Ubuntu Core 22)
microcloud cluster list
microceph cluster list
microovn cluster list
lxc cluster list
my next question is, I have lxd container installed in the microcloud and I am able to access the instance and install my snap which has flask server running(it is using port 5001) I want to access this server from machines which are in the same subnet as uplink network of microcloud
route setup inside the container look like this
default via 10.66.61.1 dev eth0 proto dhcp src 10.66.61.2 metric 100
10.66.61.0/24 dev eth0 proto kernel scope link src 10.66.61.2 metric 100
10.66.61.1 dev eth0 proto dhcp scope link src 10.66.61.2 metric 100
192.168.3.254 via 10.66.61.1 dev eth0 proto dhcp src 10.66.61.2 metric 100
My network setup on uplink looks something like this
Do you know where this route came from? It looks out of place (and unnecessary given its the same as the default route) for an instance connected to an OVN network?
You can use the proxy device on your container. This creates a local listener on the host where the container is running and forwards it into the container. Note: This isn’t related to the OVN or uplink network, and only works for IPs that are bound to the host itself. See also https://www.youtube.com/watch?v=TmGvbXfwJEA
If you want an entire IP from the uplink network routed to the container you can the ipv{n}.routes.external settings. Please note these require that the IPs be marked as routable in LXD’s uplink network by setting ipv{n}.routes.
If you just want to forward certain ports from an IP on the uplink network to the internal IP of the container on the OVN network then you can use network forwards. Because of the way network forwards use a static internal IP for the target, you should also configure the ovn NIC on your container to have static IPs using the ipv{n}.address settings.
@tomp ,
Thanks for your reply.
This route probably came while setting up ovn networking during execution of “microcloud init”
The address 192.168.3.254 is address of my physical gateway on uplink network.
Question is am I doing something wrong here?
I’m not sure, it shouldn’t be causing any problems, but strange that its been during microcloud setup.
Can you show me your netplan config after a fresh reboot of your container?
@tomp,
This is how netplan config of my container instance look like
cat /etc/netplan/50-cloud-init.yaml
# This file is generated from information provided by the datasource. Changes
# to it will not persist across an instance reboot. To disable cloud-init's
# network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}
network:
version: 2
ethernets:
eth0:
dhcp4: true
root@u2204:~# ip r
default via 10.66.61.1 dev eth0 proto dhcp src 10.66.61.2 metric 100
10.66.61.0/24 dev eth0 proto kernel scope link src 10.66.61.2 metric 100
10.66.61.1 dev eth0 proto dhcp scope link src 10.66.61.2 metric 100
192.168.3.254 via 10.66.61.1 dev eth0 proto dhcp src 10.66.61.2 metric 100
RoutesToDNS=
When true, the routes to the DNS servers received from the DHCP server will be configured. When UseDNS= is disabled, this setting is ignored. Defaults to true.