May I jump in here…
google ‘gunicorn --limit-request-line’ will get you this http://docs.gunicorn.org/en/stable/settings.html
A forum search on ‘gunicorn’ will get you for eg this Gunicorn Worker how to increase - #7 by adnan
and for your 2nd case this local search
frappe@erpnext:~/frappe-bench$ find . -name ‘*.conf’ | xargs grep “client_max_body_size”
./frappe-bench.conf: client_max_body_size 50m;
./config/nginx.conf: client_max_body_size 50m;