(Optional) Creating an IPVLAN
IPVLAN is a Linux networking driver that enables multiple logical interfaces to share a single physical network interface with minimal overhead. Unlike MACVLAN implementations, IPVLAN shares the physical interface MAC address across all sub-interfaces rather than assigning unique MAC addresses to each virtual interface. This architecture reduces MAC address conflicts in large deployments and optimizes switch performance by minimizing MAC table entries on switches.
Common Commands
- Check the Docker version.
1docker --version
- Load an image.
1docker load -i openEuler-docker.aarch64.tar.xz
- View loaded images.
1docker images
- View running Docker containers.
1docker ps
- View all containers, including stopped ones.
1docker ps -a
- Stop a container.
1docker stop <container ID>
- Remove a container.
1docker rm (-f) <container ID>
- View container networks.
1docker network ls

Creating a Docker IPVLAN
- Check whether the loaded kernel modules contain the IPVLAN module.
1lsmod | grep ipvlan
If no command output is displayed, load the IPVLAN kernel module.1sudo modprobe ipvlan
- If the Docker service is not started after the environment is restarted, restart the Docker service. Otherwise, skip this step.
1sudo systemctl restart docker
- Create a Docker IPVLAN. Each time the environment is restarted, you need to reconfigure the Docker IPVLAN. The configuration command is as follows:
1 2 3 4 5 6
docker network create -d ipvlan \ --subnet=192.168.220.0/24 \ --ip-range=192.168.220.128/25 \ --gateway=192.168.220.1 \ -o ipvlan_mode=l2 \ -o parent=bond4 ipvlan_network
Modify the following parameters as required:
- Change the values of subnet and gateway to the subnet of the environment.
- ip-range indicates the range of IP addresses allocated by Docker to containers. In the preceding example, the start IP address of Docker containers is 220.128. If this line is deleted, the start IP address of Docker containers is 220.2 by default.
- Set ipvlan_mode to l2.
- The network name is ipvlan_network.

Troubleshooting
Symptom
After the Docker IPVLAN is created, message "Error response from daemon: plugin 'ipvlan' not found" is displayed.
Solution
- Open the daemon.json file.
1vi /etc/docker/daemon.json - Modify the fields (if the file already contains content, add the following fields to the top).
{ "experimental": true } - Restart the Docker service.
1sudo systemctl restart docker
Parent topic: Setting Up the Environment and Networking