Control Web Panel
WebPanel => Installation => Topic started by: Tuan on July 10, 2018, 09:58:25 AM
-
Dear all,
After install on fresh VPS Centos 7 with instruction from http://centos-webpanel.com/installation-instructions
I try to access by port 2030 or https with port 2031, but CWP show refused to connect.
I check status for cwpsrv from command line, it show disable, try to start cwpsrv but show error
● cwpsrv.service - CentOS Web Panel service (daemon)
Loaded: loaded (/usr/lib/systemd/system/cwpsrv.service; enabled; vendor preset: disabled)
Active: activating (auto-restart) (Result: exit-code) since Tue 2018-07-10 23:56:25 +07; 4s ago
Process: 1894 ExecStartPre=/usr/local/cwpsrv/bin/cwpsrv -t (code=exited, status=1/FAILURE)
Jul 10 23:56:25 vps41234.superdata.vn systemd[1]: cwpsrv.service: control process exited, code=exited status=1
Jul 10 23:56:25 vps41234.superdata.vn systemd[1]: Failed to start CentOS Web Panel service (daemon).
Jul 10 23:56:25 vps41234.superdata.vn systemd[1]: Unit cwpsrv.service entered failed state.
Jul 10 23:56:25 vps41234.superdata.vn systemd[1]: cwpsrv.service failed.
May I know what cause the problem, and how to solve it.
Tks a lot for you help.
-
try checking the issue in the error log
tail /usr/local/cwpsrv/logs/error_log
-
view error_log it show the below error
2018/07/11 04:47:05 [emerg] 32348#0: BIO_new_file("/etc/pki/tls/certs/hostname.crt") failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/etc/pki/tls/certs/hostname.crt','r') error:2006D080:BIO routines:BIO_new _file:no such file)
what should i do next?
Tks a lot for your help.
-
view error_log it show the below error
2018/07/11 04:47:05 [emerg] 32348#0: BIO_new_file("/etc/pki/tls/certs/hostname.crt") failed (SSL: error:02001002:system library:fopen:No such file or directory:fopen('/etc/pki/tls/certs/hostname.crt','r') error:2006D080:BIO routines:BIO_new _file:no such file)
what should i do next?
Tks a lot for your help.
Seems to be an error hostname SSL.
Kindly perform this command and then tell me.
/scripts/generate_hostname_ssl
-
I tried to run your script but it shows:
[root@vps41234 scripts]# bash generate_hostname_ssl
hostname: Name or service not known
Usage: generate_hostname_ssl <domain>
Try to add domain name, hostname after the script but still the same.
Tks a lot.
-
I tried to run the following code, now CWP is working but still show a lot of errors :)
sudo openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout /etc/pki/tls/private/hostname.key -out /etc/pki/tls/certs/hostname.crt
then
sudo openssl dhparam -out /etc/pki/tls/certs/dhparam.pem 2048
then
cat /etc/pki/tls/certs/dhparam.pem | sudo tee -a /etc/pki/tls/certs/apache-selfsigned.crt
then reboot the system, reload_cwpsrv, restart_cwpsrv... can access CWP both at port 2030 and 2031 now.
Continue to fix other bugs...