Reply
Explorer
Posts: 13
Registered: ‎02-15-2016
Accepted Solution

Impala_Kudu install fails with "Error 401"

[ Edited ]

 I am installing "Impala_Kudu" in my test cluster but it is failing with the following error. I read that the CM API uses HTTP, but I think this error is because my CM Web UI uses HTTPS. Is that correct? What options do I have?

 

Traceback (most recent call last):
File "deploy.py", line 465, in <module>
main()
File "deploy.py", line 437, in main
cluster = find_cluster(api, args.cluster)
File "deploy.py", line 109, in find_cluster
cluster = api.get_cluster(cluster_name)
File "/usr/lib/python2.6/site-packages/cm_api/api_client.py", line 137, in get_cluster
return clusters.get_cluster(self, name)
File "/usr/lib/python2.6/site-packages/cm_api/endpoints/clusters.py", line 57, in get_cluster
return call(resource_root.get, "%s/%s" % (CLUSTERS_PATH, name), ApiCluster)
File "/usr/lib/python2.6/site-packages/cm_api/endpoints/types.py", line 139, in call
ret = method(path, params=params)
File "/usr/lib/python2.6/site-packages/cm_api/resource.py", line 110, in get
return self.invoke("GET", relpath, params)
File "/usr/lib/python2.6/site-packages/cm_api/resource.py", line 73, in invoke
headers=headers)
File "/usr/lib/python2.6/site-packages/cm_api/http_client.py", line 174, in execute
raise self._exc_class(ex)
cm_api.api_client.ApiException: <html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
<title>Error 401 Full authentication is required to access this resource</title>
</head>
<body><h2>HTTP ERROR 401</h2>
<p>Problem accessing /api/v10/clusters/Emerson-Dev. Reason:
<pre> Full authentication is required to access this resource</pre></p><hr /><i><small>Powered by Jetty://</small></i><br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>

</body>
</html>
(error 401)

Cloudera Employee
Posts: 31
Registered: ‎02-05-2016

Re: Impala_Kudu install fails with &quot;Error 401&quot;

Good observation! This is a limitation of the deploy.py script; I'll file an internal bug so that it gets fixed.

 

As a work around, in deploy.py change:

api = ApiResource(args.host,
                  username=args.user,
                  password=args.password,
                  version=10)

to:

api = ApiResource(args.host,
                  username=args.user,
                  password=args.password,
                  use_tls=True,
                  version=10)

That should force the script to use HTTPS.

Cloudera Employee
Posts: 31
Registered: ‎02-05-2016

Re: Impala_Kudu install fails with &quot;Error 401&quot;

Here's a link to the bug I filed: https://issues.cloudera.org/browse/IMPALA-4486
Explorer
Posts: 13
Registered: ‎02-15-2016

Re: Impala_Kudu install fails with &quot;Error 401&quot;

Hi Adar,

 

Sorry; I was on vacation which is why I could not respond sooner. 

 

Your solution is correct and I was able to figure that out the same day after digging into the script. 

 

Thanks and Regards,

Mohit

 

 

Announcements