Useful VPS Commands
Posted by Pacific Host on 04 December 2011 04:43 PM
You can find the amount of connections to Apache with this command:
To find the amount of Apache processes use this command:
To find the amount of MySQL processes use this command:
Just simply using top (standard view) or top -c (will show the actual command being used and/or location of each process as opposed to just the name) can help you monitor your VPS usage very wel.
To see your disk space usage, try using this command --> df -h
That will help you see how many connections each IP address has in total to your server.
There's a very decent script you can use to automate the banning of IP addresses available here --> http://forums.deftechgroup.com/showthread.php?t=825
Please contact our support department if you believe you are under a DDOS, we will be able to assist mitigating this.
Login to WHM as root, scroll down to "cPanel 10.8.1-R15" (it may be slightly different depending on what version you are using) then goto "Addon Modules" and install "spamdconf". Once it's done, refresh the WHM page, scroll down to "Add-ons" on the nav bar and then click on 'Setup Spamd Startup Configuration". Set "Maximum Children" to "2". Then hit Submit. Wait a few seconds (15-30, but usually less) for exim to restart and you're done .
cPanel Tweak Seatings
Here are some suggested settings:
Default catch-all/default address behavior for new accounts. fail will generally save the most CPU time.
Number of minutes between mail server queue runs (default is 60)
Track the origin of messages sent though the mail server by adding the X-Source headers (exim 4.34+ required)
Awstats Reverse Dns Resolution
Delete each domain's access logs after stats run