First page Back Continue Last page Overview Graphics
Useful Commands
Grep -- learn regular expressions! Careful with options
Awk
- Scripting/programming language in its own right. I mostly use it to parse fields delimited by whitespace like so:
- ps auxw|grep bash | awk '{print $2}'
- Say no to advanced awk scripts -- choose Perl (or Python)
Cut
- Useful for parsing files with a given delimeter
- grep -v /home /etc/passwd | cut -d : -f 1
Sed
- Stream editor, make changes based on regular expressions
- Strip comments from input files:
Notes: