• Forum has been upgraded, all links, images, etc are as they were. Please see Official Announcements for more information

P2Pool [ANN] Public P2Pool with fancy munin stats and 1% fees in .de

fydel

New member
pool: stratum+tcp://happymining.de:7903
username: (your darkcoin address)
password: (anything you want)
example: ccminer --algo=x11 -o stratum+tcp://happymining.de:7903 -u XpQ8rSWuEGqr9zm9U6wjqcmHPcV8SLV3GN -p iloveyou

I added a new button beneath the miner name where you can check out the stats for your miner.
Feedback is welcome.

Happy mining! :smile:
fydel

p2pool stats:

drk_p2pool_hashrate-day.png


drk_p2pool_eff-day.png


drk_diff-day.png



Miner stats:
2NHLiEG.png

9dfyeNw.png
 
Last edited by a moderator:
Thank you :smile:. But the scripts are really quick and dirty. For example I am lazy and wgetting the json data in every single script. m(
But if you know munin and scripting a little bit, the scripts may be a good start.
I am using Jshon to parse the data: http://kmkeen.com/jshon/ You need to compile it on your machine.

General scripts
drk_hashrate: http://pastebin.com/Q86QumyW
drk_difficulty: http://pastebin.com/SCiTutcE
drk_efficiency: http://pastebin.com/7B4qwDtq
drk_local_hashrate: http://pastebin.com/5B7crWae

Miner scripts
The Filename is important and has to stay the same because the miner address is parsed from the filename.
miner_XpQ8rSWuEGqr9zm9U6wjqcmHPcV8SLV3GN: http://pastebin.com/vFy1Tgxh
miner_XpQ8rSWuEGqr9zm9U6wjqcmHPcV8SLV3GN-payout: http://pastebin.com/Legqs6S8

You have to change happymining.de:7903 to your p2pool in every script.
If you have further questions, I will be happy to help.
 
Last edited by a moderator:
Thank you :smile:. But the scripts are really quick and dirty. For example I am lazy and wgetting the json data in every single script. m(
But if you know munin and scripting a little bit, the scripts may be a good start.
I am using Jshon to parse the data: http://kmkeen.com/jshon/ You need to compile it on your machine.

General scripts
drk_hashrate: http://pastebin.com/Q86QumyW
drk_difficulty: http://pastebin.com/SCiTutcE
drk_efficiency: http://pastebin.com/7B4qwDtq

Miner scripts
The Filename is important and has to stay the same because the miner address is parsed from the filename.
miner_XpQ8rSWuEGqr9zm9U6wjqcmHPcV8SLV3GN: http://pastebin.com/vFy1Tgxh
miner_XpQ8rSWuEGqr9zm9U6wjqcmHPcV8SLV3GN-payout: http://pastebin.com/Legqs6S8

You have to change happymining.de:7903 to your p2pool in every script.
If you have further questions, I will be happy to help.


I love the charts and the information is very valuable for miners... I especially like the way that you added the stats for each individual miner. I'd like to incorporate these into our interface as well. I've looked over the scripts and they look very straight forward but I am lost on a few details.
  1. How do I incorporate these scripts into our interface (we also use the UI by Justino)
  2. Do we embed these directly into the HTML ?
Looking for some quick assistance!

Thanks
 
Hi Ourlink!

Integrating the munin stats is not working out-of-the box. Especially with the individual stats.

Do you have munin running on your (linux) machine? Munin is mandatory. Jshon, too.

I think we should clear this up before I go into explaining the helper scripts.

Cheers!
fydel
 
Hi Ourlink!

Integrating the munin stats is not working out-of-the box. Especially with the individual stats.

Do you have munin running on your (linux) machine? Munin is mandatory. Jshon, too.

I think we should clear this up before I go into explaining the helper scripts.

Cheers!
fydel

Yes, I have all the scripts working with the exception of the individuals stats. It took a little work to get it running with Twisted but it's working great now...

So here are the issues that I see;
  1. Templates - I have the default munin templates working but you must have a modified template for the munin-services.tmpl to remove the navigation information. Can you share that template with us?
  2. Individual stats - how is this working? Do I have to create a stats plugin for each miner ahead of time with the miners address? I'm not understanding how the address of the miner is getting pulled in for the proper pages to be generated.
 
Cool. I am happy the first part works for you. But now it is getting a bit more dirty.

For example you really should consider creating a cron job for downloading the json stats only once. I still do it in every script.

1. I dont really understand. But maybe 2. clears it up.

2. To copy the a new plugin to munin when there is a new miner connected, I have a cron job (copy_plugin.sh). It runs every five minutes. And restarts munin-node so munin will pick the new plugin up on the next run.

The cron job copies the html-file to the p2pool webfolder and creates a symlink which points to the png files generated by munin (/var/cache/munin/www/localdomain/localhost.localdomain/). You have to change that in the copy_plugin.sh script to your munin cache location.

To add the stats button with links for individual miners I changed p2pool.js.
Search for the string "http://happymining.de:7903" and change it to your p2pool.

I thinks that is all.

/webstatic/js/p2pool.js: http://pastebin.com/LG8NDJeQ

copy_plugin.sh: http://pastebin.com/CEf402dm

super ugly html-template: http://pastebin.com/6CTMkYz6
(sed in the cron script replaces string "XXX" with the miner address. Maybe you have to install sed?)

If you have questions, feel free to contact me. Here or on irc freenode #darkcoin.
 
Cool. I am happy the first part works for you. But now it is getting a bit more dirty.

For example you really should consider creating a cron job for downloading the json stats only once. I still do it in every script.

1. I dont really understand. But maybe 2. clears it up.

2. To copy the a new plugin to munin when there is a new miner connected, I have a cron job (copy_plugin.sh). It runs every five minutes. And restarts munin-node so munin will pick the new plugin up on the next run.

The cron job copies the html-file to the p2pool webfolder and creates a symlink which points to the png files generated by munin (/var/cache/munin/www/localdomain/localhost.localdomain/). You have to change that in the copy_plugin.sh script to your munin cache location.

To add the stats button with links for individual miners I changed p2pool.js.
Search for the string "http://happymining.de:7903" and change it to your p2pool.

I thinks that is all.

/webstatic/js/p2pool.js: http://pastebin.com/LG8NDJeQ

copy_plugin.sh: http://pastebin.com/CEf402dm

super ugly html-template: http://pastebin.com/6CTMkYz6
(sed in the cron script replaces string "XXX" with the miner address. Maybe you have to install sed?)

If you have questions, feel free to contact me. Here or on irc freenode #darkcoin.

Fydel - Thanks for all the great info...

I had an Ahaaa moment when I seen how you were setup and running the individual miners stats. Initially, I was trying to modify the templates files from Munin to get the format for the pages that I wanted. Thus, letting Munin generate the pages for me and symlink'ing to them from p2pool. What a pain in the *^&!

I never thought about building symlink's to the images and creating my own pages... Duh!

Again, Thanks for all the great information... Send me your Darkcoin address and I'll tip you!!!

Once I get the pages working the way I want then I'll share my design!
 
I am happy it worked for you. :smile:

No need for a dontation. Thank you. Better share your design once ready. :wink:
 
Nice! That looks fancy.

I really like the individual miner page. As I am a html noob do you mind sharing the code? :wink:
 
fydel sorry for not responding to you sooner... I lost track of this thread.

I have no problem sharing the code and the templates with you for the mining stats. After all, if it wasn't for your initial exploration into adding this the stats I never would have got it completed. You can take a look at how I have everything implemented in my pool p2poolmining.us:7903 and then I think the whole implementation will make more sense to you.

I'll create an account at pastebin and put each of the files up there with an explanation. I'll let you know when I have everything documented for you.

Thanks
 
Hi ourlink!

I also lost track a little bit. But I moved to a new server now and this would be a good time to implement your great html improvements.
Do you mind to uploading the templates for the individual miner page to pastebin ?
That would be awesome because I am real html noob.

Cheers!
fydel
 
Last edited by a moderator:
Hi again!

I just copied the source from your page and modified it a little and it works for me.

Cool! We did a great job! :smile:

Cheers!
fydel
 
Awesome... Let me know if there is anything else that you need. The holidays slowed me down a bit but now I should have more time on my hands.

BTW - I started working on an integrated miner earnings page based on a script I found here on DarkCoinTalk developed by Kristov Atlas;
https://darkcointalk.org/threads/kristov-atlas-creates-a-darkcoin-usd-accounting-php-script.3342/

My goal is to create a page that displays a miners USD earnings history.

I'll let you know when it is ready.
 
Thank you. Everything works fine for me.
An integrated miner earnings page is a very cool idea. Keep up the good work!
 
Back
Top