containers / containers/podman-compose

Error validating CNI config fileError validating CNI config file

Open
#752 3 comments 6 reactions 0 assignees View on GitHub
bug
Dominant language
Python
Stars
6.2k
Forks
622
PR merge metrics
No merged PRs in 30d

Description

**Describe the bug**
Error validating CNI config file....

**To Reproduce**
Steps to reproduce the behavior:
1. what is the content of the current working directory (`docker-compose.yml`, `.env`, `Dockerfile`,)
2. what is the sequence of commands you typed `podman-compose up -d`

please use [minimal reproducible example](https://stackoverflow.com/help/minimal-reproducible-example) for example give me a small busybox-based compose yaml

**Expected behavior**
the podman container should up

**Actual behavior**
cannot run podaman compose

**Output**
$ podman-compose version
```
podman-compose version: 1.0.6
['podman', '--version', '']
using podman version: 3.4.4
podman-compose version 1.0.6
podman --version
podman version 3.4.4
exit code: 0
```

$ podman-compose up
```
$ podman-compose up -d
podman-compose version: 1.0.6
['podman', '--version', '']
using podman version: 3.4.4
** excluding: set()
['podman', 'ps', '--filter', 'label=io.podman.compose.project=beasiswa', '-a', '--format', '{{ index .Labels "io.podman.compose.config-hash"}}']
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
['podman', 'network', 'exists', 'beasiswa_default']
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
podman run --name=php -d --label io.podman.compose.config-hash=e7c38e9b1c04559ba8d11a6b05b5480eea2fedc01cd78409ea99dc49fc6c20ca --label io.podman.compose.project=beasiswa --label io.podman.compose.version=1.0.6 --label PODMAN_SYSTEMD_UNIT=podman-compose@beasiswa.service --label com.docker.compose.project=beasiswa --label com.docker.compose.project.working_dir=/mnt/sdb1/Workspaces/PHP/serkom/beasiswa --label com.docker.compose.project.config_files=docker-compose.yml --label com.docker.compose.container-number=1 --label com.docker.compose.service=php -v /mnt/sdb1/Workspaces/PHP/serkom/beasiswa:/var/www/html --net beasiswa_default --network-alias php -p 8000:80 php:8.0-apache
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
Error: error creating container storage: the container name "php" is already in use by "f929321753cba30e603826521130ca3376fc3ddb3a0bc35394cf7fd460e25eb8". You have to remove that container to be able to reuse that name.: that name is already in use
exit code: 125
podman start php
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
ERRO[0000] error loading cached network config: network "beasiswa_default" not found in CNI cache
WARN[0000] falling back to loading from existing plugins on disk
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
ERRO[0000] Error tearing down partially created network namespace for container f929321753cba30e603826521130ca3376fc3ddb3a0bc35394cf7fd460e25eb8: CNI network "beasiswa_default" not found
Error: unable to start container "f929321753cba30e603826521130ca3376fc3ddb3a0bc35394cf7fd460e25eb8": error configuring network namespace for container f929321753cba30e603826521130ca3376fc3ddb3a0bc35394cf7fd460e25eb8: CNI network "beasiswa_default" not found
exit code: 125
['podman', 'network', 'exists', 'beasiswa_default']
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
podman run --name=mysql -d --label io.podman.compose.config-hash=e7c38e9b1c04559ba8d11a6b05b5480eea2fedc01cd78409ea99dc49fc6c20ca --label io.podman.compose.project=beasiswa --label io.podman.compose.version=1.0.6 --label PODMAN_SYSTEMD_UNIT=podman-compose@beasiswa.service --label com.docker.compose.project=beasiswa --label com.docker.compose.project.working_dir=/mnt/sdb1/Workspaces/PHP/serkom/beasiswa --label com.docker.compose.project.config_files=docker-compose.yml --label com.docker.compose.container-number=1 --label com.docker.compose.service=mysql -e MYSQL_ROOT_PASSWORD=password --net beasiswa_default --network-alias mysql -p 3306:3306 mysql:8.0
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
Error: error creating container storage: the container name "mysql" is already in use by "7493cc5202f1253e9dc4793e639dd01028f52f882949dcf5b562cdc4ef6bd6a3". You have to remove that container to be able to reuse that name.: that name is already in use
exit code: 125
podman start mysql
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
ERRO[0000] error loading cached network config: network "beasiswa_default" not found in CNI cache
WARN[0000] falling back to loading from existing plugins on disk
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
ERRO[0000] Error tearing down partially created network namespace for container 7493cc5202f1253e9dc4793e639dd01028f52f882949dcf5b562cdc4ef6bd6a3: CNI network "beasiswa_default" not found
Error: unable to start container "7493cc5202f1253e9dc4793e639dd01028f52f882949dcf5b562cdc4ef6bd6a3": error configuring network namespace for container 7493cc5202f1253e9dc4793e639dd01028f52f882949dcf5b562cdc4ef6bd6a3: CNI network "beasiswa_default" not found
exit code: 125
['podman', 'network', 'exists', 'beasiswa_default']
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
podman run --name=phpmyadmin -d --label io.podman.compose.config-hash=e7c38e9b1c04559ba8d11a6b05b5480eea2fedc01cd78409ea99dc49fc6c20ca --label io.podman.compose.project=beasiswa --label io.podman.compose.version=1.0.6 --label PODMAN_SYSTEMD_UNIT=podman-compose@beasiswa.service --label com.docker.compose.project=beasiswa --label com.docker.compose.project.working_dir=/mnt/sdb1/Workspaces/PHP/serkom/beasiswa --label com.docker.compose.project.config_files=docker-compose.yml --label com.docker.compose.container-number=1 --label com.docker.compose.service=phpmyadmin -e PMA_HOST=mysql -e PMA_USER=root -e PMA_PASSWORD=password --net beasiswa_default --network-alias phpmyadmin -p 8080:80 phpmyadmin
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
Error: error creating container storage: the container name "phpmyadmin" is already in use by "06186624552e084f51d7760407eb5f4bd6afed32755eff2be40613d55197600f". You have to remove that container to be able to reuse that name.: that name is already in use
exit code: 125
podman start phpmyadmin
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
ERRO[0000] error loading cached network config: network "beasiswa_default" not found in CNI cache
WARN[0000] falling back to loading from existing plugins on disk
WARN[0000] Error validating CNI config file /home/bagusa4/.config/cni/net.d/beasiswa_default.conflist: [plugin bridge does not support config version "1.0.0" plugin portmap does not support config version "1.0.0" plugin firewall does not support config version "1.0.0" plugin tuning does not support config version "1.0.0"]
ERRO[0000] Error tearing down partially created network namespace for container 06186624552e084f51d7760407eb5f4bd6afed32755eff2be40613d55197600f: CNI network "beasiswa_default" not found
Error: unable to start container "06186624552e084f51d7760407eb5f4bd6afed32755eff2be40613d55197600f": error configuring network namespace for container 06186624552e084f51d7760407eb5f4bd6afed32755eff2be40613d55197600f: CNI network "beasiswa_default" not found
exit code: 125

```
[full error](https://pastebin.com/CL5xnN1T)

**Environment:**
- OS: Linux
- podman version: 3.4.4
- podman compose version: 1.0.6

**Additional context**

docker-compose.yaml
```
version: '3.8'
services:
php:
image: php:8.0-apache
container_name: php
ports:
- 8000:80
volumes:
- ./:/var/www/html
mysql:
image: mysql:8.0
container_name: mysql
ports:
- 3306:3306
environment:
MYSQL_ROOT_PASSWORD: password
phpmyadmin:
image: phpmyadmin
container_name: phpmyadmin
ports:
- 8080:80
environment:
PMA_HOST: mysql
PMA_USER: root
PMA_PASSWORD: password
```

Is this bug or another error?

Contributor guide

Open the contributing guide

Research direction

Start by reproducing `podman-compose up -d` with the supplied `docker-compose.yaml` on Linux using podman 3.4.4 and podman-compose 1.0.6. Inspect the reported CNI config path and separate the config-version warnings, missing `beasiswa_default` network, and existing container-name errors; done means the compose project starts without these failures.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker-compose, linux, python
Domain
cli, networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.