1, first LDD is not an executable program, but just a shell script2, LDD can display the dependency of the executable module, the principle is by setting a series of environment variablesAs follows: Ld_trace_loaded_objects, Ld_warn, Ld_bind_now,
Http://www.1987.name/141.htmlShell Basics
Terminal printing , arithmetic operations , common variables
Search for specific strings in the specified directory under Linux and highlight matching keywords
Get standard input from a keyboard or
$# is the number of arguments passed to the script. The name of the script itself is the first parameter passed to the shell script , and the second argument is passed to the shell script [email protect Ed] is a list of all parameters passed to the
Linux Shell reads a lineMethod OneBy specifying IFS--Internal Field Separator , by IFS default , you can set a value in the script IFSDEMO 1$cat t1.txt abcfd $cat test_IFS.sh #! /bin/shIFS="c"for LINE in `cat t1.txt`do echo $LINEdone$sh
What is a function? Why do we use a function?I. Related knowledge of functionsThe function is to package the code with a specific function and provide an interface for use. The advantage of this is that code reuse can be achieved on one hand, for
The scenario where the problem occurs is probably 1 cron calls a Python script 2. In the Python script, call a shell script (for log analysis) to obtain the shell output and then send an email. Similar to a monitoring task. There is no
'.' Matches any character
'*' Specifies that * can be used repeatedly for any number of times.
'^' Starts with a string
'$' String end
'. *' Any number of characters
'\' Escape Character
'[...]' Matches any character
'[^...]'
Suppose we define a variable:File =/dir1/dir2/dir3/my.file.txt
You can replace $ {} with different values:$ {File # */}: Delete the first/and its left string: dir1/dir2/dir3/my.file.txt$ {File ### */}: Delete the last/and its left string:
1. Name the variable
Num = 2 Echo "this is {$ num} Nd"
Output this is 2nd
2. Variable addition the default value is string addition.
Var = 1var = $ var + 1 echo $ VaR
Output 1 + 1
3. How to add mathematics:
Let "Var + = 1" Var = "$ [$ var + 1]
1. Change the password
Use the passwd command to change the password.
If the command is executed under the root user, the password of the root user is modified.2. Get help
Use the LS -- Help Command to obtain help.
1 [[email protected] ~] $ Ls --
There are the following texts:
{"result":"success","data":[{"ip":"60.18.151.27"},{"ip":"175.22.2.148"},{"ip":"221.204.202.40"},{"ip":"113.107.250.17"},{"ip":"119.97.146.13"},{"ip":"113.56.106.20"},{"ip":"218.60.5.144"},{"ip":"218.58.225.40"},{"ip":"
Typeset can be used to set variable attributes, such as case, width, and left-right alignment. When typeset is used to change the attributes of a variable, this change is permanent, the following uses KSh as an example to demonstrate the
System# Uname-A # view kernel/operating system/CPU Information# Head-N 1/etc/issue # view the operating system version# Cat/proc/cpuinfo # view CPU Information# Hostname # view the computer name# Lspci-TV # list all PCI devices# Lsusb-TV # list all
The host may be down, or there may be a problem with the network connection.
Sometimes such problems can also be caused by a misconfigured firewall.
The following problems may occur:
1. SSH is not installed when centos is installed.
2.
Bytes --------------------------------------------------------------------------------------------------------
I. History commands
History # view History commands
History-C # Clear history commands
History-W # exit without waiting. directly
People always want to improve efficiency, create more value, and get more choices. However, a person's energy and time are limited. It is especially important to reduce repetitive or meaningless work! You either know how to authorize or give
(Linux shell) Chapter 2-joy of command (1), linuxshell
This article is from my personal blog: (linux shell) Chapter 2 -- joy of command (1)
In the previous chapter, we described some syntaxes that need to be paid attention to in linux shell. Next we
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service