When you write a shell script that starts with the Crontab timer task, if the shell script execution time exceeds, Crontab pulls the script time interval, this time may appear the same script simultaneously initiates several times the phenomenon.
Echo is an internal command of the shell that prints the specified string on the screen. Command format:Echo ArgYou can use echo to achieve more complex output format control.Show escape charactersecho "\" It is a test\ ""The result will be:"It is a
printf "The complete list is%s\n" "$$" 24520 the shell itself PIDprintf "The complete list is%s\n" "$!" PID of the last running background process of the empty shellprintf "The complete list is%s\n" "$?" 0 end code of the last Run command (return
The following content is basically extracted from the Shell13 question.1. Truncation function${file#*/}: Take out the first/its left string: dir1/dir2/dir3/my.file.txt${file##*/}: Take out the last/and left string: my.file.txt${file#*.}: Take out
Thanks to the original, the article is very helpful.Transferred from: http://www.cnblogs.com/chengmo/archive/2010/10/02/1841355.htmlFirst, Judge read the string value
An expression
meaning
There are some files and directories under the current directory, each of which has several. txt files in each directory.It is now required to create a new directory in the current directory all, and all of those directories will have a. txt fileare
A bash vulnerability exists in the Sun Solaris Low version To resolve the issue by uninstalling or upgrading.1, all the PKG installation package:HTTP://MIRROR.OPENCSW.ORG/OPENCSW/ALLPKGS/2, download and install: #gunzip
From:http://blog.chinaunix.net/uid-2522786-id-223518.htmlThere are many commands for Unix systems, but there are more ways to use commands skillfully. With the accumulation of experience and observing the practice of learning other users, we can
Create script: Vim test.shScript content: #! /bin/bash # "#!" is a contract tag that tells the system which shell to use to executeecho "Hello world!"Make script Execute permission: chmod +x./test.shExecute script:./test.sh #注意, be sure to
One, CD switch directoryCD/ETC switch to/etc Directory CD ~ Switch to home directoryCd.. Return to the parent directory CD. /.. Return to the top level two directoryCD-Returns the directory where it was before entering this directorySecond, echo
As a result of the work, several bash scripts were written in the previous months, primarily for automated testing, packaging, installation packages, and so on. Although compared to C + + programming, to be simple, stupid, but it in the Unix-like
opkg updateopkg Install ddns-scripts Luci-app-ddnsDownload the Ddns script with the above command, edit the configuration fileVi/etc/config/ddnsConfigured as followsConfig Service"Myddns"option enabled"1"optionInterface "Wan"option Use_syslog"
When you design script, you sometimes need to modify your scripts, such as deleting or replacing certain keywords. Like this practice of dynamically modifying files during script execution, called stream editing. A tool with flow editing
Today a shell script is written, and direct execution is possible.But it's not done with a task plan.The script is as follows:#!/bin/bashtime=0504timea=05Mysqd-f-u root DTS Tangled up half a day, then changed to absolute path on it.The script is as
String interception of Linux is useful. There are eight ways.Suppose there is a variable var=http://www.aaa.com/123.htm.1. # Intercept, delete the left character, leave the right character.echo ${var#*//}where Var is the variable name and the # is
First, the installation of Mutt1 yum-y Install postfix2 #需要安装sendmail并开启防火墙的25端口, if you need to receive mail 110 port also open 3 yum-y install Mutt Second, configuration informationAbout the configuration information, there is a point to explain,
Fundamentals of the ten-year OPS series-LinuxZeng LinContact: [Email protected]Website: www.jplatformx.comCopyright: Please do not reprint the article without permission
first, use the IF statementThrough the shell, we can write a shell script
In the forum above Post asked what things, once not top, the post on the second sank, but really do not want to go to the top every moment, how to do? The following shows how to use the shell's crontab to implement automatic top-pasting.Gossip not
First, what is a variableShell programming language is a non-type interpreted language, unlike the C++/java language programming requires the declaration of variables, the shell assigns a variable, in effect, it defines the variable, in all Linux
Compiled languagesMany of the traditional programming languages, such as Fortran, Ada, Pascal, C, C + +, and Java, are compiled languages. These languages require that the source code that we have written be converted into a target tag (object
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