Re: Reducing load for LAMP app?



Gilles Ganault wrote:
On Sat, 5 Jan 2008 02:55:24 +0100, "Richard" <root@localhost> wrote:
Why (or how) are the queries "session-specific"?
No way to get rid of that?

I don't know what it means, really. I don't have enough experience
with PHP and MySQL to know the details.

Generally speaking, is there a way to share query results among all
viewers using the site, and if yes, what's the right way to do this?

Thanks for all the suggestions guys. It's very helpful.


Not from PHP, there isn't. Every user is considered independent. Just like every program running in a system is considered independent.

Yes, you can share information between users - just like you can share information between programs, i.e. shared memory. But it's not done by default.

And as Richard indicated, the MySQL query cache may be more efficient.

However, right now it looks like me you are trying to optimize your system - but haven't even identified where the source of your problem.

The FIRST thing you need to do is find out what's causing the high resource utilization!

--
==================
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
jstucklex@xxxxxxxxxxxxx
==================

.



Relevant Pages

  • newbie :-sending variable value between two scripts...
    ... I am having some problems with my PHP and MySQL, basically, I need to ... #Enter Survey Author... ... #execute query ...
    (php.general)
  • PHPs MySQL Query Length Limit? (Long SQL failing!)
    ... I've been doing PHP for a pretty good while now, ... Then I go and use it with a mysql query. ... The query is written correctly AKAIK, but no data reaches the table I'm ... The only difference between queries that work and those that do not ...
    (php.general)
  • Re: Dynamic form generation for editing mysql data
    ... I hope this is the right place to post my query. ... to php and MySQL (but have been programming in C++/python for a few ... regarding editing MySQL data using a form. ... the format of the data in the database. ...
    (comp.lang.php)
  • Re: php vs mysql speed
    ... (PHP: Loop through results to find Bob and Dave.) ... Both the first and the third queries can be described as "one big query". ... It was bugging me because php is obviously faster than mysql so I ...
    (comp.lang.php)
  • Re: I am totally stumped..with this on..LOAD_FILE Mysql+PHP= FSCK!!
    ... What I am trying to do is to upload files and stuff them in a mysql database. ... I copied the temporary file to somewhere else, and then handed it to MySQL..THAT WORKED.. ... Is there a way to force a close on the file..maybe that's the problem Mysql is opening a file that is not flushed to disk maybe? ... I gew the feeling its maintaining its own picture of file objects, and doesn't actually flush to the disk unless you do a copy or close php.. ...
    (comp.lang.php)

Loading