grep.1posix -oE %22ERROR%7CWARN%22 *log* %7C sort %7C uniq -c
search a file for a pattern
-E     Match using extended regular expressions. Treat each pattern specified as an ERE, as described  in
       the  Base  Definitions  volume of IEEE Std 1003.1-2001, Section 9.4, Extended Regular Expressions.
       If any entire ERE pattern matches some part of an input line excluding the terminating  <newline>,
       the line shall be matched.  A null ERE shall match every line.
-c     Write only a count of selected lines to standard output.

-e  pattern_list

       Specify one or more patterns to be used during the search for input.  The application shall ensure
       that patterns in pattern_list are separated by a <newline>. A null pattern can be specified by two
       adjacent  <newline>s  in  pattern_list. Unless the -E or -F option is also specified, each pattern
       shall be treated as a BRE, as described in the Base Definitions  volume  of  IEEE Std 1003.1-2001,
       Section  9.3,  Basic Regular Expressions. Multiple -e and -f options shall be accepted by the grep
       utility. All of the specified patterns shall be  used  when  matching  lines,  but  the  order  of
       evaluation is unspecified.

-f  pattern_file

       Read  one  or  more  patterns  from  the  file  named  by  the pathname pattern_file.  Patterns in
       pattern_file shall be terminated by a <newline>. A null pattern can be specified by an empty  line
       in  pattern_file. Unless the -E or -F option is also specified, each pattern shall be treated as a
       BRE, as described in the Base Definitions  volume  of  IEEE Std 1003.1-2001,  Section  9.3,  Basic
       Regular Expressions.
source manpages: grep