View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000983Sphinxsphinxsepublic2011-11-16 16:562011-11-21 09:42
Reportervojtech.kurka 
Assigned ToTomat 
PriorityhighSeveritycrashReproducibilityrandom
StatusclosedResolutionfixed 
PlatformIntel, X5650OSCentOS 5.6OS Version2.6.18-238.19.1
Product Version2.0.2-dev 
Target VersionFixed in Version2.0.2-dev 
Summary0000983: SphinxSE plugin crashes the mysql server
DescriptionWe have similar problems on 5.5, we cannot run the production workload on an upgraded
 machine, 5.1 is runing fine.

 Crash report:

 111116 7:07:34 - mysqld got signal 11 ;
 This could be because you hit a bug. It is also possible that this binary
 or one of the libraries it was linked against is corrupt, improperly built,
 or misconfigured. This error can also be caused by malfunctioning hardware.
 We will try our best to scrape up some info that will hopefully help diagnose
 the problem, but since we have already crashed, something is definitely wrong
 and this may fail.

 key_buffer_size=104857600
 read_buffer_size=131072
 max_used_connections=58
 max_threads=2000
 thread_count=18
 connection_count=17
 It is possible that mysqld could use up to
 key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 4478321 K
 bytes of memory
 Hope that's ok; if not, decrease some variables in the equation.

 Thread pointer: 0x2abd4a573110
 Attempting backtrace. You can use the following information to find out
 where mysqld died. If you see no messages after this, something went
 terribly wrong...
 stack_bottom = 0x49c420e0 thread_stack 0x40000
 /usr/sbin/mysqld(my_print_stacktrace+0x39)[0x7ce749]
 /usr/sbin/mysqld(handle_segfault+0x379)[0x500de9]
 /lib64/libpthread.so.0[0x3f5560eb10]
 /usr/lib64/mysql/plugin/ha_sphinx.so(_ZN9ha_sphinx7ConnectEPKct+0x123)[0x2aaab114b6a3]
 /usr/lib64/mysql/plugin/ha_sphinx.so(_ZN9ha_sphinx10ConnectAPIEPKci+0x47)[0x2aaab114b7b7]
 /usr/lib64/mysql/plugin/ha_sphinx.so(_ZN9ha_sphinx10index_readEPhPKhj16ha_rkey_function+0x
 2da)[0x2aaab1150eca]
 /usr/sbin/mysqld[0x59d2f0]
 /usr/sbin/mysqld(_Z10sub_selectP4JOINP13st_join_tableb+0x66)[0x5a6dd6]
 /usr/sbin/mysqld[0x5a9070]
 /usr/sbin/mysqld(_ZN4JOIN4execEv+0x12a8)[0x5b8128]
 /usr/sbin/mysqld(_Z12mysql_selectP3THDPPP4ItemP10TABLE_LISTjR4ListIS1_ES2_jP8st_orderSB_S2
 _SB_yP13select_resultP18st_select_lex_unitP13st_select_lex+0x1a9)[0x5b9589]
 /usr/sbin/mysqld(_Z13handle_selectP3THDP3LEXP13select_resultm+0x1ce)[0x5b9ede]
 /usr/sbin/mysqld[0x57727d]
 /usr/sbin/mysqld(_Z21mysql_execute_commandP3THD+0x2505)[0x579c55]
 /usr/sbin/mysqld(_Z11mysql_parseP3THDPcjP12Parser_state+0x38c)[0x57dadc]
 /usr/sbin/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcj+0x148e)[0x57ef8e]
 /usr/sbin/mysqld(_Z10do_commandP3THD+0x106)[0x57f326]
 /usr/sbin/mysqld(_Z24do_handle_one_connectionP3THD+0x111)[0x61a0a1]
 /usr/sbin/mysqld(handle_one_connection+0x54)[0x61a194]
 /lib64/libpthread.so.0[0x3f5560673d]
 /lib64/libc.so.6(clone+0x6d)[0x3f54ed44bd]

 Trying to get some variables.
 Some pointers may be invalid and cause the dump to abort.
 Query (0x2abd4ada0030): is an invalid pointer
 Connection ID (thread ID): 630783
 Status: NOT_KILLED

 The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html [^] contains
 information that should help you find out what is causing the crash.
 111116 07:07:37 mysqld_safe Number of processes running now: 0
 111116 07:07:37 mysqld_safe mysqld restarted

If you need any other information from me, you're welcome.
Steps To ReproduceUpgrade production 5.1.53 mysql instance to 5.5.16. Since the upgrade happened, we had 8 crashes in 24 hours. Crash doesn't occur right after the server startup, it occurs 'randomly'.

I've attached a plugin binary compiled using Percona-Server-5.5.16-rel22.0.tar.gz sources.
Additional InformationPlugin was compiled using mysql-5.5.16.tar.gz and then using Percona-Server-5.5.16-rel22.0.tar.gz, both versions crash the mysql server.

Sphinx source was used from SVN, we followed the steps in http://sphinxsearch.com/wiki/doku.php?id=sphinx_sphinxse_on_rhel [^]
TagsNo tags attached.
Attached Filesgz file icon ha_sphinx.so.gz [^] (1,135,388 bytes) 2011-11-16 16:56

- Relationships

-  Notes
(0002067)
Tomat (manager)
2011-11-17 14:07

Could you provide you config, index and query that cause that crash to reproduce it locally?
(0002069)
vojtech.kurka (reporter)
2011-11-17 14:41

Tomat, I don't have the exact SQL query, I'm sorry. We don't log all queries executed, so in the time of the crash I'm not able do distinguish the cause of the crash. The only clue I have is the stack trace, which I posted.
(0002070)
Tomat (manager)
2011-11-17 14:52

I need something to start with, to reproduce here locally. I've tried to reproduce that crash and here MySQL work fine.
Could you provide access to your box?
(0002088)
vojtech.kurka (reporter)
2011-11-18 14:29

I'm sorry, I cannot give you the access, it's our production box. But I can follow your instructions.

I have turned on the general query log and I'm trying to isolate the query, that could cause the crash.

Do you have any tips like attaching gdb or anything? Thank you, Vojtech
(0002089)
vojtech.kurka (reporter)
2011-11-18 14:45

I have found the query:

SELECT `id`, `weight` FROM `_Sphinx` sph WHERE sph.query = 'vestavna trouba;sort=extended:rank desc;mode=extended2;weights=10,1,100,1;host=searchd_1;limit=1000;index=index_1';

When I run the query on 5.1 using the same searchd, it runs ok and returns:

      id weight
-------- ------
  976558 12706
 4128456 12701
15039213 12680
 7930740 12706
 1914233 12704
 4041679 12701
10679300 12654
 4168161 12704
13425155 12691
14818109 12675
 4128478 12714
 1720920 12706
  105433 12698
  975720 12694
 3364825 12688
23337443 12701
26747906 12714
 4042520 12686
11009918 13697
10122644 12675
 4540524 12698
 4165838 12675
 4042362 12708
 2803996 12658
 4168245 12698
 1804142 12675
 1996992 12704
 8627484 12706
 1951818 12675
23993629 12701
24446575 11647
10677300 12714
  974065 12691
 4165833 12712
 2337878 12686
 3364717 12686
10677299 12706
 4366754 13683
15065656 12654
 1529471 12668
 4326697 12698
  167887 12694
 3364819 12675
 4124119 12691
  354574 12706
 4127648 12702
 3354951 12675
 4124120 12694
 4165826 12675
 4166242 12686
 4168247 12691
 6052108 12701
22114729 12701
 1953114 12675
12658692 12701
 4128358 11654
 4326777 12698
13823132 12716
26747922 13712
  976697 12675
 4456593 12686
  161671 12694
 3364820 12680
22867546 12654
24165152 12701
15948095 12686
  974059 12694
  167419 12668
 3364833 12675
 3554676 12708
 3777882 12675
 4011163 12675
 4042000 12698
 4128454 12691
13823131 12712
14266581 12654
 3364829 12675
10677298 12709
26747905 12710
  161248 12668
 3880826 12686
 4128459 12698
14818108 12680
 3364719 12699
 3364818 12691
 8110354 12680
10897788 12668
26747914 12714
26747919 13716
26747923 12714
  970782 12647
 4168243 12693
15065655 12668
26747899 12710
  161218 12683
 3364822 12680
 3365223 12691
 4168248 12691
 4169657 12675
11785471 12675
20204302 12694
26445324 12647
 5702177 12691
 8110358 2635
17428267 12706
24165150 12706
24187531 12698
  974691 12691
  976581 12675
 1953337 12668
 3365249 12686
 4528924 12691
26747908 12710
26747909 12708
26747911 12714
26747921 13716
  161225 12675
  218138 12693
  975320 12668
 1739398 12699
 4168244 12693
10677310 12701
12458609 12675
12829267 2614
14818110 12675
20689531 12706
26747915 12714
 2760121 12706
12787764 12657
12952417 12675
14818107 12675
22274969 12675
24165151 12694
26576974 12668
26747924 13716
  167878 12708
 3364827 12675
 4128455 12698
 4168203 12698
13476836 12701
17428268 12701
  167418 12668
 3365224 12691
 3442600 12709
 4011164 12691
 4128425 2635
 9576428 12701
11785469 12675
15468256 12647
20689535 11675
24187537 12701
  159703 12694
  160013 12675
10642724 12686
12230601 12680
14741525 12654
23993445 12701
26859499 2614
 4009903 12680
10073834 12706
10843315 12691
26747910 12694
26747912 13716
  167877 12683
 1739399 12697
 9588068 12702
12658693 12704
  163783 12680
  163785 12680
  972807 12680
 3364824 12675
 3365245 12691
 4128458 12698
 4168229 12691
 9588059 12668
11785472 12675
12658759 12680
16230689 12680
26747902 12698
26766046 12714
 1739393 12694
 3434739 12647
 3694425 12647
 4128357 12680
 4128451 12675
 4128460 12701
 4168167 12675
 4211415 12698
12658749 12694
12658754 12701
14741527 12675
18995797 12675
21908287 12686
26747926 12691
 4081294 12686
11083980 12647
12658688 12680
12658756 12680
17713485 12686
26747930 12708
 3023752 12675
 3354952 12675
 3364715 12683
 3777889 12675
 4168194 12675
 9588102 12668
12952423 12647
14825541 12654
22114727 12691
31363504 12668
  973943 12658
 1712964 12686
 3263467 12675
 3369352 12680
 3369377 12683
 3694422 12691
 4009898 12680
 8380056 12691
12658673 12714
12658690 12658
17888641 12698
21840646 12694
26747917 12691
  200767 12668
11083979 12675
13428440 12701
14818123 12647
20689532 12675
22114732 12675
 3694418 12701
 4128447 12635
 4168240 12675
13093455 12675
14741526 12675
22663857 2635
26747904 12693
26747918 12701
  160019 12680
 2822278 12647
 4168241 11635
 8962566 12668
14741524 12654
15468257 12647
17714231 12675
26747913 12680
26747925 12701
  975973 12647
 2775234 12686
 4168956 12668
11419453 12675
12952418 12675
24726185 12654
24726195 12654
26088562 12668
26747903 12691
 3694419 12668
 4326703 12701
11785470 12675
16804299 12686
20689533 11675
20702757 12675
 1562012 12686
 3795123 12668
10677256 12675
10677257 12675
12658672 12701
12658755 13697
15065654 12668
20689530 11675
26747916 12691
  973282 12668
  974062 12675
 3365247 12675
10677259 12675
11083976 12647
17467911 12654
24187545 12701
24532378 12675
 1731896 12647
 4923111 11635
11083978 12675
16945843 12647
16945847 12647
20702744 12668
20702751 12654
24187518 12675
24187523 12701
31363503 12668
  973185 12668
 1870004 12675
 3364720 12680
 3876675 12668
11005344 12654
31942878 12698
 1274458 12647
 8048948 12694
20702742 12675
20702760 12668
20702762 12668
24016148 12701
26747927 12680
31363514 12668
 1561554 12680
 4009899 12691
 8680479 12647
16945840 12647
22829356 12647
24187515 12701
24187522 12701
31942877 12698
 3369350 12680
 4128453 13698
 9214199 12647
20702763 12675
  970938 12647
 1277676 12654
 1600379 12675
 3694420 12647
 3694421 12647
10548478 12680
12658753 12694
13899598 12668
20702745 12668
20702750 12654
30109552 12647
  972433 12668
 8402773 12680
12658750 12680
12658751 12694
13428609 11675
13582155 12675
14818122 12647
20702743 12668
22829355 12647
26568987 12647
31486525 1647
 1693871 12647
 4168166 12675
10642725 12698
13899590 12668
17713483 12686
21840647 12691
29870024 11635
30109557 12680
 1274456 12647
 1276930 11647
 4168237 12675
 4945239 12704
12658752 12680
14321154 12668
14567726 12668
20702749 12647
26027387 12691
29593954 12679
 3364721 12675
 4128448 12635
 4211416 12686
29618134 12647
32273366 11635
 1215767 12664
 2218771 12693
 3086900 12654
 3364831 12675
 8680480 12654
20702752 12654
20702753 12654
23459148 11635
24976371 12668
 1211088 12647
11772869 11635
30109556 12647
31363502 12668
 2822279 12680
 6450807 12654
10965481 12668
12829252 12668
16945846 12668
20702754 12675
20702759 12675
31363501 12668
31363511 12679
32730914 12691
20521671 2647
31942875 12675
  200769 12647
 9357452 12658
12020750 12647
12736395 12647
20702756 12675
20702761 12675
26860677 2614
31363505 11635
31363515 12668
  113695 12654
 1211101 12647
 1340347 12668
 3694417 12693
 4945238 12701
 8402772 12686
 9587930 12668
15065012 12668
19617813 12654
31363513 12679
 1202846 12647
 1202847 12647
 1274460 12668
 3365250 12680
 3474800 12680
10085286 12647
14030759 12647
26747932 11635
30109553 12647
30109555 12675
32552240 11635
  159814 12675
  972622 12668
 1202855 12647
 1528453 12647
 3014830 12701
 4127647 12691
 4168232 12691
 4905350 12701
17918402 12704
26863062 2635
30109554 12668
  112596 11635
  218139 12647
 1997064 12691
 2014389 12635
 4168227 12675
 5170061 12691
11002652 12668
12658757 12675
12752602 12691
14670636 12668
18119109 12686
20702747 12647
20702748 12647
  126234 11635
  161219 12668
 3354953 12647
 4128450 12675
 4128457 12647
17556887 12706
26859481 2635
  163787 12654
 3266788 12647
 4168187 12675
 7609422 12694
10642728 12647
11814059 12675
13899592 12668
13899599 12668
17918403 12708
26445326 12691
26860781 2635
31151204 2647
31800909 12698
  146336 12666
 1202850 12647
 4168202 12675
 4168231 12675
 5342172 12668
 8048949 12691
10883498 12686
12098873 12686
22050534 12691
26239563 12668
26747931 12706
31942876 12647
  974622 12668
 1739396 12647
10883499 12635
26860572 2635
 8402769 12691
11001886 12647
12952420 12647
15048109 12658
21803900 12697
24363882 12647
 1478628 11635
 1739412 12683
 7599336 12691
11599840 12647
26852140 12668
26860775 2635
26860777 2635
26860779 2635
31800905 12701
31800906 12706
31942873 12698
32891648 2635
 1547430 12675
 2947781 12698
 7609421 12691
13859337 12686
18114772 12686
18119111 12686
26852136 12675
26859482 2635
26860571 2635
26860774 2635
29575583 2635
31375508 1635
32891647 2635
32891649 2635
  158162 12664
  162319 12647
 4168233 12675
 4168234 12647
 7609424 12691
10865627 12691
10883490 12686
12658760 12658
18035741 12693
18119110 12686
22002202 12654
26860778 2635
31800904 12698
 1318897 11635
 2561214 11635
 4128452 12647
11352412 12647
18035744 12698
18035747 12698
19848912 11635
22552930 12701
26049281 12668
26860780 2635
27331283 2614
 2822267 12647
 3365222 12686
 8962565 12647
13578668 11680
18035745 12693
26445328 12675
26859315 2635
26860776 2635
30036765 2635
31375503 2635
32150213 1635
32150214 1635
 1875518 12668
 2947538 12698
 4334405 12635
11791712 12647
12658691 12679
13707034 12668
18119115 12668
 1806080 11635
11354169 12647
12658758 12647
13369659 12647
17514629 12686
18119114 12668
  167888 12686
 1561398 12647
 2561213 12647
 8977547 12654
10921348 12647
11001885 12647
11496638 12647
12452177 11647
13866926 12647
18119113 12668
26445327 12647
26864340 2635
 1556584 12647
 2202465 11635
 8213125 11635
10921325 12635
11496581 12647
11789641 12647
16135878 12675
17926512 12658
18114775 12686
20702755 12675
26445325 11635
26859112 2635
26859314 2635
26859520 2635
 2201062 12658
 3365251 12675
11842749 12675
12424435 12668
13467789 11635
16135873 12675
16135880 12679
17147730 12668
18642672 12647
24190369 12675
24990212 12675
26749409 12647
26950499 12686
34015324 2635
  110003 11668
  110938 11635
  931954 12668
  974619 12635
 1739416 12668
 1826405 12647
 2201064 12658
 2202464 12647
 2311372 12658
 2378237 12668
11306087 12668
11306089 12668
11306097 12647
12808048 12635
12884489 12668
15035606 12635
24532401 12635
26859622 2614
26860603 2635
31151206 2647
  162870 12668
 1561557 11635
 2202471 12668
 2202479 11647
 2311376 12654
 3914170 12691
 4168950 12668
 4168962 12647
 4540527 12668
11306090 12668
11306100 12647
16135874 12675
17702093 12635
18119112 12647
24532402 12635
24998054 12668
26852137 12691
26852138 12686
26859317 2635
  967280 12647
  976686 12635
 1527398 11635
 1739415 12647
 1829380 12675
 1978954 12647
 2014385 12635
 2202480 12647
 3014835 12691
 9214609 12647
11280219 12647
11306091 11635
11306092 12647
11306096 11635
11774579 12647
12952241 12675
13786589 12647
13788625 12647
13846497 12635
14015870 12675
16135871 12647
16135877 12675
16135879 12675
21130512 12686
26852139 12686
26859144 2635
26859311 2635
27079731 12668
24187530 12698
  167003 11635
  972621 12647
  976609 12647
  977211 12668
 1739417 12668
 1804179 11635
 1826408 12647
 3515173 11647
 4031350 12647
10883492 12675
10883495 12668
11306094 11635
11791337 12647
12711710 12635
13788626 12647
15370023 11635
16135869 12675
16135870 12675
16620217 12647
16620218 12647
16620219 12647
16620220 12647
16620221 12647
17713484 12686
22589000 11654
25282135 12647
26859312 2635
26859316 2635
26859498 2614
26860585 2614
26863148 2635
34015323 2635
  167016 12647
  976408 12668
  976605 12635
 1186302 11635
 1331207 11668
 1438430 12668
 3847509 12668
 4011165 11675
 9327448 12635
11306076 11635
11306093 11635
11791855 12647
12792996 12647
16135876 12675
21632268 12668
24959658 12675
24959659 12675
25330122 12647
25914360 12686
26747900 12714
26852135 11668
26852141 12668
26859533 2614
26860057 2635
26950501 12675
31098881 2635
31098882 2635
32414945 12647
26747907 12708
  118215 11635
  200768 12647
  976592 12647
 1077491 11635
 1077493 11635
 1438428 12668
 1438433 12668
 1685812 11635
 1739401 12668
 1804129 12635
 2495568 12679
 2660798 12635
 3014900 12668
 4168228 12647
13369977 12647
21624799 12668
21624800 12668
25290060 12635
26859313 2635
26859621 2614
26860634 2635
26860664 2614
31098880 2614
34115901 11635
24187541 12698
26747901 12714
15048095 12675
  156180 11635
  171846 12635
  973773 12635
  974063 11635
  975735 11635
 1981381 12635
 2201180 12635
 2583902 12635
 2771372 12635
 3680046 12635
13369961 12647
13369962 11635
13369976 12647
13369978 12647
13369979 12647
13663216 12635
19879810 11635
22368444 12635
24993752 12635
24993753 12635
24993754 12635
24993755 12635
24993756 12647
24993757 12647
26859515 2614
26859534 2614
26859989 2635
29768932 2635
31222102 1614
35699472 2635
23067759 12654
  126233 11635
  158467 11635
  352199 12647
  899248 12647
  931953 11635
  932023 11635
  972462 12635
  972728 12668
  973109 12635
  976604 12635
 1545280 12635
 2014393 11635
 2760119 11614
 3680040 12635
 3680047 12635
 4031348 12635
 4305110 12668
 4305117 12668
 4305122 12668
11954915 11635
12458607 11635
12711641 12635
12711644 12635
12711706 12635
12711731 12635
12711732 12635
12711771 12635
13369972 11635
13687572 12635
13694702 11647
14633502 12647
15864810 12635
16083402 12635
16549309 11635
16760635 11635
18824748 12635
19320706 12647
19361455 12635
20702758 12647
22878083 11635
22878102 11635
22878103 11635
25282136 12647
25290059 12635
25290061 12635
26027394 12635
26283673 12675
26859866 2614
30473668 11635
31053139 12635
31731679 2614
32029587 12635
34215492 11635
14285695 12668
24187516 12701
31128397 11686
  160405 12635
  166950 11635
  167889 11635
  973184 12635
  974054 11635
 1128004 12635
 1202853 12635
 1211090 12635
 1561556 11635
 1685815 12635
 1693877 11635
 2561215 12647
 2781519 12635
 3036249 12635
 3944010 12635
 4030729 12635
 4030730 12635
 4305118 12668
 4306206 12635
 5204393 11668
 8830552 12668
11083977 12647
11582908 12635
11772681 12635
11791711 12635
13568289 12635
13846487 12635
13846489 12635
13846490 12635
13846491 12635
13846492 12635
13846494 12635
13846496 12635
13846499 12635
14872180 12635
15864698 12635
16230688 12691
16549287 12635
16549318 12635
16549338 12635
16549451 12635
16549472 12635
16549615 11635
16552002 12647
16552004 12647
17291625 12635
17828807 11635
18510942 12635
18622890 12647
19305642 11635
19320682 11635
19320695 12635
19320696 12635
19320699 12635
19320701 12635
19320702 12635
19320707 12635
20509470 12635
20511903 12635
24892282 12635
25563961 11679
25563966 12635
25563970 12635
26283672 12635
26510526 12635
26694848 12635
26726208 11635
26848109 12647
26860118 2635
30009505 11635
30344621 2635
30344622 2635
30944310 11635
31053138 12635
31640619 12635
31825364 12635
32008799 11635
32029580 12635
32029581 12635
32029589 12635
32224913 12635
35699473 2635
36901814 2635
12829264 12647
22552929 12683
31800911 12691
  156179 11647
  158475 11635
  160444 11635
  160445 12635
  161224 11635
  164222 11635
  975952 12635
  988944 11635
  988962 12635
 1202849 12635
 1211097 12635
 1274461 12635
 1438437 11635
 1545277 12635
 1545278 12635
 1545281 12635
 1687745 11635
 1804145 12635
 1965708 11635
 1989682 11635
 2311374 12647
 3014829 11635
 4305112 12635
 8830543 12635
10585917 11635
10585922 11635
11582907 12635
11773489 12635
11829317 11647
16537724 12635
16549335 12635
16549506 12635
17147737 11647
18668316 12635
18862924 12635
19320697 12635
19320698 12635
19714317 12635
19745509 12635
20664272 12635
22681265 11635
24892284 12635
25563962 11635
25563963 12635
26283678 12635
26747935 11635
26860012 2657
30344620 2635
31053127 12635
31053128 12635
31053129 12635
31053132 12635
31053133 12635
31053134 12635
31583349 12635
31825359 12635
31825362 12635
35134941 11635
  161226 12668
31800910 12698
31800908 12698
31800907 12698
35469364 12654
  970506 12635
 1330781 11635
 1710882 12635
 1997391 12635
 3685392 12691
 9588114 11635
11582900 12635
11582902 12635
11772683 12635
11772911 12635
11773540 12635
12755863 12635
14087690 12635

The index definition:

source default
{
   type = mysql

   sql_host = xx.xx.xx.xx
   sql_user = xxxxx
   sql_pass = xxxxx
   sql_db = xxxxx
   sql_port = 3306

   sql_query_pre = SET NAMES utf8
   sql_query_pre = SET group_concat_max_len = 1000000
   mysql_connect_flags = 32
}

source index1 : default
{
   sql_query = xxxxx

   sql_attr_uint = sekceId
   sql_attr_uint = pocetObchodu
   sql_attr_float = cenaOd
   sql_attr_float = cena
   sql_attr_uint = pocetKliku
   sql_attr_uint = rank
   sql_attr_float = prumer

   sql_query_info = xxxxx
}

index default_index
{
   source = default_index
   path = /home/sphinx/sphinx-default_index

   docinfo = extern
   mlock = 0

   morphology = none
   stopwords =
   wordforms =
   min_word_len = 1
   charset_type = utf-8
   charset_table = 0..9, A..Z->a..z, _, a..z, U+0e1->a, U+0c1->a, U+10d->c, U+10c->c, U+10f->d, \
                        U+10e->d, U+0e9->e, U+0c9->e, U+11b->e, U+11a->e, U+0ed->i, U+0cd->i, U+148->n, \
                        U+147->n, U+0f3->o, U+0d3->o, U+159->r, U+158->r, U+161->s, U+160->s, U+165->t, \
                        U+164->t, U+0fa->u, U+0da->u, U+16f->u, U+16e->u, U+0fd->y, U+0dd->y, U+17e->z, \
                        U+17d->z, U+0c4->a, U+0e4->a, U+13e->l, U+13d->l, U+139->l, U+13a->l, U+0d4->o, \
                        U+0f4->o, U+154->r, U+155->r, U+0fc->u, U+0dc->u, U+0f6->o, U+0d6->o, U+0e1->a, \
                        U+0c1->a, U+0e4->a, U+0c4->a, U+10d->c, U+10c->c, U+10f->d, U+10e->d, U+0e9->e, \
                        U+0c9->e, U+0ed->i, U+0cd->i, U+13e->l, U+13d->l, U+13a->l, U+139->l, U+148->n, \
                        U+147->n, U+0f3->o, U+0d3->o, U+0f4->o, U+0d4->o, U+155->r, U+154->r, U+161->s, \
                        U+160->s, U+165->t, U+164->t, U+0fa->u, U+0da->u, U+0fd->y, U+0dd->y, U+17e->z, \
                        U+17d->z \

   min_prefix_len = 0
   enable_star = 0
   html_strip = 0
   min_infix_len = 0
}

index index1 : default_index
{
   source = index1
   path = /home/sphinx/sphinx-index1
}


The crash log:
111118 14:03:54 - mysqld got signal 11 ;
This could be because you hit a bug. It is also possible that this binary
or one of the libraries it was linked against is corrupt, improperly built,
or misconfigured. This error can also be caused by malfunctioning hardware.
We will try our best to scrape up some info that will hopefully help diagnose
the problem, but since we have already crashed, something is definitely wrong
and this may fail.

key_buffer_size=104857600
read_buffer_size=131072
max_used_connections=4
max_threads=2000
thread_count=3
connection_count=2
It is possible that mysqld could use up to
key_buffer_size + (read_buffer_size + sort_buffer_size)*max_threads = 4478321 K
bytes of memory
Hope that's ok; if not, decrease some variables in the equation.

Thread pointer: 0x40128e70
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
stack_bottom = 0x49cc00e0 thread_stack 0x40000
/usr/sbin/mysqld(my_print_stacktrace+0x39)[0x7ce749]
/usr/sbin/mysqld(handle_segfault+0x379)[0x500de9]
/lib64/libpthread.so.0[0x3bcd80eb10]
/usr/lib64/mysql/plugin/ha_sphinx.so(_ZN9ha_sphinx7ConnectEPKct+0x123)[0x2aaab114d6a3]
/usr/lib64/mysql/plugin/ha_sphinx.so(_ZN9ha_sphinx10ConnectAPIEPKci+0x47)[0x2aaab114d7b7]
/usr/lib64/mysql/plugin/ha_sphinx.so(_ZN9ha_sphinx10index_readEPhPKhj16ha_rkey_function+0x2da)[0x2aaab1152eca]
/usr/sbin/mysqld[0x59d2f0]
/usr/sbin/mysqld(_Z10sub_selectP4JOINP13st_join_tableb+0x66)[0x5a6dd6]
/usr/sbin/mysqld[0x5a9070]
/usr/sbin/mysqld(_ZN4JOIN4execEv+0x12a8)[0x5b8128]
/usr/sbin/mysqld(_Z12mysql_selectP3THDPPP4ItemP10TABLE_LISTjR4ListIS1_ES2_jP8st_orderSB_S2_SB_yP13select_resultP18st_select_lex_unitP13st_select_lex+0x1a9)[0x5b9589]
/usr/sbin/mysqld(_Z13handle_selectP3THDP3LEXP13select_resultm+0x1ce)[0x5b9ede]
/usr/sbin/mysqld[0x57727d]
/usr/sbin/mysqld(_Z21mysql_execute_commandP3THD+0x2505)[0x579c55]
/usr/sbin/mysqld(_Z11mysql_parseP3THDPcjP12Parser_state+0x38c)[0x57dadc]
/usr/sbin/mysqld(_Z16dispatch_command19enum_server_commandP3THDPcj+0x148e)[0x57ef8e]
/usr/sbin/mysqld(_Z10do_commandP3THD+0x106)[0x57f326]
/usr/sbin/mysqld(_Z24do_handle_one_connectionP3THD+0x111)[0x61a0a1]
/usr/sbin/mysqld(handle_one_connection+0x54)[0x61a194]
/lib64/libpthread.so.0[0x3bcd80673d]
/lib64/libc.so.6(clone+0x6d)[0x3bcd0d44bd]

Trying to get some variables.
Some pointers may be invalid and cause the dump to abort.
Query (0x40094c50): SELECT `id`, `weight`
                          FROM `_Sphinx` sph
                         WHERE sph.query = 'vestavna trouba;sort=extended:rank desc;mode=extended2;weights=10,1,100,1;host=searchd_box;limit=1000;index=index1'
Connection ID (thread ID): 7209
Status: NOT_KILLED
(0002090)
vojtech.kurka (reporter)
2011-11-18 14:46

the sphinx table definition:

mysql> show create table _Sphinx\G
*************************** 1. row ***************************
       Table: _Sphinx
Create Table: CREATE TABLE `_Sphinx` (
  `id` bigint(10) unsigned NOT NULL,
  `weight` int(11) NOT NULL,
  `query` varchar(3072) COLLATE utf8_czech_ci NOT NULL,
  `group_id` int(11) DEFAULT NULL,
  `_sph_groupby` int(11) DEFAULT NULL,
  `_sph_count` int(11) DEFAULT NULL,
  KEY `query` (`query`(333))
) ENGINE=SPHINX DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci CONNECTION='sphinx://localhost:3312/' [^]
1 row in set (0.00 sec)
(0002091)
Tomat (manager)
2011-11-18 14:53

Could you drop _Sphinx table then create this one then issue that query via that table
Create Table: CREATE TABLE `_Sphinx` (
...
) ENGINE=SPHINX DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci CONNECTION='sphinx://127.0.0.1:3312/' [^]
(0002092)
vojtech.kurka (reporter)
2011-11-18 15:03

mysql> DROP TABLE `_Sphinx`;
Query OK, 0 rows affected (0.04 sec)

mysql> CREATE TABLE `_Sphinx` (
    -> `id` bigint(10) unsigned NOT NULL,
    -> `weight` int(11) NOT NULL,
    -> `query` varchar(3072) COLLATE utf8_czech_ci NOT NULL,
    -> `group_id` int(11) DEFAULT NULL,
    -> `_sph_groupby` int(11) DEFAULT NULL,
    -> `_sph_count` int(11) DEFAULT NULL,
    -> KEY `query` (`query`(333))
    -> ) ENGINE=SPHINX DEFAULT CHARSET=utf8 COLLATE=utf8_czech_ci CONNECTION='sphinx://127.0.0.1:3312/'; [^]
Query OK, 0 rows affected (0.03 sec)

mysql> SELECT `id`, `weight` FROM `_Sphinx` sph WHERE sph.query = 'vestavna trouba;sort=extended:rank desc;mode=extended2;weights=10,1,100,1;host=searchd_1;limit=10;index=index1';
ERROR 1429 (HY000): Unable to connect to foreign data source: failed to resolve searchd host (name=searchd_1)


So now I enter the search address as IP address instead of the hostname:

mysql> SELECT `id`, `weight` FROM `_Sphinx` sph WHERE sph.query = 'vestavna trouba;sort=extended:rank desc;mode=extended2;weights=10,1,100,1;host=xx.xx.214.72;limit=10;index=index1';
+----------+--------+
| id | weight |
+----------+--------+
| 976558 | 12706 |
| 4128456 | 12701 |
| 15039213 | 12680 |
| 7930740 | 12706 |
| 1914233 | 12704 |
| 4041679 | 12701 |
| 10679300 | 12654 |
| 4168161 | 12704 |
| 13425155 | 12691 |
| 14818109 | 12675 |
+----------+--------+
10 rows in set (0.01 sec)

And it works!
(0002093)
Tomat (manager)
2011-11-18 15:06

Seems that localhost got not well mapped.
(0002094)
vojtech.kurka (reporter)
2011-11-18 15:14

I thought that the host definition in the search query overrides the hostname specified in the create table, so the create table doesn't matter?
(0002095)
Tomat (manager)
2011-11-18 15:15

Could you issue command
ping localhost

Has it return data?
(0002096)
vojtech.kurka (reporter)
2011-11-18 15:17

bash> ping localhost
PING myhost.myhost.cz (127.0.0.1) 56(84) bytes of data.
64 bytes from myhost.myhost.cz (127.0.0.1): icmp_seq=1 ttl=64 time=0.029 ms
.....

Works without problems...
(0002097)
vojtech.kurka (reporter)
2011-11-18 15:24

At least, it seems we have a workaround:
- use '127.0.0.1' in the CREATE TABLE instead of 'localhost'
OR/AND
- specify the searchd host in the query using IP address, never as hostname

I assume the DNS resolve causes the plugin crash.
(0002098)
vojtech.kurka (reporter)
2011-11-18 15:26

One important thing to add:

we have set option "skip-name-resolve" in our mysql config

Maybe it doesn't matter, maybe it does...
(0002099)
vojtech.kurka (reporter)
2011-11-18 15:50
edited on: 2011-11-18 15:53

When I don't use the skip-name-resolve option, restart mysqld and THEN recreate the table using CONNECTION='sphinx://localhost:3312/', [^] mysqld doesn't crash:


mysql> SELECT `id`, `weight` FROM `_Sphinx` sph WHERE sph.query = 'vestavna trouba;sort=extended:rank desc;mode=extended2;weights=10,1,100,1;host=searchd_1;limit=10;index=index_1';
ERROR 1429 (HY000): Unable to connect to foreign data source: failed to resolve searchd host (name=searchd_1).

So the "skip-name-resolve" option does have an effect.

(0002100)
Tomat (manager)
2011-11-18 16:01

>>So the "skip-name-resolve" option does have an effect.

ok, that makes sense, I'll investagete such issues with that option
(0002105)
Tomat (manager)
2011-11-21 09:42

fixed at r3020

- Issue History
Date Modified Username Field Change
2011-11-16 16:56 vojtech.kurka New Issue
2011-11-16 16:56 vojtech.kurka File Added: ha_sphinx.so.gz
2011-11-17 14:07 Tomat Note Added: 0002067
2011-11-17 14:41 vojtech.kurka Note Added: 0002069
2011-11-17 14:52 Tomat Note Added: 0002070
2011-11-18 14:29 vojtech.kurka Note Added: 0002088
2011-11-18 14:45 vojtech.kurka Note Added: 0002089
2011-11-18 14:46 vojtech.kurka Note Added: 0002090
2011-11-18 14:53 Tomat Note Added: 0002091
2011-11-18 15:03 vojtech.kurka Note Added: 0002092
2011-11-18 15:06 Tomat Note Added: 0002093
2011-11-18 15:14 vojtech.kurka Note Added: 0002094
2011-11-18 15:15 Tomat Note Added: 0002095
2011-11-18 15:17 vojtech.kurka Note Added: 0002096
2011-11-18 15:24 vojtech.kurka Note Added: 0002097
2011-11-18 15:26 vojtech.kurka Note Added: 0002098
2011-11-18 15:50 vojtech.kurka Note Added: 0002099
2011-11-18 15:53 vojtech.kurka Note Edited: 0002099 View Revisions
2011-11-18 16:01 Tomat Note Added: 0002100
2011-11-21 09:42 Tomat Note Added: 0002105
2011-11-21 09:42 Tomat Status new => closed
2011-11-21 09:42 Tomat Assigned To => Tomat
2011-11-21 09:42 Tomat Resolution open => fixed
2011-11-21 09:42 Tomat Fixed in Version => 2.0.2-dev


Copyright © 2000 - 2010 MantisBT Group
Powered by Mantis Bugtracker