SlideShare ist ein Scribd-Unternehmen logo
1 von 20
Downloaden Sie, um offline zu lesen
dw-tpain

Gordon Klok
Demonware, Inc
A Demonware MySQL cluster

More info about the LSG see:
“Erlang and First Person Shooters”

http://www.erlang-factory.com/upload/presentations/395/ErlangandFirst-PersonShooters.pdf
backup process
• innobackupex from Percona http://

www.percona.com/doc/percona-xtrabackup/
2.1/innobackupex/innobackupex_script.html

• Allows hot backup of database
• backups the underlying MySQL files

replays a transaction log for changes
occurring during the backup

• much faster to restore then SQL dumps.
Not good
Everything checks out on the database
server
NFS Latency during backup window.
So whats the problem?
How is the slow performance of the
NAS affecting the client?

Paging...
pd_fush
•

/proc/sys/vm/dirty_background_ratio (default 10): Maximum percentage of active that can be filled
with dirty pages before pdflush begins to write them

•

/proc/sys/vm/dirty_expire_centiseconds (default 3000): In hundredths of a second, how long data can
be in the page cache before it's considered expired and must be written at the next opportunity. Note
that this default is very long: a full 30 seconds. That means that under normal circumstances, unless
you write enough to trigger the other pdflush method, Linux won't actually commit anything you
write until 30 seconds later.

• See “The Linux Page Cache and pdflush:

Theory of Operation and Tuning for WriteHeavy Loads” http://www.westnet.com/
~gsmith/content/linux-pdflush.htm
pd_flush continued
• Lots of memory in our database severs: not
hitting the 10% threshold

• During the pd_flush interval about ~775MB
of dirty pages were accumulating

•

NFS write operations were taking about
0.6 sec per 65k block

• Meaning a11 second stall in all IO while

waiting for dirty pages to be written out
pv(1)

pv - monitor the progress of data through a pipe

Very useful feature:

-L RATE, --rate-limit RATE

Limit the transfer to a maximum of RATE bytes per

second. A suffix of "k", "m", "g", or "t" can be added to denote kilobytes (*1024), megabytes, and so on.
Fixed limit problem
• If the pv rate limit is set to high we still

interfere with MySQL by stealing IO to the
database servers attached storage

• if the pv rate limit is set lower then the

rate of incoming writes to mysql
innobackupex will not finish until it fills the
volume holding the xtrabackup logs.

• Need a dynamic rate limiter
pv(1)

pv - monitor the progress of data through a pipe

Making pv dynamic
-R PID, --remote PID If PID is an instance of pv that is already running, -R PID will cause that
instance to act as though it had been given this instance's command line instead. For example, if pv -L 123k is running with
process ID 9876, then running pv -R 9876 -L 321k will cause it to start using a rate limit of 321k instead of 123k. Note that
some options cannot be changed while running, such as -c, -l, -f, -E, and -S.
Metric for IO Health
iostat -x -d -m 5 /dev/sda
Device:

rrqm/s wrqm/s

r/s

w/s

rMB/s

wMB/s avgrq-sz

avgqu-sz

await svctm %util

sda

0.06

0.08

0.39

0.00

0.00

0.00

2.23 1.22 0.06

0.51

21.17

avgqu-sz - The average queue length of the
requests that were issued to the device.
Through a bit of experimentation we found when avgqu-sz hovered around 1.0 for the
device containing the mysql data files we achieved the most efficient backup with least
impact.
A PID Controller
Success!
Cool, where can I get tpain?

•

Not open sourced yet, working on it! check
https://github.com/Demonware

•

Can’t wait? simple to create yourself (Python)

•

PID controller: http://code.activestate.com/
recipes/577231-discrete-pid-controller/

•

Async read iostat output http://
stefaanlippens.net/python-asynchronoussubprocess-pipe-reading

• PID Values P=0.060, I=0.0001, D=0.03,
limits in KB/s use iostat -x -d 5 /dev,
discard first sample

Weitere ähnliche Inhalte

Was ist angesagt?

pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)
pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)
pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)
Wei Shan Ang
 
Gc and-pagescan-attacks-by-linux
Gc and-pagescan-attacks-by-linuxGc and-pagescan-attacks-by-linux
Gc and-pagescan-attacks-by-linux
Cuong Tran
 
Webinar Slides: Migrating to Galera Cluster
Webinar Slides: Migrating to Galera ClusterWebinar Slides: Migrating to Galera Cluster
Webinar Slides: Migrating to Galera Cluster
Severalnines
 

Was ist angesagt? (20)

DataStax: Extreme Cassandra Optimization: The Sequel
DataStax: Extreme Cassandra Optimization: The SequelDataStax: Extreme Cassandra Optimization: The Sequel
DataStax: Extreme Cassandra Optimization: The Sequel
 
On The Building Of A PostgreSQL Cluster
On The Building Of A PostgreSQL ClusterOn The Building Of A PostgreSQL Cluster
On The Building Of A PostgreSQL Cluster
 
HBaseConAsia2018 Track1-2: WALLess HBase with persistent memory devices
HBaseConAsia2018 Track1-2: WALLess HBase with persistent memory devicesHBaseConAsia2018 Track1-2: WALLess HBase with persistent memory devices
HBaseConAsia2018 Track1-2: WALLess HBase with persistent memory devices
 
Scylla Summit 2018: Scylla Feature Talks - Scylla Streaming and Repair Updates
Scylla Summit 2018: Scylla Feature Talks - Scylla Streaming and Repair UpdatesScylla Summit 2018: Scylla Feature Talks - Scylla Streaming and Repair Updates
Scylla Summit 2018: Scylla Feature Talks - Scylla Streaming and Repair Updates
 
Tips and Tricks for Operating Apache Kafka
Tips and Tricks for Operating Apache KafkaTips and Tricks for Operating Apache Kafka
Tips and Tricks for Operating Apache Kafka
 
Cassandra at teads
Cassandra at teadsCassandra at teads
Cassandra at teads
 
pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)
pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)
pgDay Asia 2016 - Swapping Pacemaker-Corosync for repmgr (1)
 
Lightweight Transactions at Lightning Speed
Lightweight Transactions at Lightning SpeedLightweight Transactions at Lightning Speed
Lightweight Transactions at Lightning Speed
 
Gc and-pagescan-attacks-by-linux
Gc and-pagescan-attacks-by-linuxGc and-pagescan-attacks-by-linux
Gc and-pagescan-attacks-by-linux
 
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
Webinar Slides : Migrating to MySQL, MariaDB Galera and/or Percona XtraDB Clu...
 
Logical Replication in PostgreSQL - FLOSSUK 2016
Logical Replication in PostgreSQL - FLOSSUK 2016Logical Replication in PostgreSQL - FLOSSUK 2016
Logical Replication in PostgreSQL - FLOSSUK 2016
 
Application Caching: The Hidden Microservice (SAConf)
Application Caching: The Hidden Microservice (SAConf)Application Caching: The Hidden Microservice (SAConf)
Application Caching: The Hidden Microservice (SAConf)
 
Distributed Postgres
Distributed PostgresDistributed Postgres
Distributed Postgres
 
Eventually, Scylla Chooses Consistency
Eventually, Scylla Chooses ConsistencyEventually, Scylla Chooses Consistency
Eventually, Scylla Chooses Consistency
 
Oracle database might have problems with stale NFSv3 locks upon restart
Oracle database might have problems with stale NFSv3 locks upon restartOracle database might have problems with stale NFSv3 locks upon restart
Oracle database might have problems with stale NFSv3 locks upon restart
 
Steps to identify ONTAP latency related issues
Steps to identify ONTAP latency related issuesSteps to identify ONTAP latency related issues
Steps to identify ONTAP latency related issues
 
Scylla’s Journey Towards Being an Elastic Cloud Native Database
Scylla’s Journey Towards Being an Elastic Cloud Native DatabaseScylla’s Journey Towards Being an Elastic Cloud Native Database
Scylla’s Journey Towards Being an Elastic Cloud Native Database
 
hbaseconasia2017: HBase Practice At XiaoMi
hbaseconasia2017: HBase Practice At XiaoMihbaseconasia2017: HBase Practice At XiaoMi
hbaseconasia2017: HBase Practice At XiaoMi
 
EVCache & Moneta (GoSF)
EVCache & Moneta (GoSF)EVCache & Moneta (GoSF)
EVCache & Moneta (GoSF)
 
Webinar Slides: Migrating to Galera Cluster
Webinar Slides: Migrating to Galera ClusterWebinar Slides: Migrating to Galera Cluster
Webinar Slides: Migrating to Galera Cluster
 

Andere mochten auch (7)

Dev ops lessons learned - Michael Collins
Dev ops lessons learned  - Michael CollinsDev ops lessons learned  - Michael Collins
Dev ops lessons learned - Michael Collins
 
Heka - Rob Miller
Heka - Rob MillerHeka - Rob Miller
Heka - Rob Miller
 
Dev ops finishes what agile started - Manfred Moser
Dev ops finishes what agile started - Manfred MoserDev ops finishes what agile started - Manfred Moser
Dev ops finishes what agile started - Manfred Moser
 
Letting go gavin - Mc Donald
Letting go gavin - Mc DonaldLetting go gavin - Mc Donald
Letting go gavin - Mc Donald
 
Zero to hero - Geoff Webb
Zero to hero - Geoff WebbZero to hero - Geoff Webb
Zero to hero - Geoff Webb
 
Dev opsdays scriptcode
Dev opsdays scriptcodeDev opsdays scriptcode
Dev opsdays scriptcode
 
Penyusunan Indikator Kinerja dan Anggaran Berbasis Kinerja
Penyusunan Indikator Kinerja dan Anggaran Berbasis KinerjaPenyusunan Indikator Kinerja dan Anggaran Berbasis Kinerja
Penyusunan Indikator Kinerja dan Anggaran Berbasis Kinerja
 

Ähnlich wie Dw tpain - Gordon Klok

Shak larry-jeder-perf-and-tuning-summit14-part2-final
Shak larry-jeder-perf-and-tuning-summit14-part2-finalShak larry-jeder-perf-and-tuning-summit14-part2-final
Shak larry-jeder-perf-and-tuning-summit14-part2-final
Tommy Lee
 
Oracle Performance On Linux X86 systems
Oracle  Performance On Linux  X86 systems Oracle  Performance On Linux  X86 systems
Oracle Performance On Linux X86 systems
Baruch Osoveskiy
 
UKOUG, Lies, Damn Lies and I/O Statistics
UKOUG, Lies, Damn Lies and I/O StatisticsUKOUG, Lies, Damn Lies and I/O Statistics
UKOUG, Lies, Damn Lies and I/O Statistics
Kyle Hailey
 

Ähnlich wie Dw tpain - Gordon Klok (20)

CPN302 your-linux-ami-optimization-and-performance
CPN302 your-linux-ami-optimization-and-performanceCPN302 your-linux-ami-optimization-and-performance
CPN302 your-linux-ami-optimization-and-performance
 
Streaming in Practice - Putting Apache Kafka in Production
Streaming in Practice - Putting Apache Kafka in ProductionStreaming in Practice - Putting Apache Kafka in Production
Streaming in Practice - Putting Apache Kafka in Production
 
Shak larry-jeder-perf-and-tuning-summit14-part2-final
Shak larry-jeder-perf-and-tuning-summit14-part2-finalShak larry-jeder-perf-and-tuning-summit14-part2-final
Shak larry-jeder-perf-and-tuning-summit14-part2-final
 
Multitenancy: Kafka clusters for everyone at LINE
Multitenancy: Kafka clusters for everyone at LINEMultitenancy: Kafka clusters for everyone at LINE
Multitenancy: Kafka clusters for everyone at LINE
 
(WEB401) Optimizing Your Web Server on AWS | AWS re:Invent 2014
(WEB401) Optimizing Your Web Server on AWS | AWS re:Invent 2014(WEB401) Optimizing Your Web Server on AWS | AWS re:Invent 2014
(WEB401) Optimizing Your Web Server on AWS | AWS re:Invent 2014
 
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
End to End Processing of 3.7 Million Telemetry Events per Second using Lambda...
 
Multi-Tenancy Kafka cluster for LINE services with 250 billion daily messages
Multi-Tenancy Kafka cluster for LINE services with 250 billion daily messagesMulti-Tenancy Kafka cluster for LINE services with 250 billion daily messages
Multi-Tenancy Kafka cluster for LINE services with 250 billion daily messages
 
Netflix Keystone Pipeline at Samza Meetup 10-13-2015
Netflix Keystone Pipeline at Samza Meetup 10-13-2015Netflix Keystone Pipeline at Samza Meetup 10-13-2015
Netflix Keystone Pipeline at Samza Meetup 10-13-2015
 
Project Tungsten Phase II: Joining a Billion Rows per Second on a Laptop
Project Tungsten Phase II: Joining a Billion Rows per Second on a LaptopProject Tungsten Phase II: Joining a Billion Rows per Second on a Laptop
Project Tungsten Phase II: Joining a Billion Rows per Second on a Laptop
 
Introduction to Galera Cluster
Introduction to Galera ClusterIntroduction to Galera Cluster
Introduction to Galera Cluster
 
Practice and challenges from building IaaS
Practice and challenges from building IaaSPractice and challenges from building IaaS
Practice and challenges from building IaaS
 
MySQL Replication: Pros and Cons
MySQL Replication: Pros and ConsMySQL Replication: Pros and Cons
MySQL Replication: Pros and Cons
 
Oracle Performance On Linux X86 systems
Oracle  Performance On Linux  X86 systems Oracle  Performance On Linux  X86 systems
Oracle Performance On Linux X86 systems
 
Galera webinar migration to galera cluster from my sql async replication
Galera webinar migration to galera cluster from my sql async replicationGalera webinar migration to galera cluster from my sql async replication
Galera webinar migration to galera cluster from my sql async replication
 
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
(DAT402) Amazon RDS PostgreSQL:Lessons Learned & New Features
 
Kafka to the Maxka - (Kafka Performance Tuning)
Kafka to the Maxka - (Kafka Performance Tuning)Kafka to the Maxka - (Kafka Performance Tuning)
Kafka to the Maxka - (Kafka Performance Tuning)
 
Ovs perf
Ovs perfOvs perf
Ovs perf
 
UKOUG, Lies, Damn Lies and I/O Statistics
UKOUG, Lies, Damn Lies and I/O StatisticsUKOUG, Lies, Damn Lies and I/O Statistics
UKOUG, Lies, Damn Lies and I/O Statistics
 
Backing up Wikipedia Databases
Backing up Wikipedia DatabasesBacking up Wikipedia Databases
Backing up Wikipedia Databases
 
Oracle 11g R2 RAC setup on rhel 5.0
Oracle 11g R2 RAC setup on rhel 5.0Oracle 11g R2 RAC setup on rhel 5.0
Oracle 11g R2 RAC setup on rhel 5.0
 

Mehr von Devopsdays

Game of thrones - Jonathan Thorpe
Game of thrones - Jonathan ThorpeGame of thrones - Jonathan Thorpe
Game of thrones - Jonathan Thorpe
Devopsdays
 
Gaming dev ops - Eduardo Saito
Gaming dev ops - Eduardo SaitoGaming dev ops - Eduardo Saito
Gaming dev ops - Eduardo Saito
Devopsdays
 
From the classroom to the cloud a journey with node.js - Christopher Hogue
From the classroom to the cloud   a journey with node.js - Christopher HogueFrom the classroom to the cloud   a journey with node.js - Christopher Hogue
From the classroom to the cloud a journey with node.js - Christopher Hogue
Devopsdays
 
Dev ops at mobify - Kyle Young
Dev ops at mobify - Kyle YoungDev ops at mobify - Kyle Young
Dev ops at mobify - Kyle Young
Devopsdays
 
Your business needs devops, so don’t follow - Brian johnson
Your business needs devops, so don’t follow - Brian johnson Your business needs devops, so don’t follow - Brian johnson
Your business needs devops, so don’t follow - Brian johnson
Devopsdays
 
Test kitchen 1.0 - Fletcher Nichol
Test kitchen 1.0 - Fletcher NicholTest kitchen 1.0 - Fletcher Nichol
Test kitchen 1.0 - Fletcher Nichol
Devopsdays
 
Living system or build factory - Chris Maxwell
Living system or build factory  - Chris MaxwellLiving system or build factory  - Chris Maxwell
Living system or build factory - Chris Maxwell
Devopsdays
 
From vagrant to production - Mark Eijsermans
From vagrant to production - Mark EijsermansFrom vagrant to production - Mark Eijsermans
From vagrant to production - Mark Eijsermans
Devopsdays
 
Building for operations - Reinhardt Quelle
Building for operations - Reinhardt QuelleBuilding for operations - Reinhardt Quelle
Building for operations - Reinhardt Quelle
Devopsdays
 
Taking devops to the Next Level - Max Martin
Taking devops to the Next Level - Max MartinTaking devops to the Next Level - Max Martin
Taking devops to the Next Level - Max Martin
Devopsdays
 
Sensu intro - Sean Porter
Sensu intro - Sean PorterSensu intro - Sean Porter
Sensu intro - Sean Porter
Devopsdays
 
Ops for everyone - John Britton
Ops for everyone - John BrittonOps for everyone - John Britton
Ops for everyone - John Britton
Devopsdays
 
Effective monitoring with statsd - Alexis lê-quôc
Effective monitoring with statsd - Alexis lê-quôcEffective monitoring with statsd - Alexis lê-quôc
Effective monitoring with statsd - Alexis lê-quôc
Devopsdays
 
Being healthy dev and ops in cookpad - Issei Naruta
Being healthy dev and ops in cookpad - Issei NarutaBeing healthy dev and ops in cookpad - Issei Naruta
Being healthy dev and ops in cookpad - Issei Naruta
Devopsdays
 
Making operations visible - Nick Gallbreath
Making operations visible - Nick GallbreathMaking operations visible - Nick Gallbreath
Making operations visible - Nick Gallbreath
Devopsdays
 
What science tells us about information infrastructure - Mark Burgess
What science tells us about information infrastructure - Mark BurgessWhat science tells us about information infrastructure - Mark Burgess
What science tells us about information infrastructure - Mark Burgess
Devopsdays
 
How to use continuous improvement kungfu to pay down technical debt - Kevin B...
How to use continuous improvement kungfu to pay down technical debt - Kevin B...How to use continuous improvement kungfu to pay down technical debt - Kevin B...
How to use continuous improvement kungfu to pay down technical debt - Kevin B...
Devopsdays
 
Giving (and taking) back - Mike Fiedler
Giving (and taking) back - Mike FiedlerGiving (and taking) back - Mike Fiedler
Giving (and taking) back - Mike Fiedler
Devopsdays
 
Enterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike Baukes
Enterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike BaukesEnterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike Baukes
Enterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike Baukes
Devopsdays
 
Morgue , helping better understand events by building a post mortem tool - Be...
Morgue , helping better understand events by building a post mortem tool - Be...Morgue , helping better understand events by building a post mortem tool - Be...
Morgue , helping better understand events by building a post mortem tool - Be...
Devopsdays
 

Mehr von Devopsdays (20)

Game of thrones - Jonathan Thorpe
Game of thrones - Jonathan ThorpeGame of thrones - Jonathan Thorpe
Game of thrones - Jonathan Thorpe
 
Gaming dev ops - Eduardo Saito
Gaming dev ops - Eduardo SaitoGaming dev ops - Eduardo Saito
Gaming dev ops - Eduardo Saito
 
From the classroom to the cloud a journey with node.js - Christopher Hogue
From the classroom to the cloud   a journey with node.js - Christopher HogueFrom the classroom to the cloud   a journey with node.js - Christopher Hogue
From the classroom to the cloud a journey with node.js - Christopher Hogue
 
Dev ops at mobify - Kyle Young
Dev ops at mobify - Kyle YoungDev ops at mobify - Kyle Young
Dev ops at mobify - Kyle Young
 
Your business needs devops, so don’t follow - Brian johnson
Your business needs devops, so don’t follow - Brian johnson Your business needs devops, so don’t follow - Brian johnson
Your business needs devops, so don’t follow - Brian johnson
 
Test kitchen 1.0 - Fletcher Nichol
Test kitchen 1.0 - Fletcher NicholTest kitchen 1.0 - Fletcher Nichol
Test kitchen 1.0 - Fletcher Nichol
 
Living system or build factory - Chris Maxwell
Living system or build factory  - Chris MaxwellLiving system or build factory  - Chris Maxwell
Living system or build factory - Chris Maxwell
 
From vagrant to production - Mark Eijsermans
From vagrant to production - Mark EijsermansFrom vagrant to production - Mark Eijsermans
From vagrant to production - Mark Eijsermans
 
Building for operations - Reinhardt Quelle
Building for operations - Reinhardt QuelleBuilding for operations - Reinhardt Quelle
Building for operations - Reinhardt Quelle
 
Taking devops to the Next Level - Max Martin
Taking devops to the Next Level - Max MartinTaking devops to the Next Level - Max Martin
Taking devops to the Next Level - Max Martin
 
Sensu intro - Sean Porter
Sensu intro - Sean PorterSensu intro - Sean Porter
Sensu intro - Sean Porter
 
Ops for everyone - John Britton
Ops for everyone - John BrittonOps for everyone - John Britton
Ops for everyone - John Britton
 
Effective monitoring with statsd - Alexis lê-quôc
Effective monitoring with statsd - Alexis lê-quôcEffective monitoring with statsd - Alexis lê-quôc
Effective monitoring with statsd - Alexis lê-quôc
 
Being healthy dev and ops in cookpad - Issei Naruta
Being healthy dev and ops in cookpad - Issei NarutaBeing healthy dev and ops in cookpad - Issei Naruta
Being healthy dev and ops in cookpad - Issei Naruta
 
Making operations visible - Nick Gallbreath
Making operations visible - Nick GallbreathMaking operations visible - Nick Gallbreath
Making operations visible - Nick Gallbreath
 
What science tells us about information infrastructure - Mark Burgess
What science tells us about information infrastructure - Mark BurgessWhat science tells us about information infrastructure - Mark Burgess
What science tells us about information infrastructure - Mark Burgess
 
How to use continuous improvement kungfu to pay down technical debt - Kevin B...
How to use continuous improvement kungfu to pay down technical debt - Kevin B...How to use continuous improvement kungfu to pay down technical debt - Kevin B...
How to use continuous improvement kungfu to pay down technical debt - Kevin B...
 
Giving (and taking) back - Mike Fiedler
Giving (and taking) back - Mike FiedlerGiving (and taking) back - Mike Fiedler
Giving (and taking) back - Mike Fiedler
 
Enterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike Baukes
Enterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike BaukesEnterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike Baukes
Enterprise dev ops , going big and f*$^#&g up, a cautionary tale - Mike Baukes
 
Morgue , helping better understand events by building a post mortem tool - Be...
Morgue , helping better understand events by building a post mortem tool - Be...Morgue , helping better understand events by building a post mortem tool - Be...
Morgue , helping better understand events by building a post mortem tool - Be...
 

Kürzlich hochgeladen

Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
UXDXConf
 

Kürzlich hochgeladen (20)

Speed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in MinutesSpeed Wins: From Kafka to APIs in Minutes
Speed Wins: From Kafka to APIs in Minutes
 
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
FDO for Camera, Sensor and Networking Device – Commercial Solutions from VinC...
 
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
Secure Zero Touch enabled Edge compute with Dell NativeEdge via FDO _ Brad at...
 
Agentic RAG What it is its types applications and implementation.pdf
Agentic RAG What it is its types applications and implementation.pdfAgentic RAG What it is its types applications and implementation.pdf
Agentic RAG What it is its types applications and implementation.pdf
 
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdfLinux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
Linux Foundation Edge _ Overview of FDO Software Components _ Randy at Intel.pdf
 
The UX of Automation by AJ King, Senior UX Researcher, Ocado
The UX of Automation by AJ King, Senior UX Researcher, OcadoThe UX of Automation by AJ King, Senior UX Researcher, Ocado
The UX of Automation by AJ King, Senior UX Researcher, Ocado
 
Buy Epson EcoTank L3210 Colour Printer Online.pdf
Buy Epson EcoTank L3210 Colour Printer Online.pdfBuy Epson EcoTank L3210 Colour Printer Online.pdf
Buy Epson EcoTank L3210 Colour Printer Online.pdf
 
Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024Extensible Python: Robustness through Addition - PyCon 2024
Extensible Python: Robustness through Addition - PyCon 2024
 
Intro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджераIntro in Product Management - Коротко про професію продакт менеджера
Intro in Product Management - Коротко про професію продакт менеджера
 
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
Behind the Scenes From the Manager's Chair: Decoding the Secrets of Successfu...
 
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
Measures in SQL (a talk at SF Distributed Systems meetup, 2024-05-22)
 
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdfIntroduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
Introduction to FDO and How It works Applications _ Richard at FIDO Alliance.pdf
 
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
Integrating Telephony Systems with Salesforce: Insights and Considerations, B...
 
UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1UiPath Test Automation using UiPath Test Suite series, part 1
UiPath Test Automation using UiPath Test Suite series, part 1
 
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi IbrahimzadeFree and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
Free and Effective: Making Flows Publicly Accessible, Yumi Ibrahimzade
 
The Metaverse: Are We There Yet?
The  Metaverse:    Are   We  There  Yet?The  Metaverse:    Are   We  There  Yet?
The Metaverse: Are We There Yet?
 
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone KomSalesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
Salesforce Adoption – Metrics, Methods, and Motivation, Antone Kom
 
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya HalderCustom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
Custom Approval Process: A New Perspective, Pavel Hrbacek & Anindya Halder
 
IESVE for Early Stage Design and Planning
IESVE for Early Stage Design and PlanningIESVE for Early Stage Design and Planning
IESVE for Early Stage Design and Planning
 
Structuring Teams and Portfolios for Success
Structuring Teams and Portfolios for SuccessStructuring Teams and Portfolios for Success
Structuring Teams and Portfolios for Success
 

Dw tpain - Gordon Klok

  • 2. A Demonware MySQL cluster More info about the LSG see: “Erlang and First Person Shooters” http://www.erlang-factory.com/upload/presentations/395/ErlangandFirst-PersonShooters.pdf
  • 3. backup process • innobackupex from Percona http:// www.percona.com/doc/percona-xtrabackup/ 2.1/innobackupex/innobackupex_script.html • Allows hot backup of database • backups the underlying MySQL files replays a transaction log for changes occurring during the backup • much faster to restore then SQL dumps.
  • 4.
  • 6. Everything checks out on the database server
  • 7. NFS Latency during backup window.
  • 8. So whats the problem? How is the slow performance of the NAS affecting the client? Paging...
  • 9.
  • 10. pd_fush • /proc/sys/vm/dirty_background_ratio (default 10): Maximum percentage of active that can be filled with dirty pages before pdflush begins to write them • /proc/sys/vm/dirty_expire_centiseconds (default 3000): In hundredths of a second, how long data can be in the page cache before it's considered expired and must be written at the next opportunity. Note that this default is very long: a full 30 seconds. That means that under normal circumstances, unless you write enough to trigger the other pdflush method, Linux won't actually commit anything you write until 30 seconds later. • See “The Linux Page Cache and pdflush: Theory of Operation and Tuning for WriteHeavy Loads” http://www.westnet.com/ ~gsmith/content/linux-pdflush.htm
  • 11. pd_flush continued • Lots of memory in our database severs: not hitting the 10% threshold • During the pd_flush interval about ~775MB of dirty pages were accumulating • NFS write operations were taking about 0.6 sec per 65k block • Meaning a11 second stall in all IO while waiting for dirty pages to be written out
  • 12. pv(1) pv - monitor the progress of data through a pipe Very useful feature: -L RATE, --rate-limit RATE Limit the transfer to a maximum of RATE bytes per second. A suffix of "k", "m", "g", or "t" can be added to denote kilobytes (*1024), megabytes, and so on.
  • 13. Fixed limit problem • If the pv rate limit is set to high we still interfere with MySQL by stealing IO to the database servers attached storage • if the pv rate limit is set lower then the rate of incoming writes to mysql innobackupex will not finish until it fills the volume holding the xtrabackup logs. • Need a dynamic rate limiter
  • 14. pv(1) pv - monitor the progress of data through a pipe Making pv dynamic -R PID, --remote PID If PID is an instance of pv that is already running, -R PID will cause that instance to act as though it had been given this instance's command line instead. For example, if pv -L 123k is running with process ID 9876, then running pv -R 9876 -L 321k will cause it to start using a rate limit of 321k instead of 123k. Note that some options cannot be changed while running, such as -c, -l, -f, -E, and -S.
  • 15. Metric for IO Health iostat -x -d -m 5 /dev/sda Device: rrqm/s wrqm/s r/s w/s rMB/s wMB/s avgrq-sz avgqu-sz await svctm %util sda 0.06 0.08 0.39 0.00 0.00 0.00 2.23 1.22 0.06 0.51 21.17 avgqu-sz - The average queue length of the requests that were issued to the device. Through a bit of experimentation we found when avgqu-sz hovered around 1.0 for the device containing the mysql data files we achieved the most efficient backup with least impact.
  • 17.
  • 19.
  • 20. Cool, where can I get tpain? • Not open sourced yet, working on it! check https://github.com/Demonware • Can’t wait? simple to create yourself (Python) • PID controller: http://code.activestate.com/ recipes/577231-discrete-pid-controller/ • Async read iostat output http:// stefaanlippens.net/python-asynchronoussubprocess-pipe-reading • PID Values P=0.060, I=0.0001, D=0.03, limits in KB/s use iostat -x -d 5 /dev, discard first sample