Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

hbase rest state scanner sometime can not get result

avatar
New Member

I do : curl -v -H "Content-Type: text/xml" -d '<Scanner batch="1"/>' http://10.148.10.2:9090/device_day_metric_kt/scanner

and get result with scannerid !

Sometime can get result, however most time can not get result ! why ? what's wrong ?

----------------------------------------------------------------------------------------------------------------------

[root@basic.internal.hadoop.10-148-10-80 KHTEST]# curl -v -H "Content-Type: text/xml" -d '<Scanner batch="1"/>'  http://10.148.10.2:9090/device_day_metric_kt/scanner
* About to connect() to 10.148.10.2 port 9090 (#0)
*   Trying 10.148.10.2... connected
* Connected to 10.148.10.2 (10.148.10.2) port 9090 (#0)
> POST /device_day_metric_kt/scanner HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.19.1 Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: 10.148.10.2:9090
> Accept: */*
> Content-Type: text/xml
> Content-Length: 20
> 
< HTTP/1.1 201 Created
< Location: http://10.148.10.2:9090/device_day_metric_kt/scanner/145589362659469f85bc0
< Content-Length: 0
< 
* Connection #0 to host 10.148.10.2 left intact
* Closing connection #0
[root@basic.internal.hadoop.10-148-10-80 KHTEST]# curl -v -H "Content-Type: text/xml" http://10.148.10.2:9090/device_day_metric_kt/scanner/145589362659469f85bc0
* About to connect() to 10.148.10.2 port 9090 (#0)
*   Trying 10.148.10.2... connected
* Connected to 10.148.10.2 (10.148.10.2) port 9090 (#0)
> GET /device_day_metric_kt/scanner/145589362659469f85bc0 HTTP/1.1
> User-Agent: curl/7.19.7 (x86_64-redhat-linux-gnu) libcurl/7.19.7 NSS/3.19.1 Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: 10.148.10.2:9090
> Accept: */*
> Content-Type: text/xml
> 
< HTTP/1.1 200 OK
< Content-Length: 3
< Cache-Control: no-cache
< X-Row: LTExNzI4MTI0MDI5NjE4MjAxNjAxMDQ=
< X-Column: ZW52OmVudl9jaXR5X2NvZGU=
< X-Timestamp: 1454044118503
< Content-Type: application/octet-stream
< 
* Connection #0 to host 10.148.10.2 left intact
* Closing connection #0
1 ACCEPTED SOLUTION

avatar
New Member
9 REPLIES 9

avatar
Master Mentor

@kang hua does the same get return result in hbase shell?

avatar
New Member

yes,get return data

avatar
Master Mentor

@kang hua

is there anything in /var/log/hbase/hbase-hbase-rest-servername.log?

avatar
New Member

avatar
Master Mentor

avatar
Master Mentor

avatar
New Member

scanner not get nothing, but only one cell value , not a whole row , and not any cf or qualifier, only cell!

avatar
New Member

Set Accept header to text/xml for XML encoding , But result like from "application/octet-stream for binary encoding" setting.

avatar
New Member