1) Replace all files in the file::%s#abc#123#g (if there is # in the file, available/replace,:%s/abc/123/g)--note: replace ABC with 123 (or:%s/str1/str2/g Replace all str1 in the file with str2)
2) Local replacement in file:
: 20,30s#abc#123 (if there is # in the file, available/replace,:%s/abc/123/g)--note: Replace 20 lines to 30 in line with ABC 123
3) View the Linux version:
A. Enter "Uname-a" to display information about your computer and the operating system. B. Enter "Cat/proc/version" to indicate the kernel version that is running. C. Enter "Cat/etc/issue", which shows the release version information D.lsb_release-a (for all Linux, including Redhat, SuSE, Debian and other distributions, but installs LSB under Debian)
4) count the number of occurrences of the string:
Grep-o Objstr Filename|wc-l
5) Kill all related processes:
Kill-9 ' Ps-ef | grep Agentmain | Grep-v "grep" | Grep-v "grep" | awk ' {print $} ' continues to update ...
Advanced Linux Commands