Latest Posts

Create a PHP static Page to Show NodeQuery Monitoring Server Status

I am using NodeQuery free service (10 nodes) to monitor my VPS in the cloud for quite  a few time now. It is my favorite monitoring tools meeting most of my requirements: cloud, light weight, fast, enough detail. If I have to say one thing to improve , that would be Windows agent. It does not support Windows machine. NodeQuery is a cloud monitoring tool only for Linux servers. It can easily monitor linux server's CPU, memory, bandwidth and status. Users only need to install a light weight client on their own servers with one line auto-generated command, and you can see intuitively nice server status image in NodeQuery in a few minutes (usually less than10 minutes).


NodeQuery 

1  Registered address:  https://nodequery.com/
Go to the NodeQuery official website to register an account.

2  Create a new server in the background, fill in the host name, keep the default and save.



3  Copy the generated command and paste it into Linux to complete the installation with one click.
After waiting for about 10 minutes, you can see intuitive data in NodeQuery. If the server fails or fails to connect, NodeQuery will send an email reminder to the administrator.






To remove agent from installed server: Run following command as root to remove the NodeQuery agent from the server you've just deleted. You can find this code once you try to delete the server from Edit option. 
rm -R /etc/nodequery && (crontab -u nodequery -l | grep -v "/etc/nodequery/nq-agent.sh") | crontab -u nodequery - && userdel nodequery

Install NodeInfo

NodeQuery provides API support, and NodeInfo (developed by the small z blog) uses the data provided by the NodeQuery API to provide simple server monitoring information, which can be easily placed on your own website for administrators or visitors to view.

1  Create a Read-Only API from NodeQuery Account Settings page





2  Modify and ListServers.phpfill in your own NodeQuery API.




3  Upload whole folder's files into remote php website
I created a new folder , monitor , which is hosting all files from NodeInfo.



Here is how the webpage looks like. It will be refreshed every 3 minutes. You can modify html file and php file to have your own customization. Very nice and useful tool to show your servers in the cloud.











1 comment: