Author Topic: Firewall problem  (Read 3889 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Firewall problem
« on: March 14, 2020, 06:16:01 PM »
Every now and then websites can't connect to DB, and I can't even get CWP login screen. Bunch of lines with php and mysql errors pop up. When I manage to get inside CWP I find Firewall off, and can't turn it on.

Dashbord says that Firewall is disabled, but when I try to Enable Firewall, message says csd and lfd are not disabled!
What's going on here?


Re: Firewall problem
« Reply #1 on: March 14, 2020, 07:15:44 PM »
Quote
Bunch of lines with php and mysql errors pop up
This is as useful as a chocolate teacup! Read the error messages and digest.

Not aimed specifically at you:
  • "My car is broken"
  • What appears to be wrong with it?
  • "I don't know, it's broken"

There has been a bug with the way CWP reports a disabled CSF, from the very first time I used this panel.
To add salt to the wound, they appeared to have removed the official CSF GUI from the menu - version 0.9.8.951 freshly installed today.
The latest release has a number of errors during installation too, so not properly tested/debugged.

If you've done a 'csf -e' and 'systemctl status lfd' shows running, then take those to be the correct answers, rather than the (bug ridden, typo driven) GUI.
« Last Edit: March 14, 2020, 07:25:59 PM by ejsolutions »

Offline
*****
Re: Firewall problem
« Reply #2 on: March 15, 2020, 09:11:52 AM »
try this commands one by one :
csf -x
csf -e

Offline
*
Re: Firewall problem
« Reply #3 on: March 15, 2020, 04:36:57 PM »
Commands work, but it happens often. It seems like if I don't get it resolved in a couple of days, mysql goes wild, and I have problem logging into CWP, while websites are down (WP: Error connecting to database).

Is there a way to prevent this?

Offline
*****
Re: Firewall problem
« Reply #4 on: March 15, 2020, 07:58:13 PM »
it not normal behaviour, probably you've OOM

Offline
*
Re: Firewall problem
« Reply #5 on: March 17, 2020, 12:25:09 AM »
Ok, here is the message. It showed up after logging into CWP, situation resolved itself and everything started working.


Code: [Select]
Warning: mysqli_connect(): (HY000/2002): Connection refused in /usr/local/cwpsrv/htdocs/resources/admin/include/functions.php on line 0

Warning: mysqli_connect(): (HY000/2002): Connection refused in /usr/local/cwpsrv/htdocs/resources/admin/include/functions.php on line 0

Warning: mysqli_connect(): (HY000/2002): Connection refused in /usr/local/cwpsrv/htdocs/admin/admin/index.php on line 0

Warning: mysqli_connect(): (HY000/2002): Connection refused in /usr/local/cwpsrv/htdocs/admin/admin/index.php on line 0


Trying to start mysql server, please wait!
Try to restart CentOS Web Panel with command: sh /scripts/restart_cwpsrv

**Check your MySQL root password in: /usr/local/cwpsrv/htdocs/resources/admin/include/db_conn.php and /root/.my.cnf


Warning: mysqli_error() expects exactly 1 parameter, 0 given in /usr/local/cwpsrv/htdocs/admin/admin/index.php on line 0
Could not connect: