Should instruct customers to add /agent_listener/invoke_raw_method to routes with subdomain collector
NewRelic posts to /agent_listener/invoke_raw_method with subdomain collector. Many sites like ours map via subdomains. You should mention in the getting started guide that a route should be added to enable this path - otherwise the call will never reach the target.
1
person has this problem
I have this problem, too!
Tell me when someone solves it.
The more people who report this problem, the more it gets noticed.
The more people who report this problem, the more it gets noticed.
Create a customer community for your own organization
Plans starting at $19/month
-
Inappropriate?The call to invoke_raw_method is an outgoing Net::HTTP request. There is no rails code involved, no route mapping done on the agent. This agent is used by background jobs with no routing as well as web apps.
What exactly prevents the outgoing connection? Are you seeing errors? What is the route entry you added to fix it? Maybe I'm missing something obvious.
I’m very confused
-
Inappropriate?Bill,
Here is a snippet from an exception notification message.
No route matches "/agent_listener/invoke_raw_method" with {:accepts=>"*/*", :method=>:post, :subdomain=>"collector", :protocol=>"https://", :remote_ip=>"[redacted]", :port=>443, :request_uri=>"/agent_listener/invoke_raw_method?method=metric_data&license_key=[redacted]&protocol_version=4", :content_type=>#<mime::type:0xb75fa264>, :domain=>"newrelic.com"}
[RAILS_ROOT]/vendor/rails/actionpack/lib/action_controller/routing/recognition_optimisation.rb:66:in `recognize_path'
Around the time of these exceptions, monit notified that mogrels were dying off. Without looking further into the situation I diabled new relic via the config file and everything calmed down.
Let me know if I can provide any additional information. -
Inappropriate?Thanks Zack. I could use some additional info:
Where is this exception from? The log file of the server where the newrelic plugin is installed?
Have you made any modifications to newrelic.yml? It looks like at the very least you changed the ssl flag to 'true'. Is that right?
Is there a proxy server in your environment for connecting to the internet? Did you modify any of the proxy settings?
The error implies that an external client tried connecting to _your_ application invoking the agent_listener_controller. That controller exists on _our_ server so no route entry would resolve this. The question is: who is invoking that and why is it invoked on your server?
It is obviously the newrelic agent making the request. Is it possible there is some network configuration that would resolve 'collector.newrelic.com' to the your internal ip address?
Can you log in to the machine running your app and lookup 'collector.newrelic.com'? Does it resolve to 65.74...? Try doing telnet collector.newrelic.com 80. Will it connect?
This is very strange! -
Inappropriate?Bill,
I disabled new relic for a while and re-enabled it a few days ago. Everything was fine and then the same problem cropped up again. To answer your questions above...
* The exception I posted was from the exception notification plugin
* I made no changes to config/newrelic.yml that I can recall.
* No proxy server
* collector.newrelic.com resolves correctly:
ping collector.newrelic.com
PING collector.newrelic.com (65.74.177.195) 56(84) bytes of data.
64 bytes from collector.newrelic.com (65.74.177.195): icmp_seq=1 ttl=48 time=45.6 ms
64 bytes from collector-nr00.newrelic.com (65.74.177.195): icmp_seq=2 ttl=48 time=45.7 ms
Let me know if you need anything else. I'm going to update the plugin and monitor it from there.
Zack -
Inappropriate?Zack I've done some investigation of this and the only thing I can conclude is that something in your network configuration is intercepting outbound connections from your server (our agent) to collector.newrelic.com.
I don't know what version of the agent you have but if you look at invoke_remote in agent.rb you will see where the agent connects to collector.newrelic.com. No routes are involved in that connection. And yet it appears that your application gets the HTTP request, not @remote_host. That means either @remote_host is not set to collector.newrelic.com or something in your network is readirecting the TCP connection to your server where you saw the exception logged.
(One other thing to try. Since PING works--maybe try telnetting to port 80 on that host?)
I'm still happy to help you troubleshoot this but I need to get some more details on your environment. Please follow-up with me at support@newrelic.com.
Loading Profile...



EMPLOYEE