People using VPS hosting or dedicated hosting services for their website and app hosting, facing issues with server security.
It becomes more difficult when someone is not from technical or system administration background and managing server for his/her website, app, company.
So here we are making this task to something more simple for ssh login attacks via using fail2ban on your centos server.
Here i am discussing step by step guide to secure your VPS/dedicated hosting ssh access with the help of fail2ban.
Table of content …
- Why security is measure concern with a virtual or dedicated server
- General security tips
- Firewall based Security
- SSH Hardening
- Malware/virus/Hacking prevention tools
Secure your Linux based VPS
It’s nice that you are upgrading your website from shared hosting to VPS hosting to provide more power, more speed, more freedom, more resources, more flexibility and so on.
But when you move to VPS / dedicated server it’s security becomes an important aspect for your websites & apps data.
Security includes malware protection, virus protection, intrusion detection and protection, bandwidth stealing prevention, spam relay prevention, and much more things need to focus from a security point of view.
Here we will discuss step by step tips for virtual & dedicated server security tips.
Basic security measures
- Keep your system up to date cause software update is the biggest security measure itself, the software update includes various vulnerabilities, patches. If possible schedule automatic software updates.
- Add limited user accounts with minimum required permissions.
- Remove Unused Network-Facing Services
Firewall based security
With Cpanel installation configure lfd and CSF firewall on the server, iptables (for ipv4 and ipv6 ports)
configure ssh on nonstandard ports, install fail to ban
Malware / virus / Hacking protection tools
Why Vps Hosting prefered for startup E-commerce business
HM installation step on centos
- yum install Perl
- yum update -y
- set FQDN for server
- wget -N http://httpupdate.cPanel.net/latest
- sh latest
Once the installation is done access WHM
- Install CSF and lfd