The original article was written at 18:29:20,. NetEase blog has been deleted.To generate a random number in shell, you can call $ random in Bash to reference an introduction to random.Each time this is referenced, a random integer between 0 and 32767
A shell script must have been written as follows:
If [-D dir]ThenEcho "success"ElseEcho "failed"Fi
When talking about if, the book will mention the following two rules:
1. There must be spaces on the left of "[" and;
2. If you want
Sender Shading
From Pixar's paper
Sender Shading
This slice of hair shell is based on FMM (Fast Marching Method) to obain A Level Set function in order to get a "imaginary" curve normal for hair
1. Conditional Test
Use the test command for files, strings, and numbers
Use the expr command for numbers and strings
Expr command to test and execute numerical output
1. Test File statusTest generally has two formats:Test Condition[Conditon]-D
There are basically three ways to execute shell scripts:
(1) input is directed to the shell script.
The general form is Bash For example, bash (2) Use the script name as the parameter. The general form is:
Bash Script Name [parameter]
For
1. Echo "AA"> test.txt and echo "BB"> test.txt //> clear the original file and write the content to the file.> put the content at the end of the file.2. chmod go + w-r/home/zhangy // Add write permissions to group users and other users3, tar-tzvf
Document directory
Function Definition
Return Value
To put it simply, the popen () functionFunction Definition
#include FILE * popen(const char *command , const char *type );int pclose(FILE *stream);Function Description
The popen () function
It is a good thing. In many places of life, people like to use abbreviations, which saves time and effort. Bash also has its own abbreviation, alias,Alias always has a lot to do. Why not? As mentioned above, we often talk about a large number of
Http://blog.chinaunix.net/u/29289/showart_407859.html
A read operation can assign values to multiple variables at a time, but only one row can be read at a time. For example:
#! /Bin/bash ifs =: Read aa bb cc
Location parameters can be used
shiftCommand left shift. For example
shift 3Indicates the original
$4Change
$1, The original
$5Change
$2And so on.
$1,
$2,
$3Discard,
$0Do not move. Without Parameters
shiftThe command is equivalent
shift 1. Very
First, you need to first understand how awk works: 1. Awk reads one row of the input file at a time. 2. For each row, it matches in the given sequence mode. If it matches, the corresponding action is executed. 3. If no pattern match exists, any
11.5
Dangdang ~~~ Class ~~~ Pai_^
As mentioned above: $ cat ; after file, the results of files with original content are washed away ﹗
It is not difficult to understand this concept. This is just a matter of priority:
* In Io redirection, The stdout
Common shells are mainly divided into two major types:
SH:
Burne shell (SH)
Burne again shell (BASH)
CSH:
C shell (CSH)
TC shell (tcsh)
Korn shell (Ksh)
Bash is one of the most successful products in the GNU project. It has been widely used in UNIX
Document directory
Use the top script to retrieve the CPU of a process:
Add User:
IP address access statistics:
Calculate the sum of 2 numbers
Text Analysis
File Sorting
Print the swap partition size of the Local Machine
Output the time
The issue is that in w2k3 Telnet Server(Tlntsvr.exe) no longer runs as LocalSystem and needs to run the CMD Process(Cmd.exe) usingCredentials of the logged in user. If Secondary Logon Service is notStarted, TelnetServer process cannot start the CMD
In Windows, there are some files that can be decompressed by yourself, that is, the so-called self-decompressed files. You don't need to know which compression technology is used to compress the file, you can simply decompress the file by running
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