Re: 回复: 回复: 回复: Can query server run with hadoop ha mode?
I was going to say that https://issues.apache.org/jira/browse/PHOENIX-3223 might be related, but it looks like the HADOOP_CONF_DIR is already put on the classpath. Glad to see you goth this working :) On Thu, Sep 8, 2016 at 5:56 AM, F21 <f21.gro...@gmail.com> wrote: > Glad you got it working! :) > > Cheers, > Francis > > > On 8/09/2016 7:11 PM, zengbaitang wrote: > > > I found the reason , because i have not set the env : HADOOP_CONF_DIR > while i set the env, the problem solved . > > Thank you F21, thank you very much! > > > -- 原始邮件 -- > 发件人: "F21";<f21.gro...@gmail.com>; > 发送时间: 2016年9月8日(星期四) 下午3:33 > 收件人: "user"<user@phoenix.apache.org>; > 主题: Re: 回复: 回复: Can query server run with hadoop ha mode? > > From the response of your curl, it appears that the query server is started > correctly and running. The next bit to check is to see if it can talk to the > HBase servers properly. > > Add phoenix.queryserver.serialization to the hbase-site.xml for the query > server and set the value to JSON. > > Then try and send a CatalogsRequest to the query server using curl or wget. > See here for how to set up the request > https://calcite.apache.org/docs/avatica_json_reference.html#catalogsrequest > > Before sending the CatalogsRequest, remember to send an > OpenConnectionRequest first: > https://calcite.apache.org/docs/avatica_json_reference.html#openconnectionrequest > > In your case, the `info` key of the OpenConnectionRequest can be omitted. > > Cheers, > Francis > > On 8/09/2016 4:12 PM, zengbaitang wrote: > > yes, the query server run on one of the regionservers > > and exec curl 'http://tnode02:8765' the terminal returns : > > > Error 404 - Not Found > > Error 404 - Not Found. > No context on this server matched or handled this request.Contexts known > to this server are: http://eclipse.org/jetty;> border=0 src="/favicon.ico"/> href="http://eclipse.org/jetty;>Powered by Jetty:// Java Web Server > > > > > > > -- 原始邮件 -- > 发件人: "F21";<f21.gro...@gmail.com>; > 发送时间: 2016年9月8日(星期四) 下午2:01 > 收件人: "user"<user@phoenix.apache.org>; > 主题: Re: 回复: Can query server run with hadoop ha mode? > > Your logs do not seem to show any errors. > > You mentioned that you have 2 hbase-site.xml. Are the Phoenix query servers > running on the same machine as the HBase servers? If not, the hbase-site.xml > for the phoenix query servers also needs the zookeeper configuration. > > Did you also try to use curl or wget to get > http://your-phoenix-query-server:8765 to see if there's a response? > > Cheers, > Francis > > On 8/09/2016 3:54 PM, zengbaitang wrote: > > hi F21 , I am sure hbase-site.xml was configured properly , > > here is my hbase-site.xml (hbase side) : > > > hbase.rootdir > hdfs://stage-cluster/hbase > > > > hbase.cluster.distributed > true > > > hbase.zookeeper.quorum > tnode01,tnode02,tnode03 > > > zookeeper.znode.parent > /hbase > > > dfs.support.append > true > > > zookeeper.session.timeout > 18 > > > hbase.rpc.timeout > 12 > > > hbase.hregion.memstore.flush.size > 67108864 > > > hfile.block.cache.size > 0.1 > > > > > phoenix.schema.isNamespaceMappingEnabled > true > > > > hbase.regionserver.wal.codec > > org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec > > > > hbase.region.server.rpc.scheduler.factory.class > > org.apache.hadoop.hbase.ipc.PhoenixRpcSchedulerFactory > Factory to create the Phoenix RPC Scheduler that uses > separate queues for index and metadata updates > > > > hbase.rpc.controllerfactory.class > > org.apache.hadoop.hbase.ipc.controller.ServerRpcControllerFactory > Factory to create the Phoenix RPC Scheduler that uses > separate queues for index and metadata updates > > > > > > and the following is phoenix side hbase-site.xml > > > hbase.regionserver.wal.codec > > org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec > > > > phoenix.schema.isNamespaceMappingEnabled > true > > > > > and the following is query server log > > 2016-09-08 13:33:03,218 INFO org.
Re: 回复: 回复: 回复: Can query server run with hadoop ha mode?
Glad you got it working! :) Cheers, Francis On 8/09/2016 7:11 PM, zengbaitang wrote: I found the reason , because i have not set the env : HADOOP_CONF_DIR while i set the env, the problem solved . Thank you F21, thank you very much! -- -- *??:* "F21";; *:* 2016??9??8??(??) 3:33 *??:* "user" ; *:* Re: ?? ?? Can query server run with hadoop ha mode?? From the response of your curl, it appears that the query server is started correctly and running. The next bit to check is to see if it can talk to the HBase servers properly. Add phoenix.queryserver.serialization to the hbase-site.xml for the query server and set the value to JSON. Then try and send a CatalogsRequest to the query server using curl or wget. See here for how to set up the request https://calcite.apache.org/docs/avatica_json_reference.html#catalogsrequest Before sending the CatalogsRequest, remember to send an OpenConnectionRequest first: https://calcite.apache.org/docs/avatica_json_reference.html#openconnectionrequest In your case, the `info` key of the OpenConnectionRequest can be omitted. Cheers, Francis On 8/09/2016 4:12 PM, zengbaitang wrote: yes, the query server run on one of the regionservers and exec curl 'http://tnode02:8765' the terminal returns : Error 404 - Not Found Error 404 - Not Found. No context on this server matched or handled this request.Contexts known to this server are: href="http://eclipse.org/jetty;>src="/favicon.ico"/>href="http://eclipse.org/jetty;>Powered by Jetty:// Java Web Server -- -- *??:* "F21"; ; *:* 2016??9??8??(??) 2:01 *??:* "user" ; *:* Re: ?? Can query server run with hadoop ha mode?? Your logs do not seem to show any errors. You mentioned that you have 2 hbase-site.xml. Are the Phoenix query servers running on the same machine as the HBase servers? If not, the hbase-site.xml for the phoenix query servers also needs the zookeeper configuration. Did you also try to use curl or wget to get http://your-phoenix-query-server:8765 to see if there's a response? Cheers, Francis On 8/09/2016 3:54 PM, zengbaitang wrote: hi F21 , I am sure hbase-site.xml was configured properly , here is my *hbase-site.xml (hbase side)*: hbase.rootdir hdfs://stage-cluster/hbase hbase.cluster.distributed true hbase.zookeeper.quorum tnode01,tnode02,tnode03 zookeeper.znode.parent /hbase dfs.support.append true zookeeper.session.timeout 18 hbase.rpc.timeout 12 hbase.hregion.memstore.flush.size 67108864 hfile.block.cache.size 0.1 phoenix.schema.isNamespaceMappingEnabled true hbase.regionserver.wal.codec org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec hbase.region.server.rpc.scheduler.factory.class org.apache.hadoop.hbase.ipc.PhoenixRpcSchedulerFactory Factory to create the Phoenix RPC Scheduler that uses separate queues for index and metadata updates hbase.rpc.controllerfactory.class org.apache.hadoop.hbase.ipc.controller.ServerRpcControllerFactory Factory to create the Phoenix RPC Scheduler that uses separate queues for index and metadata updates *and the following is phoenix side hbase-site.xml* hbase.regionserver.wal.codec org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec phoenix.schema.isNamespaceMappingEnabled true *and the following is query server log* * * 2016-09-08 13:33:03,218 INFO org.apache.phoenix.queryserver.server.Main: env:PATH=/usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/hadoop/bin:/usr/local/hadoop-2.7.1/bin:/usr/local/hbase-1.1.2/bin:/usr/local/apache-hive-1.2.1-bin/bin:/usr/local/sqoop-1.4.6.bin__hadoop-2.0.4-alpha/bin 2016-09-08 13:33:03,219 INFO org.apache.phoenix.queryserver.server.Main: env:HISTCONTROL=ignoredups 2016-09-08 13:33:03,219 INFO org.apache.phoenix.queryserver.server.Main: env:HCAT_HOME=/usr/local/apache-hive-1.2.1-bin/hcatalog 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:HISTSIZE=1000 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:JAVA_HOME=/usr/local/java/latest 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:TERM=xterm 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:XFILESEARCHPATH=/usr/dt/app-defaults/%L/Dt 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:LANG=en_US.UTF-8 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:G_BROKEN_FILENAMES=1 2016-09-08 13:33:03,220 INFO
Re: 回复: 回复: Can query server run with hadoop ha mode?
From the response of your curl, it appears that the query server is started correctly and running. The next bit to check is to see if it can talk to the HBase servers properly. Add phoenix.queryserver.serialization to the hbase-site.xml for the query server and set the value to JSON. Then try and send a CatalogsRequest to the query server using curl or wget. See here for how to set up the request https://calcite.apache.org/docs/avatica_json_reference.html#catalogsrequest Before sending the CatalogsRequest, remember to send an OpenConnectionRequest first: https://calcite.apache.org/docs/avatica_json_reference.html#openconnectionrequest In your case, the `info` key of the OpenConnectionRequest can be omitted. Cheers, Francis On 8/09/2016 4:12 PM, zengbaitang wrote: yes, the query server run on one of the regionservers and exec curl 'http://tnode02:8765' the terminal returns : Error 404 - Not Found Error 404 - Not Found. No context on this server matched or handled this request.Contexts known to this server are: href="http://eclipse.org/jetty;>src="/favicon.ico"/>href="http://eclipse.org/jetty;>Powered by Jetty:// Java Web Server -- -- *??:* "F21";; *:* 2016??9??8??(??) 2:01 *??:* "user" ; *:* Re: ?? Can query server run with hadoop ha mode?? Your logs do not seem to show any errors. You mentioned that you have 2 hbase-site.xml. Are the Phoenix query servers running on the same machine as the HBase servers? If not, the hbase-site.xml for the phoenix query servers also needs the zookeeper configuration. Did you also try to use curl or wget to get http://your-phoenix-query-server:8765 to see if there's a response? Cheers, Francis On 8/09/2016 3:54 PM, zengbaitang wrote: hi F21 , I am sure hbase-site.xml was configured properly , here is my *hbase-site.xml (hbase side)*: hbase.rootdir hdfs://stage-cluster/hbase hbase.cluster.distributed true hbase.zookeeper.quorum tnode01,tnode02,tnode03 zookeeper.znode.parent /hbase dfs.support.append true zookeeper.session.timeout 18 hbase.rpc.timeout 12 hbase.hregion.memstore.flush.size 67108864 hfile.block.cache.size 0.1 phoenix.schema.isNamespaceMappingEnabled true hbase.regionserver.wal.codec org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec hbase.region.server.rpc.scheduler.factory.class org.apache.hadoop.hbase.ipc.PhoenixRpcSchedulerFactory Factory to create the Phoenix RPC Scheduler that uses separate queues for index and metadata updates hbase.rpc.controllerfactory.class org.apache.hadoop.hbase.ipc.controller.ServerRpcControllerFactory Factory to create the Phoenix RPC Scheduler that uses separate queues for index and metadata updates *and the following is phoenix side hbase-site.xml* hbase.regionserver.wal.codec org.apache.hadoop.hbase.regionserver.wal.IndexedWALEditCodec phoenix.schema.isNamespaceMappingEnabled true *and the following is query server log* * * 2016-09-08 13:33:03,218 INFO org.apache.phoenix.queryserver.server.Main: env:PATH=/usr/lib64/qt-3.3/bin:/usr/local/bin:/bin:/usr/bin:/usr/local/sbin:/usr/sbin:/sbin:/home/hadoop/bin:/usr/local/hadoop-2.7.1/bin:/usr/local/hbase-1.1.2/bin:/usr/local/apache-hive-1.2.1-bin/bin:/usr/local/sqoop-1.4.6.bin__hadoop-2.0.4-alpha/bin 2016-09-08 13:33:03,219 INFO org.apache.phoenix.queryserver.server.Main: env:HISTCONTROL=ignoredups 2016-09-08 13:33:03,219 INFO org.apache.phoenix.queryserver.server.Main: env:HCAT_HOME=/usr/local/apache-hive-1.2.1-bin/hcatalog 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:HISTSIZE=1000 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:JAVA_HOME=/usr/local/java/latest 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:TERM=xterm 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:XFILESEARCHPATH=/usr/dt/app-defaults/%L/Dt 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:LANG=en_US.UTF-8 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:G_BROKEN_FILENAMES=1 2016-09-08 13:33:03,220 INFO org.apache.phoenix.queryserver.server.Main: env:SELINUX_LEVEL_REQUESTED= 2016-09-08 13:33:03,221 INFO org.apache.phoenix.queryserver.server.Main: env:SELINUX_ROLE_REQUESTED= 2016-09-08 13:33:03,221 INFO org.apache.phoenix.queryserver.server.Main: env:MAIL=/var/spool/mail/hadoop 2016-09-08 13:33:03,221 INFO org.apache.phoenix.queryserver.server.Main: env:LOGNAME=hadoop 2016-09-08 13:33:03,221 INFO org.apache.phoenix.queryserver.server.Main: