Support Questions

Find answers, ask questions, and share your expertise

sqoop import and export data from diffrent machine ?


I am working with sqoop, I can import and export data from mysql to hive or hbase with the command:

sqoop import \
--connect "jdbc:mysql://localhost:3306/retail_db" \
--username=retail_dba \
--password=password \
--table departments \
--as-sequencefile \

It work fine for me.

Now I am trying to import and export from diffrent machine (my friend's machine)what I have to do.



You have to use his port number and his location(address) of mysql

--connect jdbc:mysql://address/portnumber


@Aymen Rahal

First you have to ensure that mysql host is reachable from your host you are operating the sqoop command

  • update /etc/hosts entry with IP/FQDN/Alias of the remote host(friends Machine)
  • No firewall should be blocking the port e.g 3306 for MySQL.
  • You should have the username/password for the remote database.
  • Run the sqoop import command from your machine.