Why do I get “/bin/sh: Argument list too long” when passing quoted arguments?
TL;DR A single argument must be shorter than MAX_ARG_STRLEN. Analysis According to this link: And as additional limit since 2.6.23, one argument must not be longer than MAX_ARG_STRLEN (131072). This might become relevant if you generate a long call like “sh -c ‘generated with long arguments’”. This is exactly the “problem” identified by the OP. … Read more