对大家有帮助的问答会被标记为“推荐”,看完课程过来浏览一下别人提的问题,会帮你学得更全面
老师,我遇到一个问题是idea提示我namenode的ip是192.168.20.101,但是我namenode实际是192.168.102.128,然后我看了一下配置文件,都是直接写主机名的,但是我的主机名对应的ip也是我实际的ip,但是idea认为我ip是老师的讲课时候的ip,我应该是前面配置哪里出问题了,但是我暂时没找到
报错是这个
Caused by: org.apache.hadoop.hbase.MasterNotRunningException: java.net.ConnectException: Call to address=node1/192.168.20.101:16000 failed on connection exception: org.apache.hbase.thirdparty.io.netty.channel.ConnectTimeoutException: connection timed out: node1/192.168.20.101:16000
老师,请问在TableReducer中context.write时key始终为null,那为什么KEYOUT还要指定类型,它有什么作用?
public void getDB() throws IOException{
String rowkey="2";
Get get=new Get(rowkey.getBytes());
Result rs=hbasetest.get(get);
Cell cell=rs.getColumnLatestCell("cf".getBytes(), "name".getBytes());
Cell cell1=rs.getColumnLatestCell("cf".getBytes(), "sex".getBytes());
Cell cell2=rs.getColumnLatestCell("cf".getBytes(), "age".getBytes());
System.out.println(new String(CellUtil.cloneValue(cell)));
System.out.println(new String(CellUtil.cloneValue(cell1)));
System.out.println(new String(CellUtil.cloneValue(cell2)));
}
执行时提示错误: