Allow me to sleep and focus on number crunching [#TSQL2sday]

T-SQL Tuesday #014

T-SQL Tuesday #014

It’s 2011 already and the first T-SQL Tuesday for the year has arrived.

This time the event is hosted by Jen McCown (Blog|Twitter), who just received an MVP nomination (congratulations Jen).

I have come up with a list that I want covered by my team this year, but my main goals are two: Allowing me to sleep properly and investing time on number crunching.

What does “allow me to sleep” mean?

Last year we started our migration project of all production database servers to High Availability solutions. We shall continue this year and finalize it. On the same token, homogenize our environment so every single business unit runs on SQL Server 2008 R2. We really spent time figuring out processes that cannot run in SQL Server 2005 (e.g. change data capture) and I need to make sure it does not happen anymore.

On the storage side, there are 2 projects running in parallel. One is to allow growth on a scalable solution which is already in place (stop concerning about hitting volume limits), and the second one to reduce data file footprint. The first project is trivial as we can hookup additional trays and expand volumes. The second one is more complex as we need to identify tables that hold historical data, partition them (if applicable), phase out old data and archive without impacting production applications.

On the monitoring side, we are creating a new project to see if we shall stick with Management Data Warehouse or get a 3rd party tool to give us bird’s eye view of our systems at the DB level, define KPIs, and report based on them. We got proper HW and Service level monitoring in place already.

What does “focus on number crunching” mean?

This has 2 phases.

The first one is to work on a Master Metadata repository project and figure out relationships between different business entities. Then work with Business Owners and Data Analysts to figure out what should we report on, how far back should we do so, and what KPIs should be defined. This can allow us to continue building our Data Warehouse, extending ETLs, and allowing business unit A to correlate its data with Business Unit B.

This project is also tied with data file footprint reduction as we will be able to rollup information that shall be available on our DSS without the need of all the transactional data.

The second phase is analytics. This can be tied with data mining and statistics and will definitely involve some of the information we have stored in our cubes. We are still figuring this one out.

That is it for me on the technical side. On the managerial and personal? I would write about them on future blog posts.

What are your resolutions for 2011?

Solving the Garage Door Opener Safety Sensor Problem [DIY]

What I expected to be a 15 minute fix became to be an almost 2 hour one. The main reason: the problem was not really related to the safety sensors, but a bad cable which I could not identify the first time. But it was worth changing them anyways as the original safety sensors were really worn out and not installed properly using any brackets at all. This was against code and was like it since I bought the house.

I proceeded to install the new safety sensors, and after ensuring that they were working properly. I installed the brackets 17 inches above the floor. Aligned the sensors and worked perfectly until I faced a new problem.

The garage door has thick horizontal wood bars which were wider than the distance provided by the brackets for installing the safety sensors. It was causing the door to open right when the first wood bar crossed the sensors. This was a big deal as it was not allowing the system to work properly. Seems  the reason why the previous owner never installed the brackets in first place.

What I ended up doing was reversing the sensors so they face backwards instead. That was the only way to make them work. This garage door opener system was installed 7 years after the house was built, so my guess is that the wrong model was chosen.

There is always a workaround. The system is working properly now.

Garage door opener safety sensor problem [DIY]

I had a problem today with my garage door opener. When I pressed the button to close it was not doing so and flashing the light bulbs instead.

The first thing I thought was something was blocking the safety sensors. Checked and nothing was blocking them. Next thing I though was that they were dirty. Cleaned them and nothing happened. Third thing I thought was that they were misaligned. I proceeded to realign them and even put them at a distance of 12 inches and nothing happened.

With those tests performed, I went ahead and researched on the web for possible issues.

I found this article explaining about the flashing LED & count for the led above the learning button:

Number of Flashes Problem Auto Reset Manual Reset
1 Photo-Cell totally misaligned or Photo-Cell wire open X
2 Photo-Cell wire shorted or the wire is reversed on the terminals X
3 Wall button (panel) wire is shorted in wall or attic X
4 Photo-Cell sensor sightly misaligned (dim or flashing LED on sensor) X
5 Possible RPM sensor failure or motor overheated, unplug opener to reset unit X
6 Motor circuit failure, replace main logic board X
Rapid Flashing This is not a problem but just an indicated that the opener is receiving a signal but it will not respond to an unauthorized code

Mine was flashing once, but one of the sensors was flashing intermittently. Every now and then it will be flashing 4 times too. So this test was inconsistent.

I searched again and found this article that pointed out:

11. Door does not close, light on garage door opener flashing:

  • Check The Protector System. Both sensors must be aligned or aimed across the door opening without any beam obstruction. Remove any obstruction or align both sensors.
  • Check for spider webs and/or dirty lenses. Wipe clean.
  • Make sure both LED lights are solid on each sensor housing.
  • Check safety sensor wiring and connections to the power head unit. Repair as necessary.
  • Check for diagnostic flashing code “1”. Located at the power head unit.
  • Try replacing safety sensors. Retest.

I have opted for the last recourse. To replace the safety sensors and retest.

Fortunately amazon has them in stock and taking advantage of amazon prime I should receive them in 2 days.

Will post an update once replaced. Wish me good luck.

Liftmaster 41A5034 Garage Door Opener Safety Beam Kit

Liftmaster 41A5034 Garage Door Opener Safety Beam Kit

What’s happening in 2011

2010 came by pretty quickly. It has been a very busy year with all kinds of expansions, migrations and consolidations. We installed HP Blade Servers, VMware, SQL Server 2008 R2, Windows Server 2008 R2, CentOS 4.2 X64, F5s, Dell R710s/610s, Dell Equallogic Storage, TFS 2010, Windows 7 X64 for all DBAs and BI developers, etc. The list continues.

So what is happening next year? Many exiting things, with a core focus on HA, DR, Analytics, SharePoint 2010, and VMware on production databases.

On the Database side:

  • Homogenous environment. All instance running under SQL Server 2008 R2 (some edition downgrades in the mix)
  • Isolated Development, QA and UAT environments with proper edition (Developer, Standard, Enterprise). VMWare and MSDN come to play.
  • Management Data Warehouse deployment to collect health information from all production instances. Birds-eye view of all instances in one location.
  • Central Management Servers Implementation
  • Policy Based Management Implementation
  • Data-Tier Application Implementation
  • RML utilities for pre-production load testing
  • PowerShell

On the Analytics side:

  • All legacy cubes migrated to SQL Server Analysis Services 2008 R2
  • Deployment of Star Schemas for the remaining business units
  • Dedicated instance for transformations (SSIS)
  • Fire up 3rd and 4th VM for our Scaled-out Deployment of Reporting Services
  • Mastering DAX. PowerPivot for Excel 2010
  • GUI implementation for browsing our cubes. We are in the process of evaluating products.

High Availability & Disaster Recovery:

  • All instances to be moved to HA (2, 3, 4 node clusters). No more single point of failures.
  • Zero-Downtime database migration with Mirroring
  • Block Level Backup and restore offsite
  • Full-Log-Daily Differential Backups across the board.
  • Backup file test by restoring to our UAT environments

Storage:

  • Footprint Reduction by archiving historical data that can be rolled up
  • Storage Expansion to benefit from the spindle count
  • SSD for the most demanding applications (over iSCSI)

Training:

  • I am encouraging my team members to use twitter, to follow knowledgeable folks and read tweets from the #sqlserver and #sqlhelp hash tags.
  • To Read Blog Posts and subscribe to RSS feeds
  • To attend to SQL Saturdays
  • To buy books (and e-books)
  • To get trained online and if necessary bring someone to get us trained.
  • To attend the SQL Rally 2011 or SQL Pass Summit 2011
  • To read about SQL Server Denali and install on a VM to test.

I see 2011 being an excellent year for us.

Happy Holidays everyone.

2011

Maintaining Passwords. What do I do?

It comes with no surprise to me that online database of passwords are being hacked. Last week Gawker Media got compromised and their password database stolen. Passwords were stored in an encrypted format but are still prone to dictionary attacks.

So how do I do it?

I use a different password for every account I create online. I combine uppercase, lowercase, numbers and non-alphabetical characters when possible.

How do I keep up with different passwords?

Well with so many passwords it is almost impossible for me to remember them. I use an excellent software: KeePass.

Do I create my own Passwords?

I do mostly. But lately I have let KeePass generate them for me.

How do I access my own password database from different places?

The easy way? Storing the password database on a USB thumb drive. Just make sure that the database has a strong password for accessing it.

The convenient way? Synchronizing to the cloud. I use DropBox for that matter. I can download from the website, or if feasible, install the DropBox and KeePass application on the local machine where I am working on.

KeePass Password Safe

KeePass Password Safe

What If I need to access the site using my SmartPhone?

No problem. I installed DropBox and KeePass for Android. Both Applications are available for pretty much all mobile platforms.

Is my smartphone saving passwords for websites?

Yes, for convenience, although it is a security concern.

What if my phone gets lost/stolen?

I installed Android Protector and the most sensitive applications require a PIN to access it. I have also installed Lookout for Android which allows me to backup sensitive data to the cloud, remote lock, remote locate and the best option, remote wipe.

Do I change my passwords?

Yes. Every 3 months at the most.

This is what I do for my passwords. How do you do it?