You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-user@hadoop.apache.org by Billy <sa...@pearsonwholesale.com> on 2007/12/31 00:56:10 UTC

REST scanner get error 500 0x1b is not valid

On one of my tables I get this when trying to get results from a scanner

I call for the scanner location and get it fine but on the first call I get 
the below error

Error 500 The character 0x1b is not valid.

Not sure if this has to do with with the first row in my table but that 
should not cause the scanner to return 500 error

I can open scanner on other tables this one is the only one doing this 
error.

I tryed to delete the first row but no luck it will not delete useing shell 
or rest. I have tryed several ways includeing urlencodeing the row key and 
the col name but no luck

First row in the table that would be called from the scanner and below curl 
results with 500 error.



hql > select * from anchors limit = 1;
+-------------------------+-------------------------+-------------------------+
| Row                     | Column                  | Cell 
|
+-------------------------+-------------------------+-------------------------+
| !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma| 1                       |
| "4d6-$n=                | in/seisaku/index.htm:htt| 
|
|                         | p                       | 
|
+-------------------------+-------------------------+-------------------------+
1 row(s) in set. (0.61 sec)


[root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
/tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?column=url:
* About to connect() to 192.168.1.200 port 60010
*   Trying 192.168.1.200... * connected
* Connected to 192.168.1.200 (192.168.1.200) port 60010
> PUT /api/anchors/scanner?column=url: HTTP/1.1
User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
Host: 192.168.1.200:60010
Pragma: no-cache
Accept: text/xml
Content-Length: 1
Expect: 100-continue

< HTTP/1.1 100 Continue
< HTTP/1.1 201 Created
< Date: Sun, 30 Dec 2007 23:23:46 GMT
< Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
< Location: /api/anchors/scanner/a99db67
< Content-Length: 0
* Connection #0 to host 192.168.1.200 left intact
* Closing connection #0
[root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
/tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
* About to connect() to 192.168.1.200 port 60010
*   Trying 192.168.1.200... * connected
* Connected to 192.168.1.200 (192.168.1.200) port 60010
> PUT /api/anchors/scanner/a99db67 HTTP/1.1
User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
Host: 192.168.1.200:60010
Pragma: no-cache
Accept: text/xml
Content-Length: 1
Expect: 100-continue

< HTTP/1.1 100 Continue
< HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
< Date: Sun, 30 Dec 2007 23:24:02 GMT
< Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
< Content-Type: text/html;charset=UTF-8
< Content-Length: 1286
< Connection: close
<html>
<head>
<title>Error 500 The character 0x1b is not valid.</title>
</head>
<body>
<h2>HTTP ERROR: 500</h2><pre>The character 0x1b is not valid.</pre>
<p>RequestURI=/api/anchors/scanner/a99db67</p>
<p><i><small><a href="http://jetty.mortbay.org">Powered by 
Jetty://</a></small></i></p>
</body>
</html>
* Closing connection #0





Re: REST scanner get error 500 0x1b is not valid

Posted by Billy <sa...@pearsonwholesale.com>.
This might have something to do with the new patch
https://issues.apache.org/jira/browse/HADOOP-2503

I have this patched applied

I thank it might be letting me insert rows/columns that is not code safe to 
return on selects

Billy


"Billy" <sa...@pearsonwholesale.com> wrote in 
message news:fl9b6v$pgd$1@ger.gmane.org...
> On one of my tables I get this when trying to get results from a scanner
>
> I call for the scanner location and get it fine but on the first call I 
> get the below error
>
> Error 500 The character 0x1b is not valid.
>
> Not sure if this has to do with with the first row in my table but that 
> should not cause the scanner to return 500 error
>
> I can open scanner on other tables this one is the only one doing this 
> error.
>
> I tryed to delete the first row but no luck it will not delete useing 
> shell or rest. I have tryed several ways includeing urlencodeing the row 
> key and the col name but no luck
>
> First row in the table that would be called from the scanner and below 
> curl results with 500 error.
>
>
>
> hql > select * from anchors limit = 1;
> +-------------------------+-------------------------+-------------------------+
> | Row                     | Column                  | Cell |
> +-------------------------+-------------------------+-------------------------+
> | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma| 1 
> |
> | "4d6-$n=                | in/seisaku/index.htm:htt| |
> |                         | p                       | |
> +-------------------------+-------------------------+-------------------------+
> 1 row(s) in set. (0.61 sec)
>
>
> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?column=url:
> * About to connect() to 192.168.1.200 port 60010
> *   Trying 192.168.1.200... * connected
> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>> PUT /api/anchors/scanner?column=url: HTTP/1.1
> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> Host: 192.168.1.200:60010
> Pragma: no-cache
> Accept: text/xml
> Content-Length: 1
> Expect: 100-continue
>
> < HTTP/1.1 100 Continue
> < HTTP/1.1 201 Created
> < Date: Sun, 30 Dec 2007 23:23:46 GMT
> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
> < Location: /api/anchors/scanner/a99db67
> < Content-Length: 0
> * Connection #0 to host 192.168.1.200 left intact
> * Closing connection #0
> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
> * About to connect() to 192.168.1.200 port 60010
> *   Trying 192.168.1.200... * connected
> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>> PUT /api/anchors/scanner/a99db67 HTTP/1.1
> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> Host: 192.168.1.200:60010
> Pragma: no-cache
> Accept: text/xml
> Content-Length: 1
> Expect: 100-continue
>
> < HTTP/1.1 100 Continue
> < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
> < Date: Sun, 30 Dec 2007 23:24:02 GMT
> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
> < Content-Type: text/html;charset=UTF-8
> < Content-Length: 1286
> < Connection: close
> <html>
> <head>
> <title>Error 500 The character 0x1b is not valid.</title>
> </head>
> <body>
> <h2>HTTP ERROR: 500</h2><pre>The character 0x1b is not valid.</pre>
> <p>RequestURI=/api/anchors/scanner/a99db67</p>
> <p><i><small><a href="http://jetty.mortbay.org">Powered by 
> Jetty://</a></small></i></p>
> </body>
> </html>
> * Closing connection #0
>
>
>
>
> 




Re: REST scanner get error 500 0x1b is not valid

Posted by Billy Pearson <sa...@pearsonwholesale.com>.


I found out that if I keep calling the scanner it will still return results 
but the 500 error was causing my script to assume it was finished. vary hard 
to tell what exactly is messing it up causing the 500 error because it does 
not return anything. I am guessing that its something like a ' or " or 
something along those lines breaking the java code.

Billy


----- Original Message ----- 
From: "Billy" <sa...@public.gmane.org>
Newsgroups: gmane.comp.jakarta.lucene.hadoop.user
To: <ha...@public.gmane.org>
Sent: Monday, December 31, 2007 4:03 PM
Subject: Re: REST scanner get error 500 0x1b is not valid


>I have added some filters to filter out some bad data but I am getting a 
>different error now
>
> Error 500 The character 0x0 is not valid.
>
> Maybe the row key should be returned as urlencoded or something.
>
> Billy
>
>
>
>
>
> "Billy" <sa...@public.gmane.org> wrote in 
> message news:fl9b6v$pgd$1@ger.gmane.org...
>> On one of my tables I get this when trying to get results from a scanner
>>
>> I call for the scanner location and get it fine but on the first call I 
>> get the below error
>>
>> Error 500 The character 0x1b is not valid.
>>
>> Not sure if this has to do with with the first row in my table but that 
>> should not cause the scanner to return 500 error
>>
>> I can open scanner on other tables this one is the only one doing this 
>> error.
>>
>> I tryed to delete the first row but no luck it will not delete useing 
>> shell or rest. I have tryed several ways includeing urlencodeing the row 
>> key and the col name but no luck
>>
>> First row in the table that would be called from the scanner and below 
>> curl results with 500 error.
>>
>>
>>
>> hql > select * from anchors limit = 1;
>> +-------------------------+-------------------------+-------------------------+
>> | Row                     | Column                  | Cell |
>> +-------------------------+-------------------------+-------------------------+
>> | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma| 1 |
>> | "4d6-$n=                | in/seisaku/index.htm:htt| |
>> |                         | p                       | |
>> +-------------------------+-------------------------+-------------------------+
>> 1 row(s) in set. (0.61 sec)
>>
>>
>> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
>> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?column=url:
>> * About to connect() to 192.168.1.200 port 60010
>> *   Trying 192.168.1.200... * connected
>> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>>> PUT /api/anchors/scanner?column=url: HTTP/1.1
>> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
>> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
>> Host: 192.168.1.200:60010
>> Pragma: no-cache
>> Accept: text/xml
>> Content-Length: 1
>> Expect: 100-continue
>>
>> < HTTP/1.1 100 Continue
>> < HTTP/1.1 201 Created
>> < Date: Sun, 30 Dec 2007 23:23:46 GMT
>> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
>> < Location: /api/anchors/scanner/a99db67
>> < Content-Length: 0
>> * Connection #0 to host 192.168.1.200 left intact
>> * Closing connection #0
>> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
>> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
>> * About to connect() to 192.168.1.200 port 60010
>> *   Trying 192.168.1.200... * connected
>> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>>> PUT /api/anchors/scanner/a99db67 HTTP/1.1
>> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
>> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
>> Host: 192.168.1.200:60010
>> Pragma: no-cache
>> Accept: text/xml
>> Content-Length: 1
>> Expect: 100-continue
>>
>> < HTTP/1.1 100 Continue
>> < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
>> < Date: Sun, 30 Dec 2007 23:24:02 GMT
>> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
>> < Content-Type: text/html;charset=UTF-8
>> < Content-Length: 1286
>> < Connection: close
>> <html>
>> <head>
>> <title>Error 500 The character 0x1b is not valid.</title>
>> </head>
>> <body>
>> <h2>HTTP ERROR: 500</h2><pre>The character 0x1b is not valid.</pre>
>> <p>RequestURI=/api/anchors/scanner/a99db67</p>
>> <p><i><small><a href="http://jetty.mortbay.org">Powered by 
>> Jetty://</a></small></i></p>
>> </body>
>> </html>
>> * Closing connection #0
>>
>>
>>
>>
>>
>
>
>
> 





Re: REST scanner get error 500 0x1b is not valid

Posted by Billy <sa...@pearsonwholesale.com>.
I have added some filters to filter out some bad data but I am getting a 
different error now

Error 500 The character 0x0 is not valid.

Maybe the row key should be returned as urlencoded or something.

Billy





"Billy" <sa...@pearsonwholesale.com> wrote in 
message news:fl9b6v$pgd$1@ger.gmane.org...
> On one of my tables I get this when trying to get results from a scanner
>
> I call for the scanner location and get it fine but on the first call I 
> get the below error
>
> Error 500 The character 0x1b is not valid.
>
> Not sure if this has to do with with the first row in my table but that 
> should not cause the scanner to return 500 error
>
> I can open scanner on other tables this one is the only one doing this 
> error.
>
> I tryed to delete the first row but no luck it will not delete useing 
> shell or rest. I have tryed several ways includeing urlencodeing the row 
> key and the col name but no luck
>
> First row in the table that would be called from the scanner and below 
> curl results with 500 error.
>
>
>
> hql > select * from anchors limit = 1;
> +-------------------------+-------------------------+-------------------------+
> | Row                     | Column                  | Cell |
> +-------------------------+-------------------------+-------------------------+
> | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma| 1 
> |
> | "4d6-$n=                | in/seisaku/index.htm:htt| |
> |                         | p                       | |
> +-------------------------+-------------------------+-------------------------+
> 1 row(s) in set. (0.61 sec)
>
>
> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?column=url:
> * About to connect() to 192.168.1.200 port 60010
> *   Trying 192.168.1.200... * connected
> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>> PUT /api/anchors/scanner?column=url: HTTP/1.1
> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> Host: 192.168.1.200:60010
> Pragma: no-cache
> Accept: text/xml
> Content-Length: 1
> Expect: 100-continue
>
> < HTTP/1.1 100 Continue
> < HTTP/1.1 201 Created
> < Date: Sun, 30 Dec 2007 23:23:46 GMT
> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
> < Location: /api/anchors/scanner/a99db67
> < Content-Length: 0
> * Connection #0 to host 192.168.1.200 left intact
> * Closing connection #0
> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T 
> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
> * About to connect() to 192.168.1.200 port 60010
> *   Trying 192.168.1.200... * connected
> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>> PUT /api/anchors/scanner/a99db67 HTTP/1.1
> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1 
> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> Host: 192.168.1.200:60010
> Pragma: no-cache
> Accept: text/xml
> Content-Length: 1
> Expect: 100-continue
>
> < HTTP/1.1 100 Continue
> < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
> < Date: Sun, 30 Dec 2007 23:24:02 GMT
> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
> < Content-Type: text/html;charset=UTF-8
> < Content-Length: 1286
> < Connection: close
> <html>
> <head>
> <title>Error 500 The character 0x1b is not valid.</title>
> </head>
> <body>
> <h2>HTTP ERROR: 500</h2><pre>The character 0x1b is not valid.</pre>
> <p>RequestURI=/api/anchors/scanner/a99db67</p>
> <p><i><small><a href="http://jetty.mortbay.org">Powered by 
> Jetty://</a></small></i></p>
> </body>
> </html>
> * Closing connection #0
>
>
>
>
> 




Re: REST scanner get error 500 0x1b is not valid

Posted by Bryan Duxbury <br...@rapleaf.com>.
See 2507 for a patch. Let me know if this solves your problem, Billy.

-Bryan

On Dec 31, 2007, at 3:55 PM, Bryan Duxbury wrote:

> If keys and column names can be any arbitrary byte string, then  
> definitely the REST servlet is not taking care of that right now.  
> The answer is just base64 encoding all that stuff on gets as well.  
> I'll create a new ticket.
>
> -Bryan
>
> On Dec 31, 2007, at 3:29 PM, Jim Kellerman wrote:
>
>>> -----Original Message-----
>>> From: Bryan Duxbury [mailto:bryan@rapleaf.com]
>>> Sent: Monday, December 31, 2007 2:46 PM
>>> To: hadoop-user@lucene.apache.org
>>> Subject: Re: REST scanner get error 500 0x1b is not valid
>>>
>>> You're probably right - column names are not base64 encoded.
>>> Isn't the contract of row/column keys printable strings?
>>
>> No. row keys do not need to be printable strings. In the future,
>> they may be changed to an arbitrary WritableComparable, even
>> less restrictive than Text.
>>
>> Column family names are restricted to the set: \w+:
>>
>> There is no restriction on the names of a column family member
>> (the part of the column key after the initial ':')
>>
>> Table names are restricted to the set of characters: [\w-.]+
>> except that table names starting with either '-' or '.' are
>> reserved for HBase internal use.
>>
>>> If
>>> so, then putting images in that field would appear to be a
>>> mismatch. Even if you need to use images as qualifiers,
>>> wouldn't it be more efficient to use an md5 of the image
>>> rather than the actual image?
>>>
>>> -Bryan
>>>
>>> On Dec 30, 2007, at 3:56 PM, Billy wrote:
>>>
>>>> On one of my tables I get this when trying to get results from a
>>>> scanner
>>>>
>>>> I call for the scanner location and get it fine but on the
>>> first call
>>>> I get the below error
>>>>
>>>> Error 500 The character 0x1b is not valid.
>>>>
>>>> Not sure if this has to do with with the first row in my table but
>>>> that should not cause the scanner to return 500 error
>>>>
>>>> I can open scanner on other tables this one is the only one
>>> doing this
>>>> error.
>>>>
>>>> I tryed to delete the first row but no luck it will not
>>> delete useing
>>>> shell or rest. I have tryed several ways includeing
>>> urlencodeing the
>>>> row key and the col name but no luck
>>>>
>>>> First row in the table that would be called from the
>>> scanner and below
>>>> curl results with 500 error.
>>>>
>>>>
>>>>
>>>> hql > select * from anchors limit = 1;
>>>> +-------------------------+-------------------------
>>>> +-------------------------+
>>>> | Row                     | Column                  | Cell
>>>> |
>>>> +-------------------------+-------------------------
>>>> +-------------------------+
>>>> | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma|
>>>> 1                       |
>>>> | "4d6-$n=                | in/seisaku/index.htm:htt|
>>>> |
>>>> |                         | p                       |
>>>> |
>>>> +-------------------------+-------------------------
>>>> +-------------------------+
>>>> 1 row(s) in set. (0.61 sec)
>>>>
>>>>
>>>> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
>>>> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?
>>>> column=url:
>>>> * About to connect() to 192.168.1.200 port 60010
>>>> *   Trying 192.168.1.200... * connected
>>>> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>>>>> PUT /api/anchors/scanner?column=url: HTTP/1.1
>>>> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
>>>> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
>>>> Host: 192.168.1.200:60010
>>>> Pragma: no-cache
>>>> Accept: text/xml
>>>> Content-Length: 1
>>>> Expect: 100-continue
>>>>
>>>> < HTTP/1.1 100 Continue
>>>> < HTTP/1.1 201 Created
>>>> < Date: Sun, 30 Dec 2007 23:23:46 GMT
>>>> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386
>>> java/1.5.0_12 <
>>>> Location: /api/anchors/scanner/a99db67 < Content-Length: 0
>>>> * Connection #0 to host 192.168.1.200 left intact
>>>> * Closing connection #0
>>>> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
>>>> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/ 
>>>> a99db67
>>>> * About to connect() to 192.168.1.200 port 60010
>>>> *   Trying 192.168.1.200... * connected
>>>> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>>>>> PUT /api/anchors/scanner/a99db67 HTTP/1.1
>>>> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
>>>> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
>>>> Host: 192.168.1.200:60010
>>>> Pragma: no-cache
>>>> Accept: text/xml
>>>> Content-Length: 1
>>>> Expect: 100-continue
>>>>
>>>> < HTTP/1.1 100 Continue
>>>> < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
>>>> < Date: Sun, 30 Dec 2007 23:24:02 GMT
>>>> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386
>>> java/1.5.0_12 <
>>>> Content-Type: text/html;charset=UTF-8 < Content-Length: 1286 <
>>>> Connection: close <html> <head> <title>Error 500 The
>>> character 0x1b is
>>>> not valid.</title> </head> <body> <h2>HTTP ERROR: 500</h2><pre>The
>>>> character 0x1b is not valid.</pre>
>>>> <p>RequestURI=/api/anchors/scanner/a99db67</p>
>>>> <p><i><small><a href="http://jetty.mortbay.org">Powered by
>>>> Jetty://</a></small></i></p> </body> </html>
>>>> * Closing connection #0
>>>>
>>>>
>>>>
>>>>
>>>
>>>
>


Re: REST scanner get error 500 0x1b is not valid

Posted by Bryan Duxbury <br...@rapleaf.com>.
If keys and column names can be any arbitrary byte string, then  
definitely the REST servlet is not taking care of that right now. The  
answer is just base64 encoding all that stuff on gets as well. I'll  
create a new ticket.

-Bryan

On Dec 31, 2007, at 3:29 PM, Jim Kellerman wrote:

>> -----Original Message-----
>> From: Bryan Duxbury [mailto:bryan@rapleaf.com]
>> Sent: Monday, December 31, 2007 2:46 PM
>> To: hadoop-user@lucene.apache.org
>> Subject: Re: REST scanner get error 500 0x1b is not valid
>>
>> You're probably right - column names are not base64 encoded.
>> Isn't the contract of row/column keys printable strings?
>
> No. row keys do not need to be printable strings. In the future,
> they may be changed to an arbitrary WritableComparable, even
> less restrictive than Text.
>
> Column family names are restricted to the set: \w+:
>
> There is no restriction on the names of a column family member
> (the part of the column key after the initial ':')
>
> Table names are restricted to the set of characters: [\w-.]+
> except that table names starting with either '-' or '.' are
> reserved for HBase internal use.
>
>> If
>> so, then putting images in that field would appear to be a
>> mismatch. Even if you need to use images as qualifiers,
>> wouldn't it be more efficient to use an md5 of the image
>> rather than the actual image?
>>
>> -Bryan
>>
>> On Dec 30, 2007, at 3:56 PM, Billy wrote:
>>
>>> On one of my tables I get this when trying to get results from a
>>> scanner
>>>
>>> I call for the scanner location and get it fine but on the
>> first call
>>> I get the below error
>>>
>>> Error 500 The character 0x1b is not valid.
>>>
>>> Not sure if this has to do with with the first row in my table but
>>> that should not cause the scanner to return 500 error
>>>
>>> I can open scanner on other tables this one is the only one
>> doing this
>>> error.
>>>
>>> I tryed to delete the first row but no luck it will not
>> delete useing
>>> shell or rest. I have tryed several ways includeing
>> urlencodeing the
>>> row key and the col name but no luck
>>>
>>> First row in the table that would be called from the
>> scanner and below
>>> curl results with 500 error.
>>>
>>>
>>>
>>> hql > select * from anchors limit = 1;
>>> +-------------------------+-------------------------
>>> +-------------------------+
>>> | Row                     | Column                  | Cell
>>> |
>>> +-------------------------+-------------------------
>>> +-------------------------+
>>> | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma|
>>> 1                       |
>>> | "4d6-$n=                | in/seisaku/index.htm:htt|
>>> |
>>> |                         | p                       |
>>> |
>>> +-------------------------+-------------------------
>>> +-------------------------+
>>> 1 row(s) in set. (0.61 sec)
>>>
>>>
>>> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
>>> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?
>>> column=url:
>>> * About to connect() to 192.168.1.200 port 60010
>>> *   Trying 192.168.1.200... * connected
>>> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>>>> PUT /api/anchors/scanner?column=url: HTTP/1.1
>>> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
>>> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
>>> Host: 192.168.1.200:60010
>>> Pragma: no-cache
>>> Accept: text/xml
>>> Content-Length: 1
>>> Expect: 100-continue
>>>
>>> < HTTP/1.1 100 Continue
>>> < HTTP/1.1 201 Created
>>> < Date: Sun, 30 Dec 2007 23:23:46 GMT
>>> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386
>> java/1.5.0_12 <
>>> Location: /api/anchors/scanner/a99db67 < Content-Length: 0
>>> * Connection #0 to host 192.168.1.200 left intact
>>> * Closing connection #0
>>> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
>>> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
>>> * About to connect() to 192.168.1.200 port 60010
>>> *   Trying 192.168.1.200... * connected
>>> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>>>> PUT /api/anchors/scanner/a99db67 HTTP/1.1
>>> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
>>> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
>>> Host: 192.168.1.200:60010
>>> Pragma: no-cache
>>> Accept: text/xml
>>> Content-Length: 1
>>> Expect: 100-continue
>>>
>>> < HTTP/1.1 100 Continue
>>> < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
>>> < Date: Sun, 30 Dec 2007 23:24:02 GMT
>>> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386
>> java/1.5.0_12 <
>>> Content-Type: text/html;charset=UTF-8 < Content-Length: 1286 <
>>> Connection: close <html> <head> <title>Error 500 The
>> character 0x1b is
>>> not valid.</title> </head> <body> <h2>HTTP ERROR: 500</h2><pre>The
>>> character 0x1b is not valid.</pre>
>>> <p>RequestURI=/api/anchors/scanner/a99db67</p>
>>> <p><i><small><a href="http://jetty.mortbay.org">Powered by
>>> Jetty://</a></small></i></p> </body> </html>
>>> * Closing connection #0
>>>
>>>
>>>
>>>
>>
>>


RE: REST scanner get error 500 0x1b is not valid

Posted by Jim Kellerman <ji...@powerset.com>.
> -----Original Message-----
> From: Bryan Duxbury [mailto:bryan@rapleaf.com]
> Sent: Monday, December 31, 2007 2:46 PM
> To: hadoop-user@lucene.apache.org
> Subject: Re: REST scanner get error 500 0x1b is not valid
>
> You're probably right - column names are not base64 encoded.
> Isn't the contract of row/column keys printable strings?

No. row keys do not need to be printable strings. In the future,
they may be changed to an arbitrary WritableComparable, even
less restrictive than Text.

Column family names are restricted to the set: \w+:

There is no restriction on the names of a column family member
(the part of the column key after the initial ':')

Table names are restricted to the set of characters: [\w-.]+
except that table names starting with either '-' or '.' are
reserved for HBase internal use.

> If
> so, then putting images in that field would appear to be a
> mismatch. Even if you need to use images as qualifiers,
> wouldn't it be more efficient to use an md5 of the image
> rather than the actual image?
>
> -Bryan
>
> On Dec 30, 2007, at 3:56 PM, Billy wrote:
>
> > On one of my tables I get this when trying to get results from a
> > scanner
> >
> > I call for the scanner location and get it fine but on the
> first call
> > I get the below error
> >
> > Error 500 The character 0x1b is not valid.
> >
> > Not sure if this has to do with with the first row in my table but
> > that should not cause the scanner to return 500 error
> >
> > I can open scanner on other tables this one is the only one
> doing this
> > error.
> >
> > I tryed to delete the first row but no luck it will not
> delete useing
> > shell or rest. I have tryed several ways includeing
> urlencodeing the
> > row key and the col name but no luck
> >
> > First row in the table that would be called from the
> scanner and below
> > curl results with 500 error.
> >
> >
> >
> > hql > select * from anchors limit = 1;
> > +-------------------------+-------------------------
> > +-------------------------+
> > | Row                     | Column                  | Cell
> > |
> > +-------------------------+-------------------------
> > +-------------------------+
> > | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma|
> > 1                       |
> > | "4d6-$n=                | in/seisaku/index.htm:htt|
> > |
> > |                         | p                       |
> > |
> > +-------------------------+-------------------------
> > +-------------------------+
> > 1 row(s) in set. (0.61 sec)
> >
> >
> > [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
> > /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner?
> > column=url:
> > * About to connect() to 192.168.1.200 port 60010
> > *   Trying 192.168.1.200... * connected
> > * Connected to 192.168.1.200 (192.168.1.200) port 60010
> >> PUT /api/anchors/scanner?column=url: HTTP/1.1
> > User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
> > OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> > Host: 192.168.1.200:60010
> > Pragma: no-cache
> > Accept: text/xml
> > Content-Length: 1
> > Expect: 100-continue
> >
> > < HTTP/1.1 100 Continue
> > < HTTP/1.1 201 Created
> > < Date: Sun, 30 Dec 2007 23:23:46 GMT
> > < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386
> java/1.5.0_12 <
> > Location: /api/anchors/scanner/a99db67 < Content-Length: 0
> > * Connection #0 to host 192.168.1.200 left intact
> > * Closing connection #0
> > [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
> > /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
> > * About to connect() to 192.168.1.200 port 60010
> > *   Trying 192.168.1.200... * connected
> > * Connected to 192.168.1.200 (192.168.1.200) port 60010
> >> PUT /api/anchors/scanner/a99db67 HTTP/1.1
> > User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
> > OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> > Host: 192.168.1.200:60010
> > Pragma: no-cache
> > Accept: text/xml
> > Content-Length: 1
> > Expect: 100-continue
> >
> > < HTTP/1.1 100 Continue
> > < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
> > < Date: Sun, 30 Dec 2007 23:24:02 GMT
> > < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386
> java/1.5.0_12 <
> > Content-Type: text/html;charset=UTF-8 < Content-Length: 1286 <
> > Connection: close <html> <head> <title>Error 500 The
> character 0x1b is
> > not valid.</title> </head> <body> <h2>HTTP ERROR: 500</h2><pre>The
> > character 0x1b is not valid.</pre>
> > <p>RequestURI=/api/anchors/scanner/a99db67</p>
> > <p><i><small><a href="http://jetty.mortbay.org">Powered by
> > Jetty://</a></small></i></p> </body> </html>
> > * Closing connection #0
> >
> >
> >
> >
>
>

Re: REST scanner get error 500 0x1b is not valid

Posted by Bryan Duxbury <br...@rapleaf.com>.
You're probably right - column names are not base64 encoded. Isn't  
the contract of row/column keys printable strings? If so, then  
putting images in that field would appear to be a mismatch. Even if  
you need to use images as qualifiers, wouldn't it be more efficient  
to use an md5 of the image rather than the actual image?

-Bryan

On Dec 30, 2007, at 3:56 PM, Billy wrote:

> On one of my tables I get this when trying to get results from a  
> scanner
>
> I call for the scanner location and get it fine but on the first  
> call I get
> the below error
>
> Error 500 The character 0x1b is not valid.
>
> Not sure if this has to do with with the first row in my table but  
> that
> should not cause the scanner to return 500 error
>
> I can open scanner on other tables this one is the only one doing this
> error.
>
> I tryed to delete the first row but no luck it will not delete  
> useing shell
> or rest. I have tryed several ways includeing urlencodeing the row  
> key and
> the col name but no luck
>
> First row in the table that would be called from the scanner and  
> below curl
> results with 500 error.
>
>
>
> hql > select * from anchors limit = 1;
> +-------------------------+------------------------- 
> +-------------------------+
> | Row                     | Column                  | Cell
> |
> +-------------------------+------------------------- 
> +-------------------------+
> | !vj!;c!"$/$i$7!"650i!| url:net.jcp-tokyo.www/ma|  
> 1                       |
> | "4d6-$n=                | in/seisaku/index.htm:htt|
> |
> |                         | p                       |
> |
> +-------------------------+------------------------- 
> +-------------------------+
> 1 row(s) in set. (0.61 sec)
>
>
> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner? 
> column=url:
> * About to connect() to 192.168.1.200 port 60010
> *   Trying 192.168.1.200... * connected
> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>> PUT /api/anchors/scanner?column=url: HTTP/1.1
> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> Host: 192.168.1.200:60010
> Pragma: no-cache
> Accept: text/xml
> Content-Length: 1
> Expect: 100-continue
>
> < HTTP/1.1 100 Continue
> < HTTP/1.1 201 Created
> < Date: Sun, 30 Dec 2007 23:23:46 GMT
> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
> < Location: /api/anchors/scanner/a99db67
> < Content-Length: 0
> * Connection #0 to host 192.168.1.200 left intact
> * Closing connection #0
> [root@PE1750-1 ~]# curl --verbose --header 'Accept: text/xml' -T
> /tmp/diff.txt http://192.168.1.200:60010/api/anchors/scanner/a99db67
> * About to connect() to 192.168.1.200 port 60010
> *   Trying 192.168.1.200... * connected
> * Connected to 192.168.1.200 (192.168.1.200) port 60010
>> PUT /api/anchors/scanner/a99db67 HTTP/1.1
> User-Agent: curl/7.12.1 (i686-redhat-linux-gnu) libcurl/7.12.1
> OpenSSL/0.9.7a zlib/1.2.1.2 libidn/0.5.6
> Host: 192.168.1.200:60010
> Pragma: no-cache
> Accept: text/xml
> Content-Length: 1
> Expect: 100-continue
>
> < HTTP/1.1 100 Continue
> < HTTP/1.1 500 The+character+0x1b+is+not+valid%2E
> < Date: Sun, 30 Dec 2007 23:24:02 GMT
> < Server: Jetty/5.1.4 (Linux/2.6.9-67.0.1.ELsmp i386 java/1.5.0_12
> < Content-Type: text/html;charset=UTF-8
> < Content-Length: 1286
> < Connection: close
> <html>
> <head>
> <title>Error 500 The character 0x1b is not valid.</title>
> </head>
> <body>
> <h2>HTTP ERROR: 500</h2><pre>The character 0x1b is not valid.</pre>
> <p>RequestURI=/api/anchors/scanner/a99db67</p>
> <p><i><small><a href="http://jetty.mortbay.org">Powered by
> Jetty://</a></small></i></p>
> </body>
> </html>
> * Closing connection #0
>
>
>
>