Grep-o
grep ignores matching own PS aux | grep python will always see a match that contains grep, which is not in line with our matching expectations. This can be filtered out of the grep match. The following command can be used to implement
grepgrepgrep
Grep-f
Grep-f is equivalent to Fgrep. Egrep is equivalent to GREP-E.
Here's the information we found.
You had a file with a list of say ten Unix usernames in plain text. You want to search the group file on your machine to see if any of the ten users listed is in any special groups:
-F-f user_list.txt /etc/group
The reason The-f switch helps here is, the usernames in your pattern file is interpreted as plain text strings. Dots For example would is interpreted as dots rather than wild-cards. -F indicates that the content is read from User_list.txt.
Grep-o
The Grep-o output matches the content.
Grep-e
A regular expression that supports extensions.
Several parameters of grep matching