1. Description
Top selection parameters
2. Option
①-B runs in batch mode, but cannot accept command line input;
②-C: displays the command line, not just the command name;
③-D N indicates the interval between two refreshes. For example,-D 5
Shell commandsXargs
Build and execute command lines from standard input
Xargs can be readStdinAnd use a space character or line break character as the resolutionStdinData is separatedArguments.
1) Description
Xargs [-0epn] command
Options
1. Diff
1) Name
Diff-find differences between two files
Synopsis
Diff [Options] From-file to-file
Description
In the simplest case, diff compares the contents of the two files from-file and to-file.
2) Option
A single letter preceded
1,Which
Which-shows the full path of (Shell) commands.
Which [Option]
2,Whereis
Whereis-locate the binary, source, and manual page files for a command
Whereis [Option] filename
3,Find
Find-search for files in a directory hierarchy
Find [
Parentheses
The parentheses structure can force the command to run in the sub-shell. Its basic format is:
(
Command 1
Command 2
...
Command n
)
The N commands in parentheses are run in the sub-shell. After bash version 3, the internal
1. Description
/Sbin/ldconfig-configure dynamic linker Run-Time Bindings
Ldconfig Option
2. Option
1)-P: indicates that ldconfig prints the names of all the shared libraries saved in the current cache file.
2)-V: ldconfig displays the
1. Description
Strace-trace system CILS and Signals
2. Option
1) strace-p pid tracks a background process
2) strace-O filename outputs the trace result to the file
3) strace-T records the time spent on each system call. You can see which
Bitwise operator.
Bitwise operators are rarely used in shell scripts..Their main purpose seems to be to operate and test from sockets
Read variables. "Bit flipping" is closely related to the compilation language , for example, C/C ++ , in
1. Tail-output the last part of Files
Tail [Option] [+/-num]... [file]...
2. Option
①-F,: Output appended data as the file grows;
②-S,: With-F, sleep for S seconds (default 1.0) between iterations.
③-N,: output the last n lines, instead of
1. About the prompt, special Variables
1) Bash has two levels of prompt. The first-level prompt is often seen when Bash is waiting for command input. The default value is the $ symbol, and PS1 is the variable value. The second-level prompt is
Http://rimuhosting.com/howto/profile.jsp
Linux Shell environment setup using/etc/profile. d /*
When a user logs in, environment variables are set from various places. That between des:
/Etc/profile (for all users ).
Then all the
> VI copy and paste
Move the cursor to the beginning of the part to be copied. Run ESC to exit the insert mode. Press V to enter visual mode. Use hjkl to select the part to be copied.
Press Y or YY to copy
Move the cursor to the target
1. find Find pathname-options [-print-Exec-OK] let's take a look at the parameters of this command: path of the Directory searched by the pathname find command. For example, use "." To represent the current directory, and use "/" to represent
I have learned shell scripts before, but it has never been used in my work. To prevent repeated startup of PHP scripts, I need to write a shell,
What I learned was finally used. I wrote this script with the knowledge points I remembered. I want to
First article written since last timeArticleTwo months have passed. This article describes how to obtain the decrypted il bytes.Code.Let's review the previous article. In the previous article, we mentioned that "After infacemaxtocode. startup is
Linux file descriptor: Three file descriptors are opened by default: standard input 0, standard output 1, error output 2
Output redirection
Command-line1 [1-N]> file or file operator or device
First, check whether the file on the right exists.
This series will focus on the advanced usage skills in Linux Shell. It is mainly intended for experienced Shell developers, Linux system administrators, and Linux enthusiasts. The examples in the blog mainly come from the Internet and some classic
7. grep family:1. grep exit status:0: indicates successful;1: The matching pattern cannot be found in the provided file;2: The file provided in the parameter does not exist.See the following example:/> Grep 'root'/etc/passwdRoot: x: 0: 0:
CPU resources are consumed in an endless loop. If the server has multiple CPUs, you can select the number of CPU resources to be consumed:
#! /bin/sh # filename killcpu.shif [ $# != 1 ] ; then echo "USAGE: $0 " exit 1;fifor i in `seq $1`do echo
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.