To add IP address in to deny list
csf -d IP
To add IP address in to allow list
csf -a IP
How to restart csf firewall
How to stop csf firewall
Path of CSF configuration file on cPanel server
Path of denied IP addresses file in CSF
Path of allowed IP address file in CSF
How to add IP address in to ignorelist
(1) login to shell
(2) add IP address in to /etc/csf/csf.ignore
How to find IP address blocked in temporary ban
grep IP /etc/csf/csf.tempban
In cPanel enviroment, you can edit the outgoing IP by edit /etc/mailips. This file controls the IP address from which each domain should send mail.
It can be configure this file in the following way:
Example 1 : all kc.com outgoing mail IP is 192.168.0.2
Example 2 : sub.kc.com outgoing mail IP is 192.168.0.3
Example 3 : All domain in this server will use outgoing IP 192.168.0.1
Note: after done the setting, make the file /etc/mailips immutable. This to ensure the file is not reseted after service restart.
chattr +i /etc/mailips
Last step, restart the service
Today I found that one account having weird error.
1) The group ownership became an ID and the site is unable to load as in valid group.
2) Where try chown the folder, it will return “invalid user” error
1) check if the group ownership is correct, it wrong as below, please continue step (2)
2) open /etc/group and add in USER:x:GROUP:
For the screen shot case, add it as ipless:x:512:
3) /etc/gshadow and add in USER:!::
For the screen shot case, add it as ipless:!::
Done and the group permission will correct automatically.
There is some command to trigger ClamAV in Linux server which is more easy to use back-end.
To scan all the file in the path
clamscan -r path
To scan all directories and sub directories recursive
clamav -ril /home/user/clamav.log
To scan all the server and provide report
clamscan -ir / -l cscanreport
When you receive the error as below when try to create Ruby on Rails application on cPanel. It mean that your rails/ruby version installed is not supported by cPanel.
Your app is NOT installed because there was a problem. Try again or contact
our support team.
So the solution will be remove the current Ruby and Rails and install it by cPanel build in script. Moving the unsupported Ruby and Rails environment and then reinstalling using the proper cPanel script should setup the machine with the right Rails version and mongrel.
(1) Remove the unsupported Ruby and Rails
mv /usr/bin/ruby /usr/bin/ruby.bak
mv /usr/lib/ruby /usr/lib/ruby.bak
mv /usr/bin/gem /usr/bin/gem.bak
mv /usr/bin/rails /usr/bin/rails.bak
(2) Install again by cPanel script