Control Web Panel

WebPanel => CentOS 6 Problems => Topic started by: johnny09 on August 03, 2018, 04:57:13 PM

Title: 502 Bad Gateway
Post by: johnny09 on August 03, 2018, 04:57:13 PM
Hi,

need help, cant login to cwp panel, not loccaly or from IP, restarted server, no ideas.

locall ip:2030 redirects to 2087
locall ip 2031 Your connection is not secure after certificate approval get 502 Bad Gateway

Running centos 6.10, cwp pro... help???
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 03, 2018, 05:16:43 PM
Dose not help

[root@host ~]# cd /scripts
[root@host scripts]# ./restart_cwpsrv
Stopping cwpsrv:                                           [  OK  ]
Starting cwpsrv:                                           [  OK  ]
cwp-phpfpm: unrecognized service
Title: Re: 502 Bad Gateway
Post by: Yun on August 03, 2018, 05:26:29 PM
I am using CENTOS 7. I think someting went wrong today while auto updating.
I have same problem.. No solution yet...
Title: Re: 502 Bad Gateway
Post by: maxwellins on August 04, 2018, 12:21:19 AM
I am using CENTOS 7. I think someting went wrong today while auto updating.
I have same problem.. No solution yet...

Yes i have same problem. centos 7 auto update ruined everything
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 05, 2018, 08:13:41 AM
Some help from support???
Title: Re: 502 Bad Gateway
Post by: josemnunez on August 05, 2018, 11:05:40 PM
Try running the following script in this same order

Code: [Select]
sh /scripts/cwpsrv_rebuild_user_conf
sh /scripts/restart_cwpsrv
Please let me know how it went
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 06, 2018, 07:13:33 AM
I have tried that, did not work:

[root@host ~]# sh /scripts/cwpsrv_rebuild_user_conf
Reloading cwpsrv:
cwp-phpfpm: unrecognized service
[root@host ~]# sh /scripts/restart_cwpsr
sh: /scripts/restart_cwpsr: No such file or directory
Title: Re: 502 Bad Gateway
Post by: bullten on August 06, 2018, 08:25:11 AM
Try this

Code: [Select]
sudo yum reinstall cwpphp -y
service cwp-phpfpm restart
service cwpsrv restart
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 06, 2018, 09:17:42 AM
Nope

[root@host ~]# sudo yum reinstall cwpphp -y
Loaded plugins: fastestmirror, refresh-packagekit, security
Setting up Reinstall Process
No Match for argument: cwpphp
Loading mirror speeds from cached hostfile
 * base: centos.koyanet.lv
 * extras: centos.koyanet.lv
 * updates: centos.koyanet.lv
Package(s) cwpphp available, but not installed.
Error: Nothing to do
[root@host ~]# service cwp-phpfpm restart
cwp-phpfpm: unrecognized service
[root@host ~]# service cwpsrv restart
Stopping cwpsrv:                                           [  OK  ]
Starting cwpsrv:                                           [  OK  ]
[root@host ~]#
Title: Re: 502 Bad Gateway
Post by: bullten on August 06, 2018, 09:28:59 AM
cwpphp is not installed.

You need to run

Code: [Select]
sudo yum install cwpphp -y
sh /scripts/cwpsrv_rebuild_user_conf

This should fix your issue.
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 06, 2018, 10:03:59 AM
Thank you, now everything seems ok. loged in CWP. Works.

What happened?
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 06, 2018, 12:44:39 PM
Stooped working, cant connect.... any one?
Title: Re: 502 Bad Gateway
Post by: bullten on August 06, 2018, 02:19:30 PM
what are output of

Code: [Select]
service cwpsrv status
service cwp-phpfpm status
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 06, 2018, 08:00:56 PM
[root@host ~]# service cwpsrv status
bash: service: command not found
[root@host ~]# service cwp-phpfpm status
bash: service: command not found
[root@host ~]#
Title: Re: 502 Bad Gateway
Post by: bullten on August 06, 2018, 11:52:44 PM
This command

Code: [Select]
/sbin/service cwpsrv status
/sbin/service cwp-phpfpm status
Title: Re: 502 Bad Gateway
Post by: johnny09 on August 07, 2018, 07:37:07 AM
[root@host ~]# /sbin/service cwpsrv status
cwpsrv (pid  29955) is running...
[root@host ~]#
[root@host ~]# /sbin/service cwp-phpfpm status
cwp-phpfpm (pid  30138) is running...

Now it seems ok....
Title: Re: 502 Bad Gateway
Post by: zienos on August 11, 2018, 12:30:50 PM
my server is centos release 6.10 final 32 bit

admin panel not work and apache logs

2018/08/11 14:45:36 [crit] 1843#0: *2029 connect() to unix:/usr/local/cwp/php71/var/sockets/cwpsrv.sock failed (2: No such file or directory) while connecting to upstream, client: 85.96.203.95, server: localhost, request: "GET / HTTP/1.$
2018/08/11 14:45:36 [error] 1843#0: *2029 open() "/usr/local/cwpsrv/htdocs/admin/favicon.ico" failed (2: No such file or directory), client: 85.96.203.95, server: localhost, request: "GET /favicon.ico HTTP/1.1", host: "ziyasuzen.com:203$




and services status



[root@svr1 scripts]# service cwpsrv status
service cwp-phpfpm statuscwpsrv (pid  14706) is running...
[root@svr1 scripts]# service cwp-phpfpm status
cwp-phpfpm: unrecognized service

[root@svr1 scripts]# service php-fpm start
php-fpm: unrecognized service




what happen?


i want to update my php versiyon php7


now my admin panel not open please help
Title: Re: 502 Bad Gateway
Post by: bullten on August 12, 2018, 12:34:58 PM
The below command will fix issue for you

Code: [Select]
yum install cwp-phpfpm -y
sh /scripts/cwpsrv_rebuild_user_conf
Title: Re: 502 Bad Gateway
Post by: nguyentrunghoa on August 19, 2019, 03:56:24 AM
I have done as you told and get this:

[root@vps ~]# sh /scripts/cwpsrv_rebuild_user_conf
Reloading cwpsrv:
Reloading cwp-phpfpm: [19-Aug-2019 10:52:50] NOTICE: configuration file /usr/local/cwp/php71/etc/php-fpm.conf test is successful

                                                           [FAILED]

Please tell me how to do now?
Title: Re: 502 Bad Gateway
Post by: hacspectrum on September 05, 2019, 08:47:54 AM
On 3 different servers
same problems help me

CentOS release 6.10 (Final)
------
service cwp-phpfpm status
cwp-phpfpm (pid  14037) is running...
------
[root@server users]# service cwpsrv status
cwpsrv (pid  2963) is running...
------
[05-Sep-2019 11:37:11] NOTICE: fpm is running, pid 14037
[05-Sep-2019 11:37:11] NOTICE: ready to handle connections
[05-Sep-2019 11:44:04] NOTICE: Terminating ...
[05-Sep-2019 11:44:04] NOTICE: exiting, bye-bye!
[05-Sep-2019 11:44:04] NOTICE: fpm is running, pid 16268
[05-Sep-2019 11:44:04] NOTICE: ready to handle connections
--------
$webpanel_version = "0.9.8.683";
--------
sh /scripts/restart_cwpsrv  #no work
sh /scripts/cwpsrv_rebuild_user_conf  #no work



Title: Re: 502 Bad Gateway
Post by: randyproxz on September 05, 2019, 03:57:02 PM
Try to using this command in ssh :

First rebuild user conf :
Code: [Select]
sh /scripts/cwpsrv_rebuild_user_conf

And update the CWP :
Code: [Select]
sh /scripts/update_cwp

Then restart the cwpsrv :
Code: [Select]
service cwpsrv restart
service cwpsrv-phpfpm restart