ServerTune Logo Dedicated Servers Colocation VPS Server Management ServerTune.com
 
ServerTune HomeAbout usContact usHelp DeskKnowledgebaseSpecialLIVE Chat ServerTune
DirectAdmin VPS Server Management

Value, Power, and Performance :: Dedicated Servers starting $89 /month

Dedicated Server Hosting

Click here to view photos from the conferences we attended.   *** Follow ServerTune on: ServerTune is on Facebook ServerTune is on Twitter
 
Browse by category   Search
 


How can I block IP addresses?
Printer Friendly
email to a friend
Email to friend
Add comment Add comment
Views: 1749
Votes: 0
Comments: 0
Posted: 03 Jun, 2007
by: Customer Service :: S.
* * * * *
Updated: 19 Feb, 2008
by: Customer Service :: S.

SSH to the server and run The following command to see the IPs with most concurrent connections:

/bin/netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n |more

Block un-wanted IPs using IPTables

/sbin/iptables -I INPUT -s 12.34.56.78 -j DROP
/sbin/service iptables save
/sbin/service iptables restart

Other articles in this Category
document How can I tranfser my data from one server to another?
document Linux Text Editors :: pico, vi, and emacs
document What ports do I need to open in my firewall?
document HTML Codes
document HowTo list all files installed by an RPM package
document How can I find the local path to a command line binary?
document I added more RAM Memory, yet the system shows the wrong amount
document perl: warning: Setting locale failed.
document HowTo :: manage Linux partitions
document HowTo :: check on the current version of CentOS installed on your server
document HowTo clone, image, and re-size your Hard Drive(s) and/or partition(s)
document HowTo :: remove the Pass Phrase set on an SSL key
document Is rebooting my Linux/FreeBSD server a useful practice?



RSS

Control Panel Licensing
cPanel Plesk Miva Merchant