CasaOS icon indicating copy to clipboard operation
CasaOS copied to clipboard

[Bug] CasaOS in Proxmox LXC not showning Network & Storage Status

Open Rod-Gomes opened this issue 9 months ago • 1 comments
trafficstars

Describe the bug

When running CasaOS inside an LXC container on Proxmox, network statistics are not displayed. This issue occurs because CasaOS incorrectly filters the main network interface eth0 due to its presence in /sys/devices/virtual/net, which is typical in LXC environments. As a result, CasaOS fails to detect and display network usage statistics.

To Reproduce

Steps to reproduce the behavior:

  1. Deploy CasaOS inside an LXC container on Proxmox.
  2. Configure the container with a virtual network interface (veth) connected to a Proxmox bridge (e.g., vmbr0).
  3. Start CasaOS and navigate to the network statistics page.
  4. Observe that no network statistics are displayed.

Expected behavior

Network statistics should be displayed correctly, and the primary network interface (eth0) should be detected regardless of its presence in /sys/devices/virtual/net.

Screenshots

Image

Desktop (please complete the following information):

 - OS: Windows 11
 - Browser Chrome
 - Version 131.0.6778.265

System Time

Run timedatectl and share the output

               Local time: Sun 2025-01-26 01:57:11 UTC
           Universal time: Sun 2025-01-26 01:57:11 UTC
                 RTC time: n/a
                Time zone: Etc/UTC (UTC, +0000)
System clock synchronized: yes
              NTP service: inactive
          RTC in local TZ: no

Logs

Run following command to collect corresponding logs:

sudo journalctl -xef -u casaos-gateway
sudo journalctl -xef -u casaos-user-service
sudo journalctl -xef -u casaos-local-storage
sudo journalctl -xef -u casaos-app-management
sudo journalctl -xef -u casaos.service

Additional context

The root cause of this issue is the logic in CasaOS that filters interfaces listed in /sys/devices/virtual/net. Inside an LXC container, even the main network interface (eth0) is treated as virtual and listed in this directory.

Solution To resolve this, CasaOS should adapt its detection logic:

  • Avoid excluding eth0 or other primary interfaces from the network statistics.
  • Use a more robust method, such as ip link, to list active network interfaces and filter irrelevant ones.

Rod-Gomes avatar Jan 26 '25 02:01 Rod-Gomes

i think Storage info is also a issue, any workaround for network status and storage info issue?

WernerAUT avatar Jun 16 '25 08:06 WernerAUT

i think Storage info is also a issue, any workaround for network status and storage info issue?

I didn’t find alternative solutions, so I gave up on using LXC and switched to VM.

Rod-Gomes avatar Aug 26 '25 01:08 Rod-Gomes