Netflix on iPad/iPhone does not work when connected to a router running DD-WRT [Fix]

I was pretty frustrated when I realized that for firing up my new iPad I needed to install iTunes to my desktop. On top of that, I needed to add a credit card number to download a free application from the App Store. I worked it around by generating a one-time number from citicards.

I decided to install Netflix and did not work, even tried resintalling and changing SSIDs. The only way to make it work was by using a backup SSID from the U-Verse router.

After researching I found out that the DNSMasq package from DD-WRT thinks that the connection from Netflix on the iPad looks like a DNS Rebinding attack.

There are a couple of workarounds:

  1. Use a different DNS server in the iPad/iPhone wireless configuration, like the one provided by OpenDNS: 208.67.222.222
  2. Add a startup rule to DD-WRT to stop DNS rebinding:
1
2
3
killall dnsmasq
sed -i -e 's/^stop-dns-rebinding/#&/' /tmp/dnsmasq.conf
dnsmasq --conf-file=/tmp/dnsmasq.conf

I pursued the second workaround as it allowed me to keep the wireless connection “stock”. Netflix is now working properly on my iPad.

Stop DNS rebinding

Stop DNS rebinding

Business Requirements. What are those? [#TSQL2sday]

This quick post is in reference to the T-SQL Tuesday for the Month of December of 2010, hosted by Steve Jones. The subject is “What issues have you had in interacting with the business to get your job done?”

T-SQL Tuesday, December of 2010

T-SQL Tuesday, December of 2010

Have you ever been in a situation where you were told to develop and deliver certain application because Business folks already sold it to a particular buyer, even with a preset delivery date? You are not alone. I have experienced similar ones without even knowing “What” we were supposed to deliver, less “How” to do it.

Business and Technology need to create a partnership, and communication needs to flow back and forth. This is where a very strong business analyst with technical knowledge comes into play. If business would like to have a portfolio of products of services they can sell, it needs to be communicated with the business analyst, who at the same time will ask questions to the technical team to get an idea of the feasibility and viability of the product. If there are technical questions then they can be asked to the business analyst or even directly to the business owners if required.

Technical teams cannot develop without having a solid business requirement, or a good understanding of what the business folks want. I agree that most of the times, especially with new products or services, complete business requirements are unfeasible, but the business analyst needs to write what business folks want conceptually in a technical form, pointing out relevance and priority.

Iterative development and deployment is a trend being followed by more companies nowadays. As releases get to production on a much quicker fashion it can give the opportunity to the business folks to analyze the original requirements/concepts and recommend changes. It can also build confidence with the technical team as results are being delivered in small releases but in a progressive fashion. This is key to continuously building a partnership.

My opinion is that technical teams need to understand what are they going to develop and for what purpose. Analyze and suggest the technology to be used and work with the project manager and/or business analyst in order to come up with a timeline. Interact with the business folks in order to clarify any doubts and prototype the solution before engaging into a full blown project. Approach short releases if viable and build confidence with the business team. Never be afraid to ask questions; if you do not know “what” needs to be developed rest assured that “how”, the way you will do it, is wrong.

SD Card unexpectedly removed [Android]

Today while I was trying to take a picture of my son wearing his costume with my new HTC G2, got the error message “SD Card unexpectedly removed”. I asked myself: how is that possible if the card is inside and even behind the battery.

Before I continued trying, decided to turn off the phone, extract the card, clean the contacts and try again. Everything went well until 20 minutes later; I got the same error again.

I performed the process again, this time thoroughly cleaning the pins on both the G2 and the SD card. I was able to record my son’s parade and even upload to YouTube, but yet again the error message came up once more.

Searched on Google, called a friend and even called T-Mobile to see if there was any known issue. Didn’t get too much help so I went ahead and performed a CheckDisk with repairs (while plugged in to the USB port of my PC). I thought it was fixed after it, but minutes later, again the issue reoccurred.

I decided to use a MicroSD adapter, plugged into my computer, tried to save whatever I could from the latest pictures and videos I took (luckily it was just 2 weeks worth) and formatted it like 3 times. I did not choose a quick format option just to ensure that all blocks get touched.

All good? No. Seems that the card is bad. Called T-Mobile, called, HTC, there are no replacement cards for the HTC G2 yet. What? It is a universal card! But no, HTC says that I need to call when they get stock parts for the HTC G2.

I guess I am out of luck on this one. I will need to buy another card.

Luckily, all the previous contents were safely backed up to the cloud.

Most Developers Have No Business In The Database World

I have been around superb developers that understand the concept of approaching efficient code that needs to be ran on the database, and will seek help from database developers/DBAs to ensure that is the case. Unfortunately, most do not really understand the need and approach a solution to certain requirement with one thing in mind: effectiveness.

Yes, If business folks request a page that will show up all kinds of fancy data and drop downs, they will do it. It does not matter if the code behind the scenes goes through an expensive loop to render each record one-by-one.

The database is the most difficult and expensive Tier to scale, and code needs to be written in a way so it does the less amount of reads to get the answer to certain request. Developers need to understand that effectiveness needs to be tied with efficiency whenever they are coding.

If they do not understand/do not know how to make efficient code then seek help from a Database Developer/DBA. For example, why code a process that updates one row at a time instead of performing a bulk operation that updates all at once? Didn’t they know that a nested loop can be the worst route instead of hash or merge join to perform an update? Reducing trips to the I/O subsystem really makes a difference.

Now, there are other type of developers that think they know the answer for improving performance to any database without even looking at their code. I have experienced situations where I was told “we need more indexes” or “the database is timing out” when the issue was another heavy process taking long I/O requests and the developer had an uncommitted transaction respectively.

If developers have a problem, work as a team. Ask for help to someone that really knows their business so they can perform a health check. Imagine if a DBA goes and tells a developer how to write their application tier code.

I have not seen any DBA that has morphed onto being a developer. Most cases are the opposite, where developers become DBAs. I have experienced it myself as a former developer (yeah the procedural days) and DBA. If DBAs become developers this will be a perfect world, as the efficiency techniques will be considered while coding application and web tier code.

My final thoughts are, DBA’s own the database; it does not matter what the developer says. If a developer has an idea, then express it as it; do not demand what needs to be done to a database as they are most likely wrong.

And no, creating a single index on each field will not make the database faster. Let the DBA collect statistical facts and go from there.