{"id":373,"date":"2010-09-13T05:00:28","date_gmt":"2010-09-13T11:00:28","guid":{"rendered":"http:\/\/blog.supportpro.com\/2010\/09\/how-to-fix-cpanel-remote-mysql-issue-having-the-error-message-warning-2-mysql_connect-ok-packet-6-bytes-shorter-than-expected-line-34-in-file-cinetpublocal_intranetwebsite_updater-php\/"},"modified":"2018-10-04T06:28:30","modified_gmt":"2018-10-04T12:28:30","slug":"how-to-fix-cpanel-remote-mysql-issue-having-the-error-message-warning-2-mysql_connect-ok-packet-6-bytes-shorter-than-expected-line-34-in-file-cinetpublocal_intranetwebsite_updater-php","status":"publish","type":"post","link":"https:\/\/www.supportpro.com\/blog\/how-to-fix-cpanel-remote-mysql-issue-having-the-error-message-warning-2-mysql_connect-ok-packet-6-bytes-shorter-than-expected-line-34-in-file-cinetpublocal_intranetwebsite_updater-php\/","title":{"rendered":"How to fix Cpanel Remote Mysql issue with the error message: WARNING [2] mysql_connect(): OK.shorter than expected"},"content":{"rendered":"<p>How to fix Cpanel Remote Mysql issue having the error message: WARNING [2] mysql_connect(): OK packet 6 bytes shorter than expected, Line: 34 in file C:\\inetpub\\local_intranet\\website_updater.php<\/p>\n<p>We need to perform two steps to check this which can be done as follows:<\/p>\n<p>Firstly, check the mysql remote connection after making sure that you are using the following parameters;<\/p>\n<p>MySQL server : Server IP<\/p>\n<p>Port : 3306<\/p>\n<p>User : fill in mysql user for eg: username_test<\/p>\n<p>Password : password of the mysql user.<\/p>\n<p><!--more--><\/p>\n<p>Secondly, we need to test if mysql remote connection is working by doing the following steps:<\/p>\n<p>[root@linux] #mysql -h server_ip -u my_sql_username -p<\/p>\n<p>Enter password:<\/p>\n<p>Welcome to the MySQL monitor. Commands end with ; or \\g.<\/p>\n<p>Your MySQL connection id is 15054<\/p>\n<p>Server version: 5.0.9-community MySQL Community Edition (GPL)<\/p>\n<p>Type &#8216;help;&#8217; or &#8216;\\h&#8217; for help. Type &#8216;\\c&#8217; to clear the current input statement.<\/p>\n<p>mysql&gt; show databases;<\/p>\n<p>+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+<\/p>\n<p>| Database |<\/p>\n<p>+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+<\/p>\n<p>| information_schema |<\/p>\n<p>| linux_catalogs |<\/p>\n<p>+&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;+<\/p>\n<p>2 rows in set (0.01 sec)<\/p>\n<p>If an Error message apprears as shown below , then this can be resolved which is explained<\/p>\n<p>after this:<\/p>\n<p>WARNING [2] mysql_connect(): OK packet 6 bytes shorter than expected, Line: 34 in file C:\\inetpub\\local_intranet\\website_updater.php<\/p>\n<p>Steps to fix this issue:<\/p>\n<p>a. vi \/etc\/my.cnf<\/p>\n<p>b. change old-passwords = 1\u00a0 to #old-passwords = 1<\/p>\n<p>c. restart mysql<\/p>\n<p>d.\u00a0 change password (change the password of mysql user\u00a0 to the same password}<\/p>\n<p>e.\u00a0 uncomment #old-passwords = 1<\/p>\n<p>f.\u00a0 restart mysql<\/p>\n<p>This will fix the above mysql remote connection issue.<\/p>\n<p>If you require help, <a href=\"https:\/\/www.supportpro.com\/requestquote.php\">contact SupportPRO Server Admin<\/a><\/p>\n<p style=\"text-align: center;\"><!--HubSpot Call-to-Action Code --><span id=\"hs-cta-wrapper-9d590242-d641-4383-94b4-8cfd62f0af6b\" class=\"hs-cta-wrapper\"><span id=\"hs-cta-9d590242-d641-4383-94b4-8cfd62f0af6b\" class=\"hs-cta-node hs-cta-9d590242-d641-4383-94b4-8cfd62f0af6b\"><!-- [if lte IE 8]><\/p>\n\n\n\n\n\n<div id=\"hs-cta-ie-element\"><\/div>\n\n\n<![endif]--><a href=\"https:\/\/cta-redirect.hubspot.com\/cta\/redirect\/2725694\/9d590242-d641-4383-94b4-8cfd62f0af6b\"><img decoding=\"async\" id=\"hs-cta-img-9d590242-d641-4383-94b4-8cfd62f0af6b\" class=\"hs-cta-img\" style=\"border-width: 0px;\" src=\"https:\/\/no-cache.hubspot.com\/cta\/default\/2725694\/9d590242-d641-4383-94b4-8cfd62f0af6b.png\" alt=\"Server not running properly? Get A FREE Server Checkup By Expert Server Admins - $125 Value\" \/><\/a><\/span><script charset=\"utf-8\" src=\"https:\/\/js.hscta.net\/cta\/current.js\"><\/script><script type=\"text\/javascript\"> hbspt.cta.load(2725694, '9d590242-d641-4383-94b4-8cfd62f0af6b', {}); <\/script><\/span><!-- end HubSpot Call-to-Action Code --><\/p>\n","protected":false},"excerpt":{"rendered":"<p>How to fix Cpanel Remote Mysql issue having the error message: WARNING [2] mysql_connect(): OK packet 6 bytes shorter than expected, Line: 34 in file C:\\inetpub\\local_intranet\\website_updater.php We need to perform&hellip;<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_lmt_disableupdate":"","_lmt_disable":"","footnotes":""},"categories":[5,1],"tags":[],"class_list":["post-373","post","type-post","status-publish","format-standard","hentry","category-general-topics","category-miscellaneous"],"aioseo_notices":[],"_links":{"self":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts\/373","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/comments?post=373"}],"version-history":[{"count":3,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts\/373\/revisions"}],"predecessor-version":[{"id":3371,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/posts\/373\/revisions\/3371"}],"wp:attachment":[{"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/media?parent=373"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/categories?post=373"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.supportpro.com\/blog\/wp-json\/wp\/v2\/tags?post=373"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}