Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

2006 - MySQL server has gone away


jarvoid

Recommended Posts

My store was working fine until I installed an SSL cert and dedicated IP. Now when a customer clicks on "Confirm Order" the gateway receives the information with the wrong IP address, but processes the order just fine. Then the customer sees the "2006 - MySQL server has gone away" error. Here's what the gateway receives:

 

yes=Y&

response_mode=simple&

upg_auth=*******&

delimited_fmt_value_delimiter=|&

response_fmt=delimited&

username=**********&

baddress=11714 Summer springs drive&

bphone=2815551212&

target_app=WebCharge_v5.06&

year=2007&

ccname=Jamie K Belinne&

bzip=77584&

bstate=Texas&

bcity=pearland&

delimitedresponse=Y&

ccnumber=****************&

systempath=IGSPRDWEB01&

delimited_fmt_include_fields=true&

clientip=74.220.207.125&

upg_version=version&

trantype=sale&

ordernumber=0&

connection_method=POST&

last_used_response_num=5&

fulltotal=0.80&

bcountry=Array&

pw=ENCRYPTED&

month=09&

include_extra_field_in_response=N&

messageid=214c2a59df224da095a887e244c31294

 

However the "clientip" should be 74.220.204.229. Where is "checkout_process.php" getting the wrong IP address and how can I fix this?

 

Here is the error:

2006 - MySQL server has gone away

 

insert into orders (customers_id, customers_name, customers_company, customers_street_address, customers_suburb, customers_city, customers_postcode, customers_state, customers_country, customers_telephone, customers_email_address, customers_address_format_id, delivery_name, delivery_company, delivery_street_address, delivery_suburb, delivery_city, delivery_postcode, delivery_state, delivery_country, delivery_address_format_id, billing_name, billing_company, billing_street_address, billing_suburb, billing_city, billing_postcode, billing_state, billing_country, billing_address_format_id, payment_method, cc_type, cc_owner, cc_number, cc_expires, date_purchased, orders_status, currency, currency_value) values ('2', 'Jarvis Belinne', '', '11714 Summer springs drive', '', 'pearland', '77584', 'Texas', 'United States', '2815551212', '[email protected]', '2', 'Jarvis Belinne', '', '11714 Summer springs drive', '', 'pearland', '77584', 'Texas', 'United States', '2', 'Jarvis Belinne', '', '11714 Summer springs drive', '', 'pearland', '77584', 'Texas', 'United States', '2', 'Credit Card', '', 'Jamie K Belinne', '****************', '', now(), '1', 'USD', '1.00000000')

 

[TEP STOP]

 

2006 - MySQL server has gone away

 

select count(*) as total from sessions where sesskey = 'c900746a395cf9e85b13b582f7b084fc'

 

[TEP STOP]

 

I've checked both the ./includes/configure.php file and it has the correct domain information:

 

define('HTTP_SERVER', 'http://www.beautyregistration.com'); // eg,
- should not be empty for productive servers

define('HTTPS_SERVER', 'https://www.beautyregistration.com'); // eg,
- should not be empty for productive servers

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

define('HTTP_COOKIE_DOMAIN', 'www.beautyregistration.com');

define('HTTPS_COOKIE_DOMAIN', 'www.beautyregistration.com');

define('HTTP_COOKIE_PATH', '/tx2007/');

define('HTTPS_COOKIE_PATH', '/tx2007/');

define('DIR_WS_HTTP_CATALOG', '/tx2007/');

define('DIR_WS_HTTPS_CATALOG', '/tx2007/');

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

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', 'pub/');

define('DIR_FS_CATALOG', '/home/beautyre/public_html/tx2007/');

define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');

define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');

 

// define our database connection

define('DB_SERVER', 'localhost'); // eg, localhost - should not be empty for productive servers

define('DB_SERVER_USERNAME', '**********');

define('DB_SERVER_PASSWORD', '********');

define('DB_DATABASE', 'beautyre_osc1');

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

define('STORE_SESSIONS', 'mysql');

 

includes/admin:

 

define('HTTP_SERVER', 'http://beautyregistration.com'); // eg,
- should not be empty for productive servers

define('HTTP_CATALOG_SERVER', 'http://beautyregistration.com');

define('HTTPS_CATALOG_SERVER', 'https://beautyregistration.com');

define('ENABLE_SSL_CATALOG', 'false'); // secure webserver for catalog module

define('DIR_FS_DOCUMENT_ROOT', '/home/beautyre/public_html/tx2007/'); // where the pages are located on the server

define('DIR_WS_ADMIN', '/tx2007/admin/'); // absolute path required

define('DIR_FS_ADMIN', '/home/beautyre/public_html/tx2007/admin/'); // absolute pate required

define('DIR_WS_CATALOG', '/tx2007/'); // absolute path required

define('DIR_FS_CATALOG', '/home/beautyre/public_html/tx2007/'); // absolute path required

define('DIR_WS_IMAGES', 'images/');

define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');

define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');

define('DIR_WS_INCLUDES', 'includes/');

define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');

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_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');

define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');

define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');

define('DIR_FS_BACKUP', DIR_FS_ADMIN . 'backups/');

 

// define our database connection

define('DB_SERVER', 'localhost'); // eg, localhost - should not be empty for productive servers

define('DB_SERVER_USERNAME', '******');

define('DB_SERVER_PASSWORD', '******');

define('DB_DATABASE', '*******');

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

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

 

I also checked the php.ini files and have SSL enabled. I spoke with both my hosting service: hostmonster.com and my gateway inovative solutions (IGS) and neither was able to help. There is no way to set a relay response IP or response URL with the gateway. Previous posts also suggest turning off PCONNECT. Mine is already off, I may try truning it On...

 

Thanks for any insight.

 

Jarvis

Link to comment
Share on other sites

When you change a site from Name Based to IP Based it does take time for the various ISP's to update their records of where the domain is now located. It usually takes around 24 hrs but I have known some ISP's to take up to a week.

 

Also, with some payment providers, you have to provide an IP Address - did you have to do that with yours?

 

Did you previous provide a shared SSL address to your payment provider?

 

Vger

Link to comment
Share on other sites

When you change a site from Name Based to IP Based it does take time for the various ISP's to update their records of where the domain is now located. It usually takes around 24 hrs but I have known some ISP's to take up to a week.

The DNS updates was the first thing I thought of, however it has been more than a week now. :-(

 

Also, with some payment providers, you have to provide an IP Address - did you have to do that with yours?

I provide IP addresses to the gateway only so they will accept access from that IP. The information the gateway receives is what the shopping cart is passing to the gateway (above with the clientIP=wrong IP. So the wrong IP is getting generated on the shoping cart server side not the gateway side.

 

They are also receiving the country as "Array", however this doesn't stop payments from being processed and I can figure that out later. Howeve whenthe the gateway replies the customer see the "2006 - MySQL..." error, I believe because the gateway is responding to that wrong IP. There is no way on the gateway side to set response IP as there is with some other gateways.

 

I'm trying to figure out how the information passed to the gateway is generated and where the wrong IP address is coming from.

 

Did you previous provide a shared SSL address to your payment provider?

 

Vger

No, however when I installed the OS store originally it was on the shared server (wrong IP). I'm thinking there must be a file somewhere which still has this IP address in it. I can not find any though :-(

 

Thanks for your suggestions. Keep them coming. PLEASE... :->

Jarvis

Link to comment
Share on other sites

The server may still have an old dns cache somewhere - so if it is your own dedicated server you'd need to look for it and remove it, or force an update.

 

No good with Windoze servers - sorry!

 

Vger

Link to comment
Share on other sites

The server may still have an old dns cache somewhere - so if it is your own dedicated server you'd need to look for it and remove it, or force an update.

 

No good with Windoze servers - sorry!

 

Vger

 

My hosting services has already forced a DNS update.

 

My store is hosted on a unix system with Hostmonster. The gateway is Innovative Gateway Solutions. What made you think I was on a windoze server..?

Link to comment
Share on other sites

  • 1 month later...

I finally got this working by re-installing OS Commerce, connecting to the same database, and removing the "BuySafe" code. BTW I would not recommend using BuySafe. It does absolutely nothing for the customer or the merchant. I'm on Hostmonster and using the Innovative Gateway Solutions module.

 

Regards,

Jarvis

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...