473,386 Members | 1,798 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

memory_get_usage() and benchmarks

Tom
Alternate subject title: Shared Hosting, Resource Usage, Standards and
Measures

I think of myself as a developer, not a sysadmin, but a couple projects
I've been working on for my small company (i.e. 3 people) have reached
a stage where we're ready to move them to a production server and I'm
overseeing the process.

The plan is to launch them on an affordable shared hosting plan to
start and move on to VPS and dedicated hosting as necessary as they
grow. I'm trying to take every precaution possible in running my
scripts efficiently and responsibly on a shared host, but after months
of research, I still have only a vague sense of how to accurately
benchmark a PHP script for a live environment.

One tool I've been playing with is the PHP memory_get_usage function.
I find that usage jumps from 28 MB from the beginning of a
representative PHP-scripted web page on our development server (before
our includes and libraries load and any database hits) to 34 MB at the
end of the page. An admin with the company with which we're hosting
told me that they automatically kill any scripts using over 200 MB. So
I'm inferring that this script is running well within reasonable
limits. But I'm not sure if I'm getting an accurate -- or even the
right type of -- measurement here.

Is this a reasonable conclusion? How do others address this issue?
Any help (e.g. links) someone could offer on this topic generally is
welcome.

Tom
http://phosphorusandlime.blogspot.co...ory-usage.html

Oct 9 '06 #1
1 2204
Tom
I'm giving this a bump (I promise only once) just in case it got missed
by any benchmarking gurus over the weekend. :)

Thanks,
Tom
Tom wrote:
Alternate subject title: Shared Hosting, Resource Usage, Standards and
Measures

I think of myself as a developer, not a sysadmin, but a couple projects
I've been working on for my small company (i.e. 3 people) have reached
a stage where we're ready to move them to a production server and I'm
overseeing the process.

The plan is to launch them on an affordable shared hosting plan to
start and move on to VPS and dedicated hosting as necessary as they
grow. I'm trying to take every precaution possible in running my
scripts efficiently and responsibly on a shared host, but after months
of research, I still have only a vague sense of how to accurately
benchmark a PHP script for a live environment.

One tool I've been playing with is the PHP memory_get_usage function.
I find that usage jumps from 28 MB from the beginning of a
representative PHP-scripted web page on our development server (before
our includes and libraries load and any database hits) to 34 MB at the
end of the page. An admin with the company with which we're hosting
told me that they automatically kill any scripts using over 200 MB. So
I'm inferring that this script is running well within reasonable
limits. But I'm not sure if I'm getting an accurate -- or even the
right type of -- measurement here.

Is this a reasonable conclusion? How do others address this issue?
Any help (e.g. links) someone could offer on this topic generally is
welcome.

Tom
http://phosphorusandlime.blogspot.co...ory-usage.html
Oct 9 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
by: aaronwmail-usenet | last post by:
I've been wondering about benchmarks recently. What is a fair benchmark? How should benchmarks be vetted or judged? I decided to see what you folks thought, so for discussion I compared two...
0
by: Dathan Vance Pattishall | last post by:
------=_NextPart_000_0401_01C35A8D.94584FD0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit At the conference a few months ago, the mysql team said that the...
13
by: Shane Wright | last post by:
Hi, I've been trying to spec a new server for my company's database for a few weeks and one of the biggest problems I've had is trying to find meaningful performance information about how...
15
by: roberts.noah | last post by:
Are there any decent benchmarks of the difference between using c strings and std::string out there? Google isn't being friendly about it. Obviously this would be dependant on different...
4
by: Dibur | last post by:
I have been told to set the performance benchmarks for all the db2 databases hosted on all servers. I have no clue as to how to approach this problem. Can this be done theoritically through...
4
by: comp.lang.php | last post by:
I wrote my own version of memory_get_usage() if that function is not available: if (!function_exists('memory_get_usage')) { /** * Determine the amount of memory you are allowed to have * *...
10
by: StephQ | last post by:
I found that old post: http://groups.google.com/group/comp.lang.c++/browse_frm/thread/3a2562c9a5f8998/15519204726d01e8?lnk=gst&q=vector+no+surprise&rnum=2#15519204726d01e8 I just erased the...
318
by: King Raz | last post by:
The shootout site has benchmarks comparing different languages. It includes C# Mono vs Java but not C# .NET vs Java. So I went through all the benchmark on the site ... ...
84
by: s0suk3 | last post by:
The task: Write a program that reads a set of words from standard input and prints the number of distinct words. I came across a website that listed a few programs to accomplish this task:...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.