3

I've installed Orion 0.24 on a server, alongside with Apache Tomcat 7, where I deployed ProtonCEP GE (4x WAR files deployed).

The issue is that Orion unswers only to half of the requests it gets (independent of request) in an alternate fashion, like so:

$ curl http://localhost:1026/version -H "Content-Type: application/json"
<orion>
  <version>0.24.0</version>
  <uptime>0 d, 0 h, 8 m, 39 s</uptime>
  <git_hash>ed11a3307c7050857ef398ee3e4cd04042a0cc01</git_hash>
  <compile_time>Mon Sep 14 17:52:44 CEST 2015</compile_time>
  <compiled_by>fermin</compiled_by>
  <compiled_in>centollo</compiled_in>
</orion>
$ curl http://localhost:1026/version -H "Content-Type: application/json"
curl: (52) Empty reply from server
$ curl http://localhost:1026/version -H "Content-Type: application/json"
<orion>
  <version>0.24.0</version>
  <uptime>0 d, 0 h, 8 m, 42 s</uptime>
  <git_hash>ed11a3307c7050857ef398ee3e4cd04042a0cc01</git_hash>
  <compile_time>Mon Sep 14 17:52:44 CEST 2015</compile_time>
  <compiled_by>fermin</compiled_by>
  <compiled_in>centollo</compiled_in>
</orion>
$ curl http://localhost:1026/version -H "Content-Type: application/json"
curl: (52) Empty reply from server

If I stop Tomcat, by running CATALINA_HOME/bin/shutdown.sh script, Orion works fine. If Tomcat is running, Orion behaves as described.

This is happening in a fresh install on CentOS 6.7. Both GEs have dependencies, so MongoDB 2.6.11 and Java jdk 8 where also installed.

This same behaviour seemed to have happened to someone else, as asked in another post, but with no mentioned relation to Tomcat then. The solution provided there (to add the option '-ipv4' to the orion's starter command) doesn't solve the issue in this case.

I hope it's a simple issue.

If more information is needed, please let me know.

Thank you

Community
  • 1
  • 1
A. Vieira
  • 1,213
  • 2
  • 11
  • 27
  • Is Tomcat running in dual mode (IPv6 and IPv4)? – fgalan Sep 18 '15 at 13:47
  • No, Tomcat is running on IPv6 only. – A. Vieira Sep 18 '15 at 16:52
  • Could you test running Tomcat on IPv4 only to see what happens? – fgalan Sep 18 '15 at 16:58
  • I'm currently testing that. – A. Vieira Sep 18 '15 at 17:24
  • I tried all combinations of contexBroker with tomcat on ipv4 and the behaviour is the same, responds only half of the time.To resume and clarify, I tried contextBroker running on ipv4,ipv6 and dual, while tomcat was ipv4. – A. Vieira Sep 18 '15 at 17:44
  • In which ports are running Tomcat and Orion? – fgalan Sep 22 '15 at 08:22
  • Are Tomcat and Orion bound to the same interface? In order to see if the problem is due to some conflict due to it, you can test the following: bind Tomcat to one interface (e.g. the external interface in the VM) and Orion to other (e.g. localahost, with `-localIp 127.0.0.1`). – fgalan Sep 22 '15 at 08:25
  • To answer to both questions. I put Tomcat on our extarnal interface: - *{extIP}:8080* (http) and - *{extIP}:8009* (AJP) . And I initialized Orion with the options `-ipv4 -localIp 127.0.0.1` so it runs on: - *127.0.0.1:1026*. I put Orion on ipv4 to minimize conflict points. The result was the same, Orion still responds to only half of requests (I only used the version GET to test). Next I'll try to turn off Tomcat's AJP connector (we don't need it). – A. Vieira Sep 22 '15 at 09:01
  • Ok. So with Tomcat only on `{extIP}:8080` and Orion on `127.0.0.1:1026` the issue persists. – A. Vieira Sep 22 '15 at 09:06
  • Did you check the logs of both Tomcat and ContextBroker? Did you find anything interesting? Is there any message correlated with the empty requests? – Daniel Morán Jiménez Sep 23 '15 at 08:09
  • An issue has been created in Orion repository about this: https://github.com/telefonicaid/fiware-orion/issues/1337 – fgalan Oct 07 '15 at 19:44

1 Answers1

2

I apologize for forgeting to mention that, by chance, we ended up switching to a VM with more RAM memory and the issue went away. The memory on the faulty VM was short but didn't seem critical. Also, the only service failing was Orion and no other process was malfunctioning, which contributed to the difficulty in diagnosing the issue.

No more tests were conducted on the faulty VM and Orion and CEP/Tomcat are working fine on the new VM, alongside other processes.

The faulty VM was running at 0.6 GB. The new VM runs at 3.75 GB

Thank you

A. Vieira
  • 1,213
  • 2
  • 11
  • 27
  • Tomcat uses to eat a lot of memory, so it makes sense that the problem happens when Tomcat runs, thus reducing even more the available free memory. – fgalan Oct 07 '15 at 21:06
  • Yes it does work when you increase the RAM memory on your VM. I can attest that. Thanks. – Diogo Nunes Oct 08 '15 at 15:29