16
How to Create a Useful MySQL Bug Report Valerii Kravchuk, Principal Support Engineer [email protected]

How to create a useful MySQL bug report

Embed Size (px)

DESCRIPTION

Slides for my BOF session from Oracle OpenWorld 2014

Citation preview

Page 1: How to create a useful MySQL bug report

How to Create a Useful MySQL Bug Report

Valerii Kravchuk, Principal Support [email protected]

Page 2: How to create a useful MySQL bug report

www.percona.com

Who am I?

Valerii (aka Valeriy) Kravchuk:● MySQL Support Engineer in MySQL AB, Sun and Oracle, 2005 - 2012

○ Bugs Verification Team all this time○ Support issues related to bugs, InnoDB, performance...○ Trainings (mostly informal) for new team members○ All kinds of decision making committees…

● Principal Support Engineer in Percona since September, 2012○ Doing more or less the same as before, but better (I hope)...○ Plus I try to speak and write about MySQL in public now

● http://mysqlentomologist.blogspot.com - my blog about MySQL (mostly bugs)● https://www.facebook.com/valerii.kravchuk - my Facebook page, a lot about

MySQL (mostly bugs…)● http://bugs.mysql.com - my personal playground. 88 bugs reported in 2014

Page 3: How to create a useful MySQL bug report

www.percona.com

What is this session about?

● Report MySQL bugs at http://bugs.mysql.com (or other public tracker)!

● What is a “Useful MySQL Bug Report”?● What to do before reporting a bug?● How to search for known MySQL bugs efficiently?● What tools may help to create a useful bug report?● Life cycle of Oracle/MySQL public bug report● Life cycle of Percona bug report● Examples of useful bug reports● Examples of useless bug reports● How to escalate bug reports?

Page 4: How to create a useful MySQL bug report

www.percona.com

Report bugs in public!

● Why? I am customer! http://mysqlentomologist.blogspot.com/2012/12/new-year-

wishes-for-customers-of.html:○ easy to search for: site:bugs.mysql.com drop add index InnoDB○ becomes visible to other customers, community members and MySQL support providers and

developers outside of Oracle

● http://bugs.mysql.com - MySQL software from Oracle● https://mariadb.atlassian.net/browse/MDEV - MariaDB● https://bugs.launchpad.net/percona-server● https://bugs.launchpad.net/percona-xtradb-cluster● https://bugs.launchpad.net/percona-xtrabackup● https://bugs.launchpad.net/percona-toolkit

Page 5: How to create a useful MySQL bug report

www.percona.com

Features of a Useful Bug Report

● It’s a real, new bug that was never reported before (or was once fixed but now appeared again)

● It’s clear what the bug is and how to reproduce it● Bug reporter cared to check on latest officially released

version in the branch● All important details about the environment and impact

are provided● It’s clear that bug reporter spent enough efforts on it

(search, testing, attempts to provide a minimal test case)● Anything wrong or missed in the above?

Page 6: How to create a useful MySQL bug report

www.percona.com

Before you report a bug...

● Try to find similar bugs (bug tracker specific search, Google, ...)

● Try to find a solution/reason by reading the manual● Try to reproduce the bug in “clean environment”● Make sure you’ve read vendor-specific (and product

specific, if any) instructions:https://mariadb.com/kb/en/mariadb/development/debugging-mariadb/reporting-bugs/http://bugs.mysql.com/how-to-report.phphttp://mysqlworkbench.org/faq/faq-bugreporting/

● Make sure you’ve read this entirely at least once:http://www.catb.org/esr/faqs/smart-questions.html

Page 7: How to create a useful MySQL bug report

www.percona.com

How to search for known bugs?

● Use Google like this:site:bugs.mysql.com drop table slowand check at least first 3 pages of results and links there

● Search for specific error messages, lines from stack trace, versions, filenames and line numbers, names

● Do not ignore bug tracker specific search:○ Specific categories○ Bugs vs. Feature requests○ Specific version, bug status etc

● Study features and limitations of your search tools● Keep your own notes and test cases “database”

Page 8: How to create a useful MySQL bug report

www.percona.com

Tools for bug reporters

● Randgen (RQG)○ http://www.percona.com/blog/2014/04/17/how-to-find-bugs-in-mysql/

● MTR (MySQL regression test suite)○ http://dev.mysql.com/doc/refman/5.6/en/mysql-test-suite.html

● reducer.sh:○ http://www.percona.com/blog/2014/09/03/reducer-sh-a-powerful-mysql-test-case-

simplificationreducer-tool/

● MySQL Sandbox● Percona Toolkit (pt-summary, pt-mysql-summary, more)● Debug binaries and trace● Valgrind and Massif:

○ http://www.percona.com/blog/2013/01/09/profiling-mysql-memory-usage-with-valgrind-massif/

● Anything else?

Page 9: How to create a useful MySQL bug report

www.percona.com

Life Cycle of MySQL Bug

http://mysqlentomologist.blogspot.com/2013/01/life-cycle-of-mysql-bug.html

● Open● Analyzing● Need Feedback → No Feedback (expires in 30 days)● Can’t repeat● Verified● Not a Bug● Duplicate● Unsupported● Won’t fix● In progress… (real progress happens elsewhere)● Closed● What about feature requests?

Page 10: How to create a useful MySQL bug report

www.percona.com

Life Cycle of Percona (launchpad) Bug

● New (“Open”), no automatic re-opening on new comment● Incomplete (“Need Feedback”), expires in 60 days● Invalid (“Not a bug”, “Can’t repeat”)● Confirmed (“Verified”)● Triaged● In progress● Fix committed● Fix released (“Closed”)● Won’t Fix● Separate status per branch (5.5/5.6) and project

(PS/PXC), also upstream references...

Page 11: How to create a useful MySQL bug report

www.percona.com

Examples: useful bug reports

● http://bugs.mysql.com/bug.php?id=69979 - how repeatable read works (NaB)● http://bugs.mysql.com/bug.php?id=73837 - how to report optimizer bugs● http://bugs.mysql.com/bug.php?id=68705 - Valgrind in use to find memory leak● http://bugs.mysql.com/bug.php?id=73825 - simple wrong results bug● http://bugs.mysql.com/bug.php?id=73881 - RQG in action● http://bugs.mysql.com/bug.php?id=68554 - optimizer trace, level of details● http://bugs.mysql.com/bug.php?id=68079 - sysbench, P_S, cooperation● http://bugs.mysql.com/bug.php?id=69253 - with patch suggested (mind OCA)● http://bugs.mysql.com/bug.php?id=73018 - even good reports may stay Open● ...

Page 12: How to create a useful MySQL bug report

www.percona.com

Examples: useless bug reports

● http://bugs.mysql.com/bug.php?id=2 - pure fun. Not fixed for 12 years!● http://bugs.mysql.com/bug.php?id=69878 - real bug, but many problems

reported in one, no respect● http://bugs.mysql.com/bug.php?id=55796 - “it really sucks”, gotcha...● http://bugs.mysql.com/bug.php?id=73960 - “this query is very slow”...● http://bugs.mysql.com/bug.php?id=73921 - free support request, 5.5.34● http://bugs.mysql.com/bug.php?id=73844 - almost no details, others wrong● https://bugs.launchpad.net/percona-server/+bug/1245141 - RBR with no

PK/UK in 5.5. Time to check for known problems… Free support request● ...

Page 13: How to create a useful MySQL bug report

www.percona.com

How to escalate the bug?

● Verified (or Open but real) bug is not fixed. What to do?○ Add comment, ask, curse, complain in report○ Ask others to comment, use “Affects Me” button○ Report it again?○ Report it in other bug tracker (to other company)○ Blog about it○ Open issue (support request) about it○ Ask some developer in private○ Complain on Facebook○ Tell me about it

Page 14: How to create a useful MySQL bug report

www.percona.com

Hall of Fame: they process your bugs!

● Umesh Shastry (Oracle, 50+% of all bugs Verified)● Shane Bester (MySQL, Sun, Oracle)● Sveta Smirnova (MySQL, Sun, Oracle)● Miguel Solorzano (MySQL, Sun, Oracle)● Elena Stepanova (Sun, Oracle, MariaDB)● Nilnandan Joshi (PS, PXC, pt-*, PXB)● Raghavendra Prabhu (PXC) ● Laurynas Biveinis (PS)● Roel Van de Paar (PS, PXC) - MySQL, Sun and Oracle● Alexey Kopytov (PXB, PS) - MySQL, Sun and Oracle● ...

Page 15: How to create a useful MySQL bug report

www.percona.com

Any bug reports you want to discuss?

● http://bugs.mysql.com/bug.php?id=73369 - sometimes even experienced Support engineers have problems

● http://bugs.mysql.com/bug.php?id=69979 - even if it’s “Not a bug” eventually, it was a useful work for all!

● http://bugs.mysql.com/bug.php?id=71095 - you can get patch in a matter of days!

● “Private” and “Security” bugs in public bugs databases. Should they exist, who decides on these statuses, when they should become public?

● Your examples?

Page 16: How to create a useful MySQL bug report

www.percona.com

Thank you!

Questions and Answers

Please, report bugs at:http://bugs.mysql.comUse “Affects Me” button!