moby / moby/swarmkit

swarmctl susceptible to 4MB grpc message limit

Open
#2,830 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
3.7k
Forks
676
Avg merge
4d 9h
Merged PRs (30d)
6

Description

Please mark this low priority. Just planting a post for swarmctl to indicate that it too seems to be affected by the likes of https://github.com/moby/moby/issues/37997.

Discovered this issue when it occurred to me that swarmctl might be used to prune excessive swarmkit objects that trigger the issue, thereby removing the immediate need to change engine versions. The work-around for swarmctl is the same as for dockerd: use an older one without the 4mb grpc message limit.

My specific need is on config list, but as indicated by the above moby issue, other calls are likely affected.

Steps to recreate issue on config list:

setup:

truncate -s 511999 bigconfig.txt
cat bigconfig.txt | swarmctl config create big1
cat bigconfig.txt | swarmctl config create big2
cat bigconfig.txt | swarmctl config create big3
cat bigconfig.txt | swarmctl config create big4
cat bigconfig.txt | swarmctl config create big5
cat bigconfig.txt | swarmctl config create big6
cat bigconfig.txt | swarmctl config create big7
cat bigconfig.txt | swarmctl config create big8
cat bigconfig.txt | swarmctl config create big9

experience:

$ swarmctl config ls
Error: grpc: received message larger than max (4692733 vs. 4194304)
Affected Versions

client:

$ swarmctl version
swarmctl github.com/docker/swarmkit v1.12.0-2067-gebfb0aa1

server: dockerd 18.09.2-ce

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the swarmctl config ls entry point and reproduce the reported failure after creating nine 511999-byte configs with config create. Compare the client and server versions and the linked Moby issue to understand the 4MB gRPC limit. Done means the affected config operation no longer fails for the reported setup, with the supported workaround or limitation documented.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli, distributed-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.