Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

My website is leaving connections open on the database


thailandosc

Recommended Posts

My hosting company is threatenting to kick me off because they say my oscommerce script is leaving a "log of open database connections" which is overloading their server.

 

I dont understand this at all can someone advise whats going on here. I dont get many hits maybe 20 visits a day. Someone suggested a search bot or a hacker is opening these connections.

 

My isp "fixed it" several times but being stupid they wont tell me what they did to fix it. When it gets bad it runs VERY slow or i get the "too many connections in database" error.

 

 

How can i a) close all the open connections B) stop bloody search spiders going into it and opening many connecitons if thats whats happening.

 

 

Im about to get kicked from my hosting company...

 

 

I am using oscommerce 2.2 i used 7dana.com ecommerce manager (which is a great template with loads of addons already installed)

 

Thanks

Link to comment
Share on other sites

My hosting company is threatenting to kick me off because they say my oscommerce script is leaving a "log of open database connections" which is overloading their server.

 

I dont understand this at all can someone advise whats going on here. I dont get many hits maybe 20 visits a day. Someone suggested a search bot or a hacker is opening these connections.

 

My isp "fixed it" several times but being stupid they wont tell me what they did to fix it. When it gets bad it runs VERY slow or i get the "too many connections in database" error.

 

 

How can i a) close all the open connections B) stop bloody search spiders going into it and opening many connecitons if thats whats happening.

 

 

Im about to get kicked from my hosting company...

 

 

I am using oscommerce 2.2 i used 7dana.com ecommerce manager (which is a great template with loads of addons already installed)

 

Thanks

Don't know, but maybe try setting both configure.php files

persistent connections to false

Link to comment
Share on other sites

Don't know, but maybe try setting both configure.php files

persistent connections to false

 

 

Yep it was already set persistent connections to fales. Also i left define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

So as its '' then the sessions should be stored to the files in TMP directory not leaving open connections on the server (i think????)

 

 

So both config files are

 

define('USE_PCONNECT', 'false'); // use persisstent connections?

define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

 

So why am i getting open connections in the databse?

 

Thanks

Link to comment
Share on other sites

Yep it was already set persistent connections to fales. Also i left define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

So as its '' then the sessions should be stored to the files in TMP directory not leaving open connections on the server (i think????)

 

 

So both config files are

 

define('USE_PCONNECT', 'false'); // use persisstent connections?

define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

 

So why am i getting open connections in the databse?

 

Thanks

 

 

My sites database has grown from 10mb to 50 mb in a month and ive had less than 100 orders. Is that right?

 

 

Also, when i backup the site using tools, backup its about 12 MB but when i back up using phpmyadmin (adding a drop table) its about 50MB. So why the difference in filesize?

 

How can i see "open connections" or what IP address is opening these connections, thanks

Link to comment
Share on other sites

Have a look in phpmy admin and see which tables are large.

 

Then you look and can decide if it is normal.

Need help installing add ons/contributions, cleaning a hacked site or a bespoke development, check my profile

 

Virus Threat Scanner

My Contributions

Basic install answers.

Click here for Contributions / Add Ons.

UK your site.

Site Move.

Basic design info.

 

For links mentioned in old answers that are no longer here follow this link Useful Threads.

 

If this post was useful, click the Like This button over there ======>>>>>.

Link to comment
Share on other sites

Yep it was already set persistent connections to fales. Also i left define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

So as its '' then the sessions should be stored to the files in TMP directory not leaving open connections on the server (i think????)

 

 

So both config files are

 

define('USE_PCONNECT', 'false'); // use persisstent connections?

define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

 

So why am i getting open connections in the databse?

 

Thanks

I guess your sessions are stored in your db. Try creating a directory for them under catalog, and change both config.php files to reflect the new directory.

Link to comment
Share on other sites

Thanks

 

How do i do this please exactly at the moment its define('STORE_SESSIONS', ''); // leave empty '' for default handler or set to 'mysql'

 

so the sesions are NOT going to sql but are going to "" whereever that it

 

Cheers

You could make a directory called "whatever" where your catalog files are and set

define('STORE_SESSIONS', 'whatever'); // leave empty '' for default handler or set to 'mysql'

 

and see if that helps. If it doesn't, undo the changes.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...