I have been running some lxc containers on an ubuntu 22 host for some time and, it has been the case from day 1 that, the lxc containers become unreachable from outside the lxcs’ host machine after a period of time (24 hours or so - not sure exactly).
The only way I can make the lxc containers reachable again is by running:
$ lxc stop --all
$ lxc start --all
I should point out that the host where the lxc containers run is still able to reach the lxc containers at all times but not other nodes on the same network.
I can’t see any logs anywhere that give me any clues as to why the lxc containers become unreachable after a period of time so I don’t know what it is I need to do in order to stop this from happening.
The configs for the lxc containers are:
config:
user.network-config: |
version: 2
ethernets:
eth0:
dhcp4: false
addresses:
- {{ server_ip }}/32
nameservers:
addresses:
- 8.8.8.8
search: []
routes:
- to: 0.0.0.0/0
via: 169.254.0.1
on-link: true
description: Server Routed Profile
devices:
eth0:
ipv4.address: {{ server_ip }}
nictype: routed
parent: wlo1
type: nic
root:
path: /
pool: dataPool
type: disk
name: dataProfile
Any ideas on how to resolve this issue would be much appreciated. Cheers, PM