close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Every time when I use PowerCMS I get this error, "MySQL server has gone away".

Thread began 2/01/2016 1:20 pm by vacuum | Last modified 2/04/2016 4:29 pm by Ray Borduin | 2665 views | 17 replies |

vacuum

Every time when I use PowerCMS I get this error, "MySQL server has gone away".

Every time when I use PowerCMS I get this error, "MySQL server has gone away".

Warning: mysql_pconnect(): MySQL server has gone away in D:\xampp\htdocs\website\Connections\PowerCMSConnection.php on line 9

$PowerCMSConnection = mysql_pconnect($hostname_PowerCMSConnection, $username_PowerCMSConnection, $password_PowerCMSConnection) or trigger_error(mysql_error(),E_USER_ERROR);
?>

Same issue on another computer.

Sign in to reply to this post

Ray BorduinWebAssist

This is an error associated with your MySQL installation on your local server. I see information about it here:

http://dev.mysql.com/doc/refman/5.7/en/gone-away.html

You may want to make sure MySQL is installed properly and running. Are you able to connect with phpMyAdmin?

Sign in to reply to this post
Did this help? Tips are appreciated...

vacuum

Yes everything works fine.

I only get this error when I connect PowerCMS to a external hosted SQL database.

When I connect PowerCMS to a localhost, there is no poblem at all.

Sign in to reply to this post

Ray BorduinWebAssist

Then contact your hosting provider to look into the issue for you. It appears to be a server configuration issue on their side.

Sign in to reply to this post
Did this help? Tips are appreciated...

vacuum

This error is pointing to PowerCMSConnection.php on a local computer, while I am using an external database.

The D: disk is on the same local computer.

Warning: mysql_pconnect(): MySQL server has gone away in D:\xampp\htdocs\website\Connections\PowerCMSConnection.php on line 9

$PowerCMSConnection = mysql_pconnect($hostname_PowerCMSConnection, $username_PowerCMSConnection, $password_PowerCMSConnection) or trigger_error(mysql_error(),E_USER_ERROR);
?>

So when I open the website on this local computer I am getting this error.
The error is not on the external hosted version of this website.

Sign in to reply to this post

Ray BorduinWebAssist

It is possible that the remote database won't allow a connection from your local server. I'd contact your hosting provider to see if that is possible and what settings to use if it is. Usually it is not possible to do that, which is why people set up a local database for testing locally.

Sign in to reply to this post
Did this help? Tips are appreciated...

vacuum

I also use a localhost normally, but with PowerCMS it is so much easier to start with a remote database.

It is possible at the hosting company I use, see attached image.

So as you can see, the remote CMS database content is available in the local dreamweaver website. Only, it looks like PowerCMS is looking for a localhost by default while there is only a remote database. D:\xampp\htdocs, is the location of phpadmin local.

Warning: mysql_pconnect(): MySQL server has gone away in D:\xampp\htdocs\website\Connections\PowerCMSConnection.php on line 9

<?php
# FileName="Connection_php_mysql.htm"
# Type="MYSQL"
# HTTP="true"
$hostname_PowerCMSConnection = "www.url.nl";
$database_PowerCMSConnection = "left out";
$username_PowerCMSConnection = "left out";
$password_PowerCMSConnection = "left out";
$PowerCMSConnection = mysql_pconnect($hostname_PowerCMSConnection, $username_PowerCMSConnection, $password_PowerCMSConnection) or trigger_error(mysql_error(),E_USER_ERROR);
?>

Sign in to reply to this post

Ray BorduinWebAssist

A database server would almost never start with "www."

Contact your hosting provider and find out if it allows remote connections and what to use as the hostname. Dreamweaver can connect to it because it actually sends a file to your remote server and gets the content from the remote server and doesn't use the local files to connect to the database.

Sign in to reply to this post
Did this help? Tips are appreciated...

vacuum

Yes it does, it is the same as the IP address.
Also tried the IP address, but the error is the same.

Sign in to reply to this post

Ray BorduinWebAssist

Do you have a program like navicat or SQLYog you can use to test the connection? The database will usually have a separate ip address from the web site.

When you contact your hosting provider, don't mention the error you get from our file. That gives them the cop out they are using.

Instead just ask for the proper credentials to connect to the database remotely using a program like Navicat or SQLYog. The same credentials should work in your connection file.

I'd even download an evaluation copy of one of them to test the information outside of your local web server to verify it is correct.

Sign in to reply to this post
Did this help? Tips are appreciated...
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...