create account

HIVE WITNESS MONITOR - 1.0 by zuun.net

View this thread on: hive.blogpeakd.comecency.com
· @zuun.net ·
$12.73
HIVE WITNESS MONITOR - 1.0
<center>
![image](https://images.ecency.com/DQmekr12aLqvbajBKb9exmYsFNrAvyb7asEu74igsU2WrN6/image.png)
</center>
<div class="justify">
In this post I announce the release of the first version of the 
(OPEN SOURCE)  HIVE WITNESS MONITOR.
<br><br>
It was initially thought as a control panel but now it is just a page to monitor the behavior of your server and the status of your witness.<br><br>

Thank you all for the support I received in the [previous post](https://ecency.com/hive-139531/@zuun.net/hive-witness-monitor-development), I realized that there are many people interested..


![image](https://images.ecency.com/DQmcDtKghLTPBCMAcu9NacDyiicQiVN38HZXZXkib1LKxzS/image.png)



<center>
DEMO HERE:
https://zuun.net/monitor/
</center>
**--== INSTALLATION ==--**

You must have a web server installed and it must support PHP.
if you don't have a web server in your witness you can install just PHP

Ubuntu
`sudo apt-get install php`

Fedora
`dnf install php`


1 Download the file:   (81.8 Kb)
`wget https://zuun.net/monitor/monitor.tar.gz`


2 Create a Directory and Unzip there.
`mkdir monitor & tar -vxzf monitor.tar.gz  -C monitor & cd monitor`

3 Edit the `data.json` file  and change the witness name to yours.
`nano data.json`
![image](https://images.ecency.com/DQmaEg7RxBkhxiNGonugRWn5VsNzHVNJTsB7WTnzn9ayWH3/image.png)

**IMPORTANT**  "Server" it should point to your local server
Please check your config.ini file where hived is and see if you have this line   
`webserver-http-endpoint = 127.0.0.1:8091`    and write   `http://127.0.0.1:8091`  in the server directive of data.json 

on the other hand, if your node is public or you want it to be public you can put it like this in the image. `0.0.0.0:8091` 
![image](https://images.ecency.com/DQmYxA9JaBYSEAnnTGpUghfBzwUuSC2QHRsXju47NqTKGxX/image.png)

And in the data.json file you write it like this  `http://0.0.0.0:8091`  in the server directive of data.json ..

For the purpose of this example I use, https://api.deathwing.me/ which is the best public node that there is at the moment... but the ideal is that you use your own node because we are going to make many http requests and we don't want to saturate the bandwidth of any witness..

With this  config  your server is LIVE and working..!
___
If you don't have a web server and you just installed the PHP you can start the web server that comes internal in PHP, the only disadvantage is that it is not multithreaded so it attends several simultaneous requests but it can get slow.

locate yourself in the directory called monitor and run this:

`php -S 0.0.0.0:9000 -t .`
This will start the PHP web server on port 9000  .. and you can access it simply like this `http://IPADDRESS:9000/`
___
In the project you will find a file called monitor.php which has execution permissions, if it doesn't have execution permissions grant them like this.

`chmod 777 monitor.php`

then you can run it like this `./monitor.php` or better to send it to the background you can do this:

`nohup ./monitor.php 2> /dev/null > /dev/null &`

**./monitor.php**
The purpose of this program is to create a file in which the last 10 blocks you have produced are stored, saving the date and time, the block number and the frequency in which you are generating the blocks, it is intended that it be in the background so that you close your browser, the information continues to be captured and it will help you to know how often you generate the blocks and how often the blocks were assigned to you..  the use of this file is completely optional.
___




![image](https://images.ecency.com/DQmNkLLbuaGAKSGzHo21HYaWxsPZjAPfx1r5tHepbkXvphZ/image.png)

**500 HIGHEST VOTES**
Show accounts and  HP

![image](https://images.ecency.com/DQmZtbU8tPHgdsFnBYeiF4E3cptcvUxEWyVYwURn8YuBWd9/image.png)

To show the votes, i get data from other project of the **arcange witness**
https://hive.arcange.eu/witnesses/


___
**System Commands:**

There are a few commands I've had to use to make it easier to display server resources like these:

`df -h`
To see how much space is free on the hard drives.

`free -m`
to see the free space in memory

`ps -x | grep hived`
to check if the ./hived process is running.

___
This code could have been made as an executable and not deliver the source code and it could be more optimal, but I have decided to use PHP so that anyone can study the code and there is transparency.

***DELIVERED AS IS***
___
Finally
at the bottom of the web page you will see from time to time a subliminal message reminding you to vote for me as witness, since it is the only support that I request, keep in mind that I have dedicated 1 week and a half of work day and night, to finish this and there are many lines of code, a lot of late night  and effort in the middle of all this..  from  Colombia with Love.. 🇨🇴
</div>

<center>
<hr>
<a href="https://hivesigner.com/sign/account-witness-vote?witness=zuun.net&approve=1"><h1>Vote for me as Hive Witness</h1></a>
<hr>
</center>
👍  , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , and 30 others
👎  ,
properties (23)
authorzuun.net
permlinkhive-witness-monitor-1-0
categoryhive-139531
json_metadata"{"links":["https://ecency.com/hive-139531/@zuun.net/hive-witness-monitor-development","https://zuun.net/monitor/","https://zuun.net/monitor/monitor.tar.gz","http://127.0.0.1:8091","http://0.0.0.0:8091","https://api.deathwing.me/","http://IPADDRESS:9000/","https://hive.arcange.eu/witnesses/","https://hivesigner.com/sign/account-witness-vote?witness=zuun.net&approve=1"],"image":["https://images.ecency.com/DQmekr12aLqvbajBKb9exmYsFNrAvyb7asEu74igsU2WrN6/image.png","https://images.ecency.com/DQmcDtKghLTPBCMAcu9NacDyiicQiVN38HZXZXkib1LKxzS/image.png","https://images.ecency.com/DQmaEg7RxBkhxiNGonugRWn5VsNzHVNJTsB7WTnzn9ayWH3/image.png","https://images.ecency.com/DQmYxA9JaBYSEAnnTGpUghfBzwUuSC2QHRsXju47NqTKGxX/image.png","https://images.ecency.com/DQmNkLLbuaGAKSGzHo21HYaWxsPZjAPfx1r5tHepbkXvphZ/image.png","https://images.ecency.com/DQmZtbU8tPHgdsFnBYeiF4E3cptcvUxEWyVYwURn8YuBWd9/image.png"],"thumbnails":["https://images.ecency.com/DQmekr12aLqvbajBKb9exmYsFNrAvyb7asEu74igsU2WrN6/image.png","https://images.ecency.com/DQmcDtKghLTPBCMAcu9NacDyiicQiVN38HZXZXkib1LKxzS/image.png","https://images.ecency.com/DQmaEg7RxBkhxiNGonugRWn5VsNzHVNJTsB7WTnzn9ayWH3/image.png","https://images.ecency.com/DQmYxA9JaBYSEAnnTGpUghfBzwUuSC2QHRsXju47NqTKGxX/image.png","https://images.ecency.com/DQmNkLLbuaGAKSGzHo21HYaWxsPZjAPfx1r5tHepbkXvphZ/image.png","https://images.ecency.com/DQmZtbU8tPHgdsFnBYeiF4E3cptcvUxEWyVYwURn8YuBWd9/image.png"],"tags":["hive-139531","witness","hive","hiveio"],"description":"In this post I announce the release of the first version of the (OPEN SOURCE) HIVE WITNESS MONITOR.","app":"ecency/3.0.23-vision","format":"markdown+html"}"
created2022-06-28 23:34:36
last_update2022-06-28 23:34:36
depth0
children2
last_payout2022-07-05 23:34:36
cashout_time1969-12-31 23:59:59
total_payout_value6.372 HBD
curator_payout_value6.354 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length4,987
author_reputation7,544,051,248,473
root_title"HIVE WITNESS MONITOR - 1.0"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id114,411,154
net_rshares21,712,709,777,296
author_curate_reward""
vote details (96)
@mintrawa ·
Nice job 👍 Do you plan to put it on Github?
properties (22)
authormintrawa
permlinkre-zuunnet-re8qie
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"peakd/2022.05.9"}
created2022-06-29 13:23:03
last_update2022-06-29 13:23:03
depth1
children1
last_payout2022-07-06 13:23:03
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length43
author_reputation18,694,802,429,423
root_title"HIVE WITNESS MONITOR - 1.0"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id114,423,493
net_rshares0
@zuun.net ·
$0.06
Thank you..   for your vote and  opinion...
maybe  on Github, when  i start a new version..
👍  , , ,
properties (23)
authorzuun.net
permlinkre-mintrawa-2022629t17424674z
categoryhive-139531
json_metadata{"tags":["hive-139531"],"app":"ecency/3.0.23-vision","format":"markdown+html"}
created2022-06-29 22:42:06
last_update2022-06-29 22:42:06
depth2
children0
last_payout2022-07-06 22:42:06
cashout_time1969-12-31 23:59:59
total_payout_value0.029 HBD
curator_payout_value0.029 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length91
author_reputation7,544,051,248,473
root_title"HIVE WITNESS MONITOR - 1.0"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id114,435,851
net_rshares104,942,069,901
author_curate_reward""
vote details (4)