This script can be placed in the/etc/init.d/directory with service RSYNCD Start\stop\status\restart management, you can also use Chkconfig for boot-start management, detailed script content as follows:#!/bin/bash# ************************************
1/etc/profile2 ~/.bash_profile3 ~/.BASHRC4 $PATHWhere/etc/profile is the global environment variable that takes effect for all users, while. Bash_profile only works on the current user.~/.bash_profile: Each user can use this file to enter shell
Tag: will return CTR Word delete Move page ackMove cursor
ctrl+b: Move forward one character (backward)
ctrl+f: Move back one character (forward)
alt+b: Move forward one word
alt+f: Move back one word
ctrl+a: Move to the
The shell script is an operation of the basic skills of personnel, in peacetime work, in order to deal with some anomalies or query data, I often have to write shell scripts automated processing.Here to share a script I wrote to detect the status of
SortHandle sorting problems.For example: Sort-r/file the rows of file in descending order.Tr:As a simplified version of SED, you can replace another character with one character, or delete some characters.CutSplitting according to the line of the
1. BackgroundThe Linux shell is a basic skill, because the weird syntax, combined with poor readability, is often replaced by scripts such as Python.Since it is the basic skills, it needs to be mastered. After all, the process of learning shell
1 Basic composition of shell statementsThe shell is separated by a space between each basic constituent element.For example, [-E file],[,-E, file,] these four basic elements are separated by a space.Same reason [!-e file],[,! ,-E, file,] each of
In short, this technique corresponds to a scenario such as the followingAssume that there is text such as the followingccccaaaabbbbddddbbbbccccaaaaIt needs to be re-processed now. This is very easy,sort-u, but suppose I want to keep the text in its
What is a Linux Shell
A shell is a user program, or an environment that is provided for the user to interact with the system.It is a language interpreter that executes commands that are read from a standard input device, has its own built-in shell
Shell Necklaceproblem DescriptionPerhaps the sea ' s definition of a shell is the pearl. However, in my view, a shell necklace with n beautiful shells contains the most sincere feeling for my best lover Arrietty , but even that's not enough.Suppose
Start specifying the script interpreter# !/bin/bash or #!/bin/sh
Opening plus copyright information#Date: 2017-8-01 22:50#author:yang Qiang wei #Mail: [email protected] #Funtion: This is delete ... #version: 1.0
No Chinese comments in
1. Array definition[[email protected] ~]# a= (12345678) [ [Email protected] -IDC ~]# Echo $aA pair of parentheses indicates an array, and the elements of the array are separated by a "space" symbol.2. Array reading and Assignment1) Get the length
There are several places in the recent new project where you need to invoke the shell script, which records a simple shell script invocation method. The code is as follows:private void Callsh () {InputStreamReader STDISR = null;InputStreamReader
1. Demandfind all unused IPs in a 192.168.0.* network segment2. Realize We know that finding methods that do not use IP can be done using the ping command. For a single IP judgment, use the following command$Ping-C1 192.168.0.1PING192.168.0.1(192.168
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