由于 Kerberos 安全性,我无法从浏览器访问 WebHDFS。谁能帮我这个?
以下是“http://****.****/webhdfs/v1/prod/snapshot_rpx/archive?op=LISTSTATUS&user.name=us”的浏览器错误</p>
HTTP 错误 401
访问 /webhdfs/v1/prod/snapshot_rpx/archive 时出现问题。原因:需要验证
用于向此 URL 发出请求的 .Net 代码
HttpWebRequest http = (HttpWebRequest)WebRequest.Create(requestUri);
http.Timeout = timeout;
http.ContentType = contentType;
string responseData = string.Empty;
using (WebResponse response = http.GetResponse())
{
Stream stream = response.GetResponseStream();
StreamReader sr = new StreamReader(stream);
responseData = sr.ReadToEnd();
}
return responseData;