Load balancing of LVS-DR mode in four layers

Two methods of LVS-DR construction matters needing attention: At this time, there is only one network card for LVS service; The IP forward forwarding function of the route must be enabled; For client access, the gateway must be specified; The VS service must be configured with a gateway. If the gateway is not ...

Posted by expertis on Mon, 04 Nov 2019 18:34:19 +0100

Python's range() function and for loop statement

range( ) Built in python functions range(stop):0~stop-1 range(start,stop):start~stop-1 range(start,stop,step):start~stop-1 step: step range(7) [0, 1, 2, 3, 4, 5, 6] range(1,5) [1, 2, 3, 4] range(1,11,2) [1, 3, 5, 7, 9] range(2,11,2) [2, 4, 6, 8, 10] FOR loop statement Syntax for recycling: for variable in range(): ...

Posted by synking on Sun, 03 Nov 2019 19:34:29 +0100

WSL update default source

Today, because of a VSC + + error on Windows, I think of WSL. With administrator privileges, the WSL of this computer is installed again. Set → update → developer options → open development mode Control panel → program and update → open or close function → WSL function check Open cmd → input bash → follo ...

Posted by scanreg on Sun, 03 Nov 2019 17:20:21 +0100

Test cycle of TDD

Writing cycle of Test Driven Development (simple overall grasp) You should know that without testing, there is no functional code. How to start test driven development? Write a new test first The outline is as follows: Add a test; /** Understand that the classes and methods used in this test do not exist. At this time, the test and even the co ...

Posted by Sam on Sun, 03 Nov 2019 06:28:31 +0100

JavaScript implementation of six sorting algorithms

This paper introduces the basic algorithm and advanced algorithm of data sorting. These algorithms only rely on arrays to store data. Array test platform First, we construct an array test platform class function CArray(numElements) { this.dataStore = []; this.numElements = numElements; this.toString = toString; this.clear = cle ...

Posted by leetcrew on Sat, 02 Nov 2019 21:40:47 +0100

Nginx hot deployment and log cutting, have you learned?

In the previous article, after we have installed Nginx and configured the Nginx file, I need to operate the command line of Nginx at this time. This article mainly explains the related knowledge of Nginx command line and familiarizes ourselves with Nginx command line operation through the daily hot deployment and cutting log file scenarios. Rec ...

Posted by LHBraun on Fri, 01 Nov 2019 19:38:48 +0100

Shell script if conditional statement

Condition testing Test command: Test whether a particular expression is valid. When the condition is valid, the return value of the test statement is 0, otherwise it is another value. Format 1: test conditional expressionFormat 2: [conditional expression] (note that there is a space between the brackets and the expression) Document testing: ...

Posted by bobbythenewb on Sat, 12 Oct 2019 00:10:37 +0200

Ops.shell-Linux shell notes: introduction

Excerpt from "Introduction to Linux shell scripts" is not finished!!! Conversion, Formatting printf "%-5s %-10s %-4.2f\n" 1 Sarath 80.3456 Color reset = 0, black = 40, red = 41, green = 42, yellow = 32, blue = 44, magenta = 45, cyan = 46, white = 47 echo -e "\e[1;31m This is red text \e[0m" Get environment variables when the process i ...

Posted by MSK7 on Wed, 09 Oct 2019 09:04:58 +0200

014_Driver Module Transfer Parameters

I. Driver Module Transfer Parameters 1. Pass a single parameter (1) Location: in include/linux/moduleparam.h under the source directory (2) Function prototype /** * module_param - typesafe helper for a module/cmdline parameter * @value: the variable to alter, and exposed parameter name. * @type: th ...

Posted by trevorturtle on Wed, 02 Oct 2019 13:55:16 +0200

Notes on the Use of Centos

Centos use 1. Shell Foundation 1.1 Shell type Bash (Bourne-Again Shell, default Linux shell, enhanced version of SH including centos ubuntu, sh soft chain to bash, GNU R&D) http://www.gnu.org/software/bash/manual/html_node/index.html ash (Almquist shell, Kenneth Almquist and 1980s, almost rep ...

Posted by karnegyhall on Wed, 25 Sep 2019 14:12:14 +0200