Forums / General Questions / Too many queries were running? -- a bug?

Too many queries were running? -- a bug?

Locked

Views: 1,698

Results 1 to 7 of 7
This thread is locked. New replies are disabled.
17 Nov 2006, 5:57 PM
#1
doubletiger avatar

doubletiger

Zen Follower

Join Date:
Apr 2005
Posts:
199
Plugin Contributions:
0

Too many queries were running? -- a bug?

Hi,

My zen cart site is version 1.3.5.

Recently, there is an issue with database, which website cannot load products and images.

My host said. "There were about 50 queries running, the same query was running about 30 times. It's very strange - perhaps there is a bug in Zencart which is causing it not to work with the database properly".

At the time my host refered to, it was only about 5 vistors and might opened about 20 connections (pages) maximum.

So how did these 50 queries come from and why it keep running? Is it a bug? or it is my host did not configure it properly?

here are queries my host refered to:

"There are lots of MySQL queries happening again:

2187403 chines00 localhost chines00_s 312 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2187150 chines00 localhost chines00_s 354 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2187093 chines00 localhost chines00_s 367 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2187000 chines00 localhost chines00_s 384 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2186988 chines00 localhost chines00_s 387 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2186920 chines00 localhost chines00_s 404 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2186242 chines00 localhost chines00_s 523 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2185969 chines00 localhost chines00_s 560 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2185761 chines00 localhost chines00_s 586 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'
2185670 chines00 localhost chines00_s 600 Query delete from
dt_db_cache where cache_entry_name =
'zc_d38797dcf3d115b1928659d3089e0d3d'

There are lots more than this - but most are the same query, some are just
'Query delete from dt_db_cache' and there are also a few trying to do the
opposite to the delete: 'Query select * from dt_db_cache where
cache_entry_name = 'zc_d38797dcf3d115b1928659d3089e0d3d'"

Can someone please help? it has caused my site went down twice in 2 days. It seems it will cause further problem if I did not sort it out.

Also, does anyone know how to clearing the cache? I hope clear the cache will help database running.

thank you in advance!

17 Nov 2006, 8:01 PM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Too many queries were running? -- a bug?

Sounds like your hosting site is strictly limiting what you can do on your site ... :cry:

You may wish to click on the Hosting link at the top of your screen and find a hosting site that is properly setup to handle e-commerce, php and MySQL vs running under such limitations that will have your site down more often than not ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

17 Nov 2006, 8:16 PM
#3
doubletiger avatar

doubletiger

Zen Follower

Join Date:
Apr 2005
Posts:
199
Plugin Contributions:
0

Re: Too many queries were running? -- a bug?

Ajeh:

Sounds like your hosting site is strictly limiting what you can do on your site ... :cry:

You may wish to click on the Hosting link at the top of your screen and find a hosting site that is properly setup to handle e-commerce, php and MySQL vs running under such limitations that will have your site down more often than not ...

Ajeh,

thank you for your reply!

Could you explain more in details? what restrictions do you think my host has been in place?

thanks!

17 Nov 2006, 8:26 PM
#4
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Too many queries were running? -- a bug?

Limits that say ...

1 you cannot do this

2 you can only do this

3 you may never do this

4 you are limited to this

5 break any rule above and we shut your site down

Those kind of limits ...

There are all kinds of limitations on sites to do with server load, memory, queries, etc.

Many sites not setup to properly handle e-commerce or php or MySQL will have these limits extreamly low so as to prevent sites from being more than an HTML site ...

php/MySQL uses a lot of memory and resources ... and hosting sites actually have to "work" to manage the servers properly for them ...

work = less profits

work = less sites per server = less profits

Those hosting sites that we have listed understand your needs and address them specifically for running a shop ...

You are in business to make money ... not worry about all the limitations imposed on your site by your hostings company ... :lamo:

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

17 Nov 2006, 9:06 PM
#5
doubletiger avatar

doubletiger

Zen Follower

Join Date:
Apr 2005
Posts:
199
Plugin Contributions:
0

Re: Too many queries were running? -- a bug?

Hi, Ajeh

thank you for pointing this out! It is time for switching!

by the way, if I want to clear the cache, how do I do it? is it just empty db_cache table? I have never done it before.

many thanks!

17 Nov 2006, 9:35 PM
#6
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: Too many queries were running? -- a bug?

If you store in the database, my preference, just empty the table db_cache ...

I would also clear:
sessions
whos_online

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

17 Nov 2006, 9:53 PM
#7
doubletiger avatar

doubletiger

Zen Follower

Join Date:
Apr 2005
Posts:
199
Plugin Contributions:
0

Re: Too many queries were running? -- a bug?

Ajeh:

If you store in the database, my preference, just empty the table db_cache ...

I would also clear:
sessions
whos_online

Yes, I store in the database. Will also empty other two tables.

many thanks for your help!