Gossamer Forum
Home : Products : Gossamer Forum : Discussion :

Database error

Quote Reply
Database error
My forum has the following error. Please help



A fatal error has occurred:
Can't call method "fetchrow_hashref" on an undefined value at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 441.


Please enable debugging in setup for more details.
Quote Reply
Re: [bgkhoo] Database error In reply to
Please turn on debugging and print out what $GT::SQL::error says..

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Database error In reply to
This is the lastes error

A fatal error has occurred:
Can't call method "fetchrow" on an undefined value at GForum::Category::_calc_new line 345.


Please enable debugging in setup for more details.
Quote Reply
Re: [Alex] Database error In reply to
A fatal error has occurred:
GT::Session::SQL (23365): Failed to execute query: 'SELECT * FROM gforum_Session WHERE ( session_id = ? AND session_date > ? ) ' Reason: Got error 134 from table handler at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 418.


Please enable debugging in setup for more details.Stack Trace======================================GForum (23365): GT::Base::error called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Session/SQL.pm line 138 with arguments (GT::Session::SQL=HASH(0x83920b4), Failed to execute query: 'SELECT * FROM gforum_Session WHERE ( session_id = ? AND session_date > ? ) ' Reason: Got error 134 from table handler).GForum (23365): GT::Session::SQL::load called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Session/SQL.pm line 73 with arguments (GT::Session::SQL=HASH(0x83920b4), 037d105aa147c0418e1626b917084bce).GForum (23365): GT::Session::SQL::new called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 418 with arguments (GT::Session::SQL, 037d105aa147c0418e1626b917084bce, GT::SQL::Table=HASH(0x8392030)).GForum (23365): GForum::Authenticate::auth_valid_session called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 40 with no arguments.GForum (23365): GForum::Authenticate::__ANON__ called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Plugins.pm line 92 with no arguments.GForum (23365): GT::Plugins::dispatch called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 40 with arguments (GT::Plugins, /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/Plugins/GForum, auth_valid_session, CODE(0x823a428)).GForum (23365): GForum::Authenticate::auth called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum.pm line 544 with arguments (valid_session).GForum (23365): GForum::_plg_authenticate called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Plugins.pm line 92 with no arguments.GForum (23365): GT::Plugins::dispatch called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum.pm line 507 with arguments (GT::Plugins, /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/Plugins/GForum, authenticate, CODE(0x829d64c)).GForum (23365): GForum::authenticate called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 80 with no arguments.GForum (23365): main::main called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Plugins.pm line 92 with no arguments.GForum (23365): GT::Plugins::dispatch called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 22 with arguments (GT::Plugins, /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/Plugins/GForum, main, CODE(0x8329830)).System Information======================================Perl Version: v5.00503Gossamer Forum Version: 1.2.0GForum.pm version: 1.128GT::SQL Version: 1.099GT::Template Version: 2.094DBI.pm Version: 1.20@INC = /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin /usr/local/lib/perl5/5.00503/i386-freebsd /usr/local/lib/perl5/5.00503 /usr/local/lib/site_perl /usr/local/lib/site_perl .GT::SQL::error = Failed to execute query: 'SELECT * FROM gforum_Session WHERE ( session_id = ? AND session_date > ? ) ' Reason: Got error 134 from table handlerCGI Cookies======================================gforum_1001621777_remember => dd5c397c8f03f49acfdc70153d1be57egpp1000_1001621777_remember => ad093ada4350b1b9728ef8410185bf03gpp3000_1001621777_remember => d9fa6674573ba844b367ad0b0973cf8bgpp3000_1001621777_session => 037d105aa147c0418e1626b917084bcegpp6000_1001621777_remember => 5f24393bf522a2f2be01daf1cdfa05c5gpp_1001621777_remember => c082490039513c28777bb097f31d0b55puppy_1001621777_remember => 7c1da1f05d336f05c8ab6e04b259a839ENVIRONMENT======================================DOCUMENT_ROOT => /usr/local/etc/httpd/vhosts/puppyGATEWAY_INTERFACE => CGI/1.1GT_TMPDIR => /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/tmpHTTP_ACCEPT => */*HTTP_ACCEPT_ENCODING => gzip, deflateHTTP_ACCEPT_LANGUAGE => msHTTP_CONNECTION => Keep-AliveHTTP_COOKIE => gpp3000_1001621777_session=037d105aa147c0418e1626b917084bce; gforum_1001621777_remember=dd5c397c8f03f49acfdc70153d1be57e; puppy_1001621777_remember=7c1da1f05d336f05c8ab6e04b259a839; gpp_1001621777_remember=c082490039513c28777bb097f31d0b55; gpp1000_1001621777_remember=ad093ada4350b1b9728ef8410185bf03; gpp3000_1001621777_remember=d9fa6674573ba844b367ad0b0973cf8b; gpp6000_1001621777_remember=5f24393bf522a2f2be01daf1cdfa05c5HTTP_HOST => www.puppy.com.myHTTP_USER_AGENT => Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.0; DigExt; YComp 5.0.2.5)PATH => /bin:/usr/bin:/usr/ucb:/usr/bsd:/usr/local/binQUERY_STRING => REMOTE_ADDR => 219.94.60.241REMOTE_PORT => 4721REQUEST_METHOD => GETREQUEST_URI => /cgi-bin/forum/gforum.cgiSCRIPT_FILENAME => /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgiSCRIPT_NAME => /cgi-bin/forum/gforum.cgiSERVER_ADDR => 128.121.216.40SERVER_ADMIN => webmaster@hileytech.comSERVER_NAME => www.puppy.com.mySERVER_PORT => 80SERVER_PROTOCOL => HTTP/1.1SERVER_SIGNATURE => SERVER_SOFTWARE => Apache/1.3.27 OpenSSL/0.9.6i (Unix) mod_perl/1.21 PHP/4.1.2 PHP/3.0.18-i18n-ja-2USER => hiley6
Quote Reply
Re: [bgkhoo] Database error In reply to
Quote:
[root@gossamer root]# perror 134
Error code 134: Unknown error 134
134 = Record was already deleted (or record file crashed)
[root@gossamer root]#

Looks like the table is broken, try typing:

REPAIR TABLE gforum_Session;

from SQL Monitor.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Database error In reply to
Latest error

A fatal error has occurred:
Can't call method "fetchrow" on an undefined value at GForum::Authenticate::auth_create_session line 551.


Please enable debugging in setup for more details.
Quote Reply
Re: [bgkhoo] Database error In reply to
Hi,

When you see those errors, you need to turn on debugging and look at what $GT::SQL::error says. Most likely your server got hard rebooted and a lot of your mysql tables are now corrupt. I'd recommend doing a:

SHOW TABLES;

and then for each table do a:

REPAIR TABLE tablename;

to make sure no other tables have errors.

Cheers,

Alex
--
Gossamer Threads Inc.
Quote Reply
Re: [Alex] Database error In reply to
A fatal error has occurred:
GT::Session::SQL (49220): Failed to execute query: 'INSERT INTO gforum_Session (session_id,session_date,session_data,session_user_id) VALUES (?,?,?,?)' Reason: Got error 127 from table handler at GForum::Authenticate::auth_create_session line 563.


Please enable debugging in setup for more details.Stack Trace======================================GForum (49220): GT::Base::error called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Session/SQL.pm line 212 with arguments (GT::Session::SQL=HASH(0x83b5b40), Failed to execute query: 'INSERT INTO gforum_Session (session_id,session_date,session_data,session_user_id) VALUES (?,?,?,?)' Reason: Got error 127 from table handler).GForum (49220): GT::Session::SQL::save called at GForum::Authenticate::auth_create_session line 563 with arguments (GT::Session::SQL=HASH(0x83b5b40)).GForum (49220): GForum::Authenticate::auth_create_session called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 40 with no arguments.GForum (49220): GForum::Authenticate::__ANON__ called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Plugins.pm line 92 with no arguments.GForum (49220): GT::Plugins::dispatch called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Authenticate.pm line 40 with arguments (GT::Plugins, /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/Plugins/GForum, auth_create_session, CODE(0x849e848)).GForum (49220): GForum::Authenticate::auth called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum.pm line 529 with arguments (create_session).GForum (49220): GForum::_plg_authenticate called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Plugins.pm line 92 with no arguments.GForum (49220): GT::Plugins::dispatch called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum.pm line 507 with arguments (GT::Plugins, /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/Plugins/GForum, authenticate, CODE(0x829d664)).GForum (49220): GForum::authenticate called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 80 with no arguments.GForum (49220): main::main called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Plugins.pm line 92 with no arguments.GForum (49220): GT::Plugins::dispatch called at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 22 with arguments (GT::Plugins, /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/Plugins/GForum, main, CODE(0x8329848)).System Information======================================Perl Version: v5.00503Gossamer Forum Version: 1.2.0GForum.pm version: 1.128GT::SQL Version: 1.099GT::Template Version: 2.094DBI.pm Version: 1.20@INC = /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin /usr/local/lib/perl5/5.00503/i386-freebsd /usr/local/lib/perl5/5.00503 /usr/local/lib/site_perl /usr/local/lib/site_perl .GT::SQL::error = Failed to execute query: 'INSERT INTO gforum_Session (session_id,session_date,session_data,session_user_id) VALUES (?,?,?,?)' Reason: Got error 127 from table handlerCGI INPUT======================================guest => 381574login_password => login_username => remember_me => 1url => http://www.puppy.com.my/cgi-bin/forum/gforum.cgi?login_attempt=1&CGI Cookies======================================gpp1000_1001621777_remember => c5f28e4b459bb63b18e3d7acd18b3cbcgpp212000_1001621777_remember => 5b505d14ed613232789950f60a96d9f2gpp212000_1001621777_session => b2cab4d84f20644adf43bd1f592e828dgpp_1001621777_remember => 1d486d36b050d7705800c23c736be70bquery_1 => REPAIR TABLE PostNew;query_2 => REPAIR TABLE gforum_Post New;query_3 => REPAIR TABLE gforum_Session;query_4 => REPAIR TABLE gforum_Category_Tree;query_5 => REPAIR TABLE gforum_CustomDict;
Post deleted by bgkhoo In reply to
Quote Reply
Re: [Alex] Database error In reply to
Managed to solve quite a numbe of error.

Now we have category that allow attachment has the following problem'

A fatal error has occurred:
Can't call method "fetchrow_hashref" on an undefined value at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Post.pm line 516.


Please enable debugging in setup for more details.

I am not able to turn debug on (4) and it will show Internal Server Error when I tried to click the link to see that page.

I have also checked the server log file and found that we have the following error message.

GT::SQL::Driver::MYSQL (64084): Creating GT::SQL::Driver::MYSQL::sth object at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/SQL/Driver/MYSQL.pm line 38.
GT::SQL::Driver::MYSQL::sth (64084): OBJECT CREATED at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/SQL/Driver.pm line 569.
Out of memory!
GT::SQL::Driver::MYSQL::sth (64084): OBJECT DESTROYED at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/SQL/Driver.pm line 701.
GT::SQL::Driver::MYSQL::sth (64084): OBJECT DESTROYED at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/SQL/Driver.pm line 701.
GT::SQL::Driver::MYSQL::sth (64084): OBJECT DESTROYED at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/SQL/Driver.pm line 701.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8551d14) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x889bfa8) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x889b8cc) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8586d8c) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x85cd180) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8666adc) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8639848) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8649e88) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x83b8eb8) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8218670) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL::Driver::MYSQL (64084): Destroyed GT::SQL::Driver::MYSQL=HASH(0x8386e28) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
GT::SQL (64084): Destroyed GT::SQL=HASH(0x83af430) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
[Sat Jul 12 00:56:22 2003] [error] [client 211.24.7.244] Premature end of script headers: /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/gforum.cgi
[Sat Jul 12 00:56:32 2003] [error] [client 209.237.238.159] File does not exist: /usr/local/etc/httpd/vhosts/olefins/robots.txt
GT::SQL (64197): OBJECT CREATED at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/SQL.pm line 154.
GForum::Config (64197): Saving '/usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Config/Data.pm' at GT::Config::save line 195.
GForum::Config (64197): '/usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Config/Data.pm' saved. at GT::Config::save line 212.
GT::SQL (64197): Destroyed GT::SQL=HASH(0x823a8c4) in package main at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/setup.cgi line 0. at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GT/Base.pm line 91.
Can't call method "fetchrow_hashref" on an undefined value at /usr/local/etc/httpd/vhosts/puppy/cgi-bin/forum/admin/GForum/Post.pm line 516.
[Sat Jul 12 01:06:54 2003] [error] [client 66.159.213.17] File does not exist: /usr/local/etc/httpd/vhosts/puppy/favicon.ico
Quote Reply
Re: [bgkhoo] Database error In reply to
Sigh. As Alex has suggested twice, you need to look at the content of $GT::SQL::error
Quote Reply
Re: [Paul] Database error In reply to
All tables repaired the forum is working well overall.

The only problem left is the Poll. Old Poll show up as usual but new Poll created simply does not show up along with the post. Check log file, there were no error.