Can't Access A Remote (Tch) Mysql Database
Posted 19 August 2010 - 04:08 PM
Via cpanel, I've enabled the TCH-based reseller database for "%" access.
I'm developing on a Mac Snow Leopard system -- PHP 5.3.
The same user/password works fine for my PHP code running in production mode on the TCH website and also on my Mac development system. But I get "OK packet 6 bytes shorter than expected" when I try to access the remote TCH database from my Mac, using the same user/password combo.
Web comments suggest software mismatch, but I have no control of the TCH system. phpinfo() hasn't made the problem clear.
Can anybody help? I'm trying to let a client with multiple websites use a single instance of his database, instead of replicating it across all his websites.
I realize "localhost" is the easy solution, since all my client's websites are on the same TCH reseller account. But my client is growing and will need multiple distinct websites in the future, probably on dedicated servers.
Thanks for your consideration,
PS: My sympathies to the TCH support crew. It seems "regression testing" is just a mild embarassment now to the developers of PHP, and all bets are off now that Oracle owns MySQL.
Posted 19 August 2010 - 07:20 PM
Once I have this information I can correct this issue for you.
Posted 20 August 2010 - 09:43 AM
Can you give me a rough idea what's involved in the fix? I prefer not to have my client inconvenienced for long, if changing password software requires major changes in my code.
I'm developing on a Mac/PHP5.3 system, but I greatly appreciate that TCH hasn't made the jump to PHP 5.3 yet. I still have some clean-up works to make my TCH/PHP 5.2x websites work cleanly under 5.3.
Just being cautious here...
Posted 20 August 2010 - 10:11 AM
We will simply disable support of the old style passwords(temporarily so we don't break other users sites), then using the current database username and password, we will recreate the password using the new style mysql passwords. Once this is done your local setup will connect as usual with no change on your part and you will be able to properly connect using your external setup.
This change is something you can actually run from phpmyadmin, however, since you cant actually disable support for the old style passwords, it would have no affect from your end.
Posted 29 September 2010 - 12:57 PM
I'm now trying to connect from my Mac development system to a MySQL database on philadelphia, and am getting the same error message about old vs new password MySQL authentication.
My Mac is running PHP 5.3.2, so I assume my PHP mysql_connect() code is producing the newer longer password hash.
I'm guessing the correct solution is to delete my MySQL user and then recreate that user, which should generate the new password hash.
I'd prefer to update to the newer MySQL password convention instead of working toward backward compatibility, and will change anything necessary in my PHP framework.
FYI, I've added my local IP address to the access list via cPanel, which is how I got as far as the old/new password conundrum.
I'm reluctant to offer more specifics in a public forum, but I'd appreciate your input to help me generate a coherent ticket.
Posted 29 September 2010 - 01:51 PM
TotalChoice Hosting, Inc.
Webhosting by Total Choice Web Hosting - General Support Forum
I am a Forum Moderator. While I can assist in answering most of your hosting related questions, I am unable to answer questions about specifics relating to your account such as billing and server related issues. Should you need assistance in these areas, please contact our Help Desk or our many other options. Another good place to find answers is with our help pages, tutorials and movie tutorials.
Posted 29 September 2010 - 03:54 PM
That database has a single user, and I already tried removing and restoring that user. I just repeated that process, and also created a new user/password. In each case, I get this error message:
Warning: mysql_connect(): OK packet 6 bytes shorter than expected in /websites/bbm_georgetown/shared_v4/libs/database_lib.php on line 96 Warning: mysql_connect(): mysqlnd cannot connect to MySQL 4.1+ using old authentication in /websites/bbm_georgetown/shared_v4/libs/database_lib.php on line 96
Other suggestions gratefully accepted...
0 user(s) are reading this topic
0 members, 0 guests, 0 anonymous users