How to find a SEO expert?
I was chatting with a colleague the other day when he found someone who claimed to be an SEO expert in LinkedIn. He was complaining about how that guy did not know jack about SEO and there are so many SEO quacks out there just ripping off their clients. Certainly, I have no arguments there as I totally agree that the SEO industry is just full of posers. However, the interesting thing is my colleague did find this so call poser through the web out of the millions of other SEO experts. So in a way, this poser already proved himself to be an expert.
So the next time you want to find a SEO expert, just Google "seo expert" and the one that comes up first is probably your guy.
Visualization Of Data
I'm sure Tufte would be all for this. Sometimes, we have so much data that it is just overwhelming. Generally, we do statistical analysis on data to get the underlying story behind it. But what about visualizing it. ManyEyes is a data visualization tool built by Martin Wattenberg at IBM that does just that. (Full disclaimer, I do know the creator.) It allows anyone to upload a dataset and use any number of their visualization tools to view the data. It is amazing how looking at data from a different angle can result in new discoveries.
Very Interesting Explanation Of Design Pattern
http://37signals.com/papers/introtopatterns/
It really simplifies the methodology of designing web applications.
Google Earth / Map Implementation Problem
One thing that was not documented fully at Google for integrating Google Earth into Google Map is that the function, getEarthInstance, is only available in the newest version of the Map API. I could not find exactly which version so the best way is to use v=2.x like in "http://maps.google.com/maps?file=api&v=2.x&key=yourkey" instead of specifying an exact version. Have fun with this new feature.
Google Earth on Google Maps
Google just added a new Earth plugin feature to Google Maps. Now we can have all the functionalities of Earth as one of the selections buttons on Maps just like Satellite view. This is a very exciting new development.
Mysql on 32bit processor vs 64bit processor
Here is the continuation of the experiment done previously on Mysql on Windows vs Linux. After doing more analysis and observation, it appeared that the difference in speed for the benchmark tests were not related to Windows and Linux but were related to the processor. The previous test just happened to have AMD 64s on the Linux machines and Intel Xeon 32bits on Windows. We hypothesized that the increased throughput of the 64bit processors resulted in about half the time required to return the same query run on a 32bit machine.
So we decided to test the same query again on a Windows machine with an AMD 64 X2. This time the result for the query took 7.35 second, almost the same as the other AMD 64s running Linux.
One more test to run the query on a Windows Intel 64bit chip machine would better solidify our hypothesis.
Mysql server has gone away
I have a spider crawling the web written in PHP running constantly to insert and update data in a Mysql database. Today, it kept stopping on a records with the error message, "Mysql server has gone away". It certainly did not time out as just starting the process again would result in this message immediately. The script did not close out the connection to the DB as it had worked just fine for over a year.
Finally, I found that the problem was max_allowed_packet setting in my.cnf was too small. It was set to 2MB and when Mysql receives a query larger than that, it assumes that something must have gone wrong and closes the connection. I increased that parameter to 4MB and everything is working fine now.
Mysql on Windows vs Linux
I was working on optimizing a Mysql database today and accidentally stumbled upon a benchmarking exercise. The original Mysql database is hosted on a Windows Server 2003. I develop on a Mysql database server running on Ubuntu Linux. The Linux server ran the same query twice as fast as the Windows server without using caching or anything. I know that Linux does I/O caching on its own as well so I even tried running the query after a fresh reboot to rule out that factor. Then I got help from a colleague and started tweaking with the my.cnf/my.ini to make sure they were the same and each time, the results came back about the same. Mysql on Windows was consistently slower than Mysql on Linux.
Then we decided to load the database onto other servers for more data points on this Mysql performance test. We ran the same query returning 429 rows of data with 13 table joins and a couple of sub-queries. All queries were run on the command line client on the servers themselves to avoid network lag. All servers are running Mysql 5.0.x.
Results
1. Ubuntu Linux: 0.70 seconds
2. CentOS: 0.78 seconds
3. Windows 2003 Server: 1.40 seconds
4. Windows 2003 Server: 1.42 seconds
Server hardware
1. Ubuntu Linux
AMD ATHLON 64 X2 4200+
2GB DDR400
200GB 7200RPM SATA/150
2. CentOS
Dual Opteron 240
2GB DDR ECC
120GB 7200RPM SATA/300
3. Windows 2003 Server
Dual Xeon
2GB DDR ECC
7200RPM PATA
4. Windows 2003 Server
2 Dual Xeon (4 CPUs)
8GB DDR ECC
3 73GB 10,000RPM SCSI in RAID 5
A followup to the benchmark that clarifies the cause of the differences
Mysql SQL_NO_CACHE Benchmark Problem
I have been trying to benchmark the sql calls to mysql from an application without success. Even when I set the SELECT statement to SQL_NO_CACHE, the results seemed to be still cached. Apparently, Linux does its own caching of disk reads also. That was giving me incorrect benchmark results if I hit the same data twice.
For those using Linux kernel 2.6.16 or higher, you can clear Linux cache with the following command.
echo 3 > /proc/sys/vm/drop_caches
Unfortunately for me, I am stuck on 2.5.xx and will have to figure out another method.