-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
All plugins return 0 for stats #12
Comments
Also, when running the app specific plugins directly I get 'yes' when run with autoconf and an error when run with debug:
I believe this is may be due to /proc/meminfo being specific to Lunixes. |
For the rails plugins at least the issue has to do with the logger format. The request-log-analyzer gem does its best to try and figure out which log format it is reading, but has issues determining between rails 2 and 3. It defaults to rails 2 I believe, which makes it run into errors in reading the log and you get out zero's. To fix this, be sure to set "env.log_format rails3" in the plugin-conf.d folder for EACH of the files that use this gem. Also note that by default the generated files specify the binary location for ruby, and passeneger-memory stats, etc to be in the "/usr/local/bin/" folder, while if you install these gems as root, they will default to the "/usr/bin" folder. The defaults are the safer and better choice if you can make them install there, but you can edit all the config files to remove the local part and this should get your plugins running. |
Ok, thanks. Setting the log format worked for the request-log-analyzer plugins. The only one I seem to have an issue with now is the munin_passenger_memory_stats plugin. It's still returning 0 for memory.value. Is this to be expected? When I run
I do get the expected output from passenger-memory-stats. |
Can you paste the conf file for this? It is likely an issue there since running it from ruby is working. |
Here it is: [munin_passenger_memory_stats] I've confirmed each path. Ruby is located in /usr/local/bin as I had to manually upgrade from 1.8 to 1.9. |
I believe the issue is that you don't have quotes on your variables. These should be formatted like Its the only issue that I can see that differ from my commands. |
I gave this a try and I still get the same results. Also, none of the other plugins have the values quoted in this manner. I've forked the repo and will look at the code for this to see if I can't find anything. FYI, munin_passenger_status is returning actual numbers (it's config variables aren't quoted). munin_passenger_queue is returning 0's also, but I'm thinking that this actual data as the server is under a pretty light load. *** Update ***
This is looking for the string 'RSS: ' correct? This token doesn't appear in the output of passenger-memory-stats on FreeBSD. Here's the output I receive when running it from the command line:
|
Yes RSS is correct, it must be an issue with FreeBSD and not reporting the RSS. On my linux boxes, you get an output like this. PID PPID VMSize Private Name2229 1 90.8 MB 0.2 MB /usr/sbin/apache2 -k start Processes: 9Total private dirty RSS: 2.19 MBThat RSS is what it is looking for, though I am not sure why it isn't there on FreeBSD must have to do with memory management differences between the two kernels. I suppose it would be possible to do a look and add up all the VMSize memory, but I feel this is an issue with the passenger gem and not the munin plugin, though that is only my opinion. |
Checking the Passenger source, there's a call to #platform_provides_dirty_rss_information? that basically just checks to see if _Update_
So I'm guessing that these guys know what they're talking about. Would updating this plugin to report Resident Set Size on non-linux OSes be alright with you? If so, I'll close this and submit a pull request when I have it done. Thanks for your help! |
Wow, this issue actually resolved itself :)! Thanks Wakemaster39! As for the plugin update.. pull requests are allways welcome. It really depends on 1) the amount of code it will take and 2) if it is possible at all (given the Passenger docs comment). |
I'm current running a Rails 3.0.4 application with Passenger 3.0.7 on FreeBSD 8.2 with Munin 1.4.4. After installing this gem and moving the symlinks to /usr/local/etc I get nothing but 0 return values for every plugin except munin_passenger_status. I have installed the application specific plugins, which also return 0 for all statistics. When I run request-log-analyzer itself I get statistics as expected.
The text was updated successfully, but these errors were encountered: