Categories: "Devices" or "Linux stuff" or "Mac stuff" or "Mobile" or "Windows stuff"
I was looking into upgrading my 2006 Mac Mini (serving as a media server) with a 2010 model, just to get a bigger hard drive… and also a faster one!
Now, according to this guy, the Mac Mini 2010 still comes with a stinky slow old SATA-1 drive, just as back in the days. And that Ricky guy actually sounds like he knows damn well what he’s talking about!
Anyone got a Mac Mini 2010? Care to check the Negotiated Link Speed in your System Profiler? (About my mac > More info…)
On the screenshot above, you can see a Negatiated Link Speed of 3 Gb/s, which is good… except I made the capture on my Mac Pro. Apparently, 2010 Mac Minis will show you a Link Speed of 3 Gb/s (that’s what the Mac is capable of) but a Negotiated Link Speed of only 1.5 Gb/s (that’s what the HD is capable of)…
What Ricky doesn’t say though, is if he has the 320 GB drive or the 500 GB drive. There may be a difference between these two.
Now, the alternative would be to upgrade the drive myself, but it’s just a big bag of hurt! I’m too old to get any pleasure out of disasenbling hardware any more…
November 2010 Update: I went to the Apple store and checked out the Mac Mini Server version: it has 7200 rpm drives but still at 1,5 Gbps. I also checked a MacBook Air for comparison: it has an SSD drive and it actually communicates at 3 Gbps.
Apple has removed that features in Snow Leopard and QuickTime X has no preferences panel to enable this. So you need to go through the command line to get it back…
In Terminal, copy/paste:
Now movies will autploay when you double click them.
In Terminal copy/paste this:
Then relaunch the Finder by Pressing Cmd+Alt+Esc.
Press space on a selected folder and admire :)
Update: it seems this no longer works in Moutain Lion.
You may have noticed that PHP scripts that echo a lot of content appear to be running with poor performance…
Well, the operative word here is “appear". It is a common misconception that “echo is the slowest PHP command"! :p
The problem is actually just a bandwidth issue! When you try to pump a lot of content though the Internet, at some point you experience “load time"… and at some point PHP actually experiences “send time"!
You may measure the execution time between the begining and the end of your script, and, on a slow connection, it may show you that it took 500 ms to execute. You may even narrow it down to a single echo statement that takes 480 ms to execute. But that time actually includes wait time where PHP cannot send any more data back to apache!
There is a common trick that consists of starting output befering before echoing, like this:
This will allow PHP to move on and appear to terminate fast. But the truth is, all the content is now in PHP’s output buffer, and although your script is done, PHP is still working in the background to send all that data to your web server (apache for instance).
If you have an apache (2) web server, you probably have an access.log file showing you all kinds of data using the “combined” log format. Let’s see how to include processing time into that log file.
By default a line in the combined log looks like this:
[codeblock lang="” line="1″]10.0.209.80 - - [03/Dec/2009:03:20:47 +0100] “GET /info-tech/ HTTP/1.1″ 200 46482 “http://fplanque.com/info-tech/” “Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:126.96.36.199) Gecko/20091102 Firefox/3.5.5″[/codeblock]
Notice the 2 dashes - - just after the IP. The first one stands for “I could not identify the user using ident” and the second one for “no user authentication was performed".
Now, let’s face it: you will never identify anyone using ident. Your apache conf probably even doesn’t try. That field is a left over from ancient times. So let’s replace that first dash with something useful, i-e: the processing time of the request! Note that by doing this we keep the global structure of the file identical and any log processing tool you might be using should not be affected.