Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

MAJOR ISSUE WITH OSC


metricbikes

Recommended Posts

I am having a very hard time with OSC. I am using a shared hosting account and several times a day it knocks OSC offline because 'user exceeds max questions = 50000'.

 

The flaw with OSC is that in configure.php you can only have one user to access the database through. All customers coming in go through the user set up in configure.php. If you have enough people online at the same time it triggers the max questions = 50000'. We do have a high volume site but this is crazy.

 

Is there a mod/fix to this problem where configure.php will vary what user the customers piggy-back on to get access to php data? That way you could set up 10 users that would have 50k queries and each customer coming online would get the next user name to access data through.

 

This is a show stopper for OSC unless it can be fixed. It limits the use to small stores.

 

Any help would be appreciated.

 

Steve

Link to comment
Share on other sites

I am having a very hard time with OSC. I am using a shared hosting account and several times a day it knocks OSC offline because 'user exceeds max questions = 50000'.

 

The flaw with OSC is that in configure.php you can only have one user to access the database through. All customers coming in go through the user set up in configure.php. If you have enough people online at the same time it triggers the max questions = 50000'. We do have a high volume site but this is crazy.

 

Is there a mod/fix to this problem where configure.php will vary what user the customers piggy-back on to get access to php data? That way you could set up 10 users that would have 50k queries and each customer coming online would get the next user name to access data through.

 

This is a show stopper for OSC unless it can be fixed. It limits the use to small stores.

 

Any help would be appreciated.

 

Steve

 

I believe your shared hosting account limits your use to a small shop.

Treasurer MFC

Link to comment
Share on other sites

Can anyone help with some php that each time a user accesses through include/configure.php they would get one of ten set up user names to access data through? I am thinking something like writing an incremental code that increments from 1 to 10 then back to 1. Each time someone accesses php through configure.php they get the user based upon the value of the incremental variable. Just have the number go from 1 to 10 and back to 1 to increment again.

 

Is this possible?

 

Thanks in advance.

 

Steve

Link to comment
Share on other sites

Yes - but how many osc installations are on dedicated servers? I bet most on on shared hosting platforms and don't have their own server??

 

Steve

 

ok, why not set up 2 database user accounts and make a change in configure.php like :

 

$user_num = rand(0,1);

if ($user_num == 0) {

define('DB_SERVER_USERNAME', 'user1');

define('DB_SERVER_PASSWORD', 'password1');

} else {

define('DB_SERVER_USERNAME', 'user2');

define('DB_SERVER_PASSWORD', 'password2');

}

 

that should randomly select either database account and ofcourse you could add as many as you like.

Treasurer MFC

Link to comment
Share on other sites

That is it! Thanks. This will work. I am going to add it now!

 

Thanks again. I will probably use about 20 user names so I can get 20 * 50000 queries within a 60 minute time frame through the shared user account.

 

Steve

 

ok, why not set up 2 database user accounts and make a change in configure.php like :

 

  $user_num = rand(0,1);

  if ($user_num == 0) {

    define('DB_SERVER_USERNAME', 'user1');

    define('DB_SERVER_PASSWORD', 'password1');

  } else {

    define('DB_SERVER_USERNAME', 'user2');

    define('DB_SERVER_PASSWORD', 'password2');

  }

 

that should randomly select either database account and ofcourse you could add as many as you like.

Link to comment
Share on other sites

Do you know what permissions a customer would need compared to admin? I assume they only need to insert permissions? The options are:

 

select, insert, update, delete, create, drop, index, alter, select all

 

Steve

 

That is it! Thanks. This will work. I am going to add it now!

 

Thanks again. I will probably use about 20 user names so I can get 20 * 50000 queries within a 60 minute time frame through the shared user account.

 

Steve

Link to comment
Share on other sites

I have used the random user code and works. I've configured 4 db users (2 random for main and 2 random for admin)

 

I want to check if this reduce my database load times... because I have oscommerce installed on a dedicated server (PIV dual server with 1Gb Ram) but the mysql overloads the processor.

 

I love to use the test and error method... :P

Link to comment
Share on other sites

Do you know what permissions a customer would need compared to admin? I assume they only need to insert permissions? The options are:

 

select, insert, update, delete, create, drop, index, alter, select all

 

Steve

 

for normal users on the DB select, insert, update and delete will suffice.

Treasurer MFC

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...