LOAD DATA LOCAL broken in PhpMyAdmin after update

maverick

Well-Known Member
Jan 6, 2003
68
0
156
Hi everyone,

After updating to cPanel 9.4.1-R55, the upload data function in PhpMyAdmin (LOAD DATA LOCAL) no longer functions. It now returns the error:
"#1148 - The used command is not allowed with this MySQL version"

This function has always worked in the past and only the two servers where we updated cPanel now exhibit the problem.

I have checked that the "local-file" option is enabled in MySQL (it definitely is) and the LOAD DATA LOCAL file works without error via a Perl script on the same server. The problem appears to be with cPanel's PHP. We had to run the the /scripts/makecpphp script in order to get Horde working after the update. I suspect that this part of the update is what caused the problem, though I haven't proven that as yet.

I have gone to some lengths to solve the problem myself, but haven't had any success. Although I have submitted a ticket already, if anybody has discovered a fix/workaround for this issue, we'd love to hear it.

Thanks.

Regards,
Mav.
 

maverick

Well-Known Member
Jan 6, 2003
68
0
156
cPanel support have provided a solution for this (thanks!).

Here was their response:

"I have confirmed this to be a bug with the makecpphp script. I submitted a bug report on your behalf on our bugzilla interface found here:

http://bugzilla.cpanel.net/show_bug.cgi?id=802

The fix for this issue is simple and you can implement it before the final fix goes through. Just edit /scripts/makecpphp where in the configure statements you see --with-mysql change it to:

--with-mysql=/usr

Save it, leaving everything else untouched. Then just run /scripts/makecpphp again."

Mav.
 

jsteel

Well-Known Member
Jul 4, 2002
646
0
166
Atlanta, GA
maverick said:
cPanel support have provided a solution for this (thanks!).

Here was their response:

"I have confirmed this to be a bug with the makecpphp script. I submitted a bug report on your behalf on our bugzilla interface found here:

http://bugzilla.cpanel.net/show_bug.cgi?id=802

The fix for this issue is simple and you can implement it before the final fix goes through. Just edit /scripts/makecpphp where in the configure statements you see --with-mysql change it to:

--with-mysql=/usr

Save it, leaving everything else untouched. Then just run /scripts/makecpphp again."

Mav.
We're amazed that it's been about three weeks since you've posted this and the makecpphp file still hasn't been fixed! Did they close out your ticket?
 

maverick

Well-Known Member
Jan 6, 2003
68
0
156
jsteel: Yeah they closed the support ticket - but the bugzilla report is still open (see link above). I was surprised too that something so blatantly broken wouldn't have been remedied right away.

Myacen: The fix did work for us (across all servers). Just to clarify, the $conf part should now look like this:

$conf = "./configure --enable-static " .
"--enable-mbstring --enable-mbstr-enc-trans " .
"--enable-mbregex --with-zlib " .
"--with-imap $IMAPFLAGS --enable-ftp --with-gettext --with-xml " .
"--enable-track-vars --enable-sockets --with-mysql=/usr " .
"$PGSQL " .
"--with-config-file-path=/usr/local/cpanel/3rdparty/etc " .
"--prefix=/usr/local/cpanel/3rdparty";

Mav.
 

manokiss

Well-Known Member
Mar 31, 2002
576
1
318
hi, the fix dont work for us, any other advice? we are in WHM 9.4.0 cPanel 9.4.1-C133
RedHat Enterprise 3 i686 - WHM X v3.1.0
 

webJ

Active Member
Apr 9, 2003
25
0
151
manokiss said:
hi, the fix dont work for us, any other advice? we are in WHM 9.4.0 cPanel 9.4.1-C133
RedHat Enterprise 3 i686 - WHM X v3.1.0

It's not working for us either.

RedHat 7.3 - WHM 9.4.0 cPanel 9.4.1-S65
 

webJ

Active Member
Apr 9, 2003
25
0
151
I cannot believe that more people aren't saying anything about this.
 

0utlier

Well-Known Member
Aug 7, 2002
46
0
156
We had this problem, but recompiled php with --with-mysql=/usr rather than the standard
--with-mysql and that fixed it for us. I imagine that advice works for most. I don't know why it's not working for you. I'm sorry.
 

zentity

Well-Known Member
Jun 16, 2004
78
0
156
http://nz2.php.net/mysql

Installation
By using the --with-mysql[=DIR] configuration option you enable PHP to access MySQL databases.

In PHP 4, the option --with-mysql is enabled by default. To disable this default behavior, you may use the --without-mysql configure option. Also in PHP 4, if you enable MySQL without specifying the path to the MySQL install DIR, PHP will use the bundled MySQL client libraries. In Windows, there is no DLL, it's simply built into PHP 4. Users who run other applications that use MySQL (for example, auth-mysql) should not use the bundled library, but rather specify the path to MySQL's install directory, like so: --with-mysql=/path/to/mysql. This will force PHP to use the client libraries installed by MySQL, thus avoiding any conflicts.

In PHP 5, MySQL is no longer enabled by default, nor is the MySQL library bundled with PHP. Read this FAQ for details on why.

This MySQL extension doesn't support full functionality of MySQL versions greater than 4.1.0. For that, use MySQLi.

If you would like to install the mysql extension along with the mysqli extension you have to use the same client library to avoid any conflicts.
--with-mysql=/dir (--with-mysql=/usr) is required in order to use the LOAD DATA LOCAL command with php.

Read also what the mysql folks have to say here : http://dev.mysql.com/doc/mysql/en/LOAD_DATA_LOCAL.html
 
Last edited:

Solokron

Well-Known Member
Aug 8, 2003
852
2
168
Seattle
cPanel Access Level
DataCenter Provider
I am having this issue as well.

Reviewing makecpphp I see...


$MYSQL='--with-mysql';
if (-e "/usr/local/bin/mysql") {
$MYSQL='--with-mysql=/usr/local';
}
if (-e "/usr/bin/mysql") {
$MYSQL='--with-mysql=/usr';
}


do I change all three values of --with-myql=?


? or is this already correct as is.
 

cyon

Well-Known Member
PartnerNOC
Jan 15, 2003
314
0
241
That's a good question, could need a bit help with this, too.
 

NNNils

Well-Known Member
Sep 17, 2002
580
0
166
Did you try doing /scripts/updatenow ?

After doing that /scripts/makecpphp did not need any modification at all for us on several servers.
 

Solokron

Well-Known Member
Aug 8, 2003
852
2
168
Seattle
cPanel Access Level
DataCenter Provider
I have not tested it since the new phpmyadmin interface in the latest stable builds but have not received any complaints since.