Latest Posts
- Using the Find Command to Search for Large Files in Linux/Unix
- Finding Files by Date in Linux/Unix: A Comprehensive ‘find’ Command Guide
- Efficient File Search in Linux/Unix: A Guide to Using ‘find’ by Name
- How to Use the ‘find’ Command by File Type in Linux/Unix: A Practical Guide
- Best Practices for Sorting with the Top Command in Linux/Unix
Tags
awk awk -F awk examples background run script bash awk command grep linux curl disk space docker commands docker usage du file search find and grep find command find examples Google Analytics grep -v grep examples java java example linux awk linux command linux find linux grep linux ls ls -al ls examples ls sort ls sort by size mkdir mv examples mysql mysql example rm sed sed examples sed tutorial seo Shell tutorial top vim vim examples vim tutorial w wordpress
Tag Archives: linux command
linux grep command – grep not include, grep reverse match
There is also a case where we need to exclude certain content when we do content search. How to achieve it? Still linux grep command! I have such a file test5.txt. Need to query the line containing “dfff” content but … Continue reading
Posted in File & Directory
Tagged grep -v, grep examples, linux command
Comments Off on linux grep command – grep not include, grep reverse match
linux grep command – grep only show match
When we search for content, sometimes we just need to show matching content. At this time we can use the grep command. linux grep You can also display the line number where the matching content is located. linux grep -n … Continue reading
Posted in File & Directory
Tagged grep before and after, grep examples, grep show match, linux command
Comments Off on linux grep command – grep only show match
AWK tutorial: three ways of awk execution
Linux awk command execution ways: 1. Command line execution Detailed introduction of syntax, see 《Linux awk》 2. Shell script file execution Explanation: !/usr/bin/awk The first line of #!/usr/bin/awk is the awk command location. use : ➜ which awk /usr/bin/awk 3. … Continue reading
Posted in Awk Command, Text Processing
Tagged awk examples, awk exec, linux awk, linux command
Comments Off on AWK tutorial: three ways of awk execution
linux grep command – grep multiple patterns
The last article 《grep or condition, grep and condition》 introduced grep and, or use, including the use of the -e parameter. Here is a detailed description of the use of the -e parameter. grep one pattern ➜ grep “12” test1.txt … Continue reading
Posted in File & Directory
Tagged grep -E, grep examples, grep for two strings, linux command
Comments Off on linux grep command – grep multiple patterns
grep show lines before and after
Usually when searching for keywords, we need to look at the keyword context information, all of which use -A, -B and -C parameters. Show num rows after matching – grep -A Show num rows before matching – grep -B Show … Continue reading
Posted in File & Directory
Tagged grep before after, grep examples, linux command
Comments Off on grep show lines before and after
linux grep or , grep and , grep not condition examples
Linux grep conditional;
Grep OR:
1. Use regular, grep -E “[A|B]”;
2. Use -e,grep -e “A” -e “B”;
Grep AND:
Use pipe, grep “A” | grep “B”;
Grep NOT: use grep -v Continue reading
Posted in File & Directory
Tagged grep and, grep or expression, grep or syntax, linux command
Comments Off on linux grep or , grep and , grep not condition examples
AWK tutorial: awk sort uniq
In daily development, we often use awk command to cut and sort log file columns and count them. awk sort uniq count example awk column count linux Sort – n : sorted by the size of the value; – r … Continue reading
Posted in Awk Command, Text Processing
Tagged awk examples, awk sort uniq, linux awk, linux command
Comments Off on AWK tutorial: awk sort uniq
linux grep regex examples
Grep regex matches the search content according to the specified rule pattern, which can help us find the content we need precisely. Syntax: grep -E “pattern” file Continue reading
Posted in File & Directory
Tagged grep examples, grep regex, linux command
Comments Off on linux grep regex examples
AWK tutorial: split on character awk or cut
In the previous article, we introduced the use of linux awk for string cutting. Here we introduce a method. use awk -F parameter use awk split function For more awk usage, please refer to the following article: Let’s look at … Continue reading
Posted in Awk Command, Text Processing
Tagged awk examples, awk split, cud -d, linux command
Comments Off on AWK tutorial: split on character awk or cut
AWK tutorial: awk [-F] print example
– awk print last field
– print line number per line
– print specific columns
– use -F specifies a delimiter Continue reading
Posted in Awk Command, Text Processing
Tagged awk examples, awk NF NR, awk OFS, linux awk, linux command
Comments Off on AWK tutorial: awk [-F] print example
AWK tutorial: awk remove last character
awk remove last character use awk length and substr functions
Posted in Awk Command, Text Processing
Tagged awk examples, awk remove, linux awk, linux command
Comments Off on AWK tutorial: awk remove last character
linux find command tutorial: find syntax and examples
linux find – search for files in a directory hierarchy. syntax examples use find command – find file find – type filter explanation where x may be any of: b – block device (buffered); c – character device (unbuffered); d … Continue reading
Posted in File & Directory
Tagged grep examples, linux command, linux find file
Comments Off on linux find command tutorial: find syntax and examples
AWK tutorial: awk save to file
AWK save to file AWK append to file
Posted in Awk Command, Text Processing
Tagged awk examples, bash awk, file Redirect, linux command
1 Comment
Awk tutorial: awk man
awk man
AWK tutorial: awk newline character
How to use Awk print out a newline character in a string ???