FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » FUDforum » FUDforum Installation Issues » 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist
Show: Today's Messages :: Polls :: Message Navigator
Switch to threaded view of this topic Create a new topic Submit Reply
1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20249] Tue, 05 October 2004 03:04 Go to next message
ajeffco   United States
Messages: 21
Registered: March 2002
Location: Orlando, Fl
Karma: 0
Junior Member

Hello,

On a fresh install of 2.6.6 on FC2, I am getting the following errors:

----

(/path/to/forum/index.php:116
/path/to/forum/index.php:178
/path/to/forum/theme/default/index.php:159
/path/to/forum/index.php:1148
) 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist
Query: SELECT count(*) FROM fud26_pmsg WHERE duser_id=2 AND fldr=1 AND read_stamp=0
Server Version: 3.23.58

----

I poked around the db, and there is no table named fud26_pmsg. Under the $forumdata/sql directory, I see a fud_pmsg.tbl file, which I am assuming should have created the fud26_pmsg table.

How do I run that tbl file to create the table, if that is the fix?

*EDIT* If I do a refresh, sometimes the page will come up that it was trying to get to. Sometimes, it does not come up, and that error continues to pop up.

Thanks,

Al Jeffcoat

[Updated on: Tue, 05 October 2004 03:21]

Report message to a moderator

Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20255 is a reply to message #20249] Tue, 05 October 2004 15:20 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
go into the sql/ directory and pipe the following to mysql
sed -e 's/{SQL_TABLE_PREFIX}/fud26_/g' fud_pmsg.tbl

This will create the missing table.


FUDforum Core Developer
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20256 is a reply to message #20255] Tue, 05 October 2004 15:36 Go to previous messageGo to next message
ajeffco   United States
Messages: 21
Registered: March 2002
Location: Orlando, Fl
Karma: 0
Junior Member

That seems to have done the trick, thanks very much.

Out of curiosity, is there a way to tell if there are any other tables that might be needed that did not get created?

This happened across two installs, I thought I had made a mistake on the first one, and so blew everything away, and re-installed.
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20257 is a reply to message #20256] Tue, 05 October 2004 15:48 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
That's very unusual, could you please tell me what are the file permissions of all the files inside the sql/ directory?

The only way this problem could've occured is if the installer was unable to find/access the .tbl defenition files. Since you have the file, then the problem is likely a permissions issue, which is rather strange since the installer created those files in an aerlier step.

Also, when you are checking permissions take a look @ the owner/group of the files and please tell me which version of PHP are you using and in what SAPI.

Thanks.



FUDforum Core Developer
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20258 is a reply to message #20257] Tue, 05 October 2004 15:58 Go to previous messageGo to next message
ajeffco   United States
Messages: 21
Registered: March 2002
Location: Orlando, Fl
Karma: 0
Junior Member

The permissions on all the files are 600, owned by apache:apache.

The PHP version is 4.3.8.

Don't know how to determine the SAPI. phpinfo() has a sapi_apache2 on it, but don't know if this is what you need or not.


Al

Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20261 is a reply to message #20258] Tue, 05 October 2004 16:09 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
Please put the following script inside the forum's main or adm/ directory, run it and let me know what output do you get.

<?php
require "./GLOBALS.php";
$sql_dir = $GLOBALS['$DATA_DIR'] . 'sql/';
if (!(
$d = opendir($sql_dir))) {
        exit(
'ERROR: failed to open SQL table definition directory, "'.$sql_dir.'"');
}
$sql_dir .= '/';
readdir($d); readdir($d);
while (
$f = readdir($d)) {
switch (
strrchr($f, '.')) {
case
'.tbl':
$tbl[] = $sql_dir . $f;
break;
case
'.sql':                                  
$sql[] = $sql_dir . $f;                       
break;
}
}
closedir($d);
var_dump($sql, $tbl);
?>


FUDforum Core Developer
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20262 is a reply to message #20261] Tue, 05 October 2004 16:15 Go to previous messageGo to next message
ajeffco   United States
Messages: 21
Registered: March 2002
Location: Orlando, Fl
Karma: 0
Junior Member

That returns a blank page.

I also got an error on a fud26_search table, but haven't dug into it yet.
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20263 is a reply to message #20262] Tue, 05 October 2004 16:20 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
did you put in the same dir as GLOBALS.php file?

FUDforum Core Developer
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20268 is a reply to message #20263] Tue, 05 October 2004 20:33 Go to previous messageGo to next message
ajeffco   United States
Messages: 21
Registered: March 2002
Location: Orlando, Fl
Karma: 0
Junior Member

Duh...

Ok, here's the output

ERROR: failed to open SQL table definition directory, "sql/"...

Apache is the owner of the data directory, and all the files within it.
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20270 is a reply to message #20268] Tue, 05 October 2004 20:46 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
oops made a typo, please change
$GLOBALS['$DATA_DIR']
to
$GLOBALS['DATA_DIR']


FUDforum Core Developer
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20272 is a reply to message #20270] Tue, 05 October 2004 21:22 Go to previous messageGo to next message
ajeffco   United States
Messages: 21
Registered: March 2002
Location: Orlando, Fl
Karma: 0
Junior Member

ok, new output

array(Cool { [0]=> string(42) "/srv/www/aixinfo.forum/sql//def_smiley.sql" [1]=> string(42) "/srv/www/aixinfo.forum/sql//def_levels.sql" [2]=> string(40) "/srv/www/aixinfo.forum/sql//def_mime.sql" [3]=> string(39) "/srv/www/aixinfo.forum/sql//def_cat.sql" [4]=> string(41) "/srv/www/aixinfo.forum/sql//def_forum.sql" [5]=> string(40) "/srv/www/aixinfo.forum/sql//def_tags.sql" [6]=> string(47) "/srv/www/aixinfo.forum/sql//def_stats_cache.sql" [7]=> string(41) "/srv/www/aixinfo.forum/sql//def_users.sql" } array(47) { [0]=> string(44) "/srv/www/aixinfo.forum/sql//fud_poll_opt.tbl" [1]=> string(39) "/srv/www/aixinfo.forum/sql//fud_cat.tbl" [2]=> string(43) "/srv/www/aixinfo.forum/sql//fud_mod_que.tbl" [3]=> string(50) "/srv/www/aixinfo.forum/sql//fud_poll_opt_track.tbl" [4]=> string(47) "/srv/www/aixinfo.forum/sql//fud_email_block.tbl" [5]=> string(44) "/srv/www/aixinfo.forum/sql//fud_ip_block.tbl" [6]=> string(39) "/srv/www/aixinfo.forum/sql//fud_msg.tbl" [7]=> string(49) "/srv/www/aixinfo.forum/sql//fud_thread_notify.tbl" [8]=> string(46) "/srv/www/aixinfo.forum/sql//fud_forum_read.tbl" [9]=> string(42) "/srv/www/aixinfo.forum/sql//fud_attach.tbl" [10]=> string(50) "/srv/www/aixinfo.forum/sql//fud_blocked_logins.tbl" [11]=> string(47) "/srv/www/aixinfo.forum/sql//fud_title_index.tbl" [12]=> string(41) "/srv/www/aixinfo.forum/sql//fud_forum.tbl" [13]=> string(43) "/srv/www/aixinfo.forum/sql//fud_fc_view.tbl" [14]=> string(48) "/srv/www/aixinfo.forum/sql//fud_search_cache.tbl" [15]=> string(47) "/srv/www/aixinfo.forum/sql//fud_custom_tags.tbl" [16]=> string(39) "/srv/www/aixinfo.forum/sql//fud_ses.tbl" [17]=> string(42) "/srv/www/aixinfo.forum/sql//fud_thread.tbl" [18]=> string(51) "/srv/www/aixinfo.forum/sql//fud_group_resources.tbl" [19]=> string(42) "/srv/www/aixinfo.forum/sql//fud_smiley.tbl" [20]=> string(42) "/srv/www/aixinfo.forum/sql//fud_groups.tbl" [21]=> string(53) "/srv/www/aixinfo.forum/sql//fud_thread_rate_track.tbl" [22]=> string(40) "/srv/www/aixinfo.forum/sql//fud_nntp.tbl" [23]=> string(42) "/srv/www/aixinfo.forum/sql//fud_themes.tbl" [24]=> string(40) "/srv/www/aixinfo.forum/sql//fud_poll.tbl" [25]=> string(47) "/srv/www/aixinfo.forum/sql//fud_group_cache.tbl" [26]=> string(39) "/srv/www/aixinfo.forum/sql//fud_mod.tbl" [27]=> string(49) "/srv/www/aixinfo.forum/sql//fud_group_members.tbl" [28]=> string(41) "/srv/www/aixinfo.forum/sql//fud_users.tbl" [29]=> string(41) "/srv/www/aixinfo.forum/sql//fud_mlist.tbl" [30]=> string(47) "/srv/www/aixinfo.forum/sql//fud_thread_view.tbl" [31]=> string(41) "/srv/www/aixinfo.forum/sql//fud_index.tbl" [32]=> string(44) "/srv/www/aixinfo.forum/sql//fud_announce.tbl" [33]=> string(47) "/srv/www/aixinfo.forum/sql//fud_user_ignore.tbl" [34]=> string(41) "/srv/www/aixinfo.forum/sql//fud_level.tbl" [35]=> string(46) "/srv/www/aixinfo.forum/sql//fud_ann_forums.tbl" [36]=> string(48) "/srv/www/aixinfo.forum/sql//fud_forum_notify.tbl" [37]=> string(45) "/srv/www/aixinfo.forum/sql//fud_ext_block.tbl" [38]=> string(48) "/srv/www/aixinfo.forum/sql//fud_thr_exchange.tbl" [39]=> string(43) "/srv/www/aixinfo.forum/sql//fud_replace.tbl" [40]=> string(40) "/srv/www/aixinfo.forum/sql//fud_mime.tbl" [41]=> string(47) "/srv/www/aixinfo.forum/sql//fud_stats_cache.tbl" [42]=> string(40) "/srv/www/aixinfo.forum/sql//fud_read.tbl" [43]=> string(41) "/srv/www/aixinfo.forum/sql//fud_buddy.tbl" [44]=> string(46) "/srv/www/aixinfo.forum/sql//fud_action_log.tbl" [45]=> string(46) "/srv/www/aixinfo.forum/sql//fud_msg_report.tbl" [46]=> string(42) "/srv/www/aixinfo.forum/sql//fud_avatar.tbl" }

I was missing the search tbl also, I added it with the same method as the pmesg tbl.

[Updated on: Tue, 05 October 2004 22:47]

Report message to a moderator

Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20277 is a reply to message #20272] Tue, 05 October 2004 23:11 Go to previous messageGo to next message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
It seems that a number of tables cannot be found by this code, while they are definately being found on my dev boxes. Would it be possible to get access to the ftp/ssh account where the forum is installed, so I can test the situation further. If so, send me the details via a private message.

FUDforum Core Developer
Re: 1146: Table 'dbname_fudforum.fud26_pmsg' doesn't exist [message #20287 is a reply to message #20277] Wed, 06 October 2004 17:23 Go to previous message
Ilia is currently offline  Ilia   Canada
Messages: 13241
Registered: January 2002
Karma: 0
Senior Member
Administrator
Core Developer
The problem that is the cause of this has been found and fixed.

I will be released 2.6.7RC2 in a day or two that will contain fixes for this problem.

The fix to your problem would be to download the new upgrade script and run it on your forum, it should re-create any missing tables.


FUDforum Core Developer
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Please help, step 2 of 5 - Database Settings
Next Topic: After Forum Database import, all Forum accounts locked
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sat Nov 16 03:26:45 GMT 2024

Total time taken to generate the page: 0.02457 seconds