Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.php > #10316 > unrolled thread
| Started by | Erwin Moller <erwinmollerusenet@xs4all.nl> |
|---|---|
| First post | 2013-07-31 14:50 +0200 |
| Last post | 2013-08-06 23:13 +0200 |
| Articles | 5 — 4 participants |
Back to article view | Back to comp.lang.php
OPcache in php5.5.1 on Windows Erwin Moller <erwinmollerusenet@xs4all.nl> - 2013-07-31 14:50 +0200
Re: OPcache in php5.5.1 on Windows Jerry Stuckle <jstucklex@attglobal.net> - 2013-07-31 09:29 -0400
Re: OPcache in php5.5.1 on Windows Goran <goran@nospam.com> - 2013-08-01 16:00 +0200
Re: OPcache in php5.5.1 on Windows Adam Harvey <usenet@adamharvey.name> - 2013-08-01 21:21 +0000
Re: OPcache in php5.5.1 on Windows Erwin Moller <erwinmollerusenet@xs4all.nl> - 2013-08-06 23:13 +0200
| From | Erwin Moller <erwinmollerusenet@xs4all.nl> |
|---|---|
| Date | 2013-07-31 14:50 +0200 |
| Subject | OPcache in php5.5.1 on Windows |
| Message-ID | <51f90805$0$15978$e4fe514c@news2.news.xs4all.nl> |
Hello cpl, Does anybody in here have experience with OPCache under windows? http://nl3.php.net/opcache It is bundled in PHP5.5 (and via PECL in earlier versions). I installed PHP5.5.1 on a SBS2008 server under IIS7 (fast cgi). After activating opcache, I used the suggested directives in php.ini, as described here: http://nl3.php.net/manual/en/opcache.configuration.php It does show up now in phpinfo() as: Opcode Caching Up and Running Optimization Enabled Startup OK Shared memory model win32 Cache hits 12 Cache misses 15 Used memory 5752832 Free memory 61356032 Wasted memory 0 Cached scripts 15 Cached keys 21 Max keys 3907 OOM restarts 0 Hash keys restarts 0 Manual restarts 0 So far so good (I think). Now I wonder: Is there any way to find out WHAT kind of performance gain it gives? I have a few ideas but I am not very enthusiastic about any of them: 1) Testing the time spend in the script: Not good, that is exclusive the time needed to interpret the script (I expect, but I couldn't find a decisive answer yet. If anybody knows, let me know please) 2) From end-user experience: Not good: If I time the responsetimes with a clockwatch on my browser, I merely measure noise I expect: time spend on the network, is the server busy doing other stuff, is the database busy, etc. 3) Making a huge complicated script, and test it. Hoping the time needed to interpret it is so long I can measure the difference as described in 2. (I haven't done this yet) What would be a good way to test the speedgains by using OPCache? Any ideas? Thanks for your time. Regards, Erwin Moller -- "That which can be asserted without evidence, can be dismissed without evidence." -- Christopher Hitchens
[toc] | [next] | [standalone]
| From | Jerry Stuckle <jstucklex@attglobal.net> |
|---|---|
| Date | 2013-07-31 09:29 -0400 |
| Message-ID | <ktb33u$dgo$1@dont-email.me> |
| In reply to | #10316 |
On 7/31/2013 8:50 AM, Erwin Moller wrote: > Hello cpl, > > Does anybody in here have experience with OPCache under windows? > http://nl3.php.net/opcache > It is bundled in PHP5.5 (and via PECL in earlier versions). > > I installed PHP5.5.1 on a SBS2008 server under IIS7 (fast cgi). > After activating opcache, I used the suggested directives in php.ini, as > described here: > http://nl3.php.net/manual/en/opcache.configuration.php > > It does show up now in phpinfo() as: > > Opcode Caching Up and Running > Optimization Enabled > Startup OK > Shared memory model win32 > Cache hits 12 > Cache misses 15 > Used memory 5752832 > Free memory 61356032 > Wasted memory 0 > Cached scripts 15 > Cached keys 21 > Max keys 3907 > OOM restarts 0 > Hash keys restarts 0 > Manual restarts 0 > > So far so good (I think). > > > Now I wonder: Is there any way to find out WHAT kind of performance gain > it gives? > > I have a few ideas but I am not very enthusiastic about any of them: > > 1) Testing the time spend in the script: Not good, that is exclusive the > time needed to interpret the script (I expect, but I couldn't find a > decisive answer yet. If anybody knows, let me know please) > > 2) From end-user experience: Not good: If I time the responsetimes with > a clockwatch on my browser, I merely measure noise I expect: time spend > on the network, is the server busy doing other stuff, is the database > busy, etc. > > 3) Making a huge complicated script, and test it. Hoping the time needed > to interpret it is so long I can measure the difference as described in > 2. (I haven't done this yet) > > What would be a good way to test the speedgains by using OPCache? > Any ideas? > > Thanks for your time. > > Regards, > Erwin Moller > > > Think about this: No matter how you do it, the only important measurement is response time to the end user (system load is related, and can also affect response time). Building a huge, complicated script which shows a 70% performance game may make you feel better - but will not be representative of the real world. -- ================== Remove the "x" from my email address Jerry Stuckle JDS Computer Training Corp. jstucklex@attglobal.net ==================
[toc] | [prev] | [next] | [standalone]
| From | Goran <goran@nospam.com> |
|---|---|
| Date | 2013-08-01 16:00 +0200 |
| Message-ID | <ktdpms$nnl$1@news.metronet.hr> |
| In reply to | #10316 |
Best way to benchmark it is to hit your testing server with your production access log.
[toc] | [prev] | [next] | [standalone]
| From | Adam Harvey <usenet@adamharvey.name> |
|---|---|
| Date | 2013-08-01 21:21 +0000 |
| Message-ID | <ktejh4$t37$1@dont-email.me> |
| In reply to | #10316 |
On Wed, 31 Jul 2013 14:50:19 +0200, Erwin Moller wrote: > What would be a good way to test the speedgains by using OPCache? > Any ideas? You may want to consider using a tool like ab (which comes with Apache, at least on most Linux distros) and hitting a representative sample of pages that you're interested in. ab provides a range of options for how many simultaneous requests it will make, the total number of options, and so on, and will then give you a report at the end showing best case, average, and worst case response times. If you do multiple runs with OPcache enabled and disabled, you should be able to get a pretty good idea of what sort of performance improvement you're getting. Adam
[toc] | [prev] | [next] | [standalone]
| From | Erwin Moller <erwinmollerusenet@xs4all.nl> |
|---|---|
| Date | 2013-08-06 23:13 +0200 |
| Message-ID | <520166f2$0$15955$e4fe514c@news2.news.xs4all.nl> |
| In reply to | #10330 |
On 8/1/2013 11:21 PM, Adam Harvey wrote: > On Wed, 31 Jul 2013 14:50:19 +0200, Erwin Moller wrote: >> What would be a good way to test the speedgains by using OPCache? >> Any ideas? > > You may want to consider using a tool like ab (which comes with Apache, at > least on most Linux distros) and hitting a representative sample of pages > that you're interested in. Thank you, Adam. Apache Bench exists for windows (named unsurprisingly ab.exe). I'll look into it. Regards, Erwin Moller -- "That which can be asserted without evidence, can be dismissed without evidence." -- Christopher Hitchens
[toc] | [prev] | [standalone]
Back to top | Article view | comp.lang.php
csiph-web