Error on 'ZipArchive'
-
Hi.
When i click in “Download” on Varnish VCLs section i get this error:
Fatal error: Class 'ZipArchive' not found in /home/mysite/public_html/wp-content/plugins/vcaching/vcaching.php on line 799.I also currently have 3 domains hosted on this server with the installed varnish, you must create a backend for each domain?
I’m currently using only one backend “default” with the host (NAT IP) and port 8080. My default.vcl: http://pastebin.com/YQUZAad4
Thx from Brazil!
-
ZipArchive is available in PHP 5 >= 5.2.0, PHP 7.
I will implement a version check and warning.Please use the manual way to get the VCLs.
Hi.
I have that
php -v:
PHP 5.5.35 (cli) (built: May 17 2016 08:56:37)The VCL’s available are very good. Would you have any example of VCL that has a fixed server (IP default) but with several Virtual Hosts?
Ex:
IP: 192.168.1.2
Host 1: http://www.google.com
Host 2: http://www.bing.com
Host 3: http://www.youtube.comTks from Brazil!
Hi.
I inserted the
libfolder andconfin/etc/varnish/…did the setting the default.vcl and everything worked properly. But the use of my server exploded reaching an Load Average of 5 ~ 51 and growing …With my current VCL I have a load of up to 0.8 ~ 1.0 at peak times on the server.
The server starts to create multiple processes using the host user, example:
User:
mysite
Command:/usr/bin/php /home/mysite/public_html/index.phpWith a CPU usage by up to 110% being with these your VCL’s active. Once I remove and return to original VCL my server stabilizes and processes back to consume 10% to 20% ..
Note: I went back to my previous VCL and the server returned to normal use … the problem is I have no automation in the cache PURGE.
Configure VCaching WP options before changing the VCLs.
Homepage TTL and Cache TTL. Otherwise Varnish Cache it will not cache anything.https://ps.w.org/vcaching/assets/screenshot-1.png?rev=1416085
This topic is resolved. I added in v1.4.3 a check for the ZipArchive class to show a notice for the admin.
Hello Razvan Stanca, thank you for support!
I will now test the new update to their VCL’s.
Thank you!
If I have more than one site hosted on the server, I need to make this change:
http://prntscr.com/bryexiAnd, in the Varnish VCL’s tab i need to configure the IP’s like:
http://prntscr.com/bryfyaConsidering 10.12.13.141 is my NAT IP, I need to make these changes?
Thank you again!!!
In the settings tab :
IPs : 10.12.13.141:8080,10.12.13.141:8080,10.12.13.141:8080
Hosts : www . mysite1.com,www . mysite2.com,www . mysite1.com
Hostnames, not URLs.In the VCLs tab :
IP : 10.12.13.141/24
Hi!
I have three sites…I will need to enter these settings in the three sites, or only one to generate the VCL’s?Thx!
The generation of VCLs uses only Backends/ACLs/Purge key/Logged in cookie.
The Hosts/IPs are used to purge Varnish, so yes, you need all of the IPs/Hosts.
I’m sorry to be disturbing, but would appreciate if you could give me one last information.
The field “backends” generated in my VCL was (Remembering that I use only one IP to the server ex. ‘10.12.13.141’):
backend backend1 { .host = ""; .port = "80"; }In Varnish caching > Varnish VCL’s I need to insert some backend or is this same way?
Note: I did apache rebuild and activated some modules (zip, opcache, tidy and mbstring). This way I can download the VCL correctly, Thank you for this one!
What is your internal IP address for the apache/nginx server ? You shoud use that IP address for VCL backends.
In the settings tab you shoud use varnish’s ip:port.For example :
External IP : 8.8.8.8:80 (varnish cache)
Internal Apache server : 192.168.0.100:80Settings :
Hosts : www. mysite1.com,www. mysite2.com,www. mysite3.com
IPs : 8.8.8.8:80,8.8.8.8:80,8.8.8.8:80VCLs :
Backends : 192.168.0.100:80
ACLs : 192.168.0.1/24Hi.
My IP address for the apache is my NAT IP (port 8080):
10.48.43.201:8080Listen 0.0.0.0:8080 Listen [::]:8080My IP for varnish (port 80):
10.48.43.201:80VARNISH_LISTEN_ADDRESS=10.48.43.201 VARNISH_LISTEN_PORT=80In this case, all the settings I use the same IP address changing only the apache port and varnish.
In my httpd.conf i have these virtual host’s configs:
<VirtualHost 10.48.43.201:8080> ...www.MYSITE1.com apache config. </VirtualHost> <VirtualHost 10.48.43.201:8080> ...www.MYSITE2.com apache config. </VirtualHost> <VirtualHost 10.48.43.201:8080> ...www.MYSITE3.com apache config. </VirtualHost>So I think the setting you passed is correct. I’ll set up and return the result soon.
Hi. I made all the settings in the plugin and following insert the files in
/etc/varnish. Apparently it’s working right. It is caching normally, but the wordpress admin panel was slow and takes more than 60 seconds to do some type of post or update post/page/plugin.When I am with the “wp-admin” opened, the Load Average of my servers are high, the Load up to 0.6 or 1.5 mostly (max is 2). But nothing terrible.
Pros:
Now when I publish something it automatically updates the cache and displays the post, it was what I was looking for.Cons:
The wp-admin was slow to update, post or exclude any posting. Maybe because it updates the cache while posting ..? Statistics aren’t work, the “varnishstat.json” file shows on the root of my site, but it doesn’t show anything. The cronjob on my cPanel: http://prntscr.com/bueapg.Obs: To see in the terminal “varnishstat” results, I need to put a “sudo” before (like:
sudo varnishstat -1). In this case, can I put the “sudo” in a cronjob?Ty Man.
If the varnishstat.json is empty, then yes on the sudo.
Hello .. Good evening.
Apparently I found why the site is slow to post something after the use of this plugin.
When I set the field “IPs” on the “Settings” publication / deleting a post is extremely slow and sometimes points out the error: http://prntscr.com/bvw7mj
If I remove the IPs of this field is normal, but can not erase the cache using the tool.
In this field I am using the following:
10.48.43.201:8080,10.48.43.201:8080,10.48.43.201:8080When i push “Purge ALL Varnish Cache” i get this: http://prntscr.com/bvwbyv
Concerning the IP NAT of my three domains and related ports.
The topic ‘Error on 'ZipArchive'’ is closed to new replies.