Hello Jennifer, >From the logs it appears that no rewrite rules were found for path '/helloworldservice/v1/say/hello'.
Assuming that the topology xml file and the service definitions (service.xml and rewrite.xml) are copied from the working system to the new system, the exact same curl command (except the hostname) should have worked. One thing you can try is to enable DEBUG logging (on both the machines), in conf/gateway-log4j.properties, uncommenting log4j.logger.org.apache.hadoop.gateway=DEBUG This should tell us a bit more about what's happening and help us compare both the logs in more details Also, what response are you getting with curl ? I am guessing 404. Can you also provide the curl command and the rules from the rewrite.xml file ? Best, Sandeep On Thu, Mar 23, 2017 at 10:30 AM, Jennifer Coston < [email protected]> wrote: > Hello, > > > > I have Knox successfully running on one system and I am trying duplicate > the configuration on another. My topology file is the same and so are the > rewrite rules for the service I am trying to use. However, when I send a > curl command through Knox on the new system I don’t get a response. When I > look in the logs I am seeing the following: > > > > 2017-03-23 09:09:34,121 INFO hadoop.gateway > (GatewayConfigImpl.java:loadConfigResource(285)) > - Loading configuration resource jar:file:/usr/hdp/2.4.2.0-258/ > knox/bin/../lib/gateway-server-0.6.0.2.4.2.0-258.jar!/ > conf/gateway-default.xml > > 2017-03-23 09:09:34,131 INFO hadoop.gateway > (GatewayConfigImpl.java:loadConfigFile(273)) > - Loading configuration file /usr/hdp/2.4.2.0-258/knox/bin/ > ../conf/gateway-site.xml > > 2017-03-23 09:09:34,158 INFO hadoop.gateway > (GatewayConfigImpl.java:initGatewayHomeDir(217)) > - Using /usr/hdp/2.4.2.0-258/knox/bin/.. as GATEWAY_HOME via system > property. > > 2017-03-23 09:09:34,875 INFO hadoop.gateway (JettySSLService.java:init(89)) > - Credential store for the gateway instance found - no need to create one. > > 2017-03-23 09:09:34,878 INFO hadoop.gateway (JettySSLService.java:init(106)) > - Keystore for the gateway instance found - no need to create one. > > 2017-03-23 09:09:34,880 INFO hadoop.gateway (JettySSLService.java: > logAndValidateCertificate(128)) - The Gateway SSL certificate is issued > to hostname: server.running.knox. > > 2017-03-23 09:09:34,881 INFO hadoop.gateway (JettySSLService.java: > logAndValidateCertificate(131)) - The Gateway SSL certificate is valid > between: 10/17/16 6:06 PM and 10/17/17 6:06 PM. > > 2017-03-23 09:09:35,119 INFO hadoop.gateway > (GatewayServer.java:startGateway(219)) > - Starting gateway... > > 2017-03-23 09:09:35,349 INFO hadoop.gateway (GatewayServer.java:start(311)) > - Loading topologies from directory: /usr/hdp/2.4.2.0-258/knox/bin/ > ../conf/topologies > > 2017-03-23 09:09:35,459 INFO hadoop.gateway > (GatewayServer.java:handleCreateDeployment(450)) > - Loading topology default from /usr/hdp/2.4.2.0-258/knox/bin/ > ../data/deployments/default.war.157d4e5c6f8 > > 2017-03-23 09:09:35,866 INFO hadoop.gateway > (GatewayServer.java:handleCreateDeployment(450)) > - Loading topology admin from /usr/hdp/2.4.2.0-258/knox/bin/ > ../data/deployments/admin.war.153ec5663f0 > > 2017-03-23 09:09:35,884 INFO hadoop.gateway > (GatewayServer.java:handleCreateDeployment(450)) > - Loading topology cluster1 from /usr/hdp/2.4.2.0-258/knox/bin/ > ../data/deployments/cluster1.war.15af1acbcd0 > > 2017-03-23 09:09:35,899 INFO hadoop.gateway (GatewayServer.java:start(315)) > - Monitoring topologies in directory: /usr/hdp/2.4.2.0-258/knox/bin/ > ../conf/topologies > > 2017-03-23 09:09:35,900 INFO hadoop.gateway > (GatewayServer.java:startGateway(232)) > - Started gateway on port 8,443. > > 2017-03-23 09:11:50,664 WARN hadoop.gateway > (GatewayFilter.java:doFilter(152)) > - Failed to match path /helloworldservice/v1/say/hello > > > > How do I troubleshoot this issue? I’m thinking there must be something > different in the configuration of the two systems. If it helps, here is the > logs from the working system: > > > > 2017-03-23 09:03:08,172 INFO hadoop.gateway > (GatewayConfigImpl.java:loadConfigResource(285)) > - Loading configuration resource jar:file:/usr/hdp/2.4.2.0-258/ > knox/bin/../lib/gateway-server-0.6.0.2.4.2.0-258.jar!/ > conf/gateway-default.xml > > 2017-03-23 09:03:08,188 INFO hadoop.gateway > (GatewayConfigImpl.java:loadConfigFile(273)) > - Loading configuration file /usr/hdp/2.4.2.0-258/knox/bin/ > ../conf/gateway-site.xml > > 2017-03-23 09:03:08,228 INFO hadoop.gateway > (GatewayConfigImpl.java:initGatewayHomeDir(217)) > - Using /usr/hdp/2.4.2.0-258/knox/bin/.. as GATEWAY_HOME via system > property. > > 2017-03-23 09:03:08,808 INFO hadoop.gateway (JettySSLService.java:init(89)) > - Credential store for the gateway instance found - no need to create one. > > 2017-03-23 09:03:08,819 INFO hadoop.gateway (JettySSLService.java:init(106)) > - Keystore for the gateway instance found - no need to create one. > > 2017-03-23 09:03:08,821 INFO hadoop.gateway (JettySSLService.java: > logAndValidateCertificate(128)) - The Gateway SSL certificate is issued > to hostname: gpi-col44.gpi.collect. > > 2017-03-23 09:03:08,822 INFO hadoop.gateway (JettySSLService.java: > logAndValidateCertificate(131)) - The Gateway SSL certificate is valid > between: 5/25/16 12:04 PM and 5/25/17 12:04 PM. > > 2017-03-23 09:03:09,140 INFO hadoop.gateway > (GatewayServer.java:startGateway(219)) > - Starting gateway... > > 2017-03-23 09:03:09,428 INFO hadoop.gateway (GatewayServer.java:start(311)) > - Loading topologies from directory: /usr/hdp/2.4.2.0-258/knox/bin/ > ../conf/topologies > > 2017-03-23 09:03:09,584 INFO hadoop.gateway > (GatewayServer.java:handleCreateDeployment(450)) > - Loading topology default from /usr/hdp/2.4.2.0-258/knox/bin/ > ../data/deployments/default.war.1572999d550 > > 2017-03-23 09:03:10,150 INFO hadoop.gateway > (GatewayServer.java:handleCreateDeployment(450)) > - Loading topology admin from /usr/hdp/2.4.2.0-258/knox/bin/ > ../data/deployments/admin.war.154e94513b8 > > 2017-03-23 09:03:10,187 INFO hadoop.gateway > (GatewayServer.java:handleCreateDeployment(450)) > - Loading topology cluster1 from /usr/hdp/2.4.2.0-258/knox/bin/ > ../data/deployments/cluster1.war.15af67141f0 > > 2017-03-23 09:03:10,211 INFO hadoop.gateway (GatewayServer.java:start(315)) > - Monitoring topologies in directory: /usr/hdp/2.4.2.0-258/knox/bin/ > ../conf/topologies > > 2017-03-23 09:03:10,213 INFO hadoop.gateway > (GatewayServer.java:startGateway(232)) > - Started gateway on port 8,443. > > 2017-03-23 09:04:59,218 INFO hadoop.gateway > (KnoxLdapRealm.java:getUserDn(556)) > - Computed userDn: uid=admin,ou=people,dc=hadoop,dc=apache,dc=org using > dnTemplate for principal: admin > > 2017-03-23 09:04:59,347 INFO hadoop.gateway > (AclsAuthorizationFilter.java:init(62)) > - Initializing AclsAuthz Provider for: HELLOWORLDSERVICE > > 2017-03-23 09:04:59,349 INFO hadoop.gateway > (AclsAuthorizationFilter.java:doFilter(85)) > - Access Granted: true > > > > Thank you, > > > > *Jennifer * > > >
