[Bio-Linux] Problems with MySQL local infile

Tim Booth tbooth at ceh.ac.uk
Wed Oct 7 12:03:33 EDT 2015


Hi Laura,

Please ensure you join the mailing list to see all replies and so your
future postings won't be held up for moderation.

I believe the same question is answered here:
http://stackoverflow.com/questions/10762239/mysql-enable-load-data-local-infile

The key point is that because this feature is considered very insecure
it needs to be enabled on both the server and on the client.  It looks
like you have not enabled it on the server, which requires you to
edit /etc/mysql/my.cnf and to restart the server process (sudo restart
mysql).

A simpler option would be to copy the data over to the server (via SCP
if it is on a different machine, or else just ensure the file is
readable by the server process) and then do the import without the LOCAL
keyword.  Maybe this would be simper?

Cheers,

TIM

On Tue, 2015-10-06 at 15:30 +0000, Lehtovirta, Laura Elina wrote:
> Hi,
>  
> I'm having a problem with loading data into MySQL using LOAD DATA
> LOCAL INFILE. The error I'm getting is "The used command is not
> allowed with this MySQL version". I’ve tried “--local-infile” when
> starting MySQL and modified the my.cnf file to contain
> “local-infile=1”. 
> Command “SHOW GLOBAL VARIABLES LIKE 'local_infile';” shows that local
> infile is on but does not get rid of the error. I’m using MySQL
> version 14.14 Distrib 5.5.44, for debian-linux-gnu (x86_64) using
> readline 6.3. Does anyone have suggestions how to fix this?
>  
> Many thanks in advance,
>  
> Laura
> 
>  
> 
> Dr Laura Lehtovirta-Morley
> 
> Postdoctoral Research Associate
> 
> Institute of Biological and Environmental Sciences
> 
> Cruickshank Building
> 
> University of Aberdeen
> 
> St Machar Drive
> 
> Aberdeen
> 
> AB24 3UU
> 
>  
> 
> 
> 
> 
> The University of Aberdeen is a charity registered in Scotland, No
> SC013683.
> Tha Oilthigh Obar Dheathain na charthannas clàraichte ann an Alba,
> Àir. SC013683. 
> _______________________________________________
> Bio-Linux mailing list
> Bio-Linux at nebclists.nerc.ac.uk
> http://nebclists.nerc.ac.uk/mailman/listinfo/bio-linux

-- 
Tim Booth <tbooth at ceh.ac.uk>

Centre for Ecology and Hydrology
Maclean Bldg, Benson Lane
Crowmarsh Gifford
Wallingford, England
OX10 8BB 

http://environmentalomics.org/bio-linux
+44 1491 69 2297





More information about the Bio-linux-list mailing list