# Could not creat macvlan with rootless docker

**URL:** <https://forums.docker.com/t/could-not-creat-macvlan-with-rootless-docker/130661>\
**Category:** General\
**Tags:** raspberrypi\
**Created:** [October 26, 2022, 11:07am UTC](https://forums.docker.com/t/could-not-creat-macvlan-with-rootless-docker/130661 "2022-10-26T11:07:14Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![damncold](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/damncold/32/32471_2.png) [@damncold](https://forums.docker.com/u/damncold)\
**Post date:** [October 26, 2022, 11:07am UTC](https://forums.docker.com/t/could-not-creat-macvlan-with-rootless-docker/130661/1 "2022-10-26T11:07:14Z")

</div>

Hi,

i followed the instructions in the [official docs](https://docs.docker.com/engine/security/rootless/) but ended up not beeing able to create a macvlan without the sudo command.

```auto
raspberrypi:~ $ docker network create -d macvlan -o parent=eth0 --subnet=10.3.0.0/24 --gateway=10.3.0.1 --ip-range=10.3.0.224/28 --aux-address="host=10.3.0.238" macvlan_docker
Error response from daemon: invalid subinterface vlan name eth0, example formatting is eth0.10

```

the same command with sudo is working, but i cant see it in  
docker network ls  
or use it when not using sudo for docker-compose …

Searched the web for half a day, but couldn’t find any thread with a hint or solution

```auto
raspberrypi:~ $ systemctl status docker
● docker.service - Docker Application Container Engine
     Loaded: loaded (/lib/systemd/system/docker.service; disabled; vendor preset: enabled)
     Active: active (running) since Wed 2022-10-26 12:53:48 CEST; 11min ago
TriggeredBy: ● docker.socket
       Docs: https://docs.docker.com
   Main PID: 64994 (dockerd)
      Tasks: 9
        CPU: 2.005s
     CGroup: /system.slice/docker.service
             └─64994 /usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock

Oct 26 12:53:38 raspberrypi dockerd[64994]: time="2022-10-26T12:53:38.144067316+02:00" level=info msg="ClientConn switching balancer to \"pick_first\"" module=grpc
Oct 26 12:53:40 raspberrypi dockerd[64994]: time="2022-10-26T12:53:40.513882829+02:00" level=info msg="[graphdriver] using prior storage driver: overlay2"
Oct 26 12:53:41 raspberrypi dockerd[64994]: time="2022-10-26T12:53:41.028839284+02:00" level=warning msg="Unable to find memory controller"
Oct 26 12:53:41 raspberrypi dockerd[64994]: time="2022-10-26T12:53:41.030019749+02:00" level=info msg="Loading containers: start."
Oct 26 12:53:43 raspberrypi dockerd[64994]: time="2022-10-26T12:53:43.883873419+02:00" level=info msg="Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option --bip can be used>
Oct 26 12:53:44 raspberrypi dockerd[64994]: time="2022-10-26T12:53:44.181989865+02:00" level=info msg="Loading containers: done."
Oct 26 12:53:47 raspberrypi dockerd[64994]: time="2022-10-26T12:53:47.548233018+02:00" level=info msg="Docker daemon" commit=03df974 graphdriver(s)=overlay2 version=20.10.20
Oct 26 12:53:47 raspberrypi dockerd[64994]: time="2022-10-26T12:53:47.548460882+02:00" level=info msg="Daemon has completed initialization"
Oct 26 12:53:48 raspberrypi systemd[1]: Started Docker Application Container Engine.
Oct 26 12:53:48 raspberrypi dockerd[64994]: time="2022-10-26T12:53:48.148506574+02:00" level=info msg="API listen on /run/docker.sock"

```

```auto
raspberrypi:~ $ systemctl status docker.socket
● docker.socket - Docker Socket for the API
     Loaded: loaded (/lib/systemd/system/docker.socket; disabled; vendor preset: enabled)
     Active: active (running) since Wed 2022-10-26 12:53:37 CEST; 12min ago
   Triggers: ● docker.service
     Listen: /run/docker.sock (Stream)
      Tasks: 0 (limit: 832)
        CPU: 6ms
     CGroup: /system.slice/docker.socket

Oct 26 12:53:37 raspberrypi systemd[1]: Starting Docker Socket for the API.
Oct 26 12:53:37 raspberrypi systemd[1]: Listening on Docker Socket for the API.

```

```auto
raspberrypi:~ $ uname -a
Linux raspberrypi 5.15.61-v8+ #1579 SMP PREEMPT Fri Aug 26 11:16:44 BST 2022 aarch64 GNU/Linux

```

---

<div class="post-metadata">

**Author:** ![dustystar](https://sea3.discourse-cdn.com/docker/user_avatar/forums.docker.com/dustystar/32/33118_2.png) [@dustystar](https://forums.docker.com/u/dustystar)\
**Post date:** [December 27, 2022, 10:34am UTC](https://forums.docker.com/t/could-not-creat-macvlan-with-rootless-docker/130661/2 "2022-12-27T10:34:16Z")

</div>

Hi, any update on this? I ran into the same problem when testing docker rootless with macvlan. I tried the stable 20.10.21 and test 22.06.0-beta.0. Thanks.

---

<div class="post-metadata">

**Author:** ![packelend](https://avatars.discourse-cdn.com/v4/letter/p/90ced4/32.png) [@packelend](https://forums.docker.com/u/packelend)\
**Post date:** [August 2, 2023, 4:00pm UTC](https://forums.docker.com/t/could-not-creat-macvlan-with-rootless-docker/130661/3 "2023-08-02T16:00:15Z")

</div>

it could be realted to [invalid subinterface vlan name en0 · Issue #3447 · docker/for-mac · GitHub](https://github.com/docker/for-mac/issues/3447) but there is not any solution yet
