Created 10-09-2018 06:35 PM
Hi,
Cluster consists of 13 nodes which have one server as a Knox Gateway (G1). I have added another hosts (for naming convention, let's call this G2), which has the same configuration of original Knox Gateway (G1). I have basically copied every Knox file I have from G1 to G2. My purpose is to transfer some of the services to G2 without having a downtime that's why I wanted them both to be started at the same time. However, upon starting Knox Gateway Service on G2, i get an error like this:
2018-10-05 14:03:45,730 - call['ambari-sudo.sh su knox -l -s /bin/bash -c 'curl --location-trusted -k --negotiate -u : -b /var/lib/ambari-agent/tmp/cookies/97b20bd8-6a80-4926-a259-5e0d1c7bc8b3 -c /var/lib/ambari-agent/tmp/cookies/97b20bd8-6a80-4926-a259-5e0d1c7bc8b3 '"'"'http://hostname:6080/service/public/v2/api/service?serviceName=ATOM_knox&serviceType=knox&isEnabled=true'"'"' --connect-timeout 10 --max-time 12 -X GET 1>/tmp/tmpdUkhUB 2>/tmp/tmpqBAJxt''] {'quiet': False, 'env': {'KRB5CCNAME': '/var/lib/ambari-agent/tmp/curl_krb_cache/ranger_admin_calls_knox_cc_1798c3584893e89264ef19583301540be127e51c242bfc943fe8a207'}}
2018-10-05 14:03:45,837 - call returned (0, '')
2018-10-05 14:03:45,837 - Will retry 4 time(s), caught exception: Error in call for getting Ranger service: No JSON object could be decoded. Sleeping for 8 sec(s)
2018-10-05 14:03:53,845 - checked_call['/usr/bin/kinit -c /var/lib/ambari-agent/tmp/curl_krb_cache/ranger_admin_calls_knox_cc_1798c3584893e89264ef19583301540be127e51c242bfc943fe8a207 -kt /etc/security/keytabs/knox.service.keytab knox/hostname@address.com> /dev/null'] {'user': 'knox'}
2018-10-05 14:03:53,949 - checked_call returned (0, '')
Am I missing any config?
Is it possible to setup 2 knox gateway with the same files and start them at the same time?
Please help.
Created 10-09-2018 06:53 PM
@NN ,
Looks like there is some issue with Ranger. Please make sure that Ranger is started before starting Knox.
Basically you want Knox HA if I'm not wrong. You can follow this doc to do the same.
http://knox.apache.org/books/knox-0-6-0/user-guide.html#High+Availability.
.
If this helps, please take a moment to login and "Accept" the answer.
Created 10-23-2018 01:23 PM
Hi @Aditya Sirna Thank you for the response. I have been able to start knox in G2 with same exact configuration (including the topology) I copied from Knox G1, after multiple errors like this:
2018-10-11 09:37:52,007 - Error in call for getting Ranger service: No JSON object could be decoded 2018-10-11 09:38:25,124 - Error in call for creating Ranger service: No JSON object could be decoded 2018-10-11 09:39:28,319 - Error in call for getting Ranger service: No JSON object could be decoded 2018-10-11 09:40:01,410 - Error in call for creating Ranger service: No JSON object could be decoded 2018-10-11 09:41:04,605 - Error in call for getting Ranger service: No JSON object could be decoded 2018-10-11 09:41:37,717 - Error in call for creating Ranger service: No JSON object could be decoded 2018-10-11 09:42:40,920 - Error in call for getting Ranger service: No JSON object could be decoded 2018-10-11 09:43:14,027 - Error in call for creating Ranger service: No JSON object could be decoded 2018-10-11 09:44:17,343 - Error in call for getting Ranger service: No JSON object could be decoded 2018-10-11 09:44:50,457 - Error in call for creating Ranger service: No JSON object could be decoded 2018-10-11 09:45:53,660 - Error in call for getting Ranger service: No JSON object could be decoded 2018-10-11 09:46:26,783 - Error in call for creating Ranger service: No JSON object could be decoded 2018-10-11 09:46:26,783 - Knox Repository creation failed in Ranger admin
I have not been able to try if this is will work when transfer to Knox G2 as our main Knox Gateway. I will update this thread once I do.
Created 10-09-2018 07:11 PM
@NN Which version of Knox is being used? I'm asking because there have been a lot of improvements in this area recently.
Created 10-23-2018 07:53 AM
Hi @Phil Zampino I'm using Knox 0.12.0. I'm still to verify if my 2nd Knox gateway setup had worked. Also, my Ranger is perfectly working while I'm starting the seocnd Knox Gateway, that's why I'm confused of this error I'm getting.