Hbase链接数据库时,在循环遍历result时,前四次遍历取数正常,第5次报错 20C

代码如下:
图片说明
p://img.ask.csdn.net/upload/201710/31/1509412397_714565.png)

报错异常如下:,,,求大神帮忙

  1. java.lang.RuntimeException: org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed after attempts=36, exceptions:
    Tue Oct 31 09:03:17 CST 2017, null, java.net.SocketTimeoutException: callTimeout=60000, callDuration=60108: row '10.10.49.161_150935' on table 'HOST_RESRC' at region=HOST_RESRC,10.10.47.55_1507847553,1509329651091.3ede1b811762ae5d54b7575a55f26a5a., hostname=node1,16020,1509329624220, seqNum=63801830

    at org.apache.hadoop.hbase.client.AbstractClientScanner$1.hasNext(AbstractClientScanner.java:97)
    at com.nantian.zabbix.service.impl.TestHbase.querybasic(TestHbase.java:135)
    at com.nantian.zabbix.service.impl.TestHbase.main(TestHbase.java:61)
    Caused by: org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed after attempts=36, exceptions:
    Tue Oct 31 09:03:17 CST 2017, null, java.net.SocketTimeoutException: callTimeout=60000, callDuration=60108: row '10.10.49.161_150935' on table 'HOST_RESRC' at region=HOST_RESRC,10.10.47.55_1507847553,1509329651091.3ede1b811762ae5d54b7575a55f26a5a., hostname=node1,16020,1509329624220, seqNum=63801830

    at org.apache.hadoop.hbase.client.RpcRetryingCallerWithReadReplicas.throwEnrichedException(RpcRetryingCallerWithReadReplicas.java:271)
    at org.apache.hadoop.hbase.client.ScannerCallableWithReplicas.call(ScannerCallableWithReplicas.java:210)
    at org.apache.hadoop.hbase.client.ScannerCallableWithReplicas.call(ScannerCallableWithReplicas.java:60)
    at org.apache.hadoop.hbase.client.RpcRetryingCaller.callWithoutRetries(RpcRetryingCaller.java:210)
    at org.apache.hadoop.hbase.client.ClientScanner.call(ClientScanner.java:327)
    at org.apache.hadoop.hbase.client.ClientScanner.loadCache(ClientScanner.java:413)
    at org.apache.hadoop.hbase.client.ClientScanner.next(ClientScanner.java:371)
    at org.apache.hadoop.hbase.client.AbstractClientScanner$1.hasNext(AbstractClientScanner.java:94)
    ... 2 more
    Caused by: java.net.SocketTimeoutException: callTimeout=60000, callDuration=60108: row '10.10.49.161_150935' on table 'HOST_RESRC' at region=HOST_RESRC,10.10.47.55_1507847553,1509329651091.3ede1b811762ae5d54b7575a55f26a5a., hostname=node1,16020,1509329624220, seqNum=63801830
    at org.apache.hadoop.hbase.client.RpcRetryingCaller.callWithRetries(RpcRetryingCaller.java:169)
    at org.apache.hadoop.hbase.client.ResultBoundedCompletionService$QueueingFuture.run(ResultBoundedCompletionService.java:65)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.io.IOException: Call to node1/10.10.49.182:16020 failed on local exception: org.apache.hadoop.hbase.ipc.CallTimeoutException: Call id=3, waitTime=60001, operationTimeout=60000 expired.
    at org.apache.hadoop.hbase.ipc.AbstractRpcClient.wrapException(AbstractRpcClient.java:284)
    at org.apache.hadoop.hbase.ipc.RpcClientImpl.call(RpcClientImpl.java:1238)
    at org.apache.hadoop.hbase.ipc.AbstractRpcClient.callBlockingMethod(AbstractRpcClient.java:223)
    at org.apache.hadoop.hbase.ipc.AbstractRpcClient$BlockingRpcChannelImplementation.callBlockingMethod(AbstractRpcClient.java:328)
    at org.apache.hadoop.hbase.protobuf.generated.ClientProtos$ClientService$BlockingStub.scan(ClientProtos.java:32831)
    at org.apache.hadoop.hbase.client.ScannerCallable.call(ScannerCallable.java:215)
    at org.apache.hadoop.hbase.client.ScannerCallable.call(ScannerCallable.java:63)
    at org.apache.hadoop.hbase.client.RpcRetryingCaller.callWithoutRetries(RpcRetryingCaller.java:210)
    at org.apache.hadoop.hbase.client.ScannerCallableWithReplicas$RetryingRPC.call(ScannerCallableWithReplicas.java:364)
    at org.apache.hadoop.hbase.client.ScannerCallableWithReplicas$RetryingRPC.call(ScannerCallableWithReplicas.java:338)
    at org.apache.hadoop.hbase.client.RpcRetryingCaller.callWithRetries(RpcRetryingCaller.java:136)
    ... 4 more
    Caused by: org.apache.hadoop.hbase.ipc.CallTimeoutException: Call id=3, waitTime=60001, operationTimeout=60000 expired.
    at org.apache.hadoop.hbase.ipc.Call.checkAndSetTimeout(Call.java:70)
    at org.apache.hadoop.hbase.ipc.RpcClientImpl.call(RpcClientImpl.java:1212)
    ... 13 more

3个回答

Caused by: org.apache.hadoop.hbase.client.RetriesExhaustedException: Failed after attempts=36, exceptions:
Tue Oct 31 09:03:17 CST 2017, null, java.net.SocketTimeoutException: callTimeout=60000, callDuration=60108: row '10.10.49.161_150935' on table 'HOST_RESRC' at region=HOST_RESRC,10.10.47.55_1507847553,1509329651091.3ede1b811762ae5d54b7575a55f26a5a., hostname=node1,16020,1509329624220, seqNum=63801830

1、看看传入的字段是否和表中字段一致
2、设置一下最大的超时响应时间
试试看吧

helloyourkey
helloyourkey 回复qq_38774360: 响应时间去看看你的配置文件,里面应该是有设置最大响应的时限的callTimeout=60000
接近 2 年之前 回复
helloyourkey
helloyourkey 回复qq_38774360: 没有相应的字段会报异常,而不是空啊
接近 2 年之前 回复
qq_38774360
**飞星** 时间设置太长也没有意义啊,怎么应用啊
接近 2 年之前 回复
qq_38774360
**飞星** 如果表中没有相应的字段不应该返回空的吗?也不应该报错啊,
接近 2 年之前 回复

空指针异常,检查空指针问题

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
链接数据库时报错,
[color=#FF0000][b]com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failurernrnThe last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.[/b][/color]rnrn[b]rn我上网看到修改设置这个wait_timeout=86400 ,设置了也没有效果[/b]
链接数据库时报错!
报错:rnlog4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).rnlog4j:WARN Please initialize the log4j system properly.rnException in thread "main" org.hibernate.exception.GenericJDBCException: Cannot open connectionrn at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:126)rn at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:114)rn at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)rn at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:52)rn at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:449)rn at org.hibernate.jdbc.ConnectionManager.getConnection(ConnectionManager.java:167)rn at org.hibernate.jdbc.JDBCContext.connection(JDBCContext.java:142)rn at org.hibernate.transaction.JDBCTransaction.begin(JDBCTransaction.java:85)rn at org.hibernate.impl.SessionImpl.beginTransaction(SessionImpl.java:1353)rn at cn.itcast.hibernate.Base.main(Base.java:21)rnCaused by: java.sql.SQLException: 用户 'sa' 登录失败。rn at net.sourceforge.jtds.jdbc.SQLDiagnostic.addDiagnostic(SQLDiagnostic.java:365)rn at net.sourceforge.jtds.jdbc.TdsCore.tdsErrorToken(TdsCore.java:2781)rn at net.sourceforge.jtds.jdbc.TdsCore.nextToken(TdsCore.java:2224)rn at net.sourceforge.jtds.jdbc.TdsCore.login(TdsCore.java:599)rn at net.sourceforge.jtds.jdbc.ConnectionJDBC2.(ConnectionJDBC2.java:331)rn at net.sourceforge.jtds.jdbc.ConnectionJDBC3.(ConnectionJDBC3.java:50)rn at net.sourceforge.jtds.jdbc.Driver.connect(Driver.java:178)rn at java.sql.DriverManager.getConnection(Unknown Source)rn at java.sql.DriverManager.getConnection(Unknown Source)rn at org.hibernate.connection.DriverManagerConnectionProvider.getConnection(DriverManagerConnectionProvider.java:133)rn at org.hibernate.jdbc.ConnectionManager.openConnection(ConnectionManager.java:446)rn ... 5 morernrn我的配置文件是rnrnrnrn rn jdbc:jtds:sqlserver://localhost:1433/testrn net.sourceforge.jtds.jdbc.Driverrn sarn sarn org.hibernate.dialect.SQLServerDialectrn truern truern -->creatern rn rnrnrnrn我的jdbc驱动jar包已经导入,并且我可以用sa登录sqlserver rnpublic static void main(String[] args) rn Configuration cfg=new Configuration();rn cfg.configure();rn SessionFactory sf=cfg.buildSessionFactory();rnrn Session s=sf.openSession();rn Transaction tx=s.beginTransaction();rn User user=new User();rn user.setBirthday(new Date());rn user.setName("name");rn s.save(user);rn tx.commit();rn s.close();rn System.out.println("end");rnrn这个方法报错了rnrn那位大侠帮帮我啊?
DBMS链接数据库时报错
我这里给的解决方法的前提是之前数据库是正常的,只是没有在连接数据库前没有打开数据库服务,如刚开机就连接数据库,但是好像数据库服务是默认手动启动的,所以会出现不能连接的错误。 错误截图(这个是mysql的海豚sqlyog连接失败的情况:) 解决方法: win+r 打开命令窗口,输入services.msc,打开本地各项服务管理器,找到mysql的服务(如下图),右键点击,选启...
Java 连接linux下的hbase数据库时报错
下面是报错图: 我的解决办法是: 关闭linux防火墙即可,service iptables stop
链接0ra9时报错!!
我有若干个ora9库的链接,在编译状态下是成功的,可是当我把执行文件考出时,报数据库连接失败。。。。。,将整个源代码目录考出的话,程序确实可以在其他PC上运行,在第一个Form中 我写了类似如下的语句 “ora9->connection = true ;”,这样的语句写了好几个(因为有若干个库要链接),我认为的是链接应该为true;执行文件报错后 我也屏蔽了这样的语句,发现好像是这个问题,请问是为什么?rn 程序中我这个函数,具体作用是改变库连接,用参数决定是连ora9的库还是连access的库。我感觉我没动什么,可是在编译状态下报“链接可能在上下文中被关闭”,代码如下,我找不到我在哪曾经关闭过!!请指教下可能的问题在哪rn[code=C/C++]AnsiString TForm2::SSqlStr_Ora(String sql,String con,int i) //创建一个Ora ado链接rn rn AnsiString sql_str = "";rn AnsiString con_str = "";rn con_str = con;rn tryrn rn TADOQuery *adosql = new TADOQuery(Application);rnrn if( con_str == "ora")rn rn adosql->Connection = room->Ora_con;rn rn elsern rn adosql->Connection = room->Acc_con;rn rn adosql->Close();rn adosql->SQL->Clear();rn adosql->SQL->Add(sql);rn adosql->Open();rn if(i == 0) //查询出stringrn rn sql_str = adosql->FieldByName(adosql->Fields->Fields[0]->FieldName)->AsString;rn rn else //查询出floatrn rn sql_str = FloatToStr(adosql->FieldByName(adosql->Fields->Fields[0]->FieldName)->AsFloat);rn rn adosql->Active = false;rn delete adosql;rn rn rn catch(Exception &e)rn rn String s = e.Message+"\n函数SqlStr_Ora()错误,请重试!!";rn Application->MessageBoxA(s.c_str(),"错误提示 :",MB_OK+16);rn rn return sql_str;rn [/code]rn最后一个问题,我写了一个dll,用的是静态链接,作用是判断程序是否正确链接到ora9库中,代码如下rn[code=C/C++]bool datecon()rnrnrn TADOConnection *connect=new TADOConnection(NULL); //定义连接rn TADOQuery *db=new TADOQuery(NULL);rn rn String con_str = "";rn con_str += "Provider=MSDAORA.1;Password=in;";rn con_str += "User ID=in;";rn con_str += "Data Source=in"; //连接驱动rn rn connect->ConnectionString = con_str;rn connect->LoginPrompt = false;rn connect->ConnectionTimeout = 15;rn tryrn rn connect->Connected = true;rn connect->Close();rn connect->Open();rn db->Connection = connect;rnrn db->Close();rn db->SQL->Clear();rn db->SQL->Add("select sysdate as time from dual");rn db->Open();rn rn catch(Exception &e)rn rn db->Close();rn connect->Close();rn return false;rn rn db->Close();rn connect->Close();rn delete connect;rn delete db;rn return true;rnrn[/code]rn用时间控件控制,每10秒检查一下,但如果断网,即使恢复了,这个检测还是返回false,请帮忙指点一下!!rnrn刚才在sqlnet.log中发现如下错误提示:rn[code=C/C++]Fatal NI connect error 6413, connecting to:rn (DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=BEQ)(PROGRAM=oracle)(ARGV0=oracleora9)(ARGS='(DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))')))(CONNECT_DATA=(SID=ora9)(CID=(PROGRAM=E:\work\program\file1.1.1(file)\zy.exe)(HOST=SRC-C718591992B)(USER=Cruise))))rnrn VERSION INFORMATION:rn TNS for 32-bit Windows: Version 9.2.0.1.0 - Productionrn Time: 12-4月 -2012 15:23:01rn Tracing not turned on.[/code]rn请问下,为什么路径名中不能有括号呢!!!
调试$numb=mysql_numrows($result); 语句时报错
rn小弟在网上下载了一个数据分页的源程序,可是在调试的时候报错,谁能帮帮我rnWarning: Supplied argument is not a valid MySQL result resource in C:\apache\htdocs\xitong\page.php on line 12rnrn数据库结构:rn数据库名称:licairnrnCREATE TABLE xiaofei (rn id int(6) NOT NULL auto_increment,rn date varchar(10) DEFAULT '0' NOT NULL,rn PRIMARY KEY (id),rn KEY id (id)rn);rnrnrn源程序如下:rn"; rnif (!empty($numb)) rnfor($i=0;$i<$numb;$i++) rn$val=mysql_result($result,$i,"id"); rn$val1=mysql_result($result,$i,"date"); rnecho "$val$val1"; rn rn rnecho ""; rnrnrn//数字循环翻页的控制 rnecho " "; rnecho " 页:"; rnrn//前翻控制 rnif ($s>20) rnif ($s==21) rn$st=$s-21; rn else rn$st=$s-20; rn rn$pstart=$st*$limit; rnecho " prve"; rn rnecho " >>"; rnrn//设置当前页对应页数无链接功能 rn$star=$start; rnrn//注意循环的初始附值,仔细想想为什么不是 0 rnfor ($page=$s;$page<($num/$limit);$page++) rnrn$start=$page*$limit; rnecho " "; rnrnif($page!=$star/$limit) rnecho ""; rn rnrnecho $page; rnrnif($page!=$star/$limit) rnecho ""; rn rnrnecho ""; rnrn//控制数字页面限制显示功能,控制只显示 20 页 rnif ($page>0 && ($page%20)==0) rnif ($s==0) rn$s=$s+21; rn else rn$s=$s+20; rn rnrn$start=$start+$limit; rnrnif ((($num/$limit)-1)>$page) rnecho " << next"; rn rn//注意跳出循环的控制 rnbreak; rn rn rnecho ""; rn?> rnrnrn原理:rn循环翻页是前翻后翻加上数字共同实现的,具体的表现形式为: rnrn页: prve << 1 2 3 4 ....... 20 >> next rnrn里面的数字表示各当前的页面,前翻 prve 和后翻 next 已不仅仅是当前页的前后翻转,而是更加复杂的数字控制前后翻转. rnrn同以往一样,在进行程序设计之前,先理清一下思路,我建议读者在看完如何实现循环翻页的功能后,能自己动手实践一次,因为这里研究的一些方法和思路可能比较抽象. rnrn首先我们大胆假设数据库里存有超过 1000 条的记录,我们希望当前显示 25 条记录,而数字翻转控制为 20,因此就有如下的显示结果: rnrn页: 0 1 2 3 ......... 19 >> next rnrn后翻后的显示结果: rnrn页: prve << 20 27 28 ....... 49 >> next rnrn好,我们来看看其中的规律,一个固定的显示数字 25 ,一个固定的数字控制倍翻 20.我们可以利用这两个数字来实现循环翻页功能; rnrn首先设置固定显示的变量: rn$limit=20; rn数据库初始变量的设置: rn$start=0; rn数据库记录总数为:$num; rn页数变量:$page; rnrn一个页数循环显示的程序如下: rnrn0 && ($page%20)==0) rnbreak; //退出循环 rn rn rn?> rn
Hbase 0.96后Result对象遍历方式
Hbase 0.96后Result对象遍历方式: 以前的遍历方式(@Deprecated 不建议使用的方式): Result rst = null; try { rst = HbaseUtil.selectByKey(tableName, rowKey); for (KeyValue kv : rst.li
链接数据库时出错......
string db="database\db.mdb";rnstring constr="Provider=Microsoft.Jet.OLEDB.4.0;Data source=" + Server.MapPath(db);rn OleDbConnection conn=new OleDbConnection(constr);rn conn.Open();rnrnrn出现无法识别的转义序列......错误提示。rnrn请问如何解决这个错误。
关闭程序时报错,其他正常。
[img=http://img.my.csdn.net/uploads/201212/12/1355314788_6532.JPG][/img][img=http://img.my.csdn.net/uploads/201212/12/1355314797_8040.JPG][/img][img=http://img.my.csdn.net/uploads/201212/12/1355314803_1232.JPG][/img][img=http://img.my.csdn.net/uploads/201212/12/1355314811_3191.JPG][/img]rn一个控制台程序,运行时完全正常,点关闭程序时报出以上错误,错误的地址不确定。程序中使用了网络和多线程。
navicat链接Oracle时报错
连接oracle报错“ORA-28547:connection to server failed,probable Oracle Net admin  ORA-12737: Instant Client Light: unsupported server character set CHS16GBK解决办法 oci.dll的版本不对     1.从 http://www.or
在统计记录数时报错
string constr = ConfigurationManager.ConnectionStrings["gsbConnectionString"].ConnectionString;rn SqlConnection con = new SqlConnection(constr);rn int maiid = Int32.Parse(ddlP.SelectedValue.ToString());rn string selconunt = "select count(pname) from plname where fid='" + maiid + "'";rn con.Open();rn SqlCommand cmd = new SqlCommand(selconunt,con); rn rn int count =cmd.ExecuteScalar();//有错误吗?rn con.Close();rnrnrn if (count>0)rn rn Response.Write(" ");rn我在代码中已经标注了,该地方报错,是什么原因,请大家指点,谢谢!
mybatis参数map包含list,取数时遍历list
mybatis xml文件: &amp;lt;update id=&quot;chooseconfirm&quot; parameterType=&quot;java.util.Map&quot;&amp;gt; UPDATE BarcodeScan SET confirmuser=#{account},confirmdate=NOW() WHERE ID in &amp;lt;foreach collection=&quot;IDlist&quot; index=&quot;in...
打开数据库时报错
数据被截断!会是什么原因造成的?
还原数据库时报错
我想还原一个.bak文件,报错“备份集中的数据库备份与现有的‘NWEB2B’数据库不同”,该怎么解决啊?
手工创建数据库时报错
手工创建数据库时报这个错:rnERROR at line 1:rnORA-01092: ORACLE instance terminated. Disconnection forcedrnORA-01501: CREATE DATABASE failedrnORA-00450: background process 'QMNC' did not startrnORA-00443: background process "QMNC" did not startrnProcess ID: 6297rnSession ID: 17 Serial number: 1rnrn请问是什么问题?
写数据库时报错
我用的是mysql数据库,delphi6在向数据库写入数据时,系统提示“Non-blob column in table required to perform operation”但是也能够正常写入,为什么?
ORACLE字符集为AL32UTF8,取数时报错,如何解决?
各位高手:rn 代码如下:如果数据表中有中文数据,则报错“java.sql.SQLException: 遇到无效字符,在: failAL32UTF8Conv”rnrnpublic class Oracle rn public static void main( String[] args ) rn String Sprt;rn try rn Class.forName( "oracle.jdbc.driver.OracleDriver" );rn Connection conn = rnDriverManager.getConnection("jdbc:oracle:thin:@168.168.2.246:1521:joan","xrh","password");rn Statement stmt = conn.createStatement() ;rn String sql ;rn sql = "select * from strings" ;rn ResultSet rs = stmt.executeQuery(sql ) ;rn System.out.println( "Column 1\t Column 2" ) ;rn while ( rs.next() ) rn Sprt = rs.getString(1);rn rn rs.close() ;rn stmt.close() ;rn conn.close() ;rn catch (Exception e ) rn System.out.println( e.toString() ) ;rn rn rn
MapReduce连接Hbase时报错及处理
MapReduce连接Hbase时报错及处理我的Map class如下:package com.hbasepackage;import java.io.IOException;import org.apache.hadoop.hbase.client.Result;import org.apache.hadoop.hbase.io.ImmutableBytesWritable;import org.
eclipse连接hbase要存储数据时报错
13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:java.io.tmpdir=/tmprn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:java.compiler=rn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:os.name=Linuxrn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:os.arch=i386rn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:os.version=2.6.38-13-genericrn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:user.name=hadooprn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:user.home=/home/hadooprn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Client environment:user.dir=/home/hadoop/Desktop/寒假/HbasePicrn13/03/14 08:38:14 INFO zookeeper.ZooKeeper: Initiating client connection, connectString=192.168.6.202:2181,192.168.6.201:2181,192.168.6.203:2181 sessionTimeout=180000 watcher=hconnectionrn13/03/14 08:38:14 INFO zookeeper.ClientCnxn: Opening socket connection to server /192.168.6.202:2181rn13/03/14 08:38:14 WARN client.ZooKeeperSaslClient: SecurityException: java.lang.SecurityException: Unable to locate a login configuration occurred when trying to find JAAS configuration.rn13/03/14 08:38:14 INFO client.ZooKeeperSaslClient: Client will not SASL-authenticate because the default JAAS configuration section 'Client' could not be found. If you are not using SASL, you may ignore this. On the other hand, if you expected SASL to work, please fix your JAAS configuration.rn13/03/14 08:38:14 INFO zookeeper.ClientCnxn: Socket connection established to datanode2.local/192.168.6.202:2181, initiating sessionrn13/03/14 08:38:14 INFO zookeeper.ClientCnxn: Session establishment complete on server datanode2.local/192.168.6.202:2181, sessionid = 0x23d62b54a350021, negotiated timeout = 40000rn13/03/14 08:38:14 INFO zookeeper.RecoverableZooKeeper: The identifier of this process is 2651@dell20-ubunturn13/03/14 08:38:15 INFO client.HConnectionManager$HConnectionImplementation: getMaster attempt 0 of 10 failed; retrying after sleep of 1008rnjava.net.ConnectException: Connection refusedrn at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method)rn at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:567)rn at org.apache.hadoop.net.SocketIOWithTimeout.connect(SocketIOWithTimeout.java:206)rn at org.apache.hadoop.net.NetUtils.connect(NetUtils.java:489)rn at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.setupConnection(HBaseClient.java:416)rn at org.apache.hadoop.hbase.ipc.HBaseClient$Connection.setupIOstreams(HBaseClient.java:462)rn at org.apache.hadoop.hbase.ipc.HBaseClient.getConnection(HBaseClient.java:1150)rn at org.apache.hadoop.hbase.ipc.HBaseClient.call(HBaseClient.java:1000)rn at org.apache.hadoop.hbase.ipc.WritableRpcEngine$Invoker.invoke(WritableRpcEngine.java:150)rn at $Proxy5.getProtocolVersion(Unknown Source)rn at org.apache.hadoop.hbase.ipc.WritableRpcEngine.getProxy(WritableRpcEngine.java:183)rn at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:335)rn at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:312)rn at org.apache.hadoop.hbase.ipc.HBaseRPC.getProxy(HBaseRPC.java:364)rn at org.apache.hadoop.hbase.client.HConnectionManager$HConnectionImplementation.getMaster(HConnectionManager.java:682)rn at org.apache.hadoop.hbase.client.HBaseAdmin.(HBaseAdmin.java:110)rn at com.hbase.mcc.test.createTable(test.java:51)rn at com.hbase.mcc.test.main(test.java:234)rnrnrnhosts文件也尝试修改过了,可以还是报一样的错
hive 和hbase整合插入数据时报错
用spark向hive于hbase关联的表中插入数据时报错java.lang.ClassCastException: org.apache.hadoop.hive.hbase.HiveHBaseTableOutputFormat cannot be cast to org.apache.hadoop.hive.ql.io.HiveOutputFormat 哪位大神可以帮忙解答下
停止HBase集群时:报错找不到pid
当你想停止hbase时,发现停止命令执行后报错: -bash: bin/stop-hbase.sh: 没有那个文件或目录 原因是,默认情况下pid文件保存在/tmp目录下,/tmp目录下的文件很容易丢失, 解决办法:在hbase-env.sh中修改pid文件的存放路径; 在hbase-env.sh中下面的文字默认是注释掉的,放开即可,也可以自己指定存放位置 The directo...
PHP取数据库时乱码问题
网上找了很多,都没法解决.数据库显示正常.rnMYSQL+PHP设置如下:rn数据库-MySQL字符集UTF-8 Unicode (utf8)rn数据库-MySQL连接校对UTF8_BINrn数据库-NAME字段整理为UTF8_BINrnPHP程序中连接数据库后即用了mysql_query("SET NAMES 'utf-8'")rn显示NAME字段时还是???????rn请指教.
.net链接数据库时的问题
我做了一个db.cs 内容为主要为:rnpublic class dsrnrn public ds()rn rn //rn //TODO: 在此处添加构造函数逻辑rn //rn rn public static string conndb()rn rn string connstring = System.Configuration.ConfigurationManager.ConnectionStrings["connstring"].ConnectionString;rn return connstring;rn rn我在连接数据库时定义sqlconnection conn= new sqlconnection(ds.conndb()); rnvs中显示,上下文中不存在ds.请问一下这是什么问题啊?rn有没有更简单的连接数据库的方法?
GET查询HBase无结果时 Result的size也不为空
用Get查询hbase某个row时,就算该row不存在,但还是返回Result,只是该Result是empty的。 [code=&quot;java&quot;]List batch= new ArrayList(); Get get1=new Get(&quot;1111111111&quot;.getBytes()); Get get2=new Get(&quot;2222222222&quot;.getBytes()); ...
链接数据库时的未知错误!
[code=C/C++][/code]rnvoid CadoDlg::OnBnClickedButton1()rnrnrn HRESULT hr;rn tryrn rn hr = m_pConnection.CreateInstance("ADODB.Connection");///创建Connection对象rn if(SUCCEEDED(hr))rn rn hr = m_pConnection->Open("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=test.mdb","","",adModeUnknown);///连接数据库rn rn rn catch(_com_error e)// [color=#FF0000]这里捕获到的为未知错误。哪里错了?谢[/color] rn CString errormessage;rn errormessage.Format(_T("连接数据库失败!\r\n错误信息:%s"),e.ErrorMessage());rn AfxMessageBox(errormessage);///显示错误信息rn rnrn _RecordsetPtr m_pRecordset;rn m_pRecordset.CreateInstance("ADODB.Recordset");rn rn tryrn rn m_pConnection->Execute("CREATE TABLE users(ID INTEGER,username TEXT,old INTEGER,birthday DATETIME)",&RecordsAffected,adCmdText);rn rn catch(_com_error e)rn rn MessageBox( e.ErrorMessage()); rn rn rnrnrn在我的类中我已加成员变量 _ConnectionPtr m_pConnection;rn在 OnInitDialog()中也加 AfxOleInit();了 rnrn我的想法很简单就是想建一个表,然后往表里填写点记录!
DVBTeletextSubtitle Filter链接正常,播放时出错
看了两天,还不能发现问题。这里我想实现Teletext 功能,在VC工程中加入了 MPEG-2 Demultiplexer ,DVBTeletextSubtitle,Color Space Convertor和Video Render,连接时正常,但播放时就出错.于是打开vs2005 的DVBTeletextSubtitle 工程,经调试前面好像都正常,后来出错时,跳到了"C:\Program Files\Microsoft Visual Studio 8\VC\include\list"中的_DEBUG_ERROR("list iterator not dereferencable"),并一直停在了这里。这里是在线程关闭时调用的。还请高手指点,我这工程可能会错在哪里?
js开平方时,取数不正,结论
JS的浮点数是基于IEEE 754 标准的。rn【结果】浮点计算时,产生这种问题是不可避免的。rnrn前几天,我的项目用到关于js需要开平方的math.pow等类似的方法是用,取出来的数据不是一定的rnrnIEEE二进制浮点数算术标准(IEEE 754)是20世纪80年代以来最广泛使用的浮点数运算标准,为许多CPU与浮点运算器所采用。这个标准定义了表示浮点数的格式(包括负零-0)与反常值(denormal number)),一些特殊数值(无穷(Inf)与非数值(NaN)),以及这些数值的“浮点数运算符”;它也指明了四种数值舍入规则和五种例外状况(包括例外发生的时机与处理方式)。rnIEEE 754规定了四种表示浮点数值的方式:单精确度(32位)、双精确度(64位)、延伸单精确度(43比特以上,很少使用)与延伸双精确度(79比特以上,通常以80位实现)。只有32位模式有强制要求,其他都是选择性的。大部分编程语言都有提供IEEE浮点数格式与算术,但有些将其列为非必需的。例如,IEEE 754问世之前就有的C语言,现在有包括IEEE算术,但不算作强制要求(C语言的float通常是指IEEE单精确度,而double是指双精确度)。rnrn该标准的全称为IEEE二进制浮点数算术标准(ANSI/IEEE Std 754-1985),又称IEC 60559:1989,微处理器系统的二进制浮点数算术(本来的编号是IEC 559:1989)[1]。后来还有“与基数无关的浮点数”的“IEEE 854-1987标准”,有规定基数为2跟10的状况。现在最新标准是“IEEE 854-2008标准”。rnrn在六、七十年代,各家计算机公司的各个型号的计算机,有着千差万别的浮点数表示,却没有一个业界通用的标准。这给数据交换、计算机协同工作造成了极大不便。IEEE的浮点数专业小组于七十年代末期开始酝酿浮点数的标准。在1980年,英特尔公司就推出了单片的8087浮点数协处理器,其浮点数表示法及定义的运算具有足够的合理性、先进性,被IEEE采用作为浮点数的标准,于1985年发布。而在此前,这一标准的内容已在八十年代初期被各计算机公司广泛采用,成了事实上的业界工业标准。rnrnrnrn==================================================================标准一览rnIEEE标准rn当前标准 rn488 754 Revision 829 830 1003 1014-1987 1016 1076 1149.1 1164 1219 1233 1275 1278 1284 1355 1364 1394 1451 1471 1491 1516 1541-2002 1547 1584 1588 1596 1603 1613 1667 1675 1685 1800 1801 1900 1901 1902 11073 12207 2030rn802系列 rn802.1rnp Q Qat Qay X ad AE ag ah ak aq axrn.2 .3 .4 .5 .6 .7 .8 .9 .10rn802.11rnLecacy a b d e f g h i j k n p r s u v w y ac ad af ah ai aj aq axrn.12 .15 .15.4 .15.4a .16 .18 .20 .21 .22rn建议标准 rnP1363 P1619 P1823rn过时标准 rn754-1985 854-1987rn==========================================================================
求助:取数时怎样不要字段名?
CELL.RSLinkSet(1,1,0,CELL.RSGetSetIndex("DB"),1,10,10,3)取数首行显示字段名称,如果不要显示字段名称,应该怎样写呢?
xmlhttp取数时出现不完整
使用这个控件有时不能完全下载文档如何处理
Ajax Javascript 遍历table时报错
写了个html,用ajax请求到一个html,返回responseText。rntableFromHTML 是经过整理的table代码。如下:rn rn rn Projectrn Januaryrn Februaryrn Totalrn rn rn the first project rn 32.00 0rn 32.00 rn rn rn the second projectrn 88.00rn 16.00rn 104.00 rn rn rn Total Hoursrn 120.00rn 16.00rn 136.00rn rnrnrn上面的代码是经过整理后的需要用到的table,格式是text。rn现在需要遍历这个table。如下js代码:rnrnjs:rnvar oMain = document.getElementById("main");rn var tempDiv = document.createElement("div");rn tempDiv.innerHTML = tableFromHTML;rn rn var tempTable = tempDiv.getElementsByTagName("table");rn rn var tr = tempTable.childNodes.item(0);rn //遍历table。。。rnrnhtml:rn rnrn但是第一次运行总是报错:就是这行代码:var tr = tempTable.childNodes.item(0);rn'childNodes' is null or ...rn第二次运行就没问题了。rnrn请问这是怎么回事?动态遍历请求到的html text里的table还有什么好办法没?rn
从数据库取数时,刚好网络有异常
在取数时遇到的网络异常问题,如何处理这种情况下的取数问题,保证程序可以继续运行?rn把数据加载到本地吗?rnrn
从地磅取数时得问题
我在做一个和地磅得接口,从地磅中读数到程序中,但现在取不到数,rn用的是微软的MSComm1空件rn提示帧错误,怎么才解决呢,急
spring配置sessionFactory时,数据库报错
警告: Could not obtain connection metadatarnjava.sql.SQLException: Access denied for user 'root'@'localhost' (using password: YES)rn at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:1055)rn at com.mysql.jdbc.SQLError.createSQLException(SQLError.java:956)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3536)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:3468)rn at com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:917)rn at com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:3974)rn at com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1282)rn at com.mysql.jdbc.ConnectionImpl.createNewIO(ConnectionImpl.java:2142)rn at com.mysql.jdbc.ConnectionImpl.(ConnectionImpl.java:773)rn at com.mysql.jdbc.JDBC4Connection.(JDBC4Connection.java:46)rn at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)rn at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)rn at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)rn at java.lang.reflect.Constructor.newInstance(Unknown Source)rn at com.mysql.jdbc.Util.handleNewInstance(Util.java:406)rn at com.mysql.jdbc.ConnectionImpl.getInstance(ConnectionImpl.java:352)rn at com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:282)rn at java.sql.DriverManager.getConnection(Unknown Source)rn at java.sql.DriverManager.getConnection(Unknown Source)rn at org.hibernate.connection.DriverManagerConnectionProvider.getConnection(DriverManagerConnectionProvider.java:110)rn at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:84)rn at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:2073)rn at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1298)rn at org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:860)rn at org.springframework.orm.hibernate3.LocalSessionFactoryBean.buildSessionFactory(LocalSessionFactoryBean.java:779)rn at org.springframework.orm.hibernate3.AbstractSessionFactoryBean.afterPropertiesSet(AbstractSessionFactoryBean.java:211)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1514)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1452)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:519)rn at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:456)rn at org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:294)rn at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:225)rn at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:291)rn at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:193)rn at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:567)rn at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:913)rn at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:464)rn at org.springframework.web.context.ContextLoader.configureAndRefreshWebApplicationContext(ContextLoader.java:385)rn at org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:284)rn at org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:111)rn at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4206)rn at org.apache.catalina.core.StandardContext.start(StandardContext.java:4705)rn at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057)rn at org.apache.catalina.core.StandardHost.start(StandardHost.java:840)rn at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1057)rn at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:463)rn at org.apache.catalina.core.StandardService.start(StandardService.java:525)rn at org.apache.catalina.core.StandardServer.start(StandardServer.java:754)rn at org.apache.catalina.startup.Catalina.start(Catalina.java:595)rn at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)rn at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)rn at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)rn at java.lang.reflect.Method.invoke(Unknown Source)rn at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289)rn at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414)rn2013-1-24 23:49:20 org.hibernate.dialect.Dialect rnrnrn[b]配置文件如下:[/b]rnrnrn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn rn classpath:hibernate.cfg.xmlrn rn rn rnrn请诸位大神指教
sqlserver 还原数据库时报错
消息 3287,级别 16,状态 1,第 1 行rn设备“E:\backup\XXXX.bak” 上的文件 ID 1 的格式不正确,无法读取。rn消息 3013,级别 16,状态 1,第 1 行rnRESTORE DATABASE 正在异常终止。rnrn备份库是2012的还原到本机2016上,版本有影响吗?还是说备份坏了?有哪位知道的能告知一下吗,非常感谢啊
数据库中插入数据时报错
我在mysql中插入数据时报了下面的错误:rn#1366 - Incorrect string value: '\xE8\xA6\x85\xE8\x89\xB2...' for column 'cont' at row 1rn真的很奇怪,能插入成功过几次!rn然后就突然不能插入了!rn各位帮帮忙吧!谢谢了!
更新数据库数据时报错
大家在刷新数据库数据时有没有碰到这个错误啊:rn无法为更新定位行.一些值可能在最后一次读取后已更改.rn这个问题怎么解决啊!程序大概意思如下:rn AddSQL("SELECT * FROM DBO.USER_LINECARD WHERE USER_TELEPHONE=:telcode");rn AddParam("telcode",a->Telephone);rn ADOQuery1->Open();rn ADOQuery1->Edit();rn ADOQuery1->FieldByName("STAFF_TIME")->Value=Now();rn SetField("USER_NAME",a->UserName);rn SetField("USER_ADDR",a->UserAddr);rn SetField("USER_NOTE",a->Note);rn SetField("USER_MDF",a->VCode);rn SetField("USER_PORT",a->HCode);rn SetField("USER_OLDMDF",a->OldVCode);rn SetField("STAFF_SITE",Staff_Site);rn SetField("STAFF_NUM",Staff_Num);rn ADOQuery1->Post();rn ADOQuery1->Close();rnPost()的时候就报错了!大家帮帮忙啊!急!rn
附加SQL2008数据库时报错
在附加一个AdventureWorks2008_Data数据库时报错,提示如下:rnrnrnrnrnrn执行 Transact-SQL 语句或批处理时发生了异常。 (Microsoft.SqlServer.ConnectionInfo)rnrn------------------------------rnrn无法打开物理文件 "d:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\Documents"。操作系统错误 2:"2(系统找不到指定的文件。)"。rn出现文件激活错误。物理文件名 'd:\Program Files\Microsoft SQL Server\MSSQL10.MSSQLSERVER\MSSQL\DATA\Documents' 可能不正确。请诊断并更正其他错误,然后重试此操作。rn无法打开新数据库 'AdventureWorks2008'。CREATE DATABASE 中止。 (Microsoft SQL Server,错误: 5120)rnrn------------------------------rn请各位大侠帮忙看看,谢谢!
备份数据库时报错,什么原因?
Could not insert a backup or restore history/detailrnrecord in the msdb database. This may indicate a rnproblem with the msdb database. The backup/restorernoperation was still successful.
创建dbf数据库时报错
由于需要,现在要创建一个DBF文件,在添加数值型字段时报错“字段定义语法错误”rn语句如下rn"Create Table TableDBF (EmPID Char(10),EmpName Char(20),TotalMount N(8,2))"rn请问在创建dbf中数值型该怎么写
执行文件删除时,时而报错时而正常
我是做eclipse插件开发的,最近遇到个怪异的问题。r 先说实现内容:r r 刷新当前工程后(或者是目录),判断当前工程中是否存在 build.xml文件,若存在,则执行删除。r r 代码如下:r r r 现象:r r 执行多次,发现有时候能正常,有时候抛异常。异常信息为:删除资源文件出错。r r 而且,我要删除的这个文件始终没有被打开过。不知道什么原因,请有遇到过此种情况的朋友帮忙看一下 问题补充 java_user 写道 被其他进程加锁了r 请问有没有好的调试方法,比如说怎么找到被哪个操作或者进程占用了。或者好的解决办法,比如释放加锁的进程或者加一步判断等待空闲时在执行删除
相关热词 c# 去空格去转义符 c#用户登录窗体代码 c# 流 c# linux 可视化 c# mvc 返回图片 c# 像素空间 c# 日期 最后一天 c#字典序排序 c# 截屏取色 c#中的哪些属于托管机制