Dino Geek, try to help you

How to use LXC with Docker?


Docker initially used LXC (Linux Containers) as a container runtime interface and the two were often used interchangeably. However, Docker later developed its own library, known as ‘libcontainer.’ As the Docker functionality grew, it moved away from LXC, and as of version 0.9 Docker no longer uses LXC within its stack.

Nevertheless, if you still want to use Docker with LXC, you can do so by configuring the Docker daemon to use LXC. Please note, this is not a recommended or popular use case.

Docker still supports the LXC driver, but only as an optional plugin. You can configure Docker to use LXC with the following steps:

1. Make sure Docker is installed in your system.

1. Edit or create the /etc/docker/daemon.json file. In the json, set the exec-opts to LXC:

```
{ “exec-opts”: [“native.cgroupdriver=systemd”], “log-driver”: “json-file”, “log-opts”: { “max-size”: “100m“ }, “storage-driver”: “overlay2”, “storage-opts”: [ “overlay2.override_kernel_check=true“ ]
}
```

1. Start Docker with the LXC driver:
```
dockerd —exec-opt lxc
```

Note: Docker’s use of the LXC driver is not maintained or tested anymore, and its support may be dropped in future Docker versions. It’s recommended to use Docker’s default runtime, runc, or another OCI compatible runtime like crun, or kata-containers, etc.


Simply generate articles to optimize your SEO
Simply generate articles to optimize your SEO





DinoGeek offers simple articles on complex technologies

Would you like to be quoted in this article? It's very simple, contact us at dino@eiki.fr

CSS | NodeJS | DNS | DMARC | MAPI | NNTP | htaccess | PHP | HTTPS | Drupal | WEB3 | LLM | Wordpress | TLD | Domain name | IMAP | TCP | NFT | MariaDB | FTP | Zigbee | NMAP | SNMP | SEO | E-Mail | LXC | HTTP | MangoDB | SFTP | RAG | SSH | HTML | ChatGPT API | OSPF | JavaScript | Docker | OpenVZ | ChatGPT | VPS | ZIMBRA | SPF | UDP | Joomla | IPV6 | BGP | Django | Reactjs | DKIM | VMWare | RSYNC | Python | TFTP | Webdav | FAAS | Apache | IPV4 | LDAP | POP3 | SMTP

| Whispers of love (API) | Déclaration d'Amour |






Legal Notice / General Conditions of Use