">/dev/null 2>&1" in the shell

Today in one of their technical group was asked such a question, and then the popular explanation, make a record, we see whether the explanation is clear! The shell may often see: >/dev/null 2>&1 The results of the command can be defined in% > to

Remove command exclude specified file in Shell environment

The file structure under the root directory is listed below +-root +-fileA.txt +-subdir1 +- a.txt +- b.txt +-c.txt +-subdir2 D.txt +-e.txt +-f.txt +-subdir3 +-subdir4 +- subdir5 +-subdir6 +-subdir7 +-subdir8

Launch shell script for Java application

For Java Applications (non-Web applications), after deployment, a startup script is often required to load some Third-party jar packs and start the application. For Java applications, I generally prefer to write the directory structure of a program

How to remove the CPU shell?

The waste CPU opens the shell to open the process. 1. Preparation work 2, this step with a knife when you must be careful to be patient, do not scratch the CPU cover and the following section, do not be afraid of no place to row, the CPU

A method in the shell script to convert the input password to * (asterisk) _linux shell

If you need to write a section to interact with the user, and need to input some sensitive information (for example: User password, license, etc.), the direct use of printf+read, the user input information will be displayed on the screen, which is

Shell script extract rpm package _linux shell

There are times when you need to extract files from the RPM package without installing and installing RPM-related libraries and programs, and this little green script can help you achieve your wish. Note:1. This script comes from the Internet, the

System calls to get a process from Linux and parameters (troubleshooting cases) _linux Shell

When a program fails, there are times when you want to troubleshoot problems by understanding the system tuning that the process is executing. You can usually use Strace to track. But Strace is no help when the process is already in the D state

Shell to process filename instances with spaces _linux shell

There was a problem working with files today, and the for loop is problematic when the file name contains spaces. For example, I create 3 files in the current folder that contain spaces: Copy Code code as follows:

Java invoke the Linux shell script method _java

First, we need to increase the user's ability to execute the script, that is, Copy Code code as follows: String cmdstring = "chmod a+x test.sh"; Process proc = Runtime.getruntime (). exec (cmdstring); Proc.waitfor (); Block until the

Shell scripting to fix bash vulnerabilities share _javascript tips

Search on the Internet to find a great God wrote Shell Repair Bash Vulnerability script, feel very good, dragged to my blog to share to everyone. Script content: Copy Code code as follows: #/bin/bash #Author Alex Fang. Updates may

Linux/unix shell arguments to SQL scripts

In the process of database operation, the Shell script provides great convenience for operation and maintenance. A shell script parameter passed as a variable to SQL and a SQL script is one of the scenarios that DBAs often encounter. This article

A comprehensive application of shell functions and scripts

1. Shell function: The shell allows a set of command sets or statements to form an available block called a shell function. A function consists of two parts: a function title, a function body. The title is the function name. A function body is a

How to generate a server password from a shell script

Write a script that can generate random passwords, if you want pure numbers or only letters or case, can be customized, I write a full element here. #!/bin/bash # Author:honway.liu # date:2013-07-19 # concate:gm100861@gmail.com len=90 str= (a B C

Linux Shell Programming Real-combat skills

Avoid common problems with timed task scripts Many scripts are actually used in the form of timed tasks rather than hand-run. However, scripts that implement the same functionality may encounter different problems in both modes of operation. A

Shell--read-u

Transferred from: https://zhidao.baidu.com/question/357781350.html while Read-u3 i && Read-u4 J; Do Echo done34Read-u3 I means to read a row of data in the I variable from FD # 3rd (file descriptor, filename descriptor), so you know what Read-u4 J

The shell learns notes.

1. Semicolons separate multiple commands.2. There are no spaces in the middle of the variable assignment.3. When constructing pipelines, try to make the amount of data in each phase less. If the two tasks are not related to the order, then the

Shell Programming Basics-sed Command

The SED usage of LinuxSed is a good file processing tool, itself is a pipe command, mainly in the behavior of the unit processing, you can replace the data rows, delete, add, select and other specific work, the following first understand the use of

Shell awk Combat

First, the text processing1. Extract key word frequency times by row (for example, 5th column)awk ' begin{fs= ' | '} {a[$5]+=1;} END {for (i in a) print I ":" A[i];} ' Opt. Forumlogicnewserver_action_20161107.log | SORT-NRK 2-t ': '2, log users per

Use shell scripts on Linux to view memory conditions (super-practical)

#!/bin/bashExport Chknum=1#shell搅拌存放目录 (The output log file is also stored in the directory after it is executed)Echo 3 >/wls/wls81/shellSyncWhile [$chknum-ge 0]Doecho "-------------------------------------------------------" >> Trace.logmt= ' Free |

Shell Experience Three

Testing and comparison of shell scriptsTest command: Checks the file type and compares the value (depending on the execution result of the expression (true or false), returns an exit status. )NAMETest-check file types and compare

Total Pages: 541 1 .... 459 460 461 462 463 .... 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.