0

Using different mysql clients, my LOAD DATA INFILE query never completes, but I can see the data has been successfully loaded. Where can I look to see why the driver gets stuck?

My complete command:

mysql> LOAD DATA INFILE '/var/lib/mysql/staging_2.csv' INTO TABLE log_line FIELDS TERMINATED BY '|' LINES TERMINATED BY '\n' IGNORE 1 LINES (df_log_id,log_line_type,log_line_data,time_us,log_line_datetime);

Alternatively I can use mysqlimport but can't get by the error mysqlimport: Error: 2068, LOAD DATA LOCAL INFILE file request rejected due to restrictions on access. despite having local_infile on:

enter image description here

Command:

root@hei13-nix02:~/development/logs# mysqlimport --local
--fields-terminated-by='|' --lines-terminated-by='\n' --user=root --columns='df_log_id,log_line_type,log_line_data,time_us,log_line_datetime' dev_wingops log_line /var/lib/mysql/staging_2.csv

Error:

mysqlimport: Error: 2068, LOAD DATA LOCAL INFILE file request rejected due to restrictions on access., when using table: log_line

Note: I've setup the same environment on Windows, and I can load no problem with the query completing normally. it seems to only affect my linux instance.

3
  • What are the permissions on the file?
    – Rick James
    May 21 at 15:21
  • "never completes" -- You are saying that the "mysql>" prompt does not come back? What if you type SHOW WARNINGS; and return?
    – Rick James
    May 21 at 15:23
  • @RickJames -rw-rw-rw- but like I said, it does load, I just never get the prompt back. No rows returned on SHOW WARNINGS; May 21 at 16:25

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Browse other questions tagged or ask your own question.