Select Country

  • Sales: +1234567890 | Sales@domainname.com
  • Billing: +1234567890 | Billing@domainname.com
cart icon 0
logo
  • Sales: +1234567890 | Sales@domainname.com
  • Billing: +1234567890 | Billing@domainname.com
cart icon 0

install CSF on a cPanel server

To install CSF on a cPanel server, SSH into your server as root, download the latest CSF package from GitHub, extract it, and run the install.cpanel.sh script located in the extracted directory. Since the official CSF website shut down in August 2025, you must download the package from GitHub and then configure the firewall through the WHM interface to enable it and disable testing mode. 
 
1. Prepare Your Server
  • Log in via SSH: Access your server using the root user. 
     
  • Remove conflicting firewalls: If you have other firewalls like APF installed, remove them first by running sh /etc/csf/remove_apf_bfd.sh. 
     
 
2. Download and Install CSF 
 
  • Navigate to the source directory: Use the cd command to go to /usr/src, a common location for installing software.
  • Download the latest package: Get the latest version of CSF from GitHub:
Código
 
    wget https://raw.githubusercontent.com/waytotheweb/scripts/refs/heads/main/csf.tgz
Extract the package.
Código
 
    tar -xzf csf.tgz
Change to the CSF directory.
Código
 
    cd csf
  • Run the cPanel install script: This script handles the installation for cPanel/WHM environments. 
     
Código
 
    <<!nav>>./install.cpanel.sh<<!/nav>>
3. Configure and Enable CSF
  • Access WHM: Log in to your WebHost Manager (WHM). 
     
  • Find the CSF plugin: Navigate to the "ConfigServer Security & Firewall" option in the WHM interface. 
     
  • Configure ports: Use the "Firewall Configuration" button in the WHM interface to open necessary ports. 
     
  • Disable testing mode: In the main CSF interface, you will need to turn off the "Test Mode" to fully activate the firewall. 
     
  • Restart the firewall: After making configuration changes, restart CSF to apply them. 
     
4. Verify Installation
  • Check CSF status: You can verify the installation and status through the WHM interface. 
     
  • Check for errors: Be aware of potential errors, especially concerning the Firewall LKM (Loadable Kernel Module), which may require enabling a monolithic kernel in /etc/csf/csf.conf. 
  • csf, cpanel/whm, cpanel, CloudFlare
  • 0 Utilisateurs l'ont trouvée utile
Cette réponse était-elle pertinente?

Articles connexes

¿Cómo actualizar su licencia de cPanel?

En algunas ocasiones, no podrá completar el acceso a su cuenta de cPanel debido a errores de...

Desactiva tu archivo .htaccess

El archivo .htacces es un archivo de control para las cuentas de cPanel y de hosting de WordPress...

How to install cPanel/WHM on CentOS 7

In this tutorial, we can check how to install cPanel on a CentOS 7 server. Before installing...

Actualizar Licencia de cPanel

Cuando tenemos un servidor recien instalado o cambiamos el hostname del servidor, podemos...

Cómo reiniciar el servicio Spamd – cPanel

Servicio Spamd ¡No es gran cosa, pero hay que saber cómo hacerlo! Me preguntaba si el servicio...

Powered by WHMCompleteSolution