Linux use shell script to automatically submit Web 404 dead link to search engine

Shell Script Just do it, simply write a Shell script and it's done! Script Name: Web site dead chain generation script Script function: Daily analysis of the site the day before the Nginx log, and then extract the status code of 404 and UA for

Problems with using SSH commands in a while loop under the shell

1 Description of the phenomenonThe most recent batch execution command using SSH (with key trust already done), the script reads the list of hosts in the configuration file (the content is one host IP address per line), and then executes, but every

Shell special symbol, cut, sort, WC, uniq, tee, TR, split command

* Represents 0 or more arbitrary characters[[email protected] ~]# ls *txt11.txt 1.txt 22.txt 2.txt aa.txt a.txt? Represents only one arbitrary characterWhether it's a number or a letter, as long as it matches a single character.[email protected] ~]#

3 ways for the shell to read a file by line

Method 1:while the most efficient and most commonly used method in the loop.While read line DoEcho $lineDone Note: This is done at the end of the file, as if it were done and then read the file in the same way.Method 2: Pipe method: Cat $FILENAME |

Shell script face Questions

What is a q:1 shell script and is it required?A: A shell script is a text file that contains one or more commands. As a system administrator, we often need to use multiple commands to accomplish a task, and we can add all these commands in a text

Process Control of shell scripts

Process Control of shell scripts Process Control of shell scripts Conditional statements Conditional judgment Loop Statement For,while,until For loop While loop Until cycle

ubuntu16.04 How do I double-click Execute Shell file?

1, first use the sudo apt-get install dconf-editor command installation Dconf-editor, the default is not installed;2, after the installation is complete, run the Dconf-editor command to call out the window, press org->gnome->nautilus->preferences

Resolve command line execution shell script succeeds, but crontab execution fails

Actual production caseThe production room self-built PPTP client is connected to the production room by dial-up, but once the client network is accidentally disconnected and then dialed againGenerates an IP conflict, so a script is written to

What about shell script execution timeouts?

In the shell there will be a less common situation, that is, the script sometimes has a time-out phenomenon. Generally speaking, we will use the following script as a "timeout watchdog":#!/bin/bash./$1 & #这里设定后台运行的第一个参数pid = $!

Shell script (Batch create script)

While ;(create a 20 file )Cd/etc/servicesMkdir-p scriptsVim scirpts. Sh#!/bin/bashI= 1, dir=/scirptsWhile [$i-lt 21]Do Touch dir/test$iLet i = $i +1DoneBatch renaming:#!/bin/bashI= 1, dir=/scirptsWhile [$i-lt 21]Do MV dir/test $i alex$iLet i = $i

Shell Monitor lists 10 cpu-intensive processes in 1 hours

The script reads as follows:-------------------------------------------------------------------------------------------------------#!/bin/sh#定义变量secs=3600Unit_time=60stepts=$ (($secs/$unit _time))echo CPU usage ...;For ((i=0;iDoPs-eo COMM,PCPU |

Shell Features: PS1, PS2

[Email protected] ~]# echo $PS 1 # View the main prompt ~]# echo $PS 2 # View from the prompt ~]# export ps1= ' [\[email protected]\h \w]\$ ' # Set the main prompt (temporary), If you want to permanently

How to solve the Chinese garbled character of SSH Secure Shell Client

Http://www.cnblogs.com/52linux/archive/2012/03/24/2415082.htmlScenario One: Modify environment variables for Linux serversWith Linux, there is a. bash_profile configuration file under the user root, which is only valid for the current user. Modify

(Linux shell) Chapter One-small trial sledgehammer (next)

Article Source: (Linux Shell) The first chapter--Small trial sledgehammer (next)1.6 Arrays and associative arrays1.6.1 Preparation KnowledgeBash supports common arrays and associative arrays at the same time. An ordinary array can use integers only

Learning spark--use Spark-shell to run Word Count

In the Hadoop, zookeeper, hbase, spark cluster environment has set up the environment, 工欲善其事 its prerequisite, now the device has been, the next is to open up, first from Spark-shell began to uncover spark artifact veil.Spark-shell is the command

"Learn Linux with older boys Koriyuki shell programming Practice"-the fourth chapter of variable numerical calculation

This article explains the numerical calculation of variables in shell programming.1. Common Arithmetic operators:650) this.width=650; "Width=" "height=" 216 "title=" 2.png "style=" WIDTH:600PX;HEIGHT:216PX; "alt=" Wkiom1j4rnrydwfjaabg6obovmq759.png "

Shell regular Expressions and text-processing tools (i)

Job One: organize regular expression Blogs1, what is the regularA regular is a method of describing a character or string with a combination of special meanings (called regular expressions).Or, the regular is the rule used to describe a class of

Linux network configuration and SSH and Shell basics

Linux network configuration and SSH and Shell basicsFirst, the Linux network configuration The ifconfig command is used to configure and display network parameters for network interfaces in the Linux kernel. The NIC information configured with the

Shell writes ping packets and ARP monitoring and sends text messages through the shell

#!/bin/bash now= "' Date +%y%m%d-%h:%m:%s '" phones=15134567893 ip=10.100.8.78 gateway=10.100.30.1 #ping失误的短信内容 Content1= "host is failed" #arp主机网关失误的短信内容 Content2= "GW is failed" #ping日志路径 logfile= '/tmp/ping ' Date "+%y%m%d-%h-%

Shell interpreter, variable, string, array

1.Shell IntroductionThe shell is a program written in C that is a bridge for users to use Linux. The shell is both a command language and a programming language. A Shell is an application that provides an interface through which users access the

Total Pages: 541 1 .... 79 80 81 82 83 .... 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.