Your SlideShare is downloading. ×
  • Like
5 things MySql
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Now you can save presentations on your phone or tablet

Available for both IPhone and Android

Text the download link to your phone

Standard text messaging rates apply
Published

5 things you need to know about MySQL if you don't have a DBA. From OSBridge '09.

5 things you need to know about MySQL if you don't have a DBA. From OSBridge '09.

Published in Technology
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
No Downloads

Views

Total Views
622
On SlideShare
0
From Embeds
0
Number of Embeds
2

Actions

Shares
Downloads
14
Comments
0
Likes
1

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide
  • Not locked into proprietary space… many options. Based from the same code tree Lib mysql vs lib drizzle – licensing gotcha libmysql gpl libdrizz bsd drizzle Maria Our delta Google patches Percona xtradb
  • Google patches include a better malloc And completely changed locking
  • Choose 5.1 or 5.4 only if you need the featuresets.
  • •❑ inno - row with exception •❑ myi - table -- fast in some cases and search cases ( fast inserts? without lock )•❑federated - replication not multiple master. •❑ blackhole handy for logging without inserting into db or skipping a db for fake muliple master
  • Much performance pain come into play with lock contention
  • Much performance pain come into play with lock contention Names changed to protect the innocent
  • Understand MTR and see if you meet that goal. tarball /dump / cpio not a valid backup
  • •❑ tarball /dump / cpio not a valid backup •❑ replication•❑innohot•❑lvm backup script... lvmbackup? •❑ mysqldump = 100% inno ok. single transaction .•❑xtrabackup -- free innohot
  • LVM and slaves give easy opportunities for creating clones for testing
  • Begin with having your application understand that reads and writes are different
  • API SHOULD KNOW THE DIFF proxy as an option if API not possible. scale writes. write own interfaces? check on it. btree index larger than memory -- writes get _slow_ Memcached – good for short lived data and caching wafflegrid -- patches to mysql -- innodb bufferpool over memcached
  • If you’re worried about swapping, use huge page support for mysql (linux doesn’t swap out huge pages
  • •❑ disk•❑memory•❑up/down•❑cachehit -- baseline defiinition•❑replication •❑ mktablesync•❑mkchecksum

Transcript

  • 1. 5 things you need to know about MySQL (if you don’t have a DBA) sarah novotny – [email_address] MySQL and LAMP services www .BlueGecko . net
  • 2.
    • changing ecosystem
    • versions
    • storage engines and locking
    • backups
    • scaling
    • free tools
    www .BlueGecko . net
  • 3.
    • changing ecosystem
    • MySQL ->
    • Sun ->
    • Oracle
    • Monty Program AB
    • OpenDB Alliance
    www .BlueGecko . net
  • 4. www .BlueGecko . net
  • 5.
    • versions
    • 5.0 – stable. (do i need to say more?)
    • 5.1 – fresh feature set
    • – many open bugs
    • – partitioning
    • – row base replication
    • – mysqlslap
    • 5.4 – 5.1 ++ google patches
    • – scalability improvements -> multicore
    • – enhanced monitoring / diagnostic
    • – sane defaults for my.cnf out of the box
    www .BlueGecko . net
  • 6. www .BlueGecko . net
  • 7.
    • a short diversion
    • from High Performance
    • MySQL 2 nd Edition (HPM2e)
    • -Baron Schwartz, Peter Zaitsev,
    • Vadim Tkachenko, and Jeremy
    • Zawodny
    • (don’t mistake 1 st Edition for 2 nd.
    • 1 st is dangerously out of date
    • unless you’re running version 4.0)
    www .BlueGecko . net
  • 8.
    • storage engines
    • innodb
    • myisam
    • merge
    • blackhole
    • archive
    • federated
    www .BlueGecko . net
  • 9.
    • and locking
    • innodb
    • myisam
    www .BlueGecko . net
  • 10.
    • and locking
    www .BlueGecko . net
  • 11.
    • backups
    • take them
    • and test a restore
    www .BlueGecko . net
  • 12.
    • backups
    • mysqldump is not always a valid backup
    • replication is easiest
    • (and it gets you a warm standby)
    • InnoDB hot backup
    • XtraBackup
    • mylvmbackup
    www .BlueGecko . net
  • 13.
    • backups
    www .BlueGecko . net
  • 14.
    • scale
    • when it’s time to
    • go big, what are
    • the options?
    • separate reads
    • from writes
    www .BlueGecko . net
  • 15.
    • scale
    • write 1 / read many
    • partitioning / sharding
    • multimaster / rings
    • memcached
    • wafflegrid
    www .BlueGecko . net
  • 16.
    • another
    • short
    • diversion
    • to swap or
    • not to swap
    • that is the
    • question
    www .BlueGecko . net
  • 17.
    • free tools
    • Innotop
    • maatkit
    • MySQL proxy
    • monitoring/trending
    • cacti templates
    • $monitoring_server
    • – the one you know
    www .BlueGecko . net
  • 18. additional resources
    • irc.freenode.org
      • #mysql
      • #maatkit
    • mysql.com
    • HPM2e - Baron Schwartz, Peter Zaitsev, Vadim Tkachenko, and Jeremy Zawodny
    www .BlueGecko . net
  • 19. credits
    • flickr
    • Make: biosphere - kevino
    • MySQL mints - jimwinstead
    • 5 – losmininos
    • storage- shuttercat7
    • clones - adactio
    • Bell Labs - sodapop81
    • License plate - severud
    • tools – meanestindian
    • console - hermzz
    • other
    • swap image
      • http://www.vocw.edu.vn/content/m10106/latest/
    • special thanks to mike hamrick for suggestions on content and slides
    www .BlueGecko . net
  • 20. Blue Gecko and contact info
    • [email_address]
    • [email_address]
    • @sarahnovotny
    • @bluegeckodba
    • senk on #mysql
    www .BlueGecko . net 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.