Zen Cart Logo
Forums / Installing on a Linux/Unix Server / "table doesn't exist" errors after 1.3.7 install

"table doesn't exist" errors after 1.3.7 install

Locked

Views: 8,912

Results 1 to 20 of 32
This thread is locked. New replies are disabled.
28 Mar 2007, 10:11 PM
#1
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

"table doesn't exist" errors after 1.3.7 install

I'm following your Wiki instructions for moving my existing Zencart from one server to another. I have uploaded & installed 1.3.7 to my new server & now when I go to the store to test it before I go to step 3, I get this error:

1146 Table 'bsdzencart.db_cache' doesn't exist
in:
[db_cache table]

After reading some other threads, I tried this fix of pasting this query into MySql on the phpMyAdmin:

DROP TABLE IF EXISTS db_cache;
CREATE TABLE db_cache (
cache_entry_name varchar(64) NOT NULL,
cache_data blob,
cache_entry_created int(15),
PRIMARY KEY (cache_entry_name)
) TYPE=MyISAM;

Now I'm getting this error:
1146 Table 'bsdzencart.configuration' doesn't exist
in:
[db_cache table]

I did a full install of 1.3.7 - NOT an upgrade. It all installed fine, but when I click on the Zen Cart Setup Finished - "Click here to go to store" button, I get the error.

I'm panicking here. Can someone please help me solve this?

28 Mar 2007, 11:04 PM
#2
schoolboy avatar

schoolboy

Totally Zenned

Join Date:
Jun 2005
Location:
Cumbria, UK
Posts:
10,327
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

Looks like you had table prefixes for the dbase on your original, but haven't put them into the instructions for the new install... ???

'bsdzencart.configuration' is different from 'configuration' .

29 Mar 2007, 1:14 AM
#3
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

But this is a brand new, fresh install. Brand new server, brand new Zencart - there's nothing "old" there anymore for it to be referring to.

29 Mar 2007, 4:09 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

Please post the contents of your /includes/configure.php file, after masking the database password.

29 Mar 2007, 4:13 AM
#5
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

<?php
/**
*
* @package Configuration Settings
* @copyright Copyright 2003-2006 Zen Cart Development Team
* @copyright Portions Copyright 2003 osCommerce
* @license http://www.zen-cart.com/license/2_0.txt GNU Public License V2.0
*/


/*************** NOTE: This file is similar, but DIFFERENT from the "admin" version of configure.php. ***********/
/*************** The 2 files should be kept separate and not used to overwrite each other. ***********/

// Define the webserver and path parameters
// HTTP_SERVER is your Main webserver: eg, http://www.yourdomain.com
// HTTPS_SERVER is your Secure webserver: eg, https://www.yourdomain.com
define('HTTP_SERVER', 'http://www.butternugsquash.com');
define('HTTPS_SERVER', 'https://www.butternugsquash.com');

// Use secure webserver for checkout procedure?
define('ENABLE_SSL', 'false');

// NOTE: be sure to leave the trailing '/' at the end of these lines if you make changes!
// * DIR_WS_* = Webserver directories (virtual/URL)
// these paths are relative to top of your webspace ... (ie: under the public_html or httpdocs folder)
define('DIR_WS_CATALOG', '/store/');
define('DIR_WS_HTTPS_CATALOG', '/store/');

define('DIR_WS_IMAGES', 'images/');
define('DIR_WS_INCLUDES', 'includes/');
define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . 'functions/');
define('DIR_WS_CLASSES', DIR_WS_INCLUDES . 'classes/');
define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
define('DIR_WS_DOWNLOAD_PUBLIC', DIR_WS_CATALOG . 'pub/');
define('DIR_WS_TEMPLATES', DIR_WS_INCLUDES . 'templates/');

define('DIR_WS_PHPBB', '/home/maggiesmom1/butternugsquash.com/phpBB/');

// * DIR_FS_* = Filesystem directories (local/physical)
//the following path is a COMPLETE path to your Zen Cart files. eg: /var/www/vhost/accountname/public_html/store/
define('DIR_FS_CATALOG', '/home/maggiesmom1/butternugsquash.com/store/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');
define('DIR_WS_UPLOADS', DIR_WS_IMAGES . 'uploads/');
define('DIR_FS_UPLOADS', DIR_FS_CATALOG . DIR_WS_UPLOADS);
define('DIR_FS_EMAIL_TEMPLATES', DIR_FS_CATALOG . 'email/');

// define our database connection
define('DB_TYPE', 'mysql');
define('DB_PREFIX', '');
define('DB_SERVER', 'mysql.butternugsquash.com');
define('DB_SERVER_USERNAME', 'maggiesmom1');
define('DB_SERVER_PASSWORD', 'XXXXXXX');
define('DB_DATABASE', 'bsdzencart');
define('USE_PCONNECT', 'false'); // use persistent connections?
define('STORE_SESSIONS', 'db'); // use 'db' for best support, or '' for file-based storage

// The next 2 "defines" are for SQL cache support.
// For SQL_CACHE_METHOD, you can select from: none, database, or file
// If you choose "file", then you need to set the DIR_FS_SQL_CACHE to a directory where your apache
// or webserver user has write privileges (chmod 666 or 777). We recommend using the "cache" folder inside the Zen Cart folder
// ie: /path/to/your/webspace/public_html/zen/cache -- leave no trailing slash
define('SQL_CACHE_METHOD', 'database');
define('DIR_FS_SQL_CACHE', '/home/maggiesmom1/butternugsquash.com/store/cache');

?>
29 Mar 2007, 4:51 AM
#6
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

During the database-setup stage, did you get a zillion ~~~~~ marks on the screen, or did it zip past that step pretty quickly? I'm guessing it went very very fast ... faster than normal.

This may sound like a bizarre suggestion, but I think maybe your SQL load isn't happening properly.
Please try re-uploading your /zc_install/sql/mysql_zencart.sql file ... I suspect perhaps it's incomplete and therefore possibly causing this problem.

29 Mar 2007, 12:53 PM
#7
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

Okay - I re-uploaded that particular file & tried re-installing Zencart again. During database setup, there was not a zillion '~~~~~", as you said, and it did go rather quickly - probably a pause of about 5 seconds.

When I get to the "finished" page & click on "Click here to go to store", I get this page:

This Is my store logo. [home link]
The site is currently down for maintenance. Please come back later.
Sorry!
There seems to be a problem connecting to our database. Please give us a few minutes to remedy the problem. Thank you.

To verify the site status ... Click here
0 DB_ERROR_NOT_CONNECTED
in:
[SHOW TABLES like 'phpbb_users']

29 Mar 2007, 7:28 PM
#8
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

maggiesmom1:

0 DB_ERROR_NOT_CONNECTED
in:
[SHOW TABLES like 'phpbb_users']

This means that while Zen Cart is attempting to checkup on your phpBB forum status it's running into problems finding the forum database. This is likely because your forum tables are in your main production database and this separate database doesn't have any forum info.

Edit your /includes/configure.php file and change this:

define('DIR_WS_PHPBB', '/home/maggiesmom1/butternugsquash.com/phpBB/');

to this:```
define('DIR_WS_PHPBB', '');


That should disable Zen Cart from trying to talk to your phpBB area. 
Granted, when you move your live site over, if you wish to retain your forum connectivity, you'll need to address this again at that time.
29 Mar 2007, 11:45 PM
#9
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

Okay - that worked. I've got it installed and I've moved all my files over & restored my database as per the Wiki instructions. Now I'm getting this error:

1146 Table 'bsdzencart.db_cache' doesn't exist
in:
[db_cache table]

I went in through phpMyAdmin and checked the tables - there wasn't a bsdzencart.db_cache, but there was a zen.db_cache. I renamed it to bsdzencart.db_cache, but it still doesn't work.

30 Mar 2007, 5:56 AM
#10
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

  1. In your "old" configure.php files, what was the setting for DB_PREFIX ?
  2. In your "new" configure.php files, what is the setting for DB_PREFIX ?

They need to match.

And, since you're restoring from the old files into the new, you are best advised to use the old prefix in the new setup.

So, since you've installed tables on the new site using "no" prefix, you should go and delete all the new tables, then adjust your new configure.php to use the old prefix, and then restore the database, and then run zc_install and choose database-upgrade.

The wiki article mentions this:> 2. Go to your new host and upload (FTP) a fresh new install using the same version files that you built your other site on. This will make sure that you get the proper settings in your configure.php files. While installing, use the same DB_prefix (table prefix, i.e. zen_ or blank, etc.) as the old site, and allow it to install the demo products, so that you can test and be sure that it's working nicely.

30 Mar 2007, 2:19 PM
#11
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

Okay - I've changed the prefix in my config from nothing to "zen" which is what the prefix is in the restored database. I've followed your instructions to delete the tables, restore teh database & re-run zcinstall choosing the "Upgrade Cfg Files" option, rather than "Install".

When I get to the "Database Setup" page, I kept everything the same:
Host = mysql.butternugsquash.com
Username: maggiesmom1
Password: XXXXXXX
DB Name: bsdzencart
DB Sessions: Yes
Sql Cache: None
Session/SQL Cache directory: /home/maggiesmom1/butternugsquash.com/store/cache

When I click on "Save DB Settings", I get this error:
1146 Table 'bsdzencart.zenconfiguration' doesn't exist
in:
[update zenconfiguration set configuration_value='/home/maggiesmom1/butternugsquash.com/store/cache' where configuration_key='SESSION_WRITE_DIRECTORY']

30 Mar 2007, 2:39 PM
#12
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

was the old prefix "zen" or "zen_" ?

30 Mar 2007, 4:19 PM
#13
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

It was "zen_"

30 Mar 2007, 4:26 PM
#14
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

maggiesmom1:

I've changed the prefix in my config from nothing to "zen" which is what the prefix is in the restored database.

1146 Table 'bsdzencart.zenconfiguration' doesn't exist
in:
[update **zen**configuration set ....

vs

It was "zen_" ... note the underscore.> DrByte:

  1. In your "old" configure.php files, what was the setting for DB_PREFIX ?
  2. In your "new" configure.php files, what is the setting for DB_PREFIX ?

They need to match.

30 Mar 2007, 4:31 PM
#15
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

Do you mean I need to change the "zen" in the config to "zen_", or is there something else I need to do?

30 Mar 2007, 4:41 PM
#16
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

maggiesmom1:

Do you mean I need to change the "zen" in the config to "zen_"

Yes .

30 Mar 2007, 4:45 PM
#17
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

Okay - did that. It's still giving me this:
1146 Table 'bsdzencart.zenconfiguration' doesn't exist
in:
[update zenconfiguration set configuration_value='/home/maggiesmom1/butternugsquash.com/store/cache' where configuration_key='SESSION_WRITE_DIRECTORY']

30 Mar 2007, 4:46 PM
#18
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

You must have changed "zen" to "zen_" in the wrong file, or the uploaded change didn't get saved/uploaded properly.

30 Mar 2007, 4:51 PM
#19
maggiesmom1 avatar

maggiesmom1

New Zenner

Join Date:
Sep 2005
Posts:
49
Plugin Contributions:
0

Re: "table doesn't exist" errors after 1.3.7 install

I changed it in includes/configure.php
I then saved it to my HD, doublechecked it to be sure the change had been made, deleted the original configure.php that's in includes/ and uploaded the one saved to my hard drive.
I then viewed includes/configure.php & it's correct.

30 Mar 2007, 4:56 PM
#20
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
177

Re: "table doesn't exist" errors after 1.3.7 install

What's the setting for HTTP_SERVER and DIR_WS_CATALOG and DIR_FS_CATALOG in that configure.php file ?