West Post Linux interest group 2020 interview questions

Run the following code and what is the output? Explain why. int i; int main(int argc,char *argv[]){ i--; if(i>sizeof(i)){ printf(">\n"); }else{ printf("<\n"); } return 0; } > The default value of uninitialized global variables is 0, while the value of i after i -- is - 1, which is binary ...

Added by awiedman on Tue, 07 Dec 2021 19:25:37 +0200

LINUX block device driver development

1. Introduction to block device driver Block device drivers provide access to block oriented devicesBlock device drivers generally transmit data in a random manner, and the data always has a fixed size block.A typical block device is a disk drive device. Introduction to block device driver The block device driver interface is relatively comp ...

Added by UKlee on Tue, 07 Dec 2021 17:18:26 +0200

Harbor builds docker private warehouse

catalogue 1, Introduction to harbor 1, Building a private warehouse in harbor 1. Upload dock compose and set permissions 3. Install harbor-offline-installer-v1.2.2 4. Configure the Harbo parameter file 5. Start Harbor 6. View Harbor boot images and containers 7. Create project in UI interface   8. Test warehouse function locally ...

Added by mydownfall on Tue, 07 Dec 2021 17:08:43 +0200

Using the Linux command line

1. What is Shell     Externally accept commands entered by usersInternally, it is passed to the kernel through system callsRendering kernel running results 2. Shell and graphical interface Graphical interface, mainly mouse operation, easy to learn. Shell: keyboard operation is the main operation, and various control commands need to ...

Added by ladokha on Tue, 07 Dec 2021 15:39:50 +0200

Practical operation of keepalive in linux

1, keepalive Foundation 1.1 VRRP Technology vrrp related terms Virtual Router: virtual router Virtual router ID: VRID(0-255), which uniquely identifies the virtual router VIP: Virtual IP VMAC: Virutal MAC (00-00-5e-00-01-VRID) Physical router: Master: master equipment backup: standby device Priority: priority 1.2 VRRP related t ...

Added by xbuzzx on Tue, 07 Dec 2021 14:25:19 +0200

Master MySQL read-write separation and master-slave replication

catalogue           1. MySQL read-write separation and master-slave replication principle 2. Why do we do read-write separation 3. When should I separate reading from writing 4. Master-slave replication and read-write separation 5. Replication types supported by mysql 6. Working process of master-slave replication ...

Added by Jorn TK on Tue, 07 Dec 2021 06:46:49 +0200

System call or crash

5 system call or crash This is where we go into system calls (and other library calls) that allow you to access the network functions of Unix boxes or any box that supports socket application programming interfaces (BSD, windows, Linux, apple, what do you have) When you call one of these functions, the kernel will automatically take over and d ...

Added by Bobo the Bugbear on Mon, 06 Dec 2021 23:18:22 +0200

Configuration and common operations of docker container network

1. The Linux kernel implements the creation of namespace 1.1 ip netns command You can complete various operations on the Network Namespace with the help of the ip netns command. The ip netns command comes from the iproute installation package. Generally, the system will install it by default. If not, please install it yourself. Note: sudo ...

Added by PDXDesigner on Mon, 06 Dec 2021 04:16:58 +0200

MySQL master-slave replication, separation and resolution

catalogue 1, MySQL master-slave replication 1.1 master slave replication architecture and principle 1.1.1 service performance expansion mode 1.2 MySQL extension 1.2.1 what is read-write separation? 1.2.2 why is read-write separation necessary 1.2.3 when should I separate reading from writing 1.2.4 master slave copy and read / write sepa ...

Added by Isoss on Sun, 05 Dec 2021 19:04:14 +0200

Container cornerstone - namespace and cgroup

The purpose of this article is to make readers have a concrete understanding of namespace and cgroup. Of course, due to my limited knowledge of Linux, I can't go deep. "Container is an execution environment that shares the kernel with the host system but is isolated from other process resources in the operating system", which is th ...

Added by chrisg101 on Sun, 05 Dec 2021 15:43:23 +0200