SlideShare a Scribd company logo
1 of 21
InnoDB usage and diagonstics sarah novotny – sarah@bluegecko.net MySQL and LAMP services www.BlueGecko.net
innodb architecture indexing curiosities scaling issues ops concerns 3p tools www.BlueGecko.net
InnoDB Architecture 	MVCC 	row level locking 	transactions foreign keys tablespaces 	undo logs 	redo logs www.BlueGecko.net
the special sauce! clustered indexing natural order page directory  www.BlueGecko.net
 two short operational diversions innodb_flush_method = O_DIRECT 	is worth benchmarking on your system.		 	choose smart primary keys www.BlueGecko.net
indexing curiosities 	secondary indexes point to the clustered index 	BLOB, VARCHAR,  TEXT can be stored  in overflow pages 	ERROR HY000: 		Too big row.  www.BlueGecko.net
scaling issues when it’s time to go big,where are the bottlenecks? www.BlueGecko.net
innodb locking 	auto- increment 	gap locking www.BlueGecko.net
a view of locking in innotop www.BlueGecko.net
concurrency google: domas concurrency  and click “I feel lucky!” http://bit.ly/domas_inno_concurrency www.BlueGecko.net
InnoDB thread concurrency www.BlueGecko.net
	balance between i/o capabilities and mutex contention innodb_thread_concurrency 	multi cores, faster disk work to be done www.BlueGecko.net
operational concerns www.BlueGecko.net
operational concerns mysql> show innodbstatus; this gives you snapshot information trending gives you framework to see when things are going wrong http://code.google.com/p/mysql-cacti-templates www.BlueGecko.net
indirect measures to see what is happening www.BlueGecko.net
operational concerns the combination of historical data with current status from the host is invaluable in determining cause	 www.BlueGecko.net
operational concerns www.BlueGecko.net
free tools Innotop MySQL proxy/  tcpdump mysql-cacti-templates gdb  (poormansprofiler.org) www.BlueGecko.net
additional resources irc.freenode.org #mysql #maatkit mysql.com HPM2e -Baron Schwartz, Peter Zaitsev, Vadim Tkachenko, and Jeremy Zawodny www.BlueGecko.net
credits flickr hk architecture – davelau special sauce – fotoosvanrobin yellow pages - f-r-a-n-k Bell Labs - sodapop81 lock - darwinbell License plate - severud voodoo - heungsub clones - adactio tools – meanestindian console - hermzz www.BlueGecko.net
Blue Gecko and contact info sarah@bluegecko.net sarah.novotny@gmail.com @sarahnovotny @bluegecko senk on #mysql Blue Gecko provides Remote DBA services for companies around the world  7x24x365 support including monitoring, performance analysis, proactive maintenance and architectural guidance for small and large datasets. www.BlueGecko.net

More Related Content

Viewers also liked

Soft Launch an Institutional Eportfolio Initiative
Soft Launch an Institutional Eportfolio InitiativeSoft Launch an Institutional Eportfolio Initiative
Soft Launch an Institutional Eportfolio InitiativeElizabeth Nesius
 
סטארטאפ - איך? כמה? ולמה
סטארטאפ - איך? כמה? ולמהסטארטאפ - איך? כמה? ולמה
סטארטאפ - איך? כמה? ולמהIdo Green
 
Estandares aprendizaje mcs
Estandares aprendizaje mcsEstandares aprendizaje mcs
Estandares aprendizaje mcsGeovanny Armijos
 
Success Magazine
Success MagazineSuccess Magazine
Success Magazinepayitearly
 
Co jsme se naučili od spuštění Fakturoidu
Co jsme se naučili od spuštění FakturoiduCo jsme se naučili od spuštění Fakturoidu
Co jsme se naučili od spuštění Fakturoidujan korbel
 
you know databases, how hard can MySQL be?
you know databases, how hard can MySQL be?you know databases, how hard can MySQL be?
you know databases, how hard can MySQL be?sarahnovotny
 
Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)
Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)
Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)Ido Green
 
Draft presentazione innova_day
Draft presentazione innova_dayDraft presentazione innova_day
Draft presentazione innova_dayFrancesco Baruffi
 
Problems of the Week
Problems of the WeekProblems of the Week
Problems of the WeekGlenn Kenyon
 
Mobile, web and cloud - the triple crown of modern applications
Mobile, web and cloud -  the triple crown of modern applicationsMobile, web and cloud -  the triple crown of modern applications
Mobile, web and cloud - the triple crown of modern applicationsIdo Green
 
Collaborative Assessment: Working Together Toward Institutional Change
Collaborative Assessment: Working Together Toward Institutional ChangeCollaborative Assessment: Working Together Toward Institutional Change
Collaborative Assessment: Working Together Toward Institutional ChangeElizabeth Nesius
 
Law & grace
Law & graceLaw & grace
Law & graceGeo Acts
 
The Means Of Salvation
The Means Of SalvationThe Means Of Salvation
The Means Of SalvationGeo Acts
 
Presentazione ricerca modena_definitivo
Presentazione ricerca modena_definitivoPresentazione ricerca modena_definitivo
Presentazione ricerca modena_definitivoFrancesco Baruffi
 
Jan 4 Sermon
Jan 4 SermonJan 4 Sermon
Jan 4 SermonGeo Acts
 
E learning Simplified for 8th Graders
E learning Simplified for 8th GradersE learning Simplified for 8th Graders
E learning Simplified for 8th GradersClint Walters
 
Lecture 5 Kernel Development
Lecture 5 Kernel DevelopmentLecture 5 Kernel Development
Lecture 5 Kernel DevelopmentMohammed Farrag
 
运营专业型社区的经验和反思
运营专业型社区的经验和反思运营专业型社区的经验和反思
运营专业型社区的经验和反思Robbin Fan
 
Jan. 17. I Am Jonah
Jan. 17. I Am JonahJan. 17. I Am Jonah
Jan. 17. I Am JonahGeo Acts
 
Comparativesquiz 3
Comparativesquiz 3Comparativesquiz 3
Comparativesquiz 3lola guillen
 

Viewers also liked (20)

Soft Launch an Institutional Eportfolio Initiative
Soft Launch an Institutional Eportfolio InitiativeSoft Launch an Institutional Eportfolio Initiative
Soft Launch an Institutional Eportfolio Initiative
 
סטארטאפ - איך? כמה? ולמה
סטארטאפ - איך? כמה? ולמהסטארטאפ - איך? כמה? ולמה
סטארטאפ - איך? כמה? ולמה
 
Estandares aprendizaje mcs
Estandares aprendizaje mcsEstandares aprendizaje mcs
Estandares aprendizaje mcs
 
Success Magazine
Success MagazineSuccess Magazine
Success Magazine
 
Co jsme se naučili od spuštění Fakturoidu
Co jsme se naučili od spuštění FakturoiduCo jsme se naučili od spuštění Fakturoidu
Co jsme se naučili od spuštění Fakturoidu
 
you know databases, how hard can MySQL be?
you know databases, how hard can MySQL be?you know databases, how hard can MySQL be?
you know databases, how hard can MySQL be?
 
Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)
Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)
Scale with a smile with Google Cloud Platform At DevConTLV (June 2014)
 
Draft presentazione innova_day
Draft presentazione innova_dayDraft presentazione innova_day
Draft presentazione innova_day
 
Problems of the Week
Problems of the WeekProblems of the Week
Problems of the Week
 
Mobile, web and cloud - the triple crown of modern applications
Mobile, web and cloud -  the triple crown of modern applicationsMobile, web and cloud -  the triple crown of modern applications
Mobile, web and cloud - the triple crown of modern applications
 
Collaborative Assessment: Working Together Toward Institutional Change
Collaborative Assessment: Working Together Toward Institutional ChangeCollaborative Assessment: Working Together Toward Institutional Change
Collaborative Assessment: Working Together Toward Institutional Change
 
Law & grace
Law & graceLaw & grace
Law & grace
 
The Means Of Salvation
The Means Of SalvationThe Means Of Salvation
The Means Of Salvation
 
Presentazione ricerca modena_definitivo
Presentazione ricerca modena_definitivoPresentazione ricerca modena_definitivo
Presentazione ricerca modena_definitivo
 
Jan 4 Sermon
Jan 4 SermonJan 4 Sermon
Jan 4 Sermon
 
E learning Simplified for 8th Graders
E learning Simplified for 8th GradersE learning Simplified for 8th Graders
E learning Simplified for 8th Graders
 
Lecture 5 Kernel Development
Lecture 5 Kernel DevelopmentLecture 5 Kernel Development
Lecture 5 Kernel Development
 
运营专业型社区的经验和反思
运营专业型社区的经验和反思运营专业型社区的经验和反思
运营专业型社区的经验和反思
 
Jan. 17. I Am Jonah
Jan. 17. I Am JonahJan. 17. I Am Jonah
Jan. 17. I Am Jonah
 
Comparativesquiz 3
Comparativesquiz 3Comparativesquiz 3
Comparativesquiz 3
 

More from sarahnovotny

Interconnecting containers at scale #Dockercon
Interconnecting containers at scale #Dockercon Interconnecting containers at scale #Dockercon
Interconnecting containers at scale #Dockercon sarahnovotny
 
NGINX 101 - now with more Docker
NGINX 101 - now with more DockerNGINX 101 - now with more Docker
NGINX 101 - now with more Dockersarahnovotny
 
5 things you didn't know nginx could do velocity
5 things you didn't know nginx could do   velocity5 things you didn't know nginx could do   velocity
5 things you didn't know nginx could do velocitysarahnovotny
 
5 things you didn't know nginx could do
5 things you didn't know nginx could do5 things you didn't know nginx could do
5 things you didn't know nginx could dosarahnovotny
 
Building a Learning Culture
Building a Learning CultureBuilding a Learning Culture
Building a Learning Culturesarahnovotny
 
Lessons Learned and Best Practices for Game Development in the Cloud
Lessons Learned and Best Practices for Game Development in the CloudLessons Learned and Best Practices for Game Development in the Cloud
Lessons Learned and Best Practices for Game Development in the Cloudsarahnovotny
 
under the covers -- chef in 20 minutes or less
under the covers -- chef in 20 minutes or lessunder the covers -- chef in 20 minutes or less
under the covers -- chef in 20 minutes or lesssarahnovotny
 
people hacking: opensource biz etiquette
people hacking: opensource biz etiquettepeople hacking: opensource biz etiquette
people hacking: opensource biz etiquettesarahnovotny
 
IRL: How Geeks Undermine Their Presentations & Conversations With Body Language
IRL: How Geeks Undermine Their Presentations & Conversations With Body LanguageIRL: How Geeks Undermine Their Presentations & Conversations With Body Language
IRL: How Geeks Undermine Their Presentations & Conversations With Body Languagesarahnovotny
 
all data everywhere
all data everywhereall data everywhere
all data everywheresarahnovotny
 
nursing for future transhumanist
nursing for future transhumanistnursing for future transhumanist
nursing for future transhumanistsarahnovotny
 
Scaling my sql_in_3d
Scaling my sql_in_3dScaling my sql_in_3d
Scaling my sql_in_3dsarahnovotny
 
IGNITE MySQL - Backups Don't Make Me Money
IGNITE MySQL - Backups Don't Make Me MoneyIGNITE MySQL - Backups Don't Make Me Money
IGNITE MySQL - Backups Don't Make Me Moneysarahnovotny
 

More from sarahnovotny (16)

Interconnecting containers at scale #Dockercon
Interconnecting containers at scale #Dockercon Interconnecting containers at scale #Dockercon
Interconnecting containers at scale #Dockercon
 
NGINX 101 - now with more Docker
NGINX 101 - now with more DockerNGINX 101 - now with more Docker
NGINX 101 - now with more Docker
 
5 things you didn't know nginx could do velocity
5 things you didn't know nginx could do   velocity5 things you didn't know nginx could do   velocity
5 things you didn't know nginx could do velocity
 
5 things you didn't know nginx could do
5 things you didn't know nginx could do5 things you didn't know nginx could do
5 things you didn't know nginx could do
 
Building a Learning Culture
Building a Learning CultureBuilding a Learning Culture
Building a Learning Culture
 
0 to enterprise
0 to enterprise0 to enterprise
0 to enterprise
 
Lessons Learned and Best Practices for Game Development in the Cloud
Lessons Learned and Best Practices for Game Development in the CloudLessons Learned and Best Practices for Game Development in the Cloud
Lessons Learned and Best Practices for Game Development in the Cloud
 
under the covers -- chef in 20 minutes or less
under the covers -- chef in 20 minutes or lessunder the covers -- chef in 20 minutes or less
under the covers -- chef in 20 minutes or less
 
people hacking: opensource biz etiquette
people hacking: opensource biz etiquettepeople hacking: opensource biz etiquette
people hacking: opensource biz etiquette
 
IRL: How Geeks Undermine Their Presentations & Conversations With Body Language
IRL: How Geeks Undermine Their Presentations & Conversations With Body LanguageIRL: How Geeks Undermine Their Presentations & Conversations With Body Language
IRL: How Geeks Undermine Their Presentations & Conversations With Body Language
 
geek_lifestyle
geek_lifestylegeek_lifestyle
geek_lifestyle
 
all data everywhere
all data everywhereall data everywhere
all data everywhere
 
nursing for future transhumanist
nursing for future transhumanistnursing for future transhumanist
nursing for future transhumanist
 
Scaling my sql_in_3d
Scaling my sql_in_3dScaling my sql_in_3d
Scaling my sql_in_3d
 
IGNITE MySQL - Backups Don't Make Me Money
IGNITE MySQL - Backups Don't Make Me MoneyIGNITE MySQL - Backups Don't Make Me Money
IGNITE MySQL - Backups Don't Make Me Money
 
5 things MySql
5 things MySql5 things MySql
5 things MySql
 

Recently uploaded

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxKatpro Technologies
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 

Recently uploaded (20)

Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptxFactors to Consider When Choosing Accounts Payable Services Providers.pptx
Factors to Consider When Choosing Accounts Payable Services Providers.pptx
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 

innodb usage and diagnostics

  • 1. InnoDB usage and diagonstics sarah novotny – sarah@bluegecko.net MySQL and LAMP services www.BlueGecko.net
  • 2. innodb architecture indexing curiosities scaling issues ops concerns 3p tools www.BlueGecko.net
  • 3. InnoDB Architecture MVCC row level locking transactions foreign keys tablespaces undo logs redo logs www.BlueGecko.net
  • 4. the special sauce! clustered indexing natural order page directory www.BlueGecko.net
  • 5. two short operational diversions innodb_flush_method = O_DIRECT is worth benchmarking on your system. choose smart primary keys www.BlueGecko.net
  • 6. indexing curiosities secondary indexes point to the clustered index BLOB, VARCHAR, TEXT can be stored in overflow pages ERROR HY000: Too big row. www.BlueGecko.net
  • 7. scaling issues when it’s time to go big,where are the bottlenecks? www.BlueGecko.net
  • 8. innodb locking auto- increment gap locking www.BlueGecko.net
  • 9. a view of locking in innotop www.BlueGecko.net
  • 10. concurrency google: domas concurrency and click “I feel lucky!” http://bit.ly/domas_inno_concurrency www.BlueGecko.net
  • 11. InnoDB thread concurrency www.BlueGecko.net
  • 12. balance between i/o capabilities and mutex contention innodb_thread_concurrency multi cores, faster disk work to be done www.BlueGecko.net
  • 14. operational concerns mysql> show innodbstatus; this gives you snapshot information trending gives you framework to see when things are going wrong http://code.google.com/p/mysql-cacti-templates www.BlueGecko.net
  • 15. indirect measures to see what is happening www.BlueGecko.net
  • 16. operational concerns the combination of historical data with current status from the host is invaluable in determining cause www.BlueGecko.net
  • 18. free tools Innotop MySQL proxy/ tcpdump mysql-cacti-templates gdb (poormansprofiler.org) www.BlueGecko.net
  • 19. additional resources irc.freenode.org #mysql #maatkit mysql.com HPM2e -Baron Schwartz, Peter Zaitsev, Vadim Tkachenko, and Jeremy Zawodny www.BlueGecko.net
  • 20. credits flickr hk architecture – davelau special sauce – fotoosvanrobin yellow pages - f-r-a-n-k Bell Labs - sodapop81 lock - darwinbell License plate - severud voodoo - heungsub clones - adactio tools – meanestindian console - hermzz www.BlueGecko.net
  • 21. Blue Gecko and contact info sarah@bluegecko.net sarah.novotny@gmail.com @sarahnovotny @bluegecko senk on #mysql Blue Gecko provides Remote DBA services for companies around the world 7x24x365 support including monitoring, performance analysis, proactive maintenance and architectural guidance for small and large datasets. www.BlueGecko.net

Editor's Notes

  1. table creation information in .frmMySQL’s core table locking is disabled (politely)transactions do not behave quite the same in innodb – autocommit on by default. transaction isolation == repeatable readdeadlock detection
  2. b-tree primary key ++ record in index (not pointer)instead of moving ½ the records, data is added to the tablespaces and indexes in natural orderpage directory uses binary searching in sparse array fill factors are auto managed – and at my last check was still an open questionindex-organized table
  3. since innodb buffers both key and data there are cases where O_DIRECT can help a lot. the idea being to avoid double cachingthere will be an arbitrary useless key that is assigned if you don’t set one!
  4. secondary indexes point to clustered. no data. extra callSecondary index records must always fit on a single B-tree pageIn a clustered index, BLOB, VARCHAR and TEXT columns that are not part of the primary key may be stored on separately allocated (“overflow”) pages. We call these “off-page columns” whose values are stored on singly-linked lists of overflow pages. ERROR HY000: Too big row. InnoDB requires that each B-tree page can accommodate at least two records.
  5. Much performance pain come into play with lock contentionglobal counter which held the last value for the auto-incrementing column. A lock would be placed on this counter for the duration of the SQL statement which did the inserting. until MySQL 5.1.22new server variable, innodb_autoinc_lock_mode -- limits how often global locking is used and still defaults to that if not able to preserve derterministicnessA type of gap lock called an insertion intention gap lock is set by INSERT operations prior to row insertion.next key locks combo of record lock and gap lock.
  6. Much performance pain come into play with lock contentionNames changed to protect the innocent
  7. can’t reprise or due justice to this talk.DomasMituzas – FB go watch it.oreilly’smysql conference 2010
  8. not enough knobs, must benchmark.innodb_thread_concurrency
  9. LVM and slaves give easy opportunities for creating clones for testinginnodbhotbackupxtra backup
  10. You might see these graphs spike during times of high concurrency or contention. These graphs basically indicate different types of activity involved in obtaining row locks or mutexes, both of which are causes of poor scaling in standard InnoDBXtraDB, the InnoDBplugin, and the Percona-patched MySQL are improved.
  11. different types of activity involved in obtaining row locks or mutexesadditionally, can see what’s going on in individual transactions.
  12. watching how the i/o threads are behaving.