Error in DB RIS Query

Installing and configuring Tera-WURFL on your server.

Error in DB RIS Query

Postby kamermans » Wed Mar 10, 2010 8:52 pm

These are the two most common DB RIS Query errors:

Error in DB RIS Query: PROCEDURE TeraWurfl_RIS does not exist
This happens when the database user doesn't have the CREATE PROCEDURE and DROP PROCEDURE permissions. The procedures are recreated whenever the database is reloaded.
Code: Select all
Fatal error: Uncaught exception 'Exception' with message 'Error in DB RIS Query: PROCEDURE TeraWurfl_RIS does not exist. Query: CALL TeraWurfl_RIS('BlackBerry8830/4.2.2 Profile/MIDP-2.0 Configuration/CLDC-1.1 VendorID/104',14,'BlackBerry') ' in /var/www/html/DatabaseConnectors/TeraWurflDatabase_MySQL5.php:103
Stack trace:
#0 /var/www/html/UserAgentMatchers/UserAgentMatcher.php(63): TeraWurflDatabase_MySQL5->getDeviceFromUA_RIS('BlackBerry8830/...', 14, Object(BlackBerryUserAgentMatcher))
#1 /var/www/html/UserAgentMatchers/BlackBerryUserAgentMatcher.php(28): UserAgentMatcher->risMatch('BlackBerry8830/...', 14)
#2 /var/www/html/TeraWurfl.php(96): BlackBerryUserAgentMatcher->applyConclusiveMatch('BlackBerry8830/...')
#3 /var/www/html/TeraWurfl.php(202): TeraWurfl->getDeviceIDFromUALoose('BlackBerry8830/...')
#4 /var/www/html/DatabaseConnectors/TeraWurflDatabase_MySQL5.php(357): TeraWurfl->getDeviceCapabilitiesFromAgent('BlackBerry8830/...')
#5 /var/www/html/TeraWurflLoader.php(104): TeraWurflDatabase_My in /var/www/html/DatabaseConnectors/TeraWurflDatabase_MySQL5.php on line 103


Error in DB RIS Query: Thread stack overrun
This is caused by MySQL not having enough memory to complete the query. According to MySQL's website:
When the thread stack is too small, this limits the complexity of the SQL statements which the server can handle, the recursion depth of stored procedures, and other memory-consuming actions. To set a stack size of N bytes for each thread, start the server with --thread_stack=N

http://dev.mysql.com/doc/refman/5.0/en/server-system-variables.html#sysvar_thread_stack
The default thread_stack on MySQL 4 was 64k, MySQL 5.0: 128k and MySQL >= 5.1: 192k (32bit) / 256k (64bit). If you are getting this error, check your thread_stack in my.cnf and increase it to 256k if it is less than that. If you can't change this variable, either upgrade MySQL to >= 5.1 or change your DatabaseConnector in TeraWurflConfig.php to "MySQL4" so the Stored Procedures are not used.

Code: Select all
Fatal error: Uncaught exception 'Exception' with message 'Error in DB RIS Query: Thread stack overrun: 5224 bytes used of a 131072 byte stack, and 128000 bytes needed. Use 'mysqld -O thread_stack=#' to specify a bigger stack.. Query: CALL TeraWurfl_RIS('SonyEricssonK700i/R2AC SEMC-Browser/4.0.2 Profile/MIDP-2.0 Configuration/CLDC-1.1',16,'SonyEricsson') ' in /var/www/html/Tera-Wurfl/DatabaseConnectors/TeraWurflDatabase_MySQL5.php:103
Stack trace:
#0 /var/www/html/Tera-Wurfl/UserAgentMatchers/UserAgentMatcher.php(63): TeraWurflDatabase_MySQL5->getDeviceFromUA_RIS('SonyEricssonK70...', 16, Object(SonyEricssonUserAgentMatcher))
#1 /var/www/html/Tera-Wurfl/UserAgentMatchers/SonyEricssonUserAgentMatcher.php(30): UserAgentMatcher->risMatch('SonyEricssonK70...', 16)
#2 /var/www/html/Tera-Wurfl/TeraWurfl.php(96): SonyEricssonUserAgentMatcher->applyConclusiveMatch('SonyEricssonK70.. in /var/www/html/Tera-Wurfl/DatabaseConnectors/TeraWurflDatabase_MySQL5.phpon line 103
Thanks,

Steve Kamerman
Tera-WURFL Author
COO of ScientiaMobile

IMPORTANT ANNOUNCEMENT! Tera-WURFL and WURFL have joined forces! We have launched ScientiaMobile to provide commercial support for our device detection solutions.

Tera-WURFL.com | Device Explorer
kamermans
Site Admin
 
Posts: 323
Joined: Wed Mar 10, 2010 12:06 pm
Location: Fort Worth, TX

Return to Installation / Configuration

Who is online

Users browsing this forum: No registered users and 1 guest

cron