Reply
Explorer
Posts: 21
Registered: ‎12-24-2015

Error creating Sqoop2 link in Hue

I am trying to set up a Sqoop2 link in Cloudera HUE.But I consistently get a

 

Could not create link. error.

 

I have the following set up

Hue Server Host Name : namenode.mydomain.com
MySQL Server is Installed on host with name : secnamenode.mydomain.com

Sqoop2 Server is installed on host name : secnamenode.mydomain.com

 

I have set up permissions the following way, to create a link in Hue ,I have enabled remote log in on MySQL , I am still not successful.

> create user 'root'@'namenode' IDENTIFIED by 'mypassword'; GRANT ALL
> PRIVILEGES ON retail_db.* TO 'root'@'namenode' IDENTIFIED BY
> 'mypassword';

It did not work , then I tried the following .


> create user 'root'@'namenode.mydomain.com' IDENTIFIED by 'mypassword';
> GRANT ALL PRIVILEGES ON retail_db.* TO 'root'@'namenode.mydomain.com'
> IDENTIFIED BY 'mypassword';

It still did not work , how do I get this to work , I am not able to create any new MySQL link.


By the way, the my users table looks like this.

mysql> select host,user from user;
+---------------+-----------+
| host            | user |
+---------------+-----------+
| %               | root |
| localhost    | mysql.sys |
| localhost    | root |
| namenode | root |
+---------------+-----------+
4 rows in set (0.00 sec)

 


**EDIT , I see the following stack trace in the exception stack trace in the file /var/log/sqoop2/.**

2016-04-07 22:23:41,920 INFO org.apache.sqoop.repository.JdbcRepositoryTransaction: Attempting transaction commit
java.lang.IllegalArgumentException: URLDecoder: Incomplete trailing escape (%) pattern2016-04-07 22:24:48,115 ERROR org.apache.sqoop.server.SqoopProtocolServlet: Exception in POST http://xxx.xxx.com:12000/sqoop/v1/link
java.lang.IllegalArgumentException: URLDecoder: Incomplete trailing escape (%) pattern
at java.net.URLDecoder.decode(URLDecoder.java:187)
at org.apache.sqoop.utils.UrlSafeUtils.urlDecode(UrlSafeUtils.java:46)
at org.apache.sqoop.model.MStringInput.restoreFromUrlSafeValueString(MStringInput.java:60)
at org.apache.sqoop.json.util.ConfigInputSerialization.restoreConfig(ConfigInputSerialization.java:199)
at org.apache.sqoop.json.util.ConfigInputSerialization.restoreConfigList(ConfigInputSerialization.java:128)
at org.apache.sqoop.json.LinkBean.restoreLink(LinkBean.java:143)
at org.apache.sqoop.json.LinkBean.restore(LinkBean.java:129)
at org.apache.sqoop.handler.LinkRequestHandler.createUpdateLink(LinkRequestHandler.java:119)
at org.apache.sqoop.handler.LinkRequestHandler.handleEvent(LinkRequestHandler.java:68)
at org.apache.sqoop.server.v1.LinkServlet.handlePostRequest(LinkServlet.java:72)
at org.apache.sqoop.server.SqoopProtocolServlet.doPost(SqoopProtocolServlet.java:63)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:643)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:723)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.hadoop.security.authentication.server.AuthenticationFilter.doFilter(AuthenticationFilter.java:589)
at org.apache.hadoop.security.token.delegation.web.DelegationTokenAuthenticationFilter.doFilter(DelegationTokenAuthenticationFilter.java:291)
at org.apache.hadoop.security.authentication.server.AuthenticationFilter.doFilter(AuthenticationFilter.java:552)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:861)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:620)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489)
at java.lang.Thread.run(Thread.java:745)