You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@phoenix.apache.org by iv...@gmail.com, iv...@gmail.com on 2018/03/28 21:38:15 UTC

"Unable to discover transaction service" prompt out when tried to create table with transaction = true

Hi, I was trying to enable the transaction function of Phoenix on my hbase.  but I keep getting the "Unable to discover transaction service" problem.
My setting:
1. Single node running on a docker.  
2. HBase configured as pseudo distributed mode(Hbase manages zookeeper)
3. HBase version 1.2.6, Phoenix: 4.13.1, sqlline 1.2.0
4. I put below setting to both hbase-site.xml in folder /phoenix/bin/ and /hbase/conf/:
<property>
  <name>phoenix.transactions.enabled</name>
  <value>true</value>
</property>
<property>
  <name>data.tx.snapshot.dir</name>
  <value>/tmp/tephra/snapshots</value>
</property>
<property>
  <name>data.tx.timeout</name>
  <value>60</value>
</property>

Steps:
1.  setup above two hbase-site.xml.
2.  start hbase.
3. start tephra with command: tephra start     ---> i also put the phoenix/bin to classpath.
4. tephra running normally and no exception.
5. sqlline.py myServerName:2181
6. after get into sqlline mode, basic command of phoenix no problem,  I can also create table without transaction enabled.
7. when I do below transaction enabling command, the issue prompt out
CREATE TABLE my_table (k BIGINT PRIMARY KEY, v VARCHAR) TRANSACTIONAL=true;

seems the transaction manager cannot be found when I trigger transaction related action.
I did some research and found that the transaction manager will register itself to zookeeper and any transactional action will automatically find the manager and get the transaction thing done through it.
I am wondering if the hbase managed zookeeper works for phoenix transaction.   or what error i did and lead to the problem.




Re: "Unable to discover transaction service" prompt out when tried to create table with transaction = true

Posted by Ivanybma gmail <iv...@gmail.com>.
Thank you very much. I replaced it and the problem is solved.

Sent from my iPhone

> On Mar 28, 2018, at 18:43, James Taylor <ja...@apache.org> wrote:
> 
> I suspect the issue may be due to the version of Guava in the hbase/lib directory being too old. Try replacing it with a newer one - I think Tephra needs Guava 14 or above.
> 
>> On Wed, Mar 28, 2018 at 2:38 PM ivanybma@gmail.com <iv...@gmail.com> wrote:
>> Hi, I was trying to enable the transaction function of Phoenix on my hbase.  but I keep getting the "Unable to discover transaction service" problem.
>> My setting:
>> 1. Single node running on a docker.
>> 2. HBase configured as pseudo distributed mode(Hbase manages zookeeper)
>> 3. HBase version 1.2.6, Phoenix: 4.13.1, sqlline 1.2.0
>> 4. I put below setting to both hbase-site.xml in folder /phoenix/bin/ and /hbase/conf/:
>> <property>
>>   <name>phoenix.transactions.enabled</name>
>>   <value>true</value>
>> </property>
>> <property>
>>   <name>data.tx.snapshot.dir</name>
>>   <value>/tmp/tephra/snapshots</value>
>> </property>
>> <property>
>>   <name>data.tx.timeout</name>
>>   <value>60</value>
>> </property>
>> 
>> Steps:
>> 1.  setup above two hbase-site.xml.
>> 2.  start hbase.
>> 3. start tephra with command: tephra start     ---> i also put the phoenix/bin to classpath.
>> 4. tephra running normally and no exception.
>> 5. sqlline.py myServerName:2181
>> 6. after get into sqlline mode, basic command of phoenix no problem,  I can also create table without transaction enabled.
>> 7. when I do below transaction enabling command, the issue prompt out
>> CREATE TABLE my_table (k BIGINT PRIMARY KEY, v VARCHAR) TRANSACTIONAL=true;
>> 
>> seems the transaction manager cannot be found when I trigger transaction related action.
>> I did some research and found that the transaction manager will register itself to zookeeper and any transactional action will automatically find the manager and get the transaction thing done through it.
>> I am wondering if the hbase managed zookeeper works for phoenix transaction.   or what error i did and lead to the problem.
>> 
>> 
>> 

Re: "Unable to discover transaction service" prompt out when tried to create table with transaction = true

Posted by James Taylor <ja...@apache.org>.
I suspect the issue may be due to the version of Guava in the hbase/lib
directory being too old. Try replacing it with a newer one - I think Tephra
needs Guava 14 or above.

On Wed, Mar 28, 2018 at 2:38 PM ivanybma@gmail.com <iv...@gmail.com>
wrote:

> Hi, I was trying to enable the transaction function of Phoenix on my
> hbase.  but I keep getting the "Unable to discover transaction service"
> problem.
> My setting:
> 1. Single node running on a docker.
> 2. HBase configured as pseudo distributed mode(Hbase manages zookeeper)
> 3. HBase version 1.2.6, Phoenix: 4.13.1, sqlline 1.2.0
> 4. I put below setting to both hbase-site.xml in folder /phoenix/bin/ and
> /hbase/conf/:
> <property>
>   <name>phoenix.transactions.enabled</name>
>   <value>true</value>
> </property>
> <property>
>   <name>data.tx.snapshot.dir</name>
>   <value>/tmp/tephra/snapshots</value>
> </property>
> <property>
>   <name>data.tx.timeout</name>
>   <value>60</value>
> </property>
>
> Steps:
> 1.  setup above two hbase-site.xml.
> 2.  start hbase.
> 3. start tephra with command: tephra start     ---> i also put the
> phoenix/bin to classpath.
> 4. tephra running normally and no exception.
> 5. sqlline.py myServerName:2181
> 6. after get into sqlline mode, basic command of phoenix no problem,  I
> can also create table without transaction enabled.
> 7. when I do below transaction enabling command, the issue prompt out
> CREATE TABLE my_table (k BIGINT PRIMARY KEY, v VARCHAR) TRANSACTIONAL=true;
>
> seems the transaction manager cannot be found when I trigger transaction
> related action.
> I did some research and found that the transaction manager will register
> itself to zookeeper and any transactional action will automatically find
> the manager and get the transaction thing done through it.
> I am wondering if the hbase managed zookeeper works for phoenix
> transaction.   or what error i did and lead to the problem.
>
>
>
>