Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

My site keeps going down


Guest

Recommended Posts

Posted

I have increased my pay per click campaign with Yahoo Marketing and it seems the increased traffic is causing my site to shut down. I am getting this error:

 

1226 - User 'adironda_osc1' has exceeded the 'max_questions' resource (current value: 50000)

 

select value from sessions where sesskey = '6432e31d6668bc60000ddce066ad5cb6' and expiry > '1165291510'

 

[TEP STOP]

 

 

I think their is something wrong with a script somewhere in my site causing the sessions to exceed the max_questions' resource.

 

Does anyone know how to fix this?

 

vr,

Don

Posted
I have increased my pay per click campaign with Yahoo Marketing and it seems the increased traffic is causing my site to shut down. I am getting this error:

 

1226 - User 'adironda_osc1' has exceeded the 'max_questions' resource (current value: 50000)

 

select value from sessions where sesskey = '6432e31d6668bc60000ddce066ad5cb6' and expiry > '1165291510'

 

[TEP STOP]

I think their is something wrong with a script somewhere in my site causing the sessions to exceed the max_questions' resource.

 

Does anyone know how to fix this?

 

vr,

Don

 

I had a silimar issue. Fixed using the information in this post:

 

http://www.oscommerce.com/forums/index.php?sho...=238191&hl=

 

Hope this helps.

Posted

Hey,

 

Here is a better fix that I just came up with (ok, I kinda stole the idea from espicom at http: //www. phpbb. com/kb/article. php?article_id=371&sid=a5547fbab7cfe9082dd13b9e0a99dd69, but I had to modify it to match up to the osC coding):

 

 

In your database setup panel, add 2 more users and use the same password for them as for your first one. Make sure that when you create your new database usernames, that you give them accessibility to the proper database.

 

Now go to your file manager, and edit ..catalog/includes/configure.php. This is where all of your database login info is stored.

 

*** FYI in this example, name1 is your database username. So in the case of adironda, she would replace name1 with "adironda_osc1". name2, name3, etc are the respective new usernames that you have just created. ***

 

In the area of line 40 you should find the following code:

 

define('DB_SERVER_USERNAME', 'name1');

 

Replace that with:

 

$username = date("i") % 3; // split hour into 3 overlapping sessions

switch ($username)

{

case 0:

$username='name1';

break;

case 1:

$username='name2';

break;

case 2:

$username='name3';

break;

}

define('DB_SERVER_USERNAME', $username);

 

 

essentially what you have just done is made it so that your "current value" of 50000 is now 150000 (50000 per username). If you still need more, just add more usernames to your database, change the "% 3" in the first line to 4, 5, etc... how ever many you now have, and add more case statements with the new names.

 

P.S. I haven't fully tested this for bugs, but it seems to work quite well. Maybe some of you with more coding experience can double check me?

Brian Quinney

Posted
Hey,

 

Here is a better fix that I just came up with (ok, I kinda stole the idea from espicom at http: //www. phpbb. com/kb/article. php?article_id=371&sid=a5547fbab7cfe9082dd13b9e0a99dd69, but I had to modify it to match up to the osC coding):

In your database setup panel, add 2 more users and use the same password for them as for your first one. Make sure that when you create your new database usernames, that you give them accessibility to the proper database.

 

Now go to your file manager, and edit ..catalog/includes/configure.php. This is where all of your database login info is stored.

 

*** FYI in this example, name1 is your database username. So in the case of adironda, she would replace name1 with "adironda_osc1". name2, name3, etc are the respective new usernames that you have just created. ***

 

In the area of line 40 you should find the following code:

 

define('DB_SERVER_USERNAME', 'name1');

 

Replace that with:

 

$username = date("i") % 3; // split hour into 3 overlapping sessions

switch ($username)

{

case 0:

$username='name1';

break;

case 1:

$username='name2';

break;

case 2:

$username='name3';

break;

}

define('DB_SERVER_USERNAME', $username);

essentially what you have just done is made it so that your "current value" of 50000 is now 150000 (50000 per username). If you still need more, just add more usernames to your database, change the "% 3" in the first line to 4, 5, etc... how ever many you now have, and add more case statements with the new names.

 

P.S. I haven't fully tested this for bugs, but it seems to work quite well. Maybe some of you with more coding experience can double check me?

 

Wow, that looks great. I have been dealing with this for quite some time now. My site went down again yesterday because of it.

 

I will try this and let you know how it works :)

 

vr,

Don

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...