Control Web Panel
WebPanel => CentOS-WebPanel Bugs => Topic started by: JPa_SK on January 26, 2022, 08:02:14 PM
-
Hi friends ...
We have had some problems with varnish ...
----------------------------------------------------
Error 503 Backend fetch failed
Backend fetch failed
Guru Meditation:
XID: 1279924
----------------------------------------------------
we use webserver configuration nginx-varnish-apache-php-fpm...
after some study/investigation of internet we found recomendations some changes in config files ...
we have added them to the files in: /etc/varnish/default.vcl
and we have added them have updated files in : /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl
then we have updated all domains in CWP > WebServers Domain Conf
And all changes from default.vcl or default.tpl were updated in files in all fomain files: /etc/varnish/conf.d/vhosts
After this was everything OK and Error 503 Backend fetch failed .... they came only very rarely ....
But the biggest that after some time (may be after CWP update) the config files were rewrited to old ones ...
files in : /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl
and
all fomain files: /etc/varnish/conf.d/vhosts
all our changes were lost ...
Please why ???
we think that it is very BAD!!!
CAn you do something with this ???
Thank
Juraj
-
This is an intended and normal behavior. CWP devs has constantly said NOT edit the default templates (tpl and stpl). You need to clone a template, give it a new name and then edit it, then use the new template that you have made.
https://wiki.centos-webpanel.com/webservers-vhost-templates
-
Hi friends ...
We have had some problems with varnish ...
----------------------------------------------------
Error 503 Backend fetch failed
Backend fetch failed
Guru Meditation:
XID: 1279924
----------------------------------------------------
we use webserver configuration nginx-varnish-apache-php-fpm...
after some study/investigation of internet we found recomendations some changes in config files ...
we have added them to the files in: /etc/varnish/default.vcl
and we have added them have updated files in : /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl
then we have updated all domains in CWP > WebServers Domain Conf
And all changes from default.vcl or default.tpl were updated in files in all fomain files: /etc/varnish/conf.d/vhosts
After this was everything OK and Error 503 Backend fetch failed .... they came only very rarely ....
But the biggest that after some time (may be after CWP update) the config files were rewrited to old ones ...
files in : /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl
and
all fomain files: /etc/varnish/conf.d/vhosts
all our changes were lost ...
Please why ???
we think that it is very BAD!!!
CAn you do something with this ???
Thank
Juraj
I have the same problem with varnish, can I ask for information what should be changed in these templates?
-
I just right now installed a new CWP server, and had this problem too. (503 backend error)
For some reason, the CWP install script didn't install the correct file '/etc/varnish/default.vcl'.
The content of the installed file is the original file from the varnish distribution, without any modification, and is proxying to 127.0.0.1 on port 8080, which does not exist.
So, to fix the problem, just change the '/etc/varnish/default.vcl' file, removing its content and replacing it with the following content:
vcl 4.0;
backend default { .host = "107.191.125.119"; .port = "8181";}
include "/etc/varnish/conf.d/vhosts.conf";
Regards,
Netino
-
This is an intended and normal behavior. CWP devs has constantly said NOT edit the default templates (tpl and stpl). You need to clone a template, give it a new name and then edit it, then use the new template that you have made.
https://wiki.centos-webpanel.com/webservers-vhost-templates
Hi friends,
I know this normal behavior ...
1. I have created my own default-XX.vcl
2. rewrited all domains in /etc/varnish/conf.d/vhosts....
but all changes were deleted after CWP wersion ubdate ...
And this seems to be very bad ...
Nobody can edit changes every CWP version update ...
!!!!!!! PLEASE Do something with this .... !!!!!!!
Juraj
-
1. I have created my own default-XX.vcl
2. rewrited all domains in /etc/varnish/conf.d/vhosts....
I don't understand why you repeat the same error. Are you directly modifying the files in /etc/varnish/conf.d/vhosts ??
-
Hi I have changed it using CWP GUI > Webservers Conf Editor > Tab:varnish > SubTab>/etc/varnish/conf.d/vhosts where are conf files for each of my domains ....
/etc/varnish/conf.d/vhosts/my-domain1.sk.conf
/etc/varnish/conf.d/vhosts/my-domain2.sk.conf
/etc/varnish/conf.d/vhosts/my-domain3.sk.conf
...
/etc/varnish/conf.d/vhosts/my-domainXXX.sk.conf
I assume that these files are generated for each domain when it is created-inserted into the system ...
I have no idea why they should change with every CWP upgrade?
Juraj
-
Copy /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl to /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/custom.tpl
Make your modifications for the port there.
In CWP, goto WebServer Settings -> WebServers Main Config
Set the template to custom.tpl
On Update, the sites should rebuild using your custom.tpl file
-
Copy /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl to /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/custom.tpl
Make your modifications for the port there.
In CWP, goto WebServer Settings -> WebServers Main Config
Set the template to custom.tpl
On Update, the sites should rebuild using your custom.tpl file
HI rcschaff,
If you will read all my posts in this article, you will be able to see that this was done almost at the beginning.
After this change I have used this CUSTOM.tpl in CWP GUI > Webservers Domains Conf Editor > for each domain ....
in place ...
See picture ...https://cimborka.sk/Varnish_Screenshot_LI.jpg (https://cimborka.sk/Varnish_Screenshot_LI.jpg)
But after CWP sw update all changes created in formular are lost .... see pisture...
WHY??
Thanks
Juraj
-
The only thing I can think of, is not name it default. Being as the code is encrypted, I can't really see what's going on, but if it's not rebuilding from your custom file each update, there's definitely a bug. I have Nginx with custom configs for wordpress, and they don't behave this way.
-
Hi rcschaff,
thank you ..
I will wait how it will behave next updates of CWP.
Thank you for you answers :-)
Juraj
-
maybe your template has some issue since it works fine when switching per domain between default/wordpress template.
try to check webservers rebuild logs to know the issue.
/var/log/cwp/webservers.log
-
I am facing the same problem.
Have you got the solustion?
Error 503 Backend fetch failed
Backend fetch failed
Guru Meditation:
XID: 4522142
Varnish cache server
Hi friends ...
We have had some problems with varnish ...
----------------------------------------------------
Error 503 Backend fetch failed
Backend fetch failed
Guru Meditation:
XID: 1279924
----------------------------------------------------
we use webserver configuration nginx-varnish-apache-php-fpm...
after some study/investigation of internet we found recomendations some changes in config files ...
we have added them to the files in: /etc/varnish/default.vcl
and we have added them have updated files in : /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl
then we have updated all domains in CWP > WebServers Domain Conf
And all changes from default.vcl or default.tpl were updated in files in all fomain files: /etc/varnish/conf.d/vhosts
After this was everything OK and Error 503 Backend fetch failed .... they came only very rarely ....
But the biggest that after some time (may be after CWP update) the config files were rewrited to old ones ...
files in : /usr/local/cwpsrv/htdocs/resources/conf/web_servers/vhosts/varnish/default.tpl
and
all fomain files: /etc/varnish/conf.d/vhosts
all our changes were lost ...
Please why ???
we think that it is very BAD!!!
CAn you do something with this ???
Thank
Juraj
-
happen to me too
but...
i use wordpress and run rss fetch...
via free cloudflare with proxy on and flexible mode.
cwp varnish config webserver using wordpress template ( better, than using default)
if i bypass the Cloudflare proxy (disable/gray) everything run well
-
Hello guys!
I've been experimenting with CWP for a while now. We already have several servers in production using it and we like it.
Most errors are resolved by doing a "rebuild".
I solved this problem on one of the servers by doing the following:
Select WebServers -> Save & Rebuild Configuration
I understand that many days have passed, but I hope this information can help someone in the future.
-
Hello guys!
I've been experimenting with CWP for a while now. We already have several servers in production using it and we like it.
Most errors are resolved by doing a "rebuild".
I solved this problem on one of the servers by doing the following:
Select WebServers -> Save & Rebuild Configuration
I understand that many days have passed, but I hope this information can help someone in the future.
try to disable varnish.varnish64 repo.. then rebuild