Monthly Archives: January 2008

Bill Gates last day..

This has been out for a few days now, but finally tracked down a decent quality.  http://on10.net/blogs/larry/Bills-Last-Day-CES-2008-Keynote-Video/Default.aspx – check out all the cameos..

SQL Server Database Backups for the enterprise – Part 1

I’ve been working with our team for a while to continually refine our db backup procedures.  We’ve got a fairly complex database environment, with quite a few sql servers in various locations, which prior to SQL SP2 we did backups primarily thru scheduled nightly jobs.  An update in SP2 broke our (basic) model, which re-energized my dreams of db backup automation and a more granular, manageable process. 

 Well, I’m nearly 90% complete with my new model – check back soon for Part 2, where I’ll offer my scripts for download.  Highlights include a single table that allows you to manage your backup job.  This table (briefly) includes the “databases” you want to backup, the backup engine to use (whether local or quest, red-gate, idera, etc), the schedule for backing up databases, including log backups and even file-group backups.  Next I wrote a Stored Proc which loops thru this table looking for backup jobs to run, using the respective backup engine.  The table/SP also includes a feature to write copies of the backup to both the local DB as well as a remote NAS device (or any path you provide in the setup table.) One nice feature about this is you can keep the past 7 days backups local on the machine, in the event you need to do a quick restore, whereas backups older than 7 days get archived to a NAS device, still recoverable, but depending on the location may take additional time to recover.  This helped us to address storage space, both locally and remotely, managing encryption and compression during the process.  While the scope of this little backup ditty grew, the flexibility/usability increased and we were able to pack in alot of functionality, that i thought others could eventually benefit from.  I wrapped up the function with some baselining capabilities, logging the start/end times of each backup with a secondary table, which provides two things.  First, helping us verify a backup runs every night and second, helping use see the backup size and file growth over time enabling us to do better storage/archival projections.  Lastly, it was important to me to make this entire process portable.  Deployment is as easy populating the tables with the DBs you want to backup and then schedule the SP to be run at some nightly interval.  thats it!

Now, before I share the code (hopefully it will be worth the wait),  here are a few things to consider when desinging your backup strategy:

  1. Understand backup types (simple vs. bulk, vs. full)
  2. Know where your backups are (dont want to go searching in time of need)
  3. Encrypt/compress/password protect your backups (as the standard .bak file can be read with notepad!)
  4. DB backups dont contain everything (also need master/userDB,msdb)
  5. Take care of system DBs (master, msdb)
  6. Plan for physical vs. logical failures (nightly backups good enough?  every 5 min/log shipping required?
  7. Ensure recoveryability of a backup (media, network, data – run restore verify only & also test entire recovery model)
  8. Forecast backup trends (do capacity planning and create a formal db recovery plan)
  9. Consider use of direct-attached or online (NAS) volumes for backup – tapes are no longer the standard for backups!
  10. Keep Control – if you are the DBA, dont rely on others with missing documention to jeapordize your restore.

Initial questions to ask.  How much data can be lost? Are there any SLAs you have to support?  What data security considerations are required?  Did you remember to backup indexes?  Some best practices include, running DBCC, then nightly backup with incremental log-backups periodically throughout the day as the business requires.

Hopefully that help to get you into the backup mindset.  Lots of things to consider, and theres certainly no one size-fits-all.  I’ll be posting the source code to my sql scripts in an upcoming post – which I hope can help you save time modernizing your backup efforts!?

What is a Plenum?

During some investigation for our new office space, cabling quickly became a subject of interest.  It seems the previous tenent had been there for some time (nearly 15 years) and underwent numerous updates, most of which ended with cat5 cabling.  Being the bandwidth-hungry company we are, we opted for category 6 cable, giving us the increased throughout and support for future bandwidth intensive applications.  In the past, we had to use plenum cable, as we had plenum space (above ceiling tiles) whereas our new space has higher ceilings direct through to the rafters, so I needed some clarification to justify the extra “plenum rated” expense – which I found below.  Now I’m just waiting for cable vendors input..

According to the National Electric Code (NEC) a plenum is a “compartment or chamber to which one or more air ducts are connected and [which] forms part of the air distribution system.” To qualify as a plenum, the space above an acoustic tile ceiling would have to extend above other rooms in the same building or be open to ducts connecting it to other parts of the building. The concern is that during a fire, if there is burning material in a plenum air space, smoke and fumes can travel through air ducts to the whole building. For this reason, there are codes to restrict the types of materials (such as wiring) that can be placed in the plenum.

It’s quite common to have an acoustic tile ceiling without having a plenum. If your room-dividing walls extend above the dropped ceiling and seal off the space above, you do not have a plenum air space and so may not require plenum-rated wires. (See illustration.) You can lift up an acoustical tile in your room and peek in to see if your room has a plenum.

So, what is the code?
According to the National Electric Code (NEC), in plenum air spaces you must use plenum rated cables, also called Communications Plenum Cable (CMP). Plenum cable is only required when cable is installed in a plenum air space. Materials kept below the ceiling — including speaker wire, computer cables, telephone cords, etc. — do not need to be plenum rated according to the NEC.

Remember that even though the National Electric Code may allow non-plenum cable, the final decision is up to your local Fire Marshall.  Most cities adopt the national codes as their own without revision, but some cities modify or expand them and require plenum-rated cable in all situations.  Regardless of the code or its interpretation, your Fire Marshall makes the final decision. We recommend that you contact your Fire Marshall if you have questions.

Why is the regulation for plenum air spaces but not for other wiring such as speaker wire?
It’s dangerous to inhale fumes from any burning material. Speaker wire is no more dangerous than any other plastic item you would find below the ceiling in a typical classroom — computers, carpet, power cords, etc. Therefore, requiring the use of plenum wires within the classroom itself would have little impact. The regulation covers the area where it’s most critical.

How is plenum wire different from other speaker wire?
Plenum rated coating on wire burns at a much higher temperature and emits fewer fumes.

Who sets the guidelines?
The National Electrical Code (NEC) is a set of guidelines recommending procedures to reduce the risk of fires, electric shock and other hazards associated with electrical installations. The code is advisory in nature, but most state and local building departments across the country use the NEC as the basis for their own electrical codes. Some local codes may be more restrictive, so please check with your local Fire Marshall if you’re unsure

TS2/MSDN Highlights – Livonia, MI

Took the trip out to Livonia today to attend a Microsoft MSDN/TS2 Event.  The 1/2 day conference was a pre-event for the upcoming Hero’s Happen Here event, taking place around the country starting in February and making its way to Michigan in March. Below are the highlights of both sessions, as I bounced between the two covering a few seperate subjects of interest.

 Firstly, highlights of Vista, now a year old, presentor took a survey of those using it and those happy, most were, those not were told their performance issues were probably due to faulty video drivers, seemingly taking the easy way out.    SP1 then came up, still not disclosing a release date, but here are some highlights:

  • Improved multi-monitor / graphic card compatibility
  • Increased compatibility with print drivers
  • improved sleep/resume functionality
  • Improved win explorer / IE performance
  • Improved network transfer performance
  • Network boot support for x64 PCs
  • Flash memory support for exFAT
  • est. download size to exceed 1GB! and requires 7-12GB available HD space (most reclaimed)

I’m happy to see several of the SP1 items appear to address items we’ve experienced first hand, guessing we weren’t the only ones..

Next up was Windows 2008 or w2k8 – whereas they touched briefly on the new server core, server manager, policy based QoS and new Windows deployment services.  I’ve seen a few sessions on w2k8 now, and while nothing too revolutionary there do seem to be a few very nice management features, such as read-only domain controllers, stronger virtualization (server, application & management) and of course IIS7.

SQl 2008 also got a brief mention, a few highlights:

  • Enhanced Mirroring
  • Failover clustering
  • Fast Recovery
  • Recource Governer
  • Enhanced Partioning
  • Transparent Encryption

Still no word on encryption/compression of backups – guess they’ll SQL let the ISV market survive a bit longer.

I then bounced over to the MSDN track, taking in yet another IIS 7 session.  The presenter did close with a brief asp.net security primer, which i think I’ve seen before, but its probably worth repeating.  The five demonstrated “hacks” were:

  1. Cross-site Scripting or XSS
    • Fix: Microsoft Anti Cross Scripting Library
  2. SQL injection
    • Fix: Use type-safe sql params
    • Restrict permissions of d users (i.e. no xp_cmdshell)
    • Sanitize data input
    • Do not disclose error information
  3. Cross site request forgery
    • Fix: viewStateUserkey = Session.sessionID
  4. Integer overflow:  2147483547 (max int value +1)
    • in C# use ‘checked’ keyword when validating INT values
    • in VB this is already done for you
  5. Insecure direct object reference

TS2 track also discussed (briefly) system center manager, Microsoft home server & data protection manager 2007, but nothing of substance, mostly marketing slides. 

That pretty much covers the highlights from my perspective.

CodeMash day 1 wrap-up

As i put close to day 1 of CodeMash, I’m certainly glad I made the trip.  I’ve met lots of very smart guys (and girls) and, I may have said this before, but its great to see such a vibrant community of vendor agnostic, language neutral people getting together – ok the ruby guys do seem to somewhat dominate conversations, but everyone here seems to have legitimate, genuine interest in promoting the community, for the sake of technology and beaking down barriers.  It’s now cool again to be a .net developer (not that I ever thought it wasnt) as people from all backgrounds are mixing and “mashing” their favorite flavor, based on their assessment of what the right technology to use is, which to me is huge.  We’ve long known every application/requirement is different, yet many shops (admittingly ours to some degree) default to an existing language, partially due to comfort, partially due to standards, but also partially due to lack of knowledge about alternatives.  This conference aims to change that, atleast the last one.  Here, everyone is treated equally and encouraged to experiment with something new, seek best practices (e.g. AGILE), and get informed!  Its a very non-threatening environment with something for everyone.

In the past, at other conferences, you were an outcast if you were a microsoft (or java) guy trying to talk about edge technologies, or more specifically, dynamic languages.  The open-source advocates on “the coasts” tend to shy away from .net/java, my guess is primarily because the reps attending the conferences (which, respectfully very smart cats) aren’t working on large enterprise class applications, such as financial banking systems, SAP, PeopleSoft or manufactoring supply chain – which are the challenges facing most of us MidWesterners.  That said, the “coasts” also tend to have access to more innovate businesses models, whether its the latestest web 2.0 application featured on TechCrunch, digg or just the latest widget from Google, Yahoo or AOL.  Yet, that doesnt mean there isnt a time and place for .net/java – or more specifically, their respective platforms.

Either way, these “un-conference” style events is clearly gaining momentum. I did find it almost shocking at dinner, where I had the liberty of sitting with several of the conference organizers (Dianne Marsh, Bruce Eckel, Bill Wagner & Dick Wall to name a few) that they were not familiar with some of the other “un-conferences” i have attended the past couple years.  They are nearly identical, however with all due respect to the others, I believe CodeMash does raise the bar, the conference has a very polished feel, yet NOT AT ALL stuffy, dull or unproductive.  It’s very much designed by devs for devs, with minimal if any corporate koolaid.  I would like to see more energy around Open Spaces, while available, i dont know that the midwest is familiar with this format yet, as to-date most conference attendees are used to paying big ticket prices and having formal tracks or session paths – Open Spaces builds on the community appeal, turning the focus to attendess (with content actually provided by attendees).  Am sure it will continue to get more popular as people become familiar with it, and everyone realizes they have the opportunity to customize the event into something that is potentially more meaningful for them.  That said, i personally do enjoy some sense of structure and pre-canned sessions, particularly from the industry vets here. 

Lots of great stuff in day 1, my only regret is that I wasnt able to attend all the sessions i wanted, as some overlap existed and I tend to want to learn more than one should in a given day.  Time to recharge the batteries for day two, physically and mentally.

IIS 7.0 keynote @ CodeMash

Having minimal exposure to IIS (only thru local development using Vista) I was anxious to dive under the covers.  Scott Hanselman was the presenter, and I must adit, he had me (and most the audience) laughing out loud thru the first 10 minutes of his speech – nothing to do with IIS whatsoever, but a very microsoft-esq, self-serving, comical lead-in.

Once we got into the presentation, interestingly he choose to showcase .php ontop of IIS.  He opened a pre-canned php picture application and continued to tweak application settings thru IIS/.net without having to modify a line of php code!  pretty cool stuff, including forms-based authentication and lots of http modules, which I found very cool.

Scott closed with some technical difficulties in his demo, highlighting somewhat complex caching, but he handled it well.  His intent seemed geared toward non-microsoft folks considering IIS as a legitimate option (at least on par, if not ahead of apache).  The demo and IIS did look impressive.  I’m now compelled to dive deeper with http modules.

Introducing Facebook Applications

At 9:30 I attended Matt Pizzimenti’s session on Facebook.  It was a indroduction, so much of the content I was semi-familiar with from previous discovery, but it was cool to see some new things, specifically implemented in ruby.  Matt started off with the registration process and went on to explain briefly key aspects of the API using REST.  The API then serves up XML (or optionally JSON).  Next up was authentication and more common method calls.  He went on to explain FBML, FBJS (still emerging), FQL, common libraries and “officially supported” languages, php/java (of course, as FB uses this internally), but un-officially ruby & python.  .net was not referenced, nor did i see it referenced much in my previous reviews, however i did find a few libraries (not officially supported by FB) floating around around on the web, one of which I’ve done some experimenting with (yet I can’t recall the name at time of writing) – damn reception cocktails 🙂

Overall I found the session very good, a follow up primer, but I enjoy seeing things presented a few different ways before I begin my own experimenting..hmm, do I smell an experimental project for Billhighway using ruby??  we’ll have to wait and see.

CodeMash 2008 – KeyNote

Neal Ford presented the keynote for CodeMash, called Software “Engineering” & Polyglot Programming.  Interesting title and speech.  Firstly, for the business folks, polyglot is someone who is able to speak, write, or read several languages.  That out of the way, Neal went on to compare the roles of traditional “engineers” with “software engineers” – which on the surface level happens alot.  He outlined some pretty distinct differences, and even joked about how software developers explain their jobs to family members around the holidays (something I have struggled with for years) – commonly referred to as the “computer guy” when rarely does one actually understand (nor typically care) about what a software developers job really consists of.

After a few bridge slides (supporting his engineer comparison/argument) he went on to talk about “platforms” referencing the java platform will outlive the language, and how language complexity actually makes a developers’ job harder.  He argued  many developers are already polyglot (using tSql, html, java/.net, ado, css, etc.) – why not add the latest dynamic language to the stack?  interesting argument.  He advocates picking the most powerful language you can tolerate (and get paid for), or otherwise put, use the most suitable design tool for the requirements – not because its java/.net – but because it can produce results, quickly. 

He wrapped up with a comment to strive for 100% TDD, start with a platform, unit testing/automated builds and bolt on the most appropriate flavor – so long as it can be tested.  overall good talk, and neat pics of bridges 🙂

How to talk technology to humans

My first session at CodeMash was the pre-conference Weds night – a panel about promoting tech to “others” (being clients, business associates, managers, etc.)  The converstation started off initially from a consultant perspective, touching on the challenges in promoting newer “edge” technologies to decision makers/execs who aren’t yet familiar and/or vested in their current offerings.  One story referenced how clients would specifically seek out java or .net applications – before even discussing the business requirements.  The panel agreed this was the wrong approach.  Understanding the requirement should come first, then align the most appropriate technology to solve the specific need.  It shouldnt be technology first, problem second. Seems to make sense. 

Next came a comment about devs not being “consultants” – however, the panel disagreed.  Devs are constantly “selling”, albeit internally, they are still speaking to, persuading or recommending improvements – and this is nothing different.  Joe went on to add, he believed Thought Works to be doing it right – hire the smartest most capable people and the technology will follow, in other words, if a company must standardize on a platform, leave it up to the dev to implement the most appropriate language.

Agile also found its way into the converstion, as agile adoption has been mixed, especially in bigger organizations, and in some cases its actually being done wrong.  Agile is about feedback. how you deliver it is as important as what you deliver.  One recommendation was to be a “virus” start small, independatly, write unit tests, techniques will get noticed in productivty, quality, etc – others (worthy) will notice, ask questions, experiment.  After unit testing, implement version control/automated builds and eventually continuous integration (CI).  Use index cards/stickies in your area to define work (“stories”) – keep tasks small, focused, you’ll get more done faster.  Evaluate pair-programming..

Techniques included selling your ideas is easier than selling yourself.  lead by example (even if quietly).  Interested, passionate devs will follow.  they took a survey and asked people with cool jobs to raise their hand – 80% went up.  They went on to add, (i believe according to a piece from Dave Thomas) – attendees were in the top 10% of their field.  which makes sense, those seeking out to better themselves do tend to advance more often. 

When promoting a new technology, never under-estimate how boring you can be.  You may have already sold them, let others absorb the info and ask questions.  Other “sales” tips included: match body language, replicate verbal buoyancy, match speech speed and get to know people and what motivates them.

Lastly, they ended with how to drive change when consistently facing deadlines.  First off, (per agile) nothing should take more than 6 months to put into produciton.  Ala SOA, de-couple, break things into smaller tasks, this also enables adopotion of multiple technologies by isolating functional units, which helped to clarify how/when you choose to change technologies (from current to latest/greatest).  There is no single answer, sometimes what you doing makes sense.  if the technology you are using is still effective, there may be no need to change?  Try to find the right technology for the task, emphasis simplicity – to do so you obviously need to stay abreast of the latest flavors.  Start with a little at a time.  Play with things in your spare time, make time if need be.  A 2 hour window can even yield productivity with newer edge technologies.  Lastly, get help from the community, read blogs, ask questions.

Not bad. So far, we’re off to a good start.

CodeMash v2.0.0.8 – on the map!

I arrived at CodeMash Wednesday eve, after a short drive from Michigan (about 2 hours!).  Kalahari is a pretty nice place for a conference.  Sure, its got tons to offer families/kids, but as an attendee, the location is a nice change as compared to hotels and more formal convention centers.  I’m here for a couple of reasons, firstly to support the local DEV community, can’t tell you how happy I am to see this take place in the MidWest.  Equally important, as the CIO I’m scouting for talent.  We’ve struggled to find good devs in Michigan, people really passionate about technology, able and willing to push the envelope forward.  Lastly, I’m hear to learn!  I do my best to keep abreast of emerging technologies, but in my daily life I rarely have the time to dive as deep as i’d like, so I hope to take this opportunity to learn from some of the guys that are making this happen (right here in our backyeard) – specifically with regard to AGILE!  

First things first, my initial impressions for CodeMash are awesome.  I under-estimated the volume of midWest developers actually involved in the latest iteration of “web 2.0” technologies (i.e. ruby, groovy, RIA, etc.)  They are expecting just over 300 developers this year, up 40% from last year!  Also cool is the mix of backgrounds here, all the major camps are represented, msft (.net) , sun (java) , ibm, adobe, plus rails, python, php, and lots more.  Its certainly a change from a few years ago where you aligned yourself with one or the other (and typically spoked negatively toward those not as cool as you).  To me, its very refreshing.  An early theme I’ve already observed is advocating for platform standardization, yet choosing your favorite flavor (language) based on the task/user requirements.  Am guessing Neal Ford will dive deeper into that tomorrow at the keynote.  pretty cool stuff.

Actually funny to me, is in the Conference Guide they acknowledge – “Why should the East and West coast have all the fun” – my thoughts exactly!  I’ve attended several “mashup” conferences over the past couple years, and yes, they’ve always been on the coasts, boston and/or the SF bay area.  A couple quick observations, firstly the format is slightly different, but more on that later.  Initially, (as expected I suppose) the coasts are represented by more “open source” folks, lots of php, mysql, ruby… almost no .net or java reps.  Also, (as expected) more participation by Google, Yahoo, AOL – here it’s slightly different, equally exciting, but a wider array of technologies (and big corproate sponsors).  Which is just fine for me, the coasts are always going to push he latest and greatest – lets face it, thats where most the innovation occurs, but not to be outdone, the midwest, with CodeMash, has provided a fantastic venue in our backyard to get exposure to edge technologies. 

well, out of time – off to the pre-conference session.  more soon.  I’ll do my best to summarize the sessions I attend for the folks back home and post some pictures over at Flickr (http://www.flickr.com/photos/22676788@N03/2182664921/in/set-72157603681472550/) when i get a chance.