我正在使用“宜必思框架”。我有
hdfs_client = ibis.hdfs_connect(...)
impala_client = ibis.impala.connect(..., hdfs_client=hdfs_client)
db = impala_client.database('abc')
data = pd.DataFrame(...)
db.create_table('tb_name', obj=data, format='parquet', force=True)
这失败了,因为namenoderpcaddress
构造者requests
(在 ibis 中调用)具有端口 8020,而对我来说正确的是 8022(这是 Cloudera 推荐的端口;可能用于 HA 目的)。
ConnectionError: HTTPConnectionPool(host='ip-0-0-0-0.ec2.internal', port=50075): Max retries exceeded with url: /webhdfs/v1/tmp/ibis/pandas_7ae170c27ee6426e97e0f84aa9a2a778/0.csv?op=CREATE&user.name=user&namenoderpcaddress=ip-0-0-0-0.ec2.internal:8020&overwrite=false&user.name=user (Caused by NewConnectionError('<requests.packages.urllib3.connection.HTTPConnection object at 0x7feb44be49d0>: Failed to establish a new connection: [Errno -2] Name or service not known',))
(上面msg中的ip地址是我编辑的)
知道如何告诉 ibis 或请求此端口号吗?
谢谢。