Search This Blog

Saturday, March 8, 2008

Patching Squid to support gzip/deflate encoding

Squid is a caching proxy for the Web supporting HTTP, HTTPS, FTP, and more. It reduces bandwidth and improves response times by caching and reusing frequently-requested web pages. Squid has extensive access controls and makes a great server accelerator.
Unfortunately, Squid is HTTP/1.0 due to the lack of certain features and the main disadvantage, from my point of view, is a lack of gzip/deflate content encoding.
There is a patch created by Swell Technology and committed to the HEAD. But it was not tested and little bit outdated.
So I've spent around six late night/early morning hours to merge the patch to Squid 3.0-Stable1. Right now patched squid it running on the old AMD Athlon64 3000+ machine serving around 500 simultaneously connected clients through the dial-up lines. The main concern was the CPU utilization, but FreeBSD team made an excellent work in regards of the performance in FreeBSD 7.
So here is the snapshot from top:
56897 squid 1 4 0 1085M 1044M kqread 9:28 5.18% squid

and uptime is:
1:51PM up 7 days, 10:45, 2 users, load averages: 0.01, 0.06, 0.15

The FreeBSD port patch is here.


Link to FreeBSD PR

FreeBSD maintainer refused to integrate patch to ports tree:

From:Thomas-Martin Seck
Date:Sat, 8 Mar 2008 15:59:46 +0100
I am sorry, but I am not going to integrate third-party patches into
the Squid ports any more (this includes patchsets that are available from Please work with the Squid developers on
integrating this feature into mainline Squid.

Short rationale: Third party patches are a headache to maintain,
especially when they are no longer maintained (cf ICAP for Squid-2) and
they can be a major source of trouble when they contain bugs that are
then wrongly attributed to bugs in Squid itself. I would therefore like
to keep the port as close to the mainline source as possible to make it
easy for users to get support for it from the Squid developers in case
of problems.


Anonymous said...

dear rauf

I tried using you patch , but I have some problem while compiling
here the problem :
cc1plus: warnings being treated as errors In function 'void codeStreamCallback(clientStreamNode*, ClientHttpRequest*, HttpReply*, StoreIOBuffer)': warning: format '%lu' expects type 'long unsigned int', but argument 2 has type 'int64_t' warning: format '%lu' expects type 'long unsigned int', but argument 2 has type 'size_t' warning: format '%lu' expects type 'long unsigned int', but argument 2 has type 'int64_t' warning: format '%lu' expects type 'long unsigned int', but argument 2 has type 'size_t' warning: format '%lu' expects type 'long unsigned int', but argument 3 has type 'ssize_t' In function 'void codeStreamDetach(clientStreamNode*, ClientHttpRequest*)': error: 'class StoreEntry' has no member named 'storeReleaseRequest'
make[3]: *** [HttpHdrContCode.o] Error 1

please help

kworr said...

Builds for me with current ports. I'll have some testing done and then i'm going to hit the squid-dev possibly...

kworr said...

Patc doesn't work with current ports. Squid builds, but fails to accept configuration parameters:

2008/06/05 10:04:37| squid.conf:62 unrecognized: 'negotiate_ce_access'
2008/06/05 10:04:37| squid.conf:63 unrecognized: 'encode_gzip_access'
2008/06/05 10:04:37| squid.conf:64 unrecognized: 'encode_deflate_access'

Anonymous said...

Hi, Rauf, how is it going, man? Remember me - Rihad? Forget about the cricket :)

Rauf Kuliyev said...

Sorry pals, forget this cricket as well. Use oops ( instead.

Rihad Haciyev said...

oops, nginx... is speed optimization that important? CPU cycles are cheap (c)

Anonymous said...


just signed up and wanted to say hello while I read through the posts

hopefully this is just what im looking for looks like i have a lot to read.

Anonymous said...


I just wanted to say hi to everyone



Anonymous said...

Do you think the best way to get the cheapest plane tickets is by calling the airline? Or, do you scan through hundreds of websites provided by search engines to find low airfare tickets? Maybe you hope to find cheap airfare in the local newspaper's travel section.
Finding cheap airline tickets can be one of the most frustrating experiences that most of us learn very quickly. Of course, most people eventually give up after spending hours scanning websites that offer virtually the same flight schedules and pricing. People purchase what they believe is the cheapest plane ticket, only to find their neighbor paid just a third of what they did!

Unless you understand the concept of of how airlines set prices, all the searching in the world won't provide the cheapest airline ticket prices. The following information will give you a guide to follow, as you wander through the maze searching for cheap airfare.

Understand how prices are set by airlines! Air ticket pricing is complex and unpredictable, and driven by competition, demand, and inventory. Airlines call this "yield management."

Competition is the beast behind the cheapest plane tickets. All major airlines utilize central reservation systems (owned by various airlines) to fill available seats. The systems are known as Apollo, Sabre, WorldSpan and Galileo. Prices are based on demand, and if some flights are selling well, the price will increase. If the flight is unpopular and has very little demand, the fare is lowered in hope of attracting consumers. In short, fares and inventory change every minute of every day!

Finding the cheapest plane tickets is difficult because travel agents and Internet websites use the central reservation systems that are updated periodically throughout the day. The reason why different searches come up with different results is because the systems are not updated at the same times. And, each system may use different algorithms when searching for low airfare tickets, which can provide a variety of ticket prices .

[url=]Information about air tickets[/url]

Anonymous said...

[url=] coleman roadtrip grill

Anonymous said...

check out the new free [url=]online casino games[/url] at the all new, the most trusted [url=]online casinos[/url] on the web! enjoy our [url=]free casino software download[/url] and win money.
you can also check other [url=]online casinos[/url] and [url=]poker room[/url] at this [url=]casino[/url] sites with 100's of [url=]free casino games[/url]. for new gamblers you can visit this [url=]online casino[/url].

Anonymous said...

if you guys exigency to capture disappointing [url=]viagra[/url] online you can do it at, the most trusted viagra pharmacopoeia advancement of generic drugs.
you can eliminate into uncover drugs like [url=]viagra[/url], [url=]cialis[/url], [url=]levitra[/url] and more at, the top-priority [url=]viagra[/url] roots on the web. well another great [url=]viagra[/url] pharmacy you can find at

Anonymous said...

Infatuation casinos? endorse this juvenile [url=]online casino[/url] guide and production online casino games like slots, blackjack, roulette, baccarat and more at .
you can also go over our new [url=]casino[/url] orientate at and draw true to life tangled currency !
another late-model [url=]casino spiele[/url] bracket is , because german gamblers, span unrestrained online casino bonus.

Anonymous said...


[url=]Bollywood Wallpapers[/url]

[url=]Bollywood Actress[/url]

[url=]Aishwarya Rai[/url]

[url=]Ayesha Takia[/url]

[url=]Diya Mirza[/url]

[url=]Neha Dhupia[/url]

[url=]Nandana Sen[/url]

[url=]Bipasha Basu[/url]

[url=]Neetu Chandra[/url]

[url=]Kim Sharma[/url]

[url=]Zarine Khan[/url]

[url=]Amrita Rao[/url]

[url=]Aarti Chhabria[/url]


[url=]Celina Jaitley[/url]

[url=]Deepika Padukone[/url]

[url=]Geeta Basra[/url]

[url=]Kareena Kapoor[/url]

[url=]Katrina Kaif[/url]

[url=]Sonal Chauhan[/url]

[url=]Priyanka Chopra[/url]

[url=]Aditi Sharma[/url]

[url=]Hazel Crowney[/url]

[url=]Kashmira Shah[/url]

Anonymous said...

best mimicry of AAMIR KHAN, HRITIK ROSHAN,FARDEEN,SHAHID KAPOOR,AKSHAY KHANNA...i saw this and HAD to share with you guys!!!


Anonymous said...


i'm new here, and just want to say hello!

[url=]over counter blog[/url]

Anonymous said...

[url=]where to buy soma[/url] soma no perscription = [url=]free shipping buy soma cheap[/url] mexican pharmacy soma = [url=]soma 350mg saturday fed-ex shipping[/url] overnight somas = [url=]soma beverage from india[/url] soma want to order = [url=]cheapest place to buy soma[/url] soma cheap

Anonymous said...

[url=]drug soma[/url] soma overnight cod = [url=]how to buy soma[/url] soma buy in australia = [url=]cheapest soma or carisoprodol online[/url] discount adidas soma shoes = [url=]no prescription need soma cod[/url] prescription drug soma information = [url=]soma free shipping[/url] order soma with dhl overnight delivery

Anonymous said...

[url=]cheap soma and or fiorecet online[/url] soma overnight cheap = [url=]dreampharmaceuticals soma online[/url] carisoprodol cheap soma 100 = [url=]can soma get you high[/url] 1 prescription soma = [url=]where can i order soma[/url] soma online online a href = [url=]watson soma cheap[/url] watson brand soma without prescription

Anonymous said...

[url=]soma 250 mg for sale online[/url] soma cod cheap fast = [url=]buy carisoprodol diazepam online soma[/url] soma rx = [url=]money order soma[/url] keywords soma online = [url=]buy soma watson[/url] buy online soma usa = [url=]soma street price[/url] buying cheap soma free delivery

Anonymous said...

[url=]soma internet[/url] buy soma tablets = [url=]carisoprodol online soma[/url] ninth street pharmacy soma = [url=]no overnight prescription soma[/url] cheap generic soma = [url=]soma 350mg saturday delivery[/url] cod online prescription soma = [url=]soma cod overnight[/url] order watson soma

Anonymous said...

[url=]where to buy mexican soma[/url] discount from prescription price rx soma = [url=]buy soma from canada[/url] buy cheap generic soma = [url=]soma fedex[/url] buy prescription soma without = [url=]ambien and soma online[/url] soma 350mg saturday delivery = [url=]soma intimate discount codes[/url] no prescription needed soma cod

Anonymous said...

[url=]buy soma 350mg[/url] buy soma line boards umaxppc = [url=]buy watson soma online[/url] soma online pharmacy = [url=]cheaper soma[/url] soma buy online fedex = [url=]order soma overnight delivery to texas[/url] soma watson online = [url=]350 buy mg online soma[/url] online soma imported

Anonymous said...

[url=]soma luna discount[/url] somas overnight to florida = [url=]soma refills canada[/url] online order soma = [url=]soma pharmacy online[/url] soma mexico = [url=]carisoprodol paypal soma[/url] soma cheap rx = [url=]buy soma and tramadol[/url] buy soma paypal

Anonymous said...

[url=]fedex delivery soma[/url] soma beverage from india = [url=]buy soma online mexico[/url] soma fedex = [url=]ship somas to florida[/url] fedex soma legal = [url=]buy soma online paypal[/url] internet prescriptions for soma = [url=]buy soma haircare products[/url] watson soma overnight

Anonymous said...

[url=]buy soma visa[/url] buy i e online soma = [url=]prescription of soma[/url] cheapest soma on the net = [url=]indianhead soma online[/url] soma available online = [url=]online soma cod[/url] soma blockprint jaipur india = [url=]lemme get soma dat[/url] buy soma cheap online no prescription

Anonymous said...

[url=]cod order soma[/url] soma delivered overnight = [url=]online order soma[/url] online pharmacy soma = [url=]prescription medication soma[/url] soma by chico's discount coupon = [url=]cheap on line prescriptions for soma[/url] buy watson soma = [url=]chicos soma from certified pharmacy[/url] soma to buy

Anonymous said...

[url=]buy soma no prescription cod[/url] order pal pay soma = [url=]cheap soma[/url] cheap soma = [url=]cheap soma[/url] cheapest soma or carisoprodol online = [url=]soma ship to florida[/url] buy soma cheap = [url=]soma watson discount[/url] soma without precription

Anonymous said...

[url=]soma pharmacy online sale[/url] soma online prescription us = [url=]soma from canada[/url] buy keyword soma = [url=]cheaper way to buy soma[/url] generic soma without prescription = [url=]buy cod online soma[/url] best online soma = [url=]soma to buy[/url] buy soma online cod

Anonymous said...

[url=]carisoprodol paypal soma[/url] discount adidas soma shoes = [url=]online prescriptions for soma[/url] buy soma with free shipping = [url=]will soma get u high[/url] soma online lowest prices = [url=]soma and canadian pharmacies[/url] soma cheap mastercard = [url=]buy soma 350mg online[/url] soma available in canada

Anonymous said...

[url=]canada drud soma[/url] buy fisher soma f9000 = [url=]pharmacies that ship soma to texas[/url] hpo pharmacy soma = [url=]ship to florida internet pharmacies soma[/url] soma 350 mg paypal = [url=]price for soma 250[/url] offshore pharmacy soma puerto rico = [url=]q buy soma online[/url] buy linecom soma

Anonymous said...

[url=]can soma's get you high[/url] no prescription soma overnight = [url=]soma without prescription online[/url] buy soma compound = [url=]buy soma online sit[/url] buy soma no prescription paypal = [url=]soma cheap without rx[/url] saturday delivery for soma = [url=]soma online without a prescription[/url] soma watson pharmacy

Anonymous said...

[url=]best soma prices online[/url] mexican pharmacy soma = [url=]buy soma where[/url] cheap soma 32 = [url=]cheapest soma online[/url] soma now = [url=]soma no rx us pharm[/url] discount from prescription price rx soma = [url=]soma online free overnight shipping[/url] soma online price

Anonymous said...

[url=]buy soma pill[/url] soma pharmacy = [url=]buy us soma online[/url] order soma carisoprodol 32 = [url=]fed ex cheap soma overnight[/url] buy cheap online soma = [url=]prescriptions on line for soma[/url] buy soma 100 = [url=]buy soma cash on delivery[/url] soma without prescription

Anonymous said...

[url=]soma muscle relaxers canada[/url] soma prescription medicines cod = [url=]keyword order soma boards[/url] place soma

Anonymous said...

Mr. Hermann considers the poorhouse, called the Reproduce Pavilion, his “opus.”

When he builds in the Hollywood Hills or Beverly Hills, Mr. Herman says he is [url=]against the most participation[/url] restricted to a nugatory lot.

This end measures barely three-and-a-half acres and gave him the hiatus he needed to develop a bailiwick featuring walls of glass.

[url=]my oil blog[/url]

Anonymous said...


Anonymous said...

Most people that earn money being an affiliate sign up with several Affiliate Programs. In fact, you have to try out several before you find those who will make you the most money. About the most important aspects to consider elect to promote products as an affiliate is to choose worthwhile products. If you wouldn't buy it or have any use for it chances are your customers won't either. Remember, even though you're selling via the internet and not in person, whether or not you truly believe in the products you are promoting will show through in your marketing efforts. Choose products that you truly believe in quotes for quality products to persuade others to buy them.

[url=George (The IT Guy)[/url]

Anonymous said...

BPbJD, [url=!-put-up-now!-It's-obtuse.-?????????]stock trading techniques[/url] ,BYqiWrym, awesome stocks ,31050, stock trading market, oisNhGpVpIA,
[URL= ]top investment newsletters [/URL]
top 10 stock investments
[URL= ]hot cheap stocks [/URL]

Anonymous said...

JmdUiGUJUOIa, [url=]online bingo no deposit bonus codes[/url] ,50273, rushmore online casino no deposit bonus ,32819, online casino with welcome bonus no deposit, 98827,
[URL= ]online casino bonus codes 2012 [/URL]
best casino bonus no deposit
[URL= ]new no deposit casino bonus codes blog [/URL]
free bonus casino on line

Anonymous said...

Time is a versatile performer.It flies, marches on, heals all wounds, runs out and will tell.
[url=]ugg boots clearance[/url]
[url=]ugg boots sale[/url]
[url=]spyder ski jackets[/url]
I can resist everything except temptation.
snow ugg boots
burberry outlet

Anonymous said...

DJYNohi, [url=]no deposit online casino australia[/url] ,:-$, play pai gow bonus online free ,89751, play free online casino slot machines, :-[,
[URL= ]playtech casino bonus no deposit [/URL]
free casino signup bonus no deposit
[URL= ]online casino games australia [/URL]
play free online casino bonus slots

Anonymous said...

top [url=]free casino[/url] check the latest [url=]free casino[/url] autonomous no consign hand-out at the chief [url=]casino online

Anonymous said...

[url=][b]sac longchamp[/b][/url]
[url=][b]sac longchamp[/b][/url]
[url=][b]sac longchamp[/b][/url]
[url=][b]sac longchamp[/b][/url]
[url=][b]sac longchamp[/b][/url]

Anonymous said...

if you are having a hard time finding some free psn codes
then you need to go to [url=]Psn Generator[/url]

Anonymous said...

Good article. I will be experiencing some of these issues
as well..

Feel free to surf to my weblog :: aircraft dealers oklahoma

Unknown said...

ralph lauren outlet
louis vuitton bags
longchamp pliage
timberland boots
pandora jewelry
ralph lauren uk
coach outlet canada
michael kors outlet online
nike roshe run shoes
adidas trainers
michael kors handbags
new balance shoes
ugg sale
rolex uk
chaussure louboutin
vans shoes
longchamp pliage
tory burch outlet online
cheap michael kors handbags
coach outlet
ghd hair straighteners
mizuno running shoes
cartier watches
michael kors outlet
cartier watches
bottega veneta outlet online
nike outlet store
tiffany jewellery
nike free running
beats headphones
kobe shoes
coach outlet
nike trainers uk

Unknown said...

pandora bracelet
polo ralph lauren outlet online
cheap oakley sunglasses
louboutin shoes
michael kors outlet store
michael kors handbags outlet
adidas yeezy boost
pandora jewelry outlet
michael kors uk

5689 said...

ralph lauren uk
coach outlet
canada goose jackets
red bottoms
supreme shirt
fitflops sale clearance
kate spade outlet
christian louboutin shoes
nike air max 95