Reprinted from Matchless Castle | Demon Angel
When the shell edits the script, the runtime appears "': not a valid identifier", or it will appear (: Command not found, many inexplicable symbols) it is likely that you are editing under Windows,
Linux variables are roughly divided into four categories: User-defined variables, environment variables, positional parameter variables, predefined variables four categories, the most commonly used is the first three categories, where positional
Using the Linux shell is my daily basic work, but I often forget some useful shell commands and L tips. Of course, I can remember the order, but I'm not sure I can remember how to use it to perform a particular task. So I began to record these
Work often will write some shell script to complete the task, in the process of writing the shell often involves some arithmetic operations, below I will often use several arithmetic operation commands to do a simple summary. The commonly used
Linux Common Commands
LS-F: Catalog will show/
[Root@milab ~]# ls-ifl
total dosage
69199780-rw-------. 1 root root 1496 June 8 2016 anaconda-ks.cfg
77471938 Dr Wxr-xr-x. 2 root 6 September 21:49 svntest/
74325841-rw-r--r--. 1 root root 7
Brief Introduction
Sed is an online editor that handles a single line of content at a time. When processing, the currently processed rows are stored in a temporary buffer, known as pattern spaces, followed by the SED command to handle the contents
Shell script, if judgment statement error [: Too many arguments
I have encountered two situations:
1, the first situation is that the Internet, you can say, the string variable may exist in a space, shell resolution when it is considered to be more
1, shell overview
Each person after successfully logged on to Linux, the system will appear a different hint symbol. For example, $, ~, #等, and then you can start typing the command you want, and if the command is correct, the system will execute
Shell programming
All the code is to simple basic sentence assembly, according to their own will to write, and finally get the desired functional program.
1, the beginning: #. /bin/bash
#。 Is the program that tells the system to follow the
The brackets inside the Shell (including the single and double brackets) can be used to test some conditions: arithmetic comparisons, such as whether a variable is 0, [$var-eq 0]. File property tests, such as whether a file exists, [-e $var], is a
1 PATH environment variable
2 Use of redirects
0 Callout Enter default keyboard input, you can use other content to redirect the correct output on the 1 standard output screen
2 error output &> redirect
all output
redirection symbols are:
> >>
2
Paste:
http://blog.csdn.net/allenlinrui/article/details/7490206
With Crontab you can execute a shell script or a series of Linux commands at a specified time. For example, the system administrator schedules a backup task to run every day
Getting
Cut-and
The Cut command extracts text columns from a text file or text stream.
Cut syntax
[root@www ~]# cut-d ' delimited character '-f fields
The PATH variable is as follows
[Root@www ~]# echo $PATH
/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/
HBase contains a shell that can communicate with HBase. HBase uses the Hadoop file system to store data. All these tasks occur in HDFs. Here are some of the
Common HBase shell commands.
Data Manipulation language
Command
a function
There is no obvious difference between a function and a shell script, but there is an essential difference in execution:
for a separate shell script, create a new shell process for it when executing, and interpret and execute the code in
1. Start HBase, go to the Bin folder under the HBase folder, and then execute the command:
HBase Shell
[Root@hadoop0 bin]# hbase shell
hbase shell; Enter ' help ' for list of supported commands.
Type "exit" to leave the HBase Shell
Version 0.98.12.1
Usage:ps [Options] Basic options:-A,-e all processes-a all with TTY, except Sessio N leaders a all with TTY, including and users-d all except session leaders-n, --deselect Negate selection R only running processes T all processes on this Terminal
Basic usage of HBase shell
HBase provides a shell terminal to interact with the user. Use the command hbase Shell to enter the command interface. You can see the Help information for the command by performing a helper.
Demonstrate the use of hbase
ObjectiveWe have successfully installed the Linux system--centos7, and now follow the super brother to the gate of Linux.So!Start a picture, equip all by dozen ...What the hell is this black one?Using Linux every day, is to open the virtual machine,
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.