The difference between printf and echo in a Linux shell

EchoEcho is a very common shell command. The parameters are as follows: -e: Turns on parsing of backslash character backslash-escaped, that is, parsing characters such as/n,/t, rather than two characters -E: Turn off parsing of

Shell command Tips--text to weight and maintain the original order

In short, this technique corresponds to one of the following scenariosSuppose there is text as followsccccaaaabbbbddddbbbbccccaaaaNow it needs to be re-processed, this is very simple, sort-u can be done, but if I want to keep the text in the

The shell condition determines if the-Z to-D meaning

The shell condition determines if the-Z to-D meaningShellfilestringless Terminal user[-A file] is true if file exists.[-B file] True if file exists and is a block special file.[-C file] True if file exists and is a word special.[-D file] True if

Shell command Set

Shell Common knowledge points---------------------------------------SED usage http://www.cnblogs.com/edwardlost/archive/2010/09/17/1829145.htmlSED is a non-interactive editor. It does not modify the file unless you use Shell redirection to save the

Common shell commands for Hadoop

A. Common Hadoop commands1. The FS command for Hadoop#查看hadoop所有的fs命令Hadoop FS#上传文件 (both put and copyfromlocal are upload commands)Hadoop fs-put jdk-7u55-linux-i586.tar.gz hdfs://hucc01:9000/jdkhadoop fs-copyfromlocal jdk-7u55-linux-i586.tar.gz

Shell script Programming Tips--for linux,bash and other technical summaries

I've seen a few books on Shell programming and Linux commands, and this one is particularly impressive, though it's still an introductory book, but I think it's a little bit more detailed and broader than I've ever seen before. Today just read, but

Shell Programming Basics Tutorial 7--script parameter delivery

7. Passing of script parameters7.1.shift commandBrief introduction:Shift n Shifts the parameter position to the left n bits at a timeExample#!/bin/bashusage () { echo "usage: ' basename ' filenames"}totalline=0# The following statement $# the

Non-interactive password change in Shell scripts

today when writing a shell script to find that you need to set the user's password, and set the password is interactive, so in the script is obviously not very good, so the Internet to find information, found the following two common non-interactive

Set-o VI Aix under shell

Set-o VIYou can use the last command with the Esc+k key again.Esc+kEsc+jUpside DownKsh default is Emacs style. Set-o EmacsUse the commands you've already used under AIXUsed under AIX, the default shell is Ksh, unlike bash under Linux, he can't use

Hadoop2-shell Operation detailed

FS ShellThe call file system (FS) shell command should use the form Bin/hadoop FS . All of the FS shell commands use URI paths as parameters. The URI format is Scheme://authority/path. For the HDFs file system, Scheme is HDFS, to the local file

Follow me---quick start shell scripting

Try to make your work more efficient, write scripts, and use scripts, often with less effort. So, take some time today to learn about shell scripting.--------------ahead of the high-energy warning, this article is written slightly entertain, if you

A shell script that automatically restarts after a Linux monitoring process crashes and hangs

How do I keep the service running? How can I ensure that the service is automatically restarted even if it is hung up? This is often a problem when you write a service program. In a Linux system, a powerful shell can handle such transactions with

Shell Command Summary

$ () and "(anti-quote ) are used to do command substitution. Next, let's see ${} ... It's actually used for variable substitution. Shell if interpretation statements are common:[Front and rear spaces] Front Space[-D file] True if file exists and

Shell Script Learning 23 Shell function parameters

In the shell, arguments can be passed to a function when it is called. Inside the function body, the value of the parameter is obtained in the form of a $n, for example, $ $ for the first argument, and $ = for the second argument ...Examples of

Shell scripting, simple & Powerful

  from the Code Farm supplement Linus and Linux, Chapter: Shell you may not know.   recently finished reading this book, feel that there are a lot of good content, this is one of the shell small dessert, bring to share with you, add some of my own

Shell script: Determine whether users and user groups already exist/create users and user groups

Typically, as a deployment script for an application, the first task that begins is to create a dedicated (dedicated) user and user group for the current app. This script is very simple, a reference sample is attached

Rhel automatic installation of zookeeper shell scripts

Rhel automatic installation of zookeeper shell scriptsA: This script runs the machine, Linux RHEL6B,c,d,... : Machine to be installed zookeeper cluster, Linux RHEL6First, on machine A that the script runs, determine that you can log on to the

Bash Shell recursively implements file copy in directory

Preface to the work today encountered a problem, if you copy the file in directory A to directory B (premise directory B does not have the file), and maintain the structure of the file in directory A. The project focuses on the following:

Examples of shell operations for Hadoop HDFs

This article was posted on my blog We know that HDFs is a distributed file system for Hadoop, and since it is a file system, there will be at least the ability to manage files and folders, like our Windows operating system, to create, modify,

Sub-Library Backup (shell) for full-scale backup

Mkdir/server/scriptCd/server/scriptVI mysql_backup_db.sh#!/bin/shmysql_backup_dir=/data/mysql_backup/$ (Date +%f)[!-D ${mysql_backup_dir}] && mkdir-p ${mysql_backup_dir}User_pass= '-u root-pyeqing 'mysql_login= ' MySQL ${user_pass}-e "show Databases"

Total Pages: 541 1 .... 150 151 152 153 154 .... 541 Go to: GO

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.