Issue adding overlay driver when creating docker network

What I’m trying to accomplish:

Setup a docker network using the overlay driver.

Setup

Using a 3 node RPI cluster via SSH to run a docker swarm to work my way through a Udemy course. Working on scaling out with overlay networking. Using the official Raspberry Pi OS image on each node.

What’s going wrong:

When I create the network, the driver is missing.

Everything was working as expected (network was being created with overlay driver) until I tried to tear it all down and build it back up again to practice.

  1. I removed both of the services running (drupal and postgres) with docker service rm postgres drupal
  2. I had run a docker node rm node(x) --force on each of the nodes: node1, node2, node3.
  3. I removed the docker network with a docker network rm myswarm
  4. I rebooted all of the pi’s.

Steps to reproduce:

  1. Create the swarm
[email protected]:~ $ docker swarm init --advertise-addr 10.0.0.12 --default-addr-pool 10.10.0.0/24
  1. Create a manager token for the other 2 nodes
[email protected]:~ $ docker swarm join-token manager

docker swarm join --token SWMTKN-1-5s0wfc7kg8puoycy7l3trodzw4qe59fgpaab6nre179ucjvn88-255j99esrvuvu7be4hma9re67 10.0.0.12:2377
  1. Have the other 2 nodes join the swarm
[email protected]:~ $ docker swarm join --token SWMTKN-1-5s0wfc7kg8puoycy7l3trodzw4qe59fgpaab6nre179ucjvn88-255j99esrvuvu7be4hma9re67 10.0.0.12:2377

[email protected]:~ $ docker swarm join --token SWMTKN-1-5s0wfc7kg8puoycy7l3trodzw4qe59fgpaab6nre179ucjvn88-255j99esrvuvu7be4hma9re67 10.0.0.12:2377
  1. Verify the swarm is active
[email protected]:~ $ docker node ls
ID                            HOSTNAME   STATUS    AVAILABILITY   MANAGER STATUS   ENGINE VERSION
n53r6l4bw9u106856v7wzsu34 *   node1      Ready     Active         Leader           20.10.7
32zpfojueqbj0is6ew4uw9n1i     node2      Ready     Active         Reachable        20.10.7
uktxcdaigu2d0r0dcwbexbt79     node3      Ready     Active         Reachable        20.10.7
  1. Create the network
[email protected]:~ $ docker network create --driver overlay myswarm

Result:

[email protected]:~ $ docker network ls

NETWORK ID     NAME              DRIVER    SCOPE
27adb8118aea   bridge            bridge    local
ce1a0f497e9d   docker_gwbridge   bridge    local
7c85cac72cf8   host              host      local
wms7dubd4783   ingress           overlay   swarm
92tsnavpodmi   myswarm                     swarm
ca5fc5682911   none              null      local

Troubleshooting:

[email protected]:~ $ docker network inspect myswarm

[
    {
        "Name": "myswarm",
        "Id": "92tsnavpodmig36uyq6uwwen9",
        "Created": "2021-07-10T02:17:05.719079589Z",
        "Scope": "swarm",
        "Driver": "",
        "EnableIPv6": false,
        "IPAM": {
            "Driver": "",
            "Options": null,
            "Config": null
        },
        "Internal": false,
        "Attachable": false,
        "Ingress": false,
        "ConfigFrom": {
            "Network": ""
        },
        "ConfigOnly": false,
        "Containers": null,
        "Options": null,
        "Labels": null
    }
]
[email protected]:~ $ docker --version

Client: Docker Engine - Community
 Version:           20.10.7
 API version:       1.41
 Go version:        go1.13.15
 Git commit:        f0df350
 Built:             Wed Jun  2 11:57:27 2021
 OS/Arch:           linux/arm
 Context:           default
 Experimental:      true

Server: Docker Engine - Community
 Engine:
  Version:          20.10.7
  API version:      1.41 (minimum version 1.12)
  Go version:       go1.13.15
  Git commit:       b0f5bc3
  Built:            Wed Jun  2 11:55:25 2021
  OS/Arch:          linux/arm
  Experimental:     false
 containerd:
  Version:          1.4.6
  GitCommit:        d71fcd7d8303cbf684402823e425e9dd2e99285d
 runc:
  Version:          1.0.0-rc95
  GitCommit:        b9ee9c6314599f1b4a7f497e1f1f856fe433d3b7
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0
[email protected]:~ $ docker service ls
ID        NAME      MODE      REPLICAS   IMAGE     PORTS
[email protected]:~ $ docker info
Client:
 Context:    default
 Debug Mode: false
 Plugins:
  app: Docker App (Docker Inc., v0.9.1-beta3)
  buildx: Build with BuildKit (Docker Inc., v0.5.1-docker)

Server:
 Containers: 0
  Running: 0
  Paused: 0
  Stopped: 0
 Images: 0
 Server Version: 20.10.7
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 1
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: active
  NodeID: n53r6l4bw9u106856v7wzsu34
  Is Manager: true
  ClusterID: lvorzzldffo83e5ngpuwacg5t
  Managers: 3
  Nodes: 3
  Default Address Pool: 10.10.0.0/24  
  SubnetSize: 24
  Data Path Port: 4789
  Orchestration:
   Task History Retention Limit: 5
  Raft:
   Snapshot Interval: 10000
   Number of Old Snapshots to Retain: 0
   Heartbeat Tick: 1
   Election Tick: 10
  Dispatcher:
   Heartbeat Period: 5 seconds
  CA Configuration:
   Expiry Duration: 3 months
   Force Rotate: 0
  Autolock Managers: false
  Root Rotation In Progress: false
  Node Address: 10.0.0.12
  Manager Addresses:
   10.0.0.12:2377
   10.0.0.25:2377
   10.0.0.93:2377
 Runtimes: io.containerd.runc.v2 io.containerd.runtime.v1.linux runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: d71fcd7d8303cbf684402823e425e9dd2e99285d
 runc version: b9ee9c6314599f1b4a7f497e1f1f856fe433d3b7
 init version: de40ad0
 Security Options:
  seccomp
   Profile: default
 Kernel Version: 5.10.17-v7+
 Operating System: Raspbian GNU/Linux 10 (buster)
 OSType: linux
 Architecture: armv7l
 CPUs: 4
 Total Memory: 924.2MiB
 Name: node1
 ID: 4MPN:MDSZ:3F7V:4QFG:JBLD:N46C:BM3J:XWCU:Z3JW:Y5O2:4EFW:GC6M
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 Registry: https://index.docker.io/v1/
 Labels:
 Experimental: false
 Insecure Registries:
  127.0.0.0/8
 Live Restore Enabled: false

WARNING: No memory limit support
WARNING: No swap limit support
WARNING: No kernel memory TCP limit support
WARNING: No oom kill disable support
WARNING: No blkio throttle.read_bps_device support
WARNING: No blkio throttle.write_bps_device support
WARNING: No blkio throttle.read_iops_device support
WARNING: No blkio throttle.write_iops_device support
[email protected]:~ $ docker node inspect node1
[
    {
        "ID": "n53r6l4bw9u106856v7wzsu34",
        "Version": {
            "Index": 101
        },
        "CreatedAt": "2021-07-10T02:03:57.31130708Z",
        "UpdatedAt": "2021-07-10T03:07:51.729471138Z",
        "Spec": {
            "Labels": {},
            "Role": "manager",
            "Availability": "active"
        },
        "Description": {
            "Hostname": "node1",
            "Platform": {
                "Architecture": "armv7l",
                "OS": "linux"
            },
            "Resources": {
                "NanoCPUs": 4000000000,
                "MemoryBytes": 969105408
            },
            "Engine": {
                "EngineVersion": "20.10.7",
                "Plugins": [
                    {
                        "Type": "Log",
                        "Name": "awslogs"
                    },
                    {
                        "Type": "Log",
                        "Name": "fluentd"
                    },
                    {
                        "Type": "Log",
                        "Name": "gcplogs"
                    },
                    {
                        "Type": "Log",
                        "Name": "gelf"
                    },
                    {
                        "Type": "Log",
                        "Name": "journald"
                    },
                    {
                        "Type": "Log",
                        "Name": "json-file"
                    },
                    {
                        "Type": "Log",
                        "Name": "local"
                    },
                    {
                        "Type": "Log",
                        "Name": "logentries"
                    },
                    {
                        "Type": "Log",
                        "Name": "splunk"
                    },
                    {
                        "Type": "Log",
                        "Name": "syslog"
                    },
                    {
                        "Type": "Network",
                        "Name": "bridge"
                    },
                    {
                        "Type": "Network",
                        "Name": "host"
                    },
                    {
                        "Type": "Network",
                        "Name": "ipvlan"
                    },
                    {
                        "Type": "Network",
                        "Name": "macvlan"
                    },
                    {
                        "Type": "Network",
                        "Name": "null"
                    },
                    {
                        "Type": "Network",
                        "Name": "overlay"
                    },
                    {
                        "Type": "Volume",
                        "Name": "local"
                    }
                ]
            },
            "TLSInfo": {
                "TrustRoot": "-----BEGIN CERTIFICATE-----nMIIBajCCARCgAwIBAgIUT5mG/5khlfSRUIU88mnmf7pwvWAwCgYIKoZIzj0EAwIwnEzERMA8GA1UEAxMIc3dhcm0tY2EwHhcNMjEwNzEwMDE1OTAwWhcNNDEwNzA1MDE1nOTAwWjATMREwDwYDVQQDEwhzd2FybS1jYTBZMBMGByqGSM49AgEGCCqGSM49AwEHnA0IABJq+1JxqBZwwA2jeL705UfeVRoolvAtIbP6jzRvApCQKYexjWYOpQ4vcZkcinC2YAVVAVK6MU40VCzORNLTw0RYijQjBAMA4GA1UdDwEB/wQEAwIBBjAPBgNVHRMBnAf8EBTADAQH/MB0GA1UdDgQWBBRPNwK65Qe4aYnkvhg47jvuIqgTaTAKBggqhkjOnPQQDAgNIADBFAiB7eaXYJnkI8n15Mensx1PEoix9W3ewsJkLowRnhynQMAIhAJ+mnWDsn2nR3GsQcLqavUhVwcsS/etnwyO1K3v2wWg5an-----END CERTIFICATE-----n",
                "CertIssuerSubject": "MBMxETAPBgNVBAMTCHN3YXJtLWNh",
                "CertIssuerPublicKey": "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEmr7UnGoFnDADaN4vvTlR95VGiiW8C0hs/qPNG8CkJAph7GNZg6lDi9xmRyILZgBVUBUroxTjRULM5E0tPDRFiA=="
            }
        },
        "Status": {
            "State": "ready",
            "Addr": "10.0.0.12"
        },
        "ManagerStatus": {
            "Reachability": "reachable",
            "Addr": "10.0.0.12:2377"
        }
    }
]

I’m not sure if it adds anything to the clues, but the Pi I’ve been running as the Leader node1 has been laggy / hanging ever since these issues started.

Source: Docker Questions

LEAVE A COMMENT