Squid details 1

xiaoxiao2021-03-06  207

Squid Working Principle: After Squid starts, a Hash Table is created in RAM, and the situation in which the Object configuration in the hard disk is recorded. Squid will create a Digest Table in RAM, which is functional with other cooperative Squid (Sibling) to exchange Digest Table, in case the information you want, you can know very quickly. Which Squid Server has information (Squid can also query other Squid through ICP, but slower speed). However, Digest Table itself is not small, both memory and width, if the memory is not in full, the outer bandwidth is not enough, but more slower than the ICP query. The type of Squid [may not be appropriate to be called, but there is no better word. Language is too bad ^ _ ^] Child, Sibling, Parent. The relationship is as follows: The first relationship between Squid Server is: Child and Parent. When Child Squid Server does not have information, you will be directly to the Parent Squid Server, and then wait until the PARENT gives it information. The second relationship between Squid Server is: Sibling and Sibling. When Squid Server does not have information, you will first ask SIBLING Squid Server, if Sibling is not available, skip it directly to PARENT or on the Internet. The mode of operation of Squid Server is: 1. When Squid Server does not have information, you will first ask Sibling's Squid Server. If SIBLING is not available, you skip it directly to PARENT. 2. To the PARENT, then wait until the Parent gives it information (PARENT you have some information or on the Internet). 3. When there is no Parent, go to the Internet. 4. If these three can't get information, they will not be able to reward the user. Compilation and installation Squid: ./ Configure --prefix = / usr / local / squid [-ip] --enable-async-= 160 --enable-icmp --enable-kill-parent-holk --enable-cache- Digests --Nable-Default-Err-Language = Simplify_Chinese --Nable-Poll && Make && Make Install - Enable-async-IO = 160: This is mainly setting Async mode to run Squid, my understanding is to set up a thread To run Squid, if the server is very strong, there is more than 1G memory, the CPU can consider setting up 160 or higher if the CPU uses SMP. If the server is bad, according to the actual situation (don't be too greedy, ^ _ ^). --enable-ICMP: Add ICMP. It is not added by default. --enbale-kill-parent-hack: When Kill offs the Nobody's Squid process, it will kill its parent process at the same time. --enable-cache-digests: [. . .

】 --Enable-default-err-language = simplify_chinese: Simplified Chinese is displayed in the page when there is an error. [But Squid will still put all languages, and write unhabined words. "--Enable-poll: can improve efficiency. Struad Structure: Installed Directory in / usr / local / squid-10 (where my primary IP is the last section is 10) The structure is: bin /: Place Squid default written startup script. There is runaccel; runcache; squidclient; the first 2 started Squid can be used, because when the Squid process is dead, this script can automatically detect. Runacce is a script for web acceleration, and Runcache is used for Squid agents, and SquidClient is tested with this unit. ETC /: Squid.conf in this directory libexec /: function library; Man /: Help file. Don't say it. . . The SBIN /: Squid command where the directory is located. Generally, if I use it to test, start the Squid command. Or use this command to create SWAP, or add -K parameter restarting. Share /: Some erroneous displayed HTMLs are in it; var /: log, pid, swap are in this directory!

Squid details 2

转载请注明原文地址:https://www.9cbs.com/read-128524.html

New Post(0)