How to execute multiple. sql files at the same time in a shell script and write the end to the file

First edition:#!/bin/Bashuser="root"DATABASE="test" TABLE="user"-u $USER $DATABASE--html--default-character-set= UTF8 /tmp/-u $USER $DATABASE--html--default-character-set=utf8 >/tmp/c Heck.htmlSecond Edition:#!/bin/Bashuser="root"DATABASE="test"

Shell Scripting Learning

The format of writing shell scripts with vim or VI is fixed, as follows: #!/bin/sh#commentscode #! tells the system that the program specified after the path is the shell that interprets this script file. If there is no such sentence in the first

(031) The shell location parameters of Linux

Fundamentals of the ten-year OPS series-LinuxZeng LinContact: [Email protected]Website: www.jplatformx.comCopyright: Please do not reprint the article without permission First, IntroductionWe have not had the ability to receive and process

Using SendMail to send messages in the shell

Cat > Sendmymail.sh#!/bin/bash/usr/sbin/sendmail-t from:mail testing to : [email protected]Cc: [email protected]BCC: [email protected]Subject:mail Testing----------------------------------                                This is the mail content ...--

Shell File Size calculation

Du simple Usage exampleDu-SH xmldb/Du-Sm* | sort -n //statistics current directory size and size sorting du -sk *| sort -ndu -sk * | grep guojf //look at a person's size du -m | cut -d "/" -f 2 //See text before second/character See how

(004) Linux shell wildcard

Fundamentals of the ten-year OPS series-LinuxZeng LinContact: [Email protected]Website: www.jplatformx.comCopyright: Please do not reprint the article without permission First, IntroductionWe often have to execute command-line programs under

Apue Exercise 3.2 and the use of redirect symbols in the shell

The requirement of exercise 3.2 is to write a function with the same dup2 () function without using fcntl (). It is intuitive to constantly use the DUP () until the specified file descriptor is returned. #include #include #define OPEN_MAX 6

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

Self-paced shell scripts

First, learn Zhao Wenyu's summary script:1. Variableshost=$ (/bin/hostname)Assigns the result of the command executed in () to the host variableHost= '/bin/hostname 'Assigns the execution result inside the anti-quotation mark to the host

Linux shell read file by line processing

One way is to useCatand anti-quotePS: Anti-quotes play the role of command substitution in Linux. Command substitution refers to the ability of the shell to interpolate the standard output of a command anywhere on a command line.The input format is

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

Linux Shell Recording and playback of terminal sessions

While others are demonstrating certain commands, one of the solutions is to record the process at the time of presentation, and the video is of course the most perfect but cost-efficient. Use the script and Scriptrelay commands to record the order

Bourne again shell built-in command

The built- in command (build-in commands) is the command of the shell Build-in, and when built-in commands are used, the shell executes directly without creating a new child process. Built-in commands are used to create functional or convenient

View all users under Linux (Shell scripting get)

In Linux systems, the two most important files for user account management are/etc/password and/etc/shadow.In the/etc/password file, each line represents an account, but there are many accounts that are system accounts. Like what:Bin, ADM, etc., as

Basic shell operations for HDFS

(1) Distributed File systemAs the amount of data is increasing and the scope of an operating system is not enough, it is allocated to more operating system-managed disks, but it is not easy to manage and maintain, so a system is urgently needed to

CentOS Linux Next tomcat stop, view log shell script

The Tomcat installation directory for CentOS:/usr/local/tomcatVI mytomcatuitl.sh creating fileschmod u+x mytomcatutil.sh Assignment Execution permissionsShell script:1#!/bin/Bash2 3 # tomcat Start, stop, log display script4 5 if[ $1=="']; Then6

basename dirname read in the shell

1. basename is the name left after the directory is removed .example:shell>temp=/home/temp/1.testshell>base= ' basename $temp 'Shell>echo $baseThe result is: 1.test2. dirname is to fetch directory example:shell>temp=/home/temp/1.testshell>dir= '

12 Linux Systems High-frequency command line and Shell small script

The following are some of the more commonly used command line or shell scripts that are extracted during the deployment of OpenStack, for informational purposes only.1. Kill all existing zombie processesPs-ef | grep Defunc | Grep-v grep | awk '

CentOS 7.0 Install peanut shell

No wget first download get command yum-y install wget1. Download Peanut shells[Email protected] ~]# wget http://download.oray.com/peanuthull/linux/phddns-2.0.6.x86_64.tar.gz2. Unzip the tar.gz[Email protected] ~]# tar zxvf

Shell exit, return summary, shell exit summary

Shell exit, return summary, shell exit summary Common Responses in shell: exit, breakm, return Exit: In fact, after each command is executed, an execution state is returned! If the execution is successful, 0 is returned. If the execution limit

Total Pages: 541 1 .... 250 251 252 253 254 .... 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.