CodeCharge Studio
search Register Login  

Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> CodeChargeStudio.Discussion

 Php performance / codecharge

Print topic Send  topic

Author Message
Walt
Posted: 12/03/2003, 7:53 AM

Does anyone have any performance tips using php.

I have a page with a fair number of forms - 6 read only 'grid' type
forms and 1 update 'record' form on the page. Which is really used as a
front end for a database.

:)

response time / changing page takes about 4 secs and it is the Web
Server that is bottleneck.

Apache, Postgresql, Php, Linux

--

Are there perhaps certain functions / features that generate alot of
overhead?

Would performance increase dramatically if I with something like jsp or
Servlets.

I have tried accelerator type products (Zend) and tuning the basic
settings for apache but the best I can do is get page load time down
from about 4 secs to 3 secs.

Any advice would really be appreciated.

Cheers

Walt
Daniel Gaudreault
Posted: 12/03/2003, 8:15 AM

Try installing the Turck MMCache for PHP on your webserver. We use it
in both our production and development environments, and we've noticed a
significant improvement on the server munging end of the deal.

Also, we are running trials with PG 7.4 and that seems to be helping a
lot too. (They've done some huge performance tweaking in the latest build.)

http://turck-mmcache.sourceforge.net/

Good luck,
Dan

Walt wrote:
> Does anyone have any performance tips using php.
>
> I have a page with a fair number of forms - 6 read only 'grid' type
> forms and 1 update 'record' form on the page. Which is really used as a
> front end for a database.
>
> :)
>
> response time / changing page takes about 4 secs and it is the Web
> Server that is bottleneck.
>
> Apache, Postgresql, Php, Linux
>
> --
>
> Are there perhaps certain functions / features that generate alot of
> overhead?
>
> Would performance increase dramatically if I with something like jsp or
> Servlets.
>
> I have tried accelerator type products (Zend) and tuning the basic
> settings for apache but the best I can do is get page load time down
> from about 4 secs to 3 secs.
>
> Any advice would really be appreciated.
>
> Cheers
>
> Walt
>
Walt
Posted: 12/03/2003, 2:27 PM

Thanks

Will try it tonight, although i didn't see too much of a performance
gain using the Zend version which I think is the same sort of thing.

Does the choice of webserver make a significant difference? I am using
Apache 2.

Cheers

Walt

Daniel Gaudreault wrote:
> Try installing the Turck MMCache for PHP on your webserver. We use it
> in both our production and development environments, and we've noticed a
> significant improvement on the server munging end of the deal.
>
> Also, we are running trials with PG 7.4 and that seems to be helping a
> lot too. (They've done some huge performance tweaking in the latest build.)
>
> http://turck-mmcache.sourceforge.net/
>
> Good luck,
> Dan
>
> Walt wrote:
>
>> Does anyone have any performance tips using php.
>>
>> I have a page with a fair number of forms - 6 read only 'grid' type
>> forms and 1 update 'record' form on the page. Which is really used as
>> a front end for a database.
>>
>> :)
>>
>> response time / changing page takes about 4 secs and it is the Web
>> Server that is bottleneck.
>>
>> Apache, Postgresql, Php, Linux
>>
>> --
>>
>> Are there perhaps certain functions / features that generate alot of
>> overhead?
>>
>> Would performance increase dramatically if I with something like jsp
>> or Servlets.
>>
>> I have tried accelerator type products (Zend) and tuning the basic
>> settings for apache but the best I can do is get page load time down
>> from about 4 secs to 3 secs.
>>
>> Any advice would really be appreciated.
>>
>> Cheers
>>
>> Walt
>>
Walt
Posted: 12/04/2003, 4:12 AM

On further digging the main problem seems to be the grids

example 1 user 1 page access 1 grid on page

10 records / page is reasonably fast apache load is < 10%

200 records / page - apache hits up to 70%,response time is 3 secs

400 records / page - apache hits 95 % response time 5-6 secs

Does this seem correct to everyone. or does it seem excessive?

Cheers

Walt

Walt wrote:
> Thanks
>
> Will try it tonight, although i didn't see too much of a performance
> gain using the Zend version which I think is the same sort of thing.
>
> Does the choice of webserver make a significant difference? I am using
> Apache 2.
>
> Cheers
>
> Walt
>
> Daniel Gaudreault wrote:
>
>> Try installing the Turck MMCache for PHP on your webserver. We use it
>> in both our production and development environments, and we've noticed
>> a significant improvement on the server munging end of the deal.
>>
>> Also, we are running trials with PG 7.4 and that seems to be helping a
>> lot too. (They've done some huge performance tweaking in the latest
>> build.)
>>
>> http://turck-mmcache.sourceforge.net/
>>
>> Good luck,
>> Dan
>>
>> Walt wrote:
>>
>>> Does anyone have any performance tips using php.
>>>
>>> I have a page with a fair number of forms - 6 read only 'grid' type
>>> forms and 1 update 'record' form on the page. Which is really used as
>>> a front end for a database.
>>>
>>> :)
>>>
>>> response time / changing page takes about 4 secs and it is the Web
>>> Server that is bottleneck.
>>>
>>> Apache, Postgresql, Php, Linux
>>>
>>> --
>>>
>>> Are there perhaps certain functions / features that generate alot of
>>> overhead?
>>>
>>> Would performance increase dramatically if I with something like jsp
>>> or Servlets.
>>>
>>> I have tried accelerator type products (Zend) and tuning the basic
>>> settings for apache but the best I can do is get page load time down
>>> from about 4 secs to 3 secs.
>>>
>>> Any advice would really be appreciated.
>>>
>>> Cheers
>>>
>>> Walt
>>>
>
DonB
Posted: 12/04/2003, 6:32 AM

200 or more records per page seems quite excessive ;-)

If you have any listboxes (or DLookups) in the grid, then performance will
suffer as a result. That is because more database hits will occur.

Are you doing a "SELECT *" for the grid's datasource? Try reducing the
number of columns to only those actually needed. If you are doing a join or
merely a WHERE, maybe the problem lies in the indexes on your tables -
specifically, you might be doing a table scan instead of an indexed lookup.

--
DonB

http://www.gotodon.com/ccbth


"Walt" <null@null.null> wrote in message
news:bqn8al$3r9$1@news.codecharge.com...
> On further digging the main problem seems to be the grids
>
> example 1 user 1 page access 1 grid on page
>
> 10 records / page is reasonably fast apache load is < 10%
>
> 200 records / page - apache hits up to 70%,response time is 3 secs
>
> 400 records / page - apache hits 95 % response time 5-6 secs
>
> Does this seem correct to everyone. or does it seem excessive?
>
> Cheers
>
> Walt
>
> Walt wrote:
> > Thanks
> >
> > Will try it tonight, although i didn't see too much of a performance
> > gain using the Zend version which I think is the same sort of thing.
> >
> > Does the choice of webserver make a significant difference? I am using
> > Apache 2.
> >
> > Cheers
> >
> > Walt
> >
> > Daniel Gaudreault wrote:
> >
> >> Try installing the Turck MMCache for PHP on your webserver. We use it
> >> in both our production and development environments, and we've noticed
> >> a significant improvement on the server munging end of the deal.
> >>
> >> Also, we are running trials with PG 7.4 and that seems to be helping a
> >> lot too. (They've done some huge performance tweaking in the latest
> >> build.)
> >>
> >> http://turck-mmcache.sourceforge.net/
> >>
> >> Good luck,
> >> Dan
> >>
> >> Walt wrote:
> >>
> >>> Does anyone have any performance tips using php.
> >>>
> >>> I have a page with a fair number of forms - 6 read only 'grid' type
> >>> forms and 1 update 'record' form on the page. Which is really used as
> >>> a front end for a database.
> >>>
> >>> :)
> >>>
> >>> response time / changing page takes about 4 secs and it is the Web
> >>> Server that is bottleneck.
> >>>
> >>> Apache, Postgresql, Php, Linux
> >>>
> >>> --
> >>>
> >>> Are there perhaps certain functions / features that generate alot of
> >>> overhead?
> >>>
> >>> Would performance increase dramatically if I with something like jsp
> >>> or Servlets.
> >>>
> >>> I have tried accelerator type products (Zend) and tuning the basic
> >>> settings for apache but the best I can do is get page load time down
> >>> from about 4 secs to 3 secs.
> >>>
> >>> Any advice would really be appreciated.
> >>>
> >>> Cheers
> >>>
> >>> Walt
> >>>
> >
>

Walt
Posted: 12/04/2003, 8:19 AM

Hi Don

The database is just ticking over.

and in the test case it is just the standard grid.

Cutting it down right down

With 1 column, numeric field, no formatting, direct access on a table -
no selects, 1 user I get apache hitting between 20-30% for approx 400
records and takes just over a couple of seconds to run on average.

running the same thing adjusting to 10 records per page I get apache
hitting about 2% and pretty much an instant page.

Does this seem about right?

Cheers


DonB wrote:
> 200 or more records per page seems quite excessive ;-)
>
> If you have any listboxes (or DLookups) in the grid, then performance will
> suffer as a result. That is because more database hits will occur.
>
> Are you doing a "SELECT *" for the grid's datasource? Try reducing the
> number of columns to only those actually needed. If you are doing a join or
> merely a WHERE, maybe the problem lies in the indexes on your tables -
> specifically, you might be doing a table scan instead of an indexed lookup.
>
DonB
Posted: 12/04/2003, 1:54 PM

Lots of contributing factors - CPU speed, memory, network bandwidth - but,
yeah, doesn't sound bad. That is a heck of a lot of rows to pump out on a
web page. I hope you have no dialup users, Walt. They will hate you if you
feed them 400 rows at a time.

A page served by PHP, ASP or whatever is going to have a bit of lag as the
page gets processed (before it is ever sent).

You might want to try this site to measure your speed.
http://www.wid.info/nettools/websitespeed.xml

--
DonB

http://www.gotodon.com/ccbth


"Walt" <null@null.null> wrote in message
news:bqnmra$n9v$1@news.codecharge.com...
> Hi Don
>
> The database is just ticking over.
>
> and in the test case it is just the standard grid.
>
> Cutting it down right down
>
> With 1 column, numeric field, no formatting, direct access on a table -
> no selects, 1 user I get apache hitting between 20-30% for approx 400
> records and takes just over a couple of seconds to run on average.
>
> running the same thing adjusting to 10 records per page I get apache
> hitting about 2% and pretty much an instant page.
>
> Does this seem about right?
>
> Cheers
>
>
> DonB wrote:
> > 200 or more records per page seems quite excessive ;-)
> >
> > If you have any listboxes (or DLookups) in the grid, then performance
will
> > suffer as a result. That is because more database hits will occur.
> >
> > Are you doing a "SELECT *" for the grid's datasource? Try reducing the
> > number of columns to only those actually needed. If you are doing a
join or
> > merely a WHERE, maybe the problem lies in the indexes on your tables -
> > specifically, you might be doing a table scan instead of an indexed
lookup.
> >
>

Walt
Posted: 12/04/2003, 4:25 PM

Thanks

I feel better if that sort of performance is normal.

Not that i don't have anything to do over the xmas period but.... would
java servlets / jsp be significantly quicker than php + cache software.

This is really from and end user / server perspective when accessing
database intensive pages.

or is there not much in it overall?

Cheers

Walt



DonB wrote:
> Lots of contributing factors - CPU speed, memory, network bandwidth - but,
> yeah, doesn't sound bad. That is a heck of a lot of rows to pump out on a
> web page. I hope you have no dialup users, Walt. They will hate you if you
> feed them 400 rows at a time.
>
> A page served by PHP, ASP or whatever is going to have a bit of lag as the
> page gets processed (before it is ever sent).
>
> You might want to try this site to measure your speed.
> http://www.wid.info/nettools/websitespeed.xml
>

   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.