c++webserver/Chapter III Linux Thread Development
1. Threads
1. Definition
Similar to a process, threads are a mechanism that allows applications to perform multiple tasks concurrently. ** A process can contain multiple threads. ** All threads in the same program execute the same program independently and share the same global memory area, including initialized, uninitialized, and hea ...
Added by sheila on Mon, 21 Feb 2022 19:22:04 +0200
It's hard to hear C language? Why don't you take a look at my UNIX system call
1. Write in front
Previously, we have introduced some common knowledge of C language and standard input and output. In this blog, we will introduce the call of UNIX system interface. UNIX operating system provides services through a series of system calls. These system calls are actually functions in the operating system, which can be called b ...
Added by ekalath on Mon, 21 Feb 2022 11:14:49 +0200
5, Memory structure
1. Virtual memory, physical memory, semiconductor memory and page feed file
Virtual memory: address space, virtual storage area, and virtual memory accessed by applications. Physical memory: storage space, the actual storage area. Only the system kernel can access the physical memory. Physical memory includes semiconductor memory and pa ...
Added by vtolbert on Fri, 18 Feb 2022 23:00:29 +0200
Programming three swordsmen in Shell regular expressions (grep, sed, awk)
preface:
There are many kinds of text processors or text editors in Linux/UNIX system, including VIM editor and grep, which we have learned before.
grep, sed and awk are text processing tools often used in shell programming, which are called three swordsmen of shell programming.
1, sed editor
(1) Overview of sed editor
sed is a flow editor ...
Added by justAnoob on Mon, 14 Feb 2022 14:14:42 +0200
Awk entry to mastery series - awk quick start
brief introduction
Awk is an excellent text processing tool and one of the most powerful data processing engines in Linux and Unix environments. The greatest function of this programming and data manipulation language (whose name comes from the initials of the surnames of its founders Alfred aihou, Peter Weinberg and Brian collinhan) depends o ...
Added by Grande on Mon, 14 Feb 2022 08:58:59 +0200
Detailed explanation of awk variables, common built-in variables, user-defined variables, built-in variables NR, NF, FNR, RS, ORS, FILENAME, ARGC and ARGV
preface
Detailed explanation of awk variables, common built-in variables, user-defined variables, built-in variables NR, NF, FNR, RS, ORS, FILENAME, ARGC and ARGV
awk variable
"Variables" are divided into "built-in variables" and "custom variables". "Input separator FS" and "output separat ...
Added by akop on Fri, 11 Feb 2022 10:54:20 +0200
Advanced programming in Unix environment chapter16 network IPC: socket
chapter16 network IPC: socket
socket descriptor
To create a socket, call the socket function
/*
domain: Communication domain
type: socket type
protocol: agreement
*/
int socket(int domain,int type,int protocol); //If successful, the file (socket) descriptor is returned
Socket communication domain is divided into:
fielddescribeAF_I ...
Added by wholetthe15 on Wed, 09 Feb 2022 12:49:40 +0200
Handling VFS objects and standard functions -- VFS objects
File system operation
First, we study the system calls used to communicate with the kernel from the standard library. Although file operation is a standard function for all applications, the operation on the file system is limited to a few system programs, that is, the mount and umount programs used to mount and unmount the file system.
Regis ...
Added by moriman on Sat, 05 Feb 2022 12:35:07 +0200
File redirection and pipeline
Standard file descriptors
Concept of file descriptor: a file descriptor is an integer greater than or equal to 0, which means the sequence number of items in the file opening table of the process (starting from 0). For a process, a file descriptor is a handle that operates on an open file (or a device file, or a socket connection). This entry ...
Added by twilightnights on Wed, 02 Feb 2022 07:53:53 +0200
Linux explore 13- directory operations
-----Latest update [2022-01-22]-----
Preview of this article's directory structure:
1, Related concepts
1. Absolute path and relative path
2. Current directory
3. Home directory
4. Path name abbreviations: And~
2, Related commands
1. Switch and view working directory: cd, pwd
2. Directory operations: create (mkdir), remove (rmdir), rename (mv) ...
Added by dancingbear on Tue, 25 Jan 2022 14:45:45 +0200