View previous topic :: View next topic |
Author |
Message |
baboo Senior Member
Joined: 04 Sep 2007 Posts: 676
|
Posted: Tue May 22, 2012 3:59 pm Post subject: Varnish |
|
|
I found a slackbuild for this. Do you have any experience in using it? I have an application server running java and many web pages. I thought this might speed it up.
any insights would be appreciated. |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Tue May 22, 2012 4:14 pm Post subject: |
|
|
Their site it's fast
I didn't know it before, that's a nice suggestion, I'll check it.
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
baboo Senior Member
Joined: 04 Sep 2007 Posts: 676
|
Posted: Tue May 22, 2012 8:29 pm Post subject: |
|
|
yes it is. I checked out a couple of other sites using it and they are very fast. |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Tue May 29, 2012 9:01 pm Post subject: |
|
|
Added in network series (n).
To test it, just change apache port to 8080, uncomment backend in /etc/varnish/default.vcl and start rc.varnish and apache.
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
baboo Senior Member
Joined: 04 Sep 2007 Posts: 676
|
Posted: Wed May 30, 2012 3:08 pm Post subject: |
|
|
thanks! Will test and let you know. |
|
Back to top |
|
simbad Senior Member
Joined: 30 Jun 2011 Posts: 106
|
Posted: Wed May 30, 2012 6:48 pm Post subject: |
|
|
how to add vanish to startup at boot? |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Wed May 30, 2012 8:07 pm Post subject: |
|
|
Make /etc/rc.d/rc.varnishd executable and either upgrade sysvinit-scripts from SMS-Current or add an entry "/etc/rc.d/rc.varnishd start" in rc.local.
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
simbad Senior Member
Joined: 30 Jun 2011 Posts: 106
|
Posted: Thu May 31, 2012 1:37 pm Post subject: |
|
|
root@xenya:/etc/varnish# telnet 127.0.0.1 8080
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
quit
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>501 Method Not Implemented</title>
</head><body>
<h1>Method Not Implemented</h1>
<p>quit to / not supported.<br />
</p>
</body></html>
Connection closed by foreign host.
root@xenya:/etc/varnish# telnet 127.0.0.1 80
Trying 127.0.0.1...
telnet: connect to address 127.0.0.1: Connection refused
Any sugestion? |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Thu May 31, 2012 1:51 pm Post subject: |
|
|
Did you change port in /etc/httpd/httpd.conf?
Code: | Listen 8080
ServerName sms:8080 |
Did you uncomment backend in /etc/varnish/default.vcl?
Code: | backend default {
.host = "127.0.0.1";
.port = "8080";
} |
Code: | /etc/rc.d/rc.varnish restart
apachectl restart |
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
simbad Senior Member
Joined: 30 Jun 2011 Posts: 106
|
Posted: Thu May 31, 2012 2:10 pm Post subject: |
|
|
Yes, and chmod 755 /etc/varnish/default.vcl
root@xenya:~# /etc/rc.d/rc.varnish restart
-bash: /etc/rc.d/rc.varnish: No such file or directory
root@xenya:~# |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Thu May 31, 2012 2:27 pm Post subject: |
|
|
My bad, it' a typo
Code: | chmod +x /etc/rc.d/rc.varnishd
/etc/rc.d/rc.varnishd start |
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
simbad Senior Member
Joined: 30 Jun 2011 Posts: 106
|
Posted: Thu May 31, 2012 2:48 pm Post subject: |
|
|
root@xenya:~# /etc/rc.d/rc.varnishd start
starting varnish...
/var/run/varnish.pid: Resource temporarily unavailable
root@xenya:~# |
|
Back to top |
|
simbad Senior Member
Joined: 30 Jun 2011 Posts: 106
|
Posted: Thu May 31, 2012 2:49 pm Post subject: |
|
|
root@xenya:~# /etc/rc.d/rc.varnishd start
/etc/rc.d/rc.varnishd: line 44: [: 2726: unary operator expected
/etc/rc.d/rc.varnishd: line 48: /var/run/varnish.pid exists but pid doesn't match pid of varnishd. please investigate.: No such file or directory
root@xenya:~# |
|
Back to top |
|
gerasimos_h Site Admin
Joined: 09 Aug 2007 Posts: 1757 Location: Greece
|
Posted: Thu May 31, 2012 2:55 pm Post subject: |
|
|
Code: | killall -9 varnishd
rm -f /var/run/varnish.pid
/etc/rc.d/rc.varnishd start |
gerasimos_h _________________ Superb! Mini Server Project Manager
http://sms.it-ccs.com |
|
Back to top |
|
simbad Senior Member
Joined: 30 Jun 2011 Posts: 106
|
Posted: Thu May 31, 2012 4:27 pm Post subject: |
|
|
Code: |
root@xenya:~# ./etc/rc.d/rc.varnishd start
-bash: ./etc/rc.d/rc.varnishd: No such file or directory
root@xenya:~# clear
root@xenya:~# killall -9 varnishd
varnishd: no process found
root@xenya:~# rm -f /var/run/varnish.pid
root@xenya:~# /etc/rc.d/rc.varnishd start
starting varnish...
Message from C-compiler:
gcc: error trying to exec 'as': execvp: No such file or directory
Running C-compiler failed, exit 1
VCL compilation failed
root@xenya:~#
|
|
|
Back to top |
|
|