Page 1 of 1

Bandwidth testing….???

Posted: Fri Jul 04, 2003 10:49 pm
by alexus
I would like to test my visitor’s amount of bandwidth and current connection speed… :?:

Well I’m not quiet sure how to do it, I even don’t know that PHP can do this, but in another hand I definitely can not use user side scripts…

PS: :idea: I got one idea but I still don’t know how to use it: I could use SYSTEM command then CMD (I’m running 2003 Web server) then PING $user_ip (or something else that can give me the user speed / bandwidth information), but even than I’ll have a problem retrieving speed value from system return argument…

Any Ideas How Can I Do This?
:arrow:
Thanks!

Posted: Sat Jul 05, 2003 7:00 am
by Judas
Real speed.
Try uploading or downloading some data file's from and to client pc.
These data file's have an exact size.(you can use seperate data file for txt and bin content)
Count the acctual time.
Calculate "time" "content" "size".

Posted: Sat Jul 05, 2003 11:54 am
by alexus
Is there any build in functions for this, because I don’t like to up / down loading files to the client?

I just want to know the speed… + it will be tech problem with uploading a file without client permission especially to WinXP

Posted: Sat Jul 05, 2003 12:16 pm
by Judas
I don't know at the momment.
http://www.speedtest.nl/TestSuite/TestController.asp
Maybe you can discover howe the have done it.

Posted: Sat Jul 05, 2003 12:31 pm
by alexus
Download : 167.0 KByte/sec
Upload : 86.8 KByte/sec
Connection : 471.0 Conn/min
Ping test Nederland : 90.0 ms

1. The did it in ASP ( VB.6 or C#)
2. The results is not accurate my connection speed should be at least 1000 Kb/s (T1)

So how can I get real connection speed…???

Posted: Sat Jul 05, 2003 1:40 pm
by Stoker
167 Kilobyte per second = 1336 Kilo bit per second .. then comes some overhead, and possibly some compression included, so that does not sound to far off for a T1, if it is somewhat slower its likely the route inbetween and/or the webserver/noc activity/connection/burst-allowance etc..

I have never done any bandwidth testing code, but I would question how easy it is to do just from PHP or any webserver scripting language may be tricky, as all output will often be buffered and thrown out in a chunk, and even if you turn buffering off I assume that the webserver or networking layers has mechanisms that will allow the script to end before the transfer was actually finished..

Posted: Sat Jul 05, 2003 1:50 pm
by m3rajk
not to mentiont hat there's stuff done on his lan. in a t1 you will never reach max speed becasue the network people have things set to be checked for your safety, not to mention however many you are sharing it with. between all that 167Kb/sec is good

Posted: Sun Jul 06, 2003 3:37 pm
by alexus
So, after all is there any way to create such script on PHP? :roll:

Posted: Sun Jul 06, 2003 3:42 pm
by m3rajk
same way they did it in asp i imagine. they send a few files and time it and then calculate on the round trip.

just remember that there's always overhead.
even though a 56k modem CAN transfer up to 56k, upstream has a 33.3 limit (federal setting) and when you take into account what will always be there, a reasonable maximum is 30k/sec. add in other traffic and you're looking at 20k/sec or lower as an expected average

if you want to know more and live near boston, harvard has a great course on it: Communication Protocols and Internet Architecture

i'm sure other schools have similar courses. look at the write up to that at http://www.harvard.edu and find something comparable at a college near you if you really wanna understand.

Posted: Mon Jul 07, 2003 7:12 pm
by alexus
:cry: … Harvard would never accept me… (Unfortunately) … even if I really want to study some courses there…

Now back to PHP and now asp, as far as I remembered PHP could force user to download file but the I need to get the statistic ( I’m not sute thet PHP is generating this statistics for uploads, so we will then download same file from user [ 50k for example]. Well we don’t want to do so many jobs for user so we want to up load file automatically… :roll: And how can I do that?

:arrow:
And I just came up with another Idea! --- Macromedia Flash 5 or MX, client side action script, all preloders are showing real speed (at least I think so…) :?: but how can I transmit data from *.swf to *.PHP

Posted: Mon Jul 07, 2003 8:41 pm
by m3rajk
if you do like me and go summer school i don't think they'll care about anything but if you can pay the $$ for the tuition.

i wanted to lighten the workload for my sr year, so summer after jr year i took courses via harvard's summer school since i wanted to know a bit more about the nitty gritty since all the brandeis courses are programming THEORY. i wanted something that's not theory....so i took some courses at harvard

Posted: Mon Jul 07, 2003 11:12 pm
by alexus
Sounds good, but it is the middle of the summer now... and how much do they want? (for summer school?)

Is they really better then others?
8)