SlideShare a Scribd company logo
1 of 10
NCACHE ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
OVERVIEW F5 NGINX PROXY NCACHE BACKEND BACKEND BACKEND
STRUCTURE Be proxy hash index Init by Ngx master process when nginx is start on Ngx worker process Ngx worker process Disk Files Read / write by file system or raw dev Backend server Backend server Backend server Body filter Get the proxy content and save into the disk by aio
Logic Diagram Request Request Find cache in index found Not found Timeout? not yes Sendfile output Proxy backend Body filter Writev output Aiowrite fresh index
The self sort share mem hash index 2(5) 3(4) First floor of hash index List to solve the conflict of the hash Hash_malloc 1(6) Index[1]+2 = 7 1(6) 3(4) 2(7) Top:0 16777216 33554432 If arrived at the bottom of the share memory then ncache will return to the 16777216 point and find which can be reused
Record lock Mmap auto sync Mem index Sync file Worker process Worker process Read Write Worker process Do not need to lock  any worker process or request cause wait not cause wait not cause wait
Performance between SQUID 1  First: cpu last: io Blue is ncache
Performance between SQUID 2 SQUID NCACHE
Future ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
The end ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

More Related Content

Viewers also liked

Portfolio Single compressed
Portfolio Single compressedPortfolio Single compressed
Portfolio Single compressedSibin K Sam
 
2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter
2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter
2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korterStipo
 
Лотман Ю. М. "Декабрист в повседневной жизни"
Лотман Ю. М.   "Декабрист в повседневной жизни"Лотман Ю. М.   "Декабрист в повседневной жизни"
Лотман Ю. М. "Декабрист в повседневной жизни"инна ветрова
 
30.07.2015 vodafone power talks ver02
30.07.2015 vodafone power talks ver0230.07.2015 vodafone power talks ver02
30.07.2015 vodafone power talks ver02Robert Kintu
 
Romo jeremiah mobile presentation
Romo jeremiah mobile presentationRomo jeremiah mobile presentation
Romo jeremiah mobile presentationvisioningbiz
 
Smet Product Applications
Smet Product ApplicationsSmet Product Applications
Smet Product ApplicationsSMET
 
Gestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseaux
Gestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseauxGestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseaux
Gestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseauxVincent Laurent
 
Microman Brochure Webview
Microman Brochure WebviewMicroman Brochure Webview
Microman Brochure Webviewmark petrelle
 

Viewers also liked (13)

Portfolio Single compressed
Portfolio Single compressedPortfolio Single compressed
Portfolio Single compressed
 
Quantum API 1.1 proposal
Quantum API 1.1 proposalQuantum API 1.1 proposal
Quantum API 1.1 proposal
 
2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter
2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter
2014 10 stipo alkmaar zoho, broedplaatsen en placemaking korter
 
Лотман Ю. М. "Декабрист в повседневной жизни"
Лотман Ю. М.   "Декабрист в повседневной жизни"Лотман Ю. М.   "Декабрист в повседневной жизни"
Лотман Ю. М. "Декабрист в повседневной жизни"
 
30.07.2015 vodafone power talks ver02
30.07.2015 vodafone power talks ver0230.07.2015 vodafone power talks ver02
30.07.2015 vodafone power talks ver02
 
Album
AlbumAlbum
Album
 
Romo jeremiah mobile presentation
Romo jeremiah mobile presentationRomo jeremiah mobile presentation
Romo jeremiah mobile presentation
 
My last summer
My last summerMy last summer
My last summer
 
Smet Product Applications
Smet Product ApplicationsSmet Product Applications
Smet Product Applications
 
Cátedra Datos UBA - Legales Cursada NTI 2012
Cátedra Datos UBA - Legales Cursada NTI 2012Cátedra Datos UBA - Legales Cursada NTI 2012
Cátedra Datos UBA - Legales Cursada NTI 2012
 
Gestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseaux
Gestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseauxGestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseaux
Gestion de la sécurité sanitaire de l'eau et gestion patrimoniale des réseaux
 
Microman Brochure Webview
Microman Brochure WebviewMicroman Brochure Webview
Microman Brochure Webview
 
VTax Partnerships Presentations
VTax Partnerships PresentationsVTax Partnerships Presentations
VTax Partnerships Presentations
 

Recently uploaded

Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesZilliz
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsSergiu Bodiu
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticscarlostorres15106
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Patryk Bandurski
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Wonjun Hwang
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLScyllaDB
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostZilliz
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 

Recently uploaded (20)

Vector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector DatabasesVector Databases 101 - An introduction to the world of Vector Databases
Vector Databases 101 - An introduction to the world of Vector Databases
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
DevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platformsDevEX - reference for building teams, processes, and platforms
DevEX - reference for building teams, processes, and platforms
 
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmaticsKotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
Kotlin Multiplatform & Compose Multiplatform - Starter kit for pragmatics
 
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
Integration and Automation in Practice: CI/CD in Mule Integration and Automat...
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
Bun (KitWorks Team Study 노별마루 발표 2024.4.22)
 
Developer Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQLDeveloper Data Modeling Mistakes: From Postgres to NoSQL
Developer Data Modeling Mistakes: From Postgres to NoSQL
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage CostLeverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
Leverage Zilliz Serverless - Up to 50X Saving for Your Vector Storage Cost
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 

ncache

  • 1.
  • 2. OVERVIEW F5 NGINX PROXY NCACHE BACKEND BACKEND BACKEND
  • 3. STRUCTURE Be proxy hash index Init by Ngx master process when nginx is start on Ngx worker process Ngx worker process Disk Files Read / write by file system or raw dev Backend server Backend server Backend server Body filter Get the proxy content and save into the disk by aio
  • 4. Logic Diagram Request Request Find cache in index found Not found Timeout? not yes Sendfile output Proxy backend Body filter Writev output Aiowrite fresh index
  • 5. The self sort share mem hash index 2(5) 3(4) First floor of hash index List to solve the conflict of the hash Hash_malloc 1(6) Index[1]+2 = 7 1(6) 3(4) 2(7) Top:0 16777216 33554432 If arrived at the bottom of the share memory then ncache will return to the 16777216 point and find which can be reused
  • 6. Record lock Mmap auto sync Mem index Sync file Worker process Worker process Read Write Worker process Do not need to lock any worker process or request cause wait not cause wait not cause wait
  • 7. Performance between SQUID 1 First: cpu last: io Blue is ncache
  • 8. Performance between SQUID 2 SQUID NCACHE
  • 9.
  • 10.