Why do I get the error "-bash: /bin/grep: Argument list too long"?

Updated -

Issue

Why do I get the error "-bash: /bin/grep: Argument list too long"?

Environment

Red Hat Enterprise Linux All versions

Resolution

The constant ARG_MAX declared in include/linux/limits.h, defines how long an argument list can be on the command line.

./include/linux/limits.h:
[...]
6 #define NGROUPS_MAX...

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.