Nagios is the most popular open-source infrastructure monitoring tools. Nagios offers monitoring and alerting for servers, switches, applications, and services. It alerts users when things go wrong and alerts them again when the problem has been resolved.
I have created a script to install Nagios and Nagious plugin in RHEL/CentOS:
#!/bin/bash # Install nagios and [...]
I usually having problem whereby I always forgot to check what happen to my copying or downloading progress in the server. This has gives me idea to create a script to notify me via email once the command executed and completed.
For example, I usually download a big installer file which usually make me constantly [...]
Here are several of my BASH commands collection related to looping which I frequently used. This list will be always updated for reference and knowledge base.
1. Copy .htaccess file under /home/website1/public_html to all directories and sub-directories under /home/website2/public_html excluding .svn directories:
cd /home/website2/public_html for i in $(find -type d | egrep -v .svn); do cp [...]
The good thing about cPanel is you can generate your own backup automatically using cPanel API. In this case, we will use PHP to run on schedule to automatically generate backup and transfer via FTP or SCP to another server. This implementation can be done on user level without need to login into cPanel login page.
To [...]
If you familiar in administrating cPanel, you should know a script/tool called pkgacct. This is the backup tools being used by cPanel in order to create and manage cPanel user’s account backup. By using this tool, we can take advantage by create a centralized backup server where cPanel account backup will be sent over to [...]
Our company has launched an online contest for our dedicated clients and we are collecting some really important information from them in order join the contest. My boss wants me to create a database backup every half an hour to make sure we reduce the data loss chance to the minimum possible.
I have create [...]
One of the server that I am working with has some infinitely running PHP process. Due to incorrect way of cron setup by the development team, it has caused the process hanging and not ended properly. According to them, these processes can be killed if still hang after 12 hours.
Any process which run in [...]
FrontPage Extension in cPanel is consider deprecated and there are many security holes reported in this. Microsoft has discontinued FrontPage extension support for the Unix platform since end of 2006. It is good thing to remove this extension which sometimes being installed without your acknowledgement.
When you have 2 MySQL server which is not running in replication or cluster, is recommended to have MySQL backup running daily. This will help you on fast restoration, reliable data backup and disaster recovery.
I have created a bash script to run daily and make sure the data is save into local disk and [...]
This post will required Fsniper installed and running on your box. Please see following post: FSniper – Monitor Newly Created Files in Directory . This is similar to popular paid-version of ConfigServer eXploit Scanner (cxs), which also using inotify functionality which comes since kernel 2.6.13.
I am using Fsniper to [...]
Sci/Tech – Google News- Moon meteor blast was visible to naked eye: NASA - Zee News - India - Zee News 19 May 2013
- BMW 5 Series LCI - Sedan, Touring and Gran Turismo - ASEAN Automotive News (blog) 19 May 2013
- Check out the new 2013 Peugeot RCZ Magnetic Limited Edition - Motoroids 19 May 2013
- Google Glass: Cool or creepy? - Mail & Guardian Online 19 May 2013
- Lexus IS - TRD works its magic on the third-gen - ASEAN Automotive News (blog) 19 May 2013


Bash Script – Delete Comments from a C program
I wrote a bash script to delete comments from a C program. C language will required /* and */ between the contents of the comment. Example as below:
MQLONG Reason; /* Qualifying reason */ MQOD ObjDesc = {MQOD_DEFAULT}; /* Object descriptor */ MQLONG OpenOptions; /* Options control MQOPEN */ ⋮ /*—————————————– */ /* Initialize the [...]