$ find -type f -size +100M -exec ls -l {} \; 2> /dev/null
find: path must precede expression: 2
usage: find [-H] [L] [-P] [path ...] [expression ...]
$
This bizarre error often occurs when you’re using the wrong shell! – You think you’re using bash, ksh, or sh, but you’re actually using csh!
When using csh, there is no easy way to redirect only stderr. If you want to redirect both stdout and stderr in csh you can use “>&”. In fact, “>&” works the same way in bash, and so does “&>”.
If you want to easily redirect only stderr, use a different shell, e.g. bash, ksh, or sh.