Server Proxy Cache Technology: SquidSquid uses a separate, non-module, io driver to process customer requests. The supported protocols include HTTP. FTP. SSL. WAIS simple principle: 1. structure: several disks, Several partitions, and several directories 2. query: hashtable in request Hashtable Digesttable: similar to Digest
Server Proxy Cache Technology: Squid uses a separate, non-module, I/o driver to process customer requests. The supported protocols include HTTP. FTP. SSL. WAIS simple principle: 1. structure: several disks = Several partitions = several directories 2. query: Request = hash table = Digest table = file Hash table: similar to Digest
Server Proxy Cache Technology: Squid
Squid uses a separate, non-module, I/o driver to process customer requests. The supported protocols include HTTP. FTP. SSL. WAIS.
Simple principle:
1. Structure: several disks = Several partitions = several directories
2. Query: Request = hash table = Digest table = File
Hash table: similar to outline Digest table: similar directory
3. Working Relationship: child-parent and sibling
Sibling: Neighbor Relationship
- Common commands:
- #/Usr/local/squid/sbin/squid-z // initialize the cache space
- Ps: there is a problem. The common problem is the directory permission problem chown-R squid: squid/cacheX
- #/Usr/local/squid/sbin/squid-k parse // check squid. conf syntax Configuration
- #/Usr/local/squid/sbin/squid-N-d1 // frontend output
- #/Usr/local/squid/sbin/squid-s // run in the background
- #/Usr/local/squid/sbin/squid-k shutdown // close the service
- #/Usr/local/squid/sbin/squid-k reconfigure // load the new configuration file
- #/Usr/local/squid/sbin/squid-k rotate round-robin logs
- Add squid to system startup Item
- Edit/etc/rc. d/rc. local
- Add the following lines:/usr/local/squid/sbin/squid-s
-
- # More/usr/local/squid/var/logs/access. log | grep TCP_MEM_HIT
- This command shows which files are cached to the memory during squid operation,
- And return it to the access user.
- # More/usr/local/squid/var/logs/access. log | grep TCP_HIT
- This command shows which files are cached by squid to the cache during squid operation.
- Directory and return it to the access user.
- # More/usr/local/squid/var/logs/access. log | grep TCP_MISS
- This command shows that some files are not cached by squid while squid is running.
- Is to obtain data from the original server and return it to the access user.
-
- Squid hit rate analysis
- Squid/bin/squidclient-p 80 mgr: info // some running status information
- Squid/bin/squidclient-p 80 mgr: 5 min // 5 min Information
- Obtain squid memory usage:
- Squidclient-p 80 mgr: mem
- # Retrieve the cached squid list:
- # Squidclient-p 80 mgr: objects
- Obtain the disk usage of squid:
- Squidclient-p 80 mgr: diskd
- Force update a url:
- Squidclient-p 80-mb purge http://www.xxxx.com/static. php
- For more information, see:
- Squidclient-h or squidclient-p 80 mgr:
- Hit rate:
- /Usr/local/squid/bin/squidclient-h 1.1.1.1-p80 mgr: info
- /Usr/local/squid/bin/squidclient-h specific IP address-p80 mgr: info