Ubuntu's basic regular expression metacharacters and meanings: "*" ------ used to match the previous normal character 0 or multiple times; ". "------ used to match any character;" ^ "------ used to match the first line, indicating the character (or string) after the character" ^ "at the beginning of the line ); "$" ------ used to match the beginning and end, $ is placed after the matching character, opposite to the function and usage of the "^" symbol; "[]" ------ used to match character sets, this symbol supports the exhaustive method to list all elements of a character set. It also supports the use of the "-" symbol to indicate the range of character sets, indicating that the range of character sets starts from the Left character, ends with the character on the right side of "-". example-01: the exhaustive method is used to list character set combinations: sudo find/etc/-name *. conf | grep [abc] use the "-" symbol to indicate the word set range: sudo find/etc/-name *. conf | grep [a-d] example-02: sudo f Ind/etc/-name *. conf | grep [^ a-d] In the above example, "^" indicates the reverse meaning, no longer the meaning of matching the first character of the line; "\" ------ is an escape character, it is used to block the special meaning of a metacharacters and to interpret the metacharacters after the "\" symbol by literal meaning. example: sudo find/etc/-name *. conf | grep \. in the example above, it no longer indicates matching any character, but only indicates the character itself. "\ <\>" ------ Is a exact match symbol, which uses the "\" symbol to shield the "<>" symbol; "\ {\}" ------ the series symbols are similar to "*", indicating the repetition of the previous character. However, the "*" symbol indicates zero or any repetition, and the "\ {\}" series symbol can specify the number of repetitions, the "\ {\}" series symbols can be in the following three forms. 1. \ {n \}: match the previous character to appear n times; 2. \ {n, \}: match the previous character to appear at least n times; 3. \ {n, m \}: match the previous character to appear n to m times.