MeetMe / newrelic-plugin-agent

Multi-Plugin python-based Agent for NewRelic's Platform
BSD 3-Clause "New" or "Revised" License
425 stars 265 forks source link

newrelic_plugin_agent not working #465

Open skbera84 opened 8 years ago

skbera84 commented 8 years ago

Hi, We have installed newrelic_plugin_agent to monitor httpd. It was working for few days and graph was showing. Suddently we have seen that agent was stopped. Whenever we are trying to start the agent it gives error and not starting. See the logs below. [root@portalweb1 newrelic_plugin_agent-1.3.0]# newrelic-pnewrelic-plugin-agent -c /etc/newrelic/newrelic-plugin-agent.cfg -f INFO 2015-11-30 11:58:25,581 20572 MainProcess MainThread newrelic_plugin_agent.agent init L55 : Agent v1.3.0 initialized, Linux-2.6.32-431.el6.x86_64-x86_64-with-glibc2.2.5 (CentOS 6.5 Final) CPython v2.6.6 INFO 2015-11-30 11:58:25,582 20572 MainProcess MainThread helper.controller run L251 : newrelic-plugin-agent v2.4.1 started INFO 2015-11-30 11:58:25,582 20572 MainProcess MainThread newrelic_plugin_agent.agent start_plugin_polling L263 : Enabling plugin: apache_httpd Traceback (most recent call last): File "/usr/bin/newrelic-plugin-agent", line 9, in load_entry_point('newrelic-plugin-agent==1.3.0', 'console_scripts', 'newrelic-plugin-agent')() File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/agent.py", line 337, in main helper.start(NewRelicPluginAgent) File "/usr/lib/python2.6/site-packages/helper/init.py", line 174, in start obj.start() File "/usr/lib/python2.6/site-packages/helper/controller.py", line 266, in start self.run() File "/usr/lib/python2.6/site-packages/helper/controller.py", line 253, in run self.process() File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/agent.py", line 118, in process self.start_plugin_polling() File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/agent.py", line 280, in start_plugin_polling self.config.application.get(plugin)) File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/agent.py", line 108, in poll_plugin thread.run() File "/usr/lib64/python2.6/threading.py", line 484, in run self.target(_self.__args, *_self.kwargs) File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/agent.py", line 308, in thread_process obj.poll() File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/plugins/base.py", line 361, in poll data = self.fetch_data() File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/plugins/base.py", line 335, in fetch_data data = self.http_get() File "/usr/lib/python2.6/site-packages/newrelic_plugin_agent/plugins/base.py", line 347, in http_get response = requests.get(_self.request_kwargs) File "/usr/lib/python2.6/site-packages/requests/api.py", line 55, in get return request('get', url, _kwargs) File "/usr/lib/python2.6/site-packages/requests/api.py", line 44, in request return session.request(method=method, url=url, _kwargs) File "/usr/lib/python2.6/site-packages/requests/sessions.py", line 448, in request resp = self.send(prep, _send_kwargs) File "/usr/lib/python2.6/site-packages/requests/sessions.py", line 580, in send history = [resp for resp in gen] if allow_redirects else [] File "/usr/lib/python2.6/site-packages/requests/sessions.py", line 111, in resolve_redirects raise TooManyRedirects('Exceeded %s redirects.' % self.max_redirects) requests.exceptions.TooManyRedirects: Exceeded 30 redirects. Please help.

ralphct commented 8 years ago

Looks to me like the URL you're trying to check is returning a 301 or 302 redirect, which the plugin is then following, but gets another redirect, follows it... and so on until it does this 30 times.