Plesk on Linux: updates, firewall, two-factor and a safe baseline
Plesk makes it easy to host many sites, and just as easy to leave its panel, mail and database services open to everyone. Updates, the built-in firewall and two-factor give a solid baseline.
Update Plesk and the operating system
Check the version, install pending updates and let Plesk update automatically within your window.
plesk version plesk installer --select-release-current --show-componentsEnable the Plesk firewall and Fail2Ban
Turn both on in Tools & Settings and keep the default rules for the panel, SSH, mail and web, then close ports you do not use, such as database ports.
sudo plesk bin ip_ban --listRequire two-factor authentication
Enable it for the administrator and for subscriptions that have panel access.
Restrict the panel by IP
In Tools & Settings, Security, add the addresses that may reach the panel on port 8443 if you have fixed ones, and keep a way back in.
Review PHP versions and extensions
Move sites off end-of-life PHP, one by one with a test, and remove extensions you do not use.
Check backups and test one restore
Schedule backups to a second location and restore one subscription to confirm it works.
Common mistakes
- Panel and database ports open to the internet.
- Updates paused and forgotten.
- One shared admin account for several people.
- Backups only on the same disk.
How to undo it
Remove a firewall rule you added from the panel or the console, and restore a backed-up configuration from /etc if you changed SSH settings.
Sources
Commands are for Debian and Ubuntu unless noted. Test on a copy first and keep a backup: you are responsible for changes on your own systems.