containers / netavark

Container network stack
Apache License 2.0
537 stars 85 forks source link

failed to configure bridge and veth interface: Operation not supported #864

Closed kallisti5 closed 6 months ago

kallisti5 commented 11 months ago
# podman run docker.io/busybox
Error: netavark: failed to configure bridge and veth interface: failed while configuring network interface: failed to create a bridge interface podman0: Received a netlink error message Operation not supported (os error 95)
# dpkg -l | grep -E "neta|podman|bridge"-utils
ii  bridge-utils                              1.7-1+b1                          riscv64      Utilities for configuring the Linux Ethernet bridge
ii  netavark                                  1.0.3-4                           riscv64      Rust based network stack for containers
ii  podman                                    4.3.1+ds1-5                       riscv64      engine to run OCI-based containers in Pods
# uname -a
Linux starfive 5.15.0-starfive #1 SMP Fri Nov 24 07:22:28 UTC 2023 riscv64 GNU/Linux
# cat /etc/debian_version 
bookworm/sid
Dec 06 14:17:48 starfive systemd[1]: Started Podman API Service.
Dec 06 14:17:49 starfive podman[3616]: time="2023-12-06T14:17:49Z" level=info msg="/usr/bin/podman filtering at log level info"
Dec 06 14:17:49 starfive podman[3616]: time="2023-12-06T14:17:49Z" level=info msg="Not using native diff for overlay, this may cause degraded performance for building images: kernel has CONFIG_OVERLAY_FS_REDIR>
Dec 06 14:17:49 starfive podman[3616]: time="2023-12-06T14:17:49Z" level=info msg="[graphdriver] using prior storage driver: overlay"
Dec 06 14:17:49 starfive podman[3616]: time="2023-12-06T14:17:49Z" level=info msg="Setting parallel job count to 13"
Dec 06 14:17:49 starfive podman[3616]: time="2023-12-06T14:17:49Z" level=info msg="Using systemd socket activation to determine API endpoint"
Dec 06 14:17:49 starfive podman[3616]: time="2023-12-06T14:17:49Z" level=info msg="API service listening on \"/run/podman/podman.sock\". URI: \"/run/podman/podman.sock\""
Dec 06 14:17:54 starfive systemd[1]: podman.service: Deactivated successfully.
# podman system info
host:
  arch: riscv64
  buildahVersion: 1.28.0
  cgroupControllers:
  - cpu
  cgroupManager: systemd
  cgroupVersion: v2
  conmon:
    package: conmon_2.1.3+ds1-1+b1_riscv64
    path: /usr/bin/conmon
    version: 'conmon version 2.1.3, commit: unknown'
  cpuUtilization:
    idlePercent: 99.83
    systemPercent: 0.07
    userPercent: 0.1
  cpus: 4
  distribution:
    codename: bookworm
    distribution: debian
    version: unknown
  eventLogger: journald
  hostname: starfive
  idMappings:
    gidmap: null
    uidmap: null
  kernel: 5.15.0-starfive
  linkmode: dynamic
  logDriver: journald
  memFree: 7007604736
  memTotal: 8292904960
  networkBackend: netavark
  ociRuntime:
    name: crun
    package: crun_1.5+dfsg-1+b1_riscv64
    path: /usr/bin/crun
    version: |-
      crun version 1.5
      commit: 54ebb8ca8bf7e6ddae2eb919f5b82d1d96863dea
      spec: 1.0.0
      +SYSTEMD +SELINUX +APPARMOR +CAP +SECCOMP +EBPF +YAJL
  os: linux
  remoteSocket:
    exists: true
    path: /run/podman/podman.sock
  security:
    apparmorEnabled: false
    capabilities: CAP_CHOWN,CAP_DAC_OVERRIDE,CAP_FOWNER,CAP_FSETID,CAP_KILL,CAP_NET_BIND_SERVICE,CAP_SETFCAP,CAP_SETGID,CAP_SETPCAP,CAP_SETUID,CAP_SYS_CHROOT
    rootless: false
    seccompEnabled: false
    seccompProfilePath: /usr/share/containers/seccomp.json
    selinuxEnabled: false
  serviceIsRemote: false
  slirp4netns:
    executable: /usr/bin/slirp4netns
    package: slirp4netns_1.2.0-1+b1_riscv64
    version: |-
      slirp4netns version 1.2.0
      commit: 656041d45cfca7a4176f6b7eed9e4fe6c11e8383
      libslirp: 4.7.0
      SLIRP_CONFIG_VERSION_MAX: 4
      libseccomp: 2.5.4
  swapFree: 0
  swapTotal: 0
  uptime: 17h 2m 15.00s (Approximately 0.71 days)
plugins:
  authorization: null
  log:
  - k8s-file
  - none
  - passthrough
  - journald
  network:
  - bridge
  - macvlan
  volume:
  - local
registries: {}
store:
  configFile: /usr/share/containers/storage.conf
  containerStore:
    number: 9
    paused: 0
    running: 0
    stopped: 9
  graphDriverName: overlay
  graphOptions: {}
  graphRoot: /var/lib/containers/storage
  graphRootAllocated: 3932766208
  graphRootUsed: 3418484736
  graphStatus:
    Backing Filesystem: extfs
    Native Overlay Diff: "false"
    Supports d_type: "true"
    Using metacopy: "true"
  imageCopyTmpDir: /var/tmp
  imageStore:
    number: 1
  runRoot: /run/containers/storage
  volumePath: /var/lib/containers/storage/volumes
version:
  APIVersion: 4.3.1
  Built: 0
  BuiltTime: Thu Jan  1 00:00:00 1970
  GitCommit: ""
  GoVersion: go1.19.3
  Os: linux
  OsArch: linux/riscv64
  Version: 4.3.1
Luap99 commented 11 months ago

Please use the latest version to test, it is possible that this has been fixed in the meantime.

dvzrv commented 7 months ago

FWIW: I ran into this issue on Arch Linux as well.

In my case the reason was, that I had upgraded the kernel but didn't reboot yet (we nuke the modules of the previous kernel, so netavark was not able to load the required kernel modules on demand).

Luap99 commented 6 months ago

FWIW: I ran into this issue on Arch Linux as well.

In my case the reason was, that I had upgraded the kernel but didn't reboot yet (we nuke the modules of the previous kernel, so netavark was not able to load the required kernel modules on demand).

Huh? This sounds like big arch linux issue, doesn't it keep older kernels on updates like other distros?

Regardless this is not something netavark can fix so I close this one.

dvzrv commented 6 months ago

Huh? This sounds like big arch linux issue, doesn't it keep older kernels on updates like other distros?

You can keep the modules of the previous kernel around with a script but generally we do not have that type of versioned package. The linux package is always tracking the latest version, the linux-lts always the LTS releases, etc.