LinuxCommandLibrary

squid

TLDR

Start squid

$ squid
copy
Check configuration
$ squid -k parse
copy
Reload configuration
$ squid -k reconfigure
copy
Shutdown gracefully
$ squid -k shutdown
copy
Show version
$ squid -v
copy
Run in foreground
$ squid -N
copy
Debug mode
$ squid -d [5]
copy
Clear cache
$ squid -k rotate && rm -rf [/var/spool/squid/*] && squid -z
copy

SYNOPSIS

squid [-k command] [-f config] [-N] [options]

DESCRIPTION

squid is a caching HTTP proxy. It accelerates web access and provides content filtering.
Forward proxy serves client requests. Caches responses for faster repeat access.
Reverse proxy accelerates web servers. Offloads content delivery.
Access control lists filter traffic. Block sites, limit bandwidth, authenticate users.
Cache management optimizes storage. Disk and memory caching configurable.

PARAMETERS

-k COMMAND

Send command to running squid.
-f FILE
Configuration file.
-N
No daemon mode.
-d LEVEL
Debug level.
-z
Create swap directories.
-v
Show version.

COMMANDS

parse - Check config
reconfigure - Reload config
shutdown - Graceful stop
interrupt - Immediate stop
rotate - Rotate logs

CAVEATS

Configuration is complex. ACL order matters. HTTPS interception needs certificates.

HISTORY

Squid originated from the Harvest project at the University of Colorado in 1996. It became the most widely deployed caching proxy.

SEE ALSO

nginx(1), apache(1), privoxy(1)

Copied to clipboard