'No InnoDB Support Enabled' in 5.5

Bug #828611 reported by Anatoliy Dobrosynets
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
MySQL Tuning Primer Script
Fix Released
Critical
TodoInTX

Bug Description

hi,
iit iseems it does not recognize innodb enabled for some reason.
I'm using version is 1.6-r1, released on on 2011-08-06

See,
# ./tuning-primer.sh innodb
        -- MYSQL PERFORMANCE TUNING PRIMER --
             - By: Matthew Montgomery -

MySQL Version 5.5.14-55-log i686

Uptime = 0 days 0 hrs 12 min 2 sec
Avg. qps = 0
Total Questions = 15
Threads Connected = 1

Warning: Server has not been running for at least 48hrs.
It may not be safe to use these recommendations

To find out more information on how each of these
runtime variables effects performance visit:
http://dev.mysql.com/doc/refman/5.5/en/server-system-variables.html
Visit http://www.mysql.com/products/enterprise/advisors.html
for info about MySQL's Enterprise Monitoring and Advisory Service

No InnoDB Support Enabled!
----

, and when I run it with sh -x , I can see:

...
+ check_innodb_status
+ '[' 050514 -lt 50603 ']'
+ mysql_variable ''\''have_innodb'\''' have_innodb
++ mysql -Bse 'show /*!50000 global */ variables like '\''have_innodb'\'''
++ awk '{ print $2 }'
+ local variable=YES
+ export have_innodb=YES
+ have_innodb=YES
+ '[' 050514 -lt 50500 ']'
+ '[' 050514 -ge 50500 ']'
+ '[' 050514 -lt 50512 ']'
+ '[' 050514 -ge 50600 ']'
+ '[' '' = 1 ']'
+ cecho 'No InnoDB Support Enabled!' boldred
+ local 'default_msg=No message passed.'
+ message='No InnoDB Support Enabled!'

----

My environment:

# mysql -Bse 'show /*!50000 global */ variables like '\''have_innodb'\'''
have_innodb YES

# mysql -Bse 'select version()'
5.5.14-55-log

# cat /etc/redhat-release
CentOS release 5.6 (Final)

TodoInTX (matt-day32)
Changed in mysql-tuning-primer:
status: New → Fix Committed
importance: Undecided → Critical
assignee: nobody → TodoInTX (matt-day32)
Revision history for this message
TodoInTX (matt-day32) wrote :

Please grab revision 27

Revision history for this message
Anatoliy Dobrosynets (anatolijd) wrote :

Hi,
it still does not work for me.

# /bin/sh tuning-primer.sh innodb
tuning-primer.sh: line 1266: syntax error near unexpected token `elif'
tuning-primer.sh: line 1266: ` elif [ "$mysql_version_num" -ge 050600 ] && [ "$mysql_version_num" -lt 050603 ] ; then'

I've looked into it, and found typo-mistake there ('if' instead of closing 'fi'):

$ diff tuning-primer.sh tuning-primer.sh.update
1259c1259
< elif [ "$major_version" -eq '5.5'] && [ "$mysql_version_num" -ge 050512 ] ; then
---
> elif [ "$major_version" -eq '5.5' ] && [ "$mysql_version_num" -ge 050512 ] ; then
1265c1265
< if
---
> fi
1279c1279
< if
---
> fi

----

Though, even patched, script still doesn't work correct :

# /bin/sh tuning-primer.sh.update innodb
        -- MYSQL PERFORMANCE TUNING PRIMER --
             - By: Matthew Montgomery -

MySQL Version 5.5.14-55-log i686

Uptime = 0 days 0 hrs 29 min 13 sec
Avg. qps = 0
Total Questions = 1172
Threads Connected = 1

Warning: Server has not been running for at least 48hrs.
It may not be safe to use these recommendations

To find out more information on how each of these
runtime variables effects performance visit:
http://dev.mysql.com/doc/refman/5.5/en/server-system-variables.html
Visit http://www.mysql.com/products/enterprise/advisors.html
for info about MySQL's Enterprise Monitoring and Advisory Service

tuning-primer.sh.2: line 1259: [: 5.5: integer expression expected
tuning-primer.sh.2: line 1273: [: 5.5: integer expression expected
No InnoDB Support Enabled!
----

, and when I run it with sh -x , I can see:

+ check_innodb_status
+ '[' 050514 -lt 050603 ']'
+ mysql_variable ''\''have_innodb'\''' have_innodb
++ mysql -Bse 'show /*!50000 global */ variables like '\''have_innodb'\'''
++ awk '{ print $2 }'
+ local variable=YES
+ export have_innodb=YES
+ have_innodb=YES
+ '[' 050514 -lt 050500 ']'
+ '[' 050514 -ge 050500 ']'
+ '[' 050514 -lt 050512 ']'
+ '[' 5.5 -eq 5.5 ']'
tuning-primer.sh.2: line 1259: [: 5.5: integer expression expected
+ '[' 050514 -ge 050600 ']'
+ '[' 5.5 -eq 5.6 ']'
tuning-primer.sh.2: line 1273: [: 5.5: integer expression expected
+ '[' '' = 1 ']'
+ cecho 'No InnoDB Support Enabled!' boldred
+ local 'default_msg=No message passed.'
+ message='No InnoDB Support Enabled!'
+ color=boldred
+ case $color in
+ printf '\033[1;31m'
+ printf '%s\n' 'No InnoDB Support Enabled!'
No InnoDB Support Enabled!
+ tput sgr0
+ printf '\033[0m'
+ return
+ echo

My environment is the same as above,
$ echo $SHELL
/bin/bash

Revision history for this message
Jynxster (jynxster) wrote :

patched to fix your latest revision:

1259c1259
< elif [ "$major_version" -eq '5.5'] && [ "$mysql_version_num" -ge 050512 ] ; then
---
> elif [ "$major_version" = '5.5' ] && [ "$mysql_version_num" -ge 050512 ] ; then
1265c1265
< if
---
> fi
1273c1273
< elif [ "$major_version" -eq '5.6' ] && [ "$mysql_version_num" -ge 050603 ] ; then
---
> elif [ "$major_version" = '5.6' ] && [ "$mysql_version_num" -ge 050603 ] ; then
1279c1279
< if
---
> fi
1634a1635
>

Revision history for this message
Anatoliy Dobrosynets (anatolijd) wrote :

Thank you.
Now it works perfect.

Revision history for this message
TodoInTX (matt-day32) wrote :

Patches from jynxster are applied and pushed to rev no. 28

Changed in mysql-tuning-primer:
status: Fix Committed → Fix Released
Revision history for this message
TodoInTX (matt-day32) wrote :

1.6-r1 download file is replaced with rev. 28

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.