Problem Description
Execute statementbin/sqoop import --connect jdbc:mysql://localhost:3306/gdcmxy --username root --password root --table 2019bigdata --fields-terminated-by '\t' --delete-target-dir --num-mappers 1 --hive-import --hive-database gdcmxy --hive-table 2019bigdata
Error: java.lang.RuntimeException: java.lang.RuntimeException: com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
After seeing the error report, it was preliminarily judged that the main problem was the database connection problem. At first, I thought the firewall was not turned off, but considering that hadoo had certainly turned off the firewall before, it should have nothing to do with the firewall.
Cluster environment:
Solution:
Change the localhost of the execution statement to the IP address of the local machine bin/sqoop import -- connect JDBC: mysql://192.168.112.81:3306/gdcmxy --Username root -- password root -- table 2019bigdata -- fields terminated by '\ t' -- delete target dir -- num mappers 1 -- hive import -- hive database gdcmxy -- hive table 2019bigdata
successfully imported
Read More:
- ERROR java.lang.RuntimeException: azkaban.jobExecutor.utils.process.ProcessFailureException
- Error: java.lang.RuntimeException: PipeMapRed.waitOutputThreads(): subprocess failed with code 127
- Error in idea compilation: java.lang.OutOfMemoryError Java heap space and java.lang.StackOverflowError
- java.lang.NoSuchMethodError: org.json.JSONObject.put(Java/lang/String; Java/util/Collection;) “209151;”
- build.gradle Warming: cannot be applied to ‘(groovy.lang.Closure)’/'(java.lang.String)’
- Cause: java.sql.SQLException: Error setting driver on UnpooledDataSource. Cause: java.lang.ClassNot
- Java:java.lang.OutOfMemoryError : GC overhead limit exceeded solution
- [Solved] Flowable Start Error: ClassCastException: java.time.LocalDateTime cannot be cast to java.lang.String
- java.lang.UnsupportedOperationException resolvent
- java.lang.Error: Unresolved compilation problems
- java.lang.IllegalArgumentException: column ‘_id’ does not exist
- Summary of common runtimeException exceptions
- java.lang.UnsupportedOperationException: null
- Android studio — java.lang.nullpointerexception(no error message)
- java.lang.IllegalArgumentException : urlcoder exception resolution
- Caused by: java.lang.reflect.InvocationTargetExceptio
- appear java.lang.NoClassDefFoundError A kind of reason and solution of the mistake
- java.lang.reflect.InvocationTargetException
- Mybatis exception error setting driver on unpoleddatasource. Cause: java.lang.ClassNotFoundException :
- Regular error in UDF java.lang.stackoverflowerror