Wednesday, December 23, 2009

ReverseDOS - spam filter for ASP.NET sites

ReverseDOS is a very simple HttpModule that checks various parts of incoming requests against a list of crap that you don't want pushed on to your site. If ReverseDOS detects a match, it attempts to stall the requesting client for a number of seconds (specified in a .config file). During this loop, which uses virtually no server resources - and only a tiny smidgen of bandwidth, ReverseDOS checks every .3 seconds to see if the client is still connected. If the spammer disconnects, good riddance. If the spammer sticks around, they're finally rewarded with the Response Headers - containing an HTTP 403 - Access Denied Response Code. (Awwwhh tooo bad...)

Monday, December 21, 2009

Microsoft Hyper-V Networking and Configuration - Part 1

In the first of a series of articles on Hyper-V Networking, Nirmal explains Hyper-V networking and VLAN tagging, and shows how to set up a Virtual Network switch. Once this is done, the Hyper-V Virtual Network Switches can be used to connect unlimited no. of Virtual Machines.

Upgrade Exchange 2003 to Exchange 2010

In this article, the first of two in which Jaap describes how to move from Exchange Server 2003 straight to Exchange Server 2010, he shows what is required before moving mailboxes from Exchange Server 2003 to Exchange Server 2010. He shows how to upgrade Active Directory, install both Exchange Server 2010 and certificates, and set up the Public Folder replication.

Part II here.

Thursday, October 15, 2009

Finding Data Corruption

In this article, taken from Chapter 8 of his new book, SQL Server Tacklebox, Rodney describes how a working DBA goes about troubleshooting data corruption. He demonstrates the tools and scripts required to seek out and fix data corruption in a timely manner, and so prevent it propagating into your backups.

Friday, September 25, 2009

The 10 Things to Do First for Windows 7

  • Getting to know Windows 7
  • Dealing with the latest volume-activation requirements
  • Developing a roadmap
  • Handling new distributed-security features
  • Virtualizing desktops and infrastructures
  • Removing users' local-admin rights

Saturday, August 29, 2009

Hyper-V Server 2008 R2: Bare Metal to Live Migration (In about an hour!)

In this one-off video, Matt McSpirit, Partner Technology Specialist at Microsoft UK, walks through a bare-metal installation of Hyper-V Server 2008 R2 (RC) on 2 physical nodes, hooks them up to an iSCSI SAN, configures the SAN storage, and then, from a Windows 7 (RC) laptop, validates, and builds a Hyper-V Server 2008 R2 (RC) Cluster. The end result? A Highly Available, Live Migratable, Virtual Machine!

All in about an hour!!

Monday, August 3, 2009

Getting Real - the smarter, faster, easier way to build a succesful web application

Getting Real is the business, design, programming, and marketing philosophies of 37signals — a developer of web-based software used by over 1 million people and businesses in 70 countries.

37signals used the unconventional Getting Real process to launch five successful web-based applications (Basecamp, Campfire, Backpack, Writeboard, Ta-da List), and Ruby on Rails, an open-source web application framework, in just two years with no funding, no debt, and only 7 people.

Anyone working on a web app — including entrepreneurs, designers, programmers, executives, or marketers — will find value, fresh perspectives, and inspiration in this practical book.

Troubleshooting Performance Problems in SQL Server 2008

It’s not uncommon to experience the occasional slowdown of a database running the Microsoft SQL Server database software. The reasons can range from a poorly designed database to a system that is improperly configured for the workload. As an administrator, you want to proactively prevent or minimize problems; if they occur, you want to diagnose the cause and take corrective actions to fix the problem whenever possible. This white paper provides step-by-step guidelines for diagnosing and troubleshooting common performance problems by using publicly available tools such as:

  • SQL Server Profiler
  • System Monitor (in the Windows Server 2003 operating system) or Performance Monitor (in the Windows Vista operating system and Windows Server 2008), also known as Perfmon
  • Dynamic management views (sometimes referred to as DMVs)
  • SQL Server Extended Events (Extended Events) and the data collector, which are new in SQL Server 2008.

We have limited the scope of this white paper to the problems commonly seen by Microsoft Customer Service and Support (CSS), because an exhaustive analysis of all possible problems is not feasible.

Because this paper is very long (102 pages), reading it in an online format such as the Library becomes impractical, so we offer it as a downloadable Microsoft Word document.

Friday, July 24, 2009

A Google-like Full Text Search

Thanks to Internet search engines like Google and Yahoo!, your search application users are more sophisticated and demanding than ever. Your application users have a wealth of search application knowledge that they're probably not even aware of. Ask one of them to find a website dedicated to their favorite band or movie and odds are they'll have their browser pointed to that page in a matter of seconds.

You can tap into the self-education that comes from countless hours spent at home trying to locate information on the Web and turn it to your advantage in your own SQL Server-based search applications. With just a little bit of code you can help reduce your training costs and give your users an easy to use interface that will make them want to use your search applications. In this article I'll explain how to convert Google-style queries to SQL Server's full-text search CONTAINS predicate syntax.

Tuesday, July 21, 2009

Saving Time with Proactive DBA Monitoring

A typical day for the DBA usually starts with an overall health check of the database servers in the network. No matter how big or small the environment, the database administrator usually finds himself doing more or less the same type of checks every day.

If the DBA is responsible for ten production SQL Server instances, each hosting three databases on average - it would be thirty production databases to look after. Each morning the DBA would want to know if the instances are all up and running and accepting user connections. Next, he would probably want to see if overnight backups were all successful. When that is ascertained, perhaps the attention would turn to scheduled jobs. There may be regular processes that are critical to the business – like an SSIS package or a reporting job. If nothing has failed in that front, it would be time to check the Windows Event Log and the SQL Error Log for any suspicious looking error messages. Finally, it will be prudent to see if replication has failed or mirroring has frozen or log shipping has broken.

These are only part of the day-to-day health checks and yet when done manually, can take a significant amount of time.

There are a number of tasks that you as the DBA can automate to make life easier and save time. Smart DBAs would always try to proactively check database and server health without waiting for something to happen or someone else reporting about them.

In this article I will try to present some ideas about how some of the daily database health checks can be automated and turned into proactive monitoring. Although database monitoring is not a new idea and there are quite a few third party tools in the market, it may be cost prohibitive for some organisations. The alternative is to build a custom monitoring solution.

Thursday, July 9, 2009

Map IP Address to a Geographical Location

On the Internet there is the concept of web site analytics that helps track all the visitors' activities and usage patterns. One of the dimensions to track is the geographical information of the visitors, which can be obtained by using the IP address information that is collected when a user lands on a Website. In this article, I will describe a simple process that enables your reporting system to display the geographical information of the visitors.

Wednesday, July 8, 2009

Automating Performance Monitor Statistics Collection for SQL Server and Windows

You have about 100 SQL Servers installed in your production environment. You have performance problems on few of the servers, but they happen during the time when you are not watching the servers. So, how can you automate performance statistics collection on all the servers around the clock so we have the statistics for 24/7/365.

You can use the built-in windows utility "logman" that comes free.

Logman is the command line utility for Perfmon. Thru logman, it is easy to automate perfmon data collection which I will show you below.

Monday, June 22, 2009

A Beginner’s Guide to Virtualizing Exchange Server, Part 2

It isn't easy to measure the consumption of physical resources by servers in virtual machines, since each partition has its' own virtualised view of system resources. Not only that, but there is a subtle difference between virtual processors and physical processors. Brien Posey explains the special performance counters that can be used to get an accurate assessment, and goes on to describe how to test your physical servers to see if they are good candidates for virtualization.

If you read my first article in this series, then you got something of a crash course in Hyper-V’s architecture. Of everything that I covered in that article though, there are two main points that you need to keep in mind:

  1. When it comes to virtualizing Exchange Server, it is critical that you monitor resource consumption so that you can ensure that there are sufficient hardware resources available to effectively service Exchange and any other virtual machines that may be running on the server.
  2. Each of the various resource monitoring mechanisms that I showed you tells a completely different story regarding how much of the server’s physical resources are actually being consumed.

In other words, it is important to find out how much of the server’s resources are being consumed, but you are not going to be able to do so in the usual way.

Thursday, June 18, 2009

Use Backup/Restore to Minimize Upgrade Downtimes

As a SQL Server professional, at some point in your career, you will need to upgrade between versions of SQL Server, or move a database from an older server onto a newer one. There are quite a few different ways to go about doing this, the most common being; Detach/Copy/Attach and Backup/Restore. When downtime is acceptable, either of these methods can get the job done, the only caveat being that if you are performing a upgrade to a newer version of SQL Server and you decide to use Detach/Copy/Attach to upgrade the databases that you still should take a backup of the database before moving it so that you have a point to fall back top. Once you attach the database files to the newer version they will be upgraded internally and will no longer be able to be used on the older version.

If time is of the essence during the migration, and downtime must be minimized, the best approach will depend on the size of the database being upgraded. For a database that is under 4GB in size, it may be acceptable to still do a Detach/Copy/Attach move of the database, but for a database that is 40GB in size, the time it takes to copy the files to the newer server could exceed the allowable downtime for the system. If the database is 400GB, it will most certainly take to long to move the database by Detach/Copy/Attach. In this case the best path to migration/upgrade is to work with Backup/Restore.

So how do you go about doing this?

Thursday, June 4, 2009

Calling a Web Service from within SQL Server

More and more shops are implementing web services. Doing this provides an architecture that allows applications to consume services to retrieve data. These services could be within your own organization or from a business partner. One of the problems you might run into when building applications that consume web services is how you can use web services data within a SQL Server instance. One of the reasons you might want to do this is so you can join a record set that is returned from a web service with one of your SQL Server tables. This can easily be done within an application, but how do you do this within a stored procedure that only runs within the context of SQL Server. In this article I will discuss one approach for doing this.

Backup Monitoring and Reporting

Database recovery is a core task of database administration and is defined as executing the tasks necessary to backup, save, retrieve and restore databases from hardware, software and user error. Your database recovery procedures should be documented and regularly tested by restoring either a full or random sample of backups. A key part of database backups is monitoring whether backups are in fact occurring. A common mistake in backup monitoring is only checking for backup success or failure when there are in fact three possible outcomes; success, failure and nothing. What is nothing? Nothing is what happens when a database or entire SQL instance for that matter is not configured for backups or the SQL Agent job or Windows services which are often a part of 3rd tools are in a hung state. In order to achieve effective backup monitoring you need to look at the non-event of a lack of backup rather than failed backup messages. Regardless of how a database is backed up, whether through SQL Server native backups or any one of a number of commercial backup software a row is written to the msdb.baclkupset table. Knowing this information, you can create daily monitoring and backup reports.

Wednesday, May 20, 2009

Creating a recycle bin for SQL Server 2005\2008

Recently while being shown around Oracle 10G (yes I said the 'O' word) I noticed that this product has a recycle bin. This recycle bin which stores only dropped tables falls under the Oracle flashback technology umbrella.

I was pretty sure I could do the same in SQL server using DDL triggers and schemas and prevent accidental drops of other objects as well. This article is the result of that challenge.

In a nutshell the SQL Server recycle bin is a combination of two schemas which act as bins (recycle bin and trash can) and a DDL trigger which determines which bin to place the dropped object (which is not dropped but renamed). A stored procedure (sp_undrop) is used to revert the object to its original name and schema.

Monday, May 4, 2009

SQL Server 2008 - Response Time Analysis using Extended Events

This tool demonstrates response time analysis at the session or statement level including waitstats using the new Extended Events infrastructure in SQL Server 2008. This tool is based on the simple principle:

Response time = service time + wait time

This tool allows you to drill down on the time spent in serving the user requests and the time spent in waiting for resources.

Download the application and documentation from Follow the User Guide to install and use the tool. The download also contains the source code for the project.

Tuesday, April 28, 2009

Comparison of Dates in SQL

Dealing with dates has always been a problem with SQL Server queries. Small things lead to critical errors, which are very difficult to detect. One of the common usages of dates is in 'where' clause of the query to filter out the records based on one or more datetime fields. Keeping few things in mind while writing such SQL queries will help you to write an effective query which does not miss any desired records. This article gives you an idea about writing such queries involving date comparisons.

Tuesday, April 14, 2009

Auto generate change scripts in SQL Server Management Studio (SSMS) for tables

As a part of my best practices, I always save the T-SQL scripts used for creation and modification of objects in SQL Server. When creating and modifying tables using SQL Server Management Studio designer it is easy to right click in the designer and select "Generate Change Script...", but is there a way to automatically script the creation and/or modification of tables made through of SQL Server Management Studio (SSMS) designer?  This tip shows you an option that exists within SSMS to automatically generate these scripts for all table changes when using the table designer.

Monday, April 13, 2009

Creating a merged (slipstreamed) drop containing SQL Server 2008 RTM + Service Pack 1

Today, I am going to show you how to create new source media that will slipstream the original source media and SQL Server 2008 Service Pack 1. Once you have created this drop, you can install SQL Server 2008 SP1 in a single step! These instructions are included with the Service Pack 1 release but there are some issues with the documentation that will be addressed in the next revision of the on-line documentation. There is not a lot of user interface that indicates you are slipstreaming, but there are a few clues, see at the bottom for screen shots.

Microsoft SQL Server 2008 Resource Governor primer

Managing workloads and consumption with Resource Governor

Resource Governor is a new feature and one of the most anticipated management features in SQL Server 2008. It bolsters SQL Server performance by allowing DBAs to establish resource limits and priorities on processor and memory-related workloads and resource pools. By defining resource limits on resource consumption, it is possible to prioritize multiple workloads in order to ensure consistent performance and maximize the experience of the end users and the efficiency of the applications without degradation.

It is important to realize from the start that Resource Governor will only throttle processes if SQL Server is experiencing CPU or memory pressure, and it will only throttle incoming requests. For example, a process that consumes high CPU will not be throttled, but the next process may be throttled. Resource Governor is unable to throttle high I/O consumers (processes that read and write excessively from disk) in the SQL Server 2008 release, but this is planned for a future release. 

Thursday, April 9, 2009

Collecting performance counters and using SQL Server to analyze the data

The following will explain how to select counters, how to collect data, how to load the data to SQL Server and how to query the data that has been saved.

Wednesday, April 8, 2009

Database level permissions for SQL Server 2005 and 2008

SQL Server 2005 introduced a new concept to SQL Server security and permissions: securables. Securables are anything within SQL Server that can have a permission assigned. One such securable is the database.

These are the list of database-level permissions.

Tuesday, April 7, 2009

Exploring SQL Server 2008’s Filtered Indexes

One of the most interesting features in SQL Server 2008 is filtered indexes. Let’s start with a quick explanation and then dig into the details and results.

A filtered index is simply an index with a WHERE clause. For example, if you have a table where a date is NULL in 90% of the records but you need to be able to find only records with a non-NULL date, a filtered index will have only the 10% that are not NULL.

It can be very useful for saving space, saving index maintenance costs, and making queries run faster. However, it is important to understand under whatcircumstances it will make your query faster.

Handling workloads on SQL Server 2008 with Resource Governor

Handling workloads has been quite difficult until SQL Server 2005. For example consider a scenario where one SQL instance is serving two applications i.e. an OLTP application and a reporting/data warehousing application. Since reporting applications are normally resource intensive, it may consume all the SQL Server available resources and may hamper the OLTP application which ideally should have more preference over the reporting application.

To handle this scenario, in earlier version of SQL Server there was one option to create multiple instances for these application (segregating by running one application on each instance) and setting CPU affinity mask for these instances appropriately. But the problems with this approach are, first it works for CPU only and second the dedicated CPUs cannot be shared by other SQL Server instances. For example, if there are two SQL Server instances and instance one has been assigned CPU 1 and 2 and instance two has been assigned CPU 3 and 4 on a four processor machine, even if instance one is idle and instance two is in need of additional resources, it can only use CPU 3 and 4.  So what does SQL 2008 offer to solve this issue?

Monday, April 6, 2009

Deleting duplicate Records using SQLCMD

This article presents an approach to showing and deleting duplicate records that is concise, generic and efficient. It uses some features that were introduced in SQL Server 2005.

Tuesday, March 31, 2009

SQLFury - An SQL injection scanner, using blind SQL injection techniques to extract information from a target database

SQL Injection Scanner:
An SQL injection scanner, using blind SQL injection techniques to extract information from a target database. 

Database Support:
Microsoft SQL Server

Extract from database:
Database version.
Current database user.
All database users.
Database name.
All database names.
All table names.
All columns names.
Entire columns.

Monday, March 30, 2009

How to back up Hyper-V virtual machines from the parent partition on a Windows Server 2008-based computer by using Windows Server Backup

This article describes how to back up Hyper-V virtual machines from the parent partition on a Windows Server 2008-based computer by using Windows Server Backup.

To back up Hyper-V virtual machines from the parent partition on Windows Server 2008 by using Windows Server Backup, you must register the Microsoft Hyper-V VSS writer with Windows Server Backup.

To register the Hyper-V VSS writer with Windows Server Backup, follow these steps.

Friday, March 20, 2009

EventTracker PULSE

EventTracker PULSE is a smart search engine for log data. Available as a free software download, it automates the real-time collection and long term archival of all log data from Windows (servers and workstations), Unix/Linux, Cisco devices, applications and any syslog source. A Google-like interface provides searching across hundreds of gigiabytes of data, allowing users to pinpoint critical data in a matter of seconds. Hundreds of preconfigured knowledge categories help users find common events such as Cisco authentication failures or Windows logon failures. In addition, an optional Windows agent provides monitoring of CPU usage, network connections, disk space utilization, capacity utilization, user activity etc.

The benefits of Log Search limitless for system administration and security. For instance, users can quickly identify root cause of service degradations or IT failures for remediation, or in the event of an internal breach, pinpoint who did what and when and plug security holes.

EventTracker PULSE installs on any Windows server or workstation. Key features include:

  • No limit on collection and archival of log data
  • Real-time collection from Windows (servers and workstations), Unix/Linux, Cisco devices, applications and any syslog source
  • Compressed, secure (SHA1) storage of data
  • Easy to use Google-like interface with options for free-form searching using keywords, exact phrases, operators, wildcard characters or a combination of all for complex queries
  • Endless refine to extract precise matches from large volumes
  • Hundreds of preconfigured knowledge categories
  • One-click access to the Prism KnowledgeBase for helpful descriptions on over 20,000 events
  • Agent-optional architecture; centralized agent configuration
More details and download availabile here:

Wednesday, March 18, 2009

Dealing with Windows 64bit "I want SIGNED drivers!"

Solving 64-Bit Windows' "I Only Want Signed Drivers!" Tantrums

I love 64-bit Windows.  I love the ability to stick 8 gigs of RAM on a laptop, allowing me to run several virtual servers, each of which I can equip with 1.5 GB of RAM.  (Life's too short to wait for Server 2008 to get things done in 512 MB of RAM, y'know?)  I love how much snappier Adobe Lightroom is when it's no longer shackled to the 2 GB limits that 32-bit Windows requires.  And I especially love that the main problem with 64-bit Windows -- the lack of 64-bit drivers -- is largely a thing of the past, save for those cases where vendors use the new architecture as a way to force you to upgrade (and yes, I am talking to you, HP printer division and Cisco VPN folks).

Once in a while, though, I run up against the the thing that I most don't like about 64-bit Windows:  the iron rule of driver signing.  Ever since XP and 2003, the 64-bit versions of Windows have refused to load kernel executables or device drivers unless those executables and drivers are digitally signed.  Load a driver that's not signed, and 64-bit Windows pops up some scary-looking message essentially saying, "take a walk, buddy, and take your unsigned driver with you... I mean you don't really know where this thing's been, do you?"  You can get around it by pressing F8 every time you boot and disabling driver signing, but that's a pain.  There was once, briefly, a setting in bcdedit that would let you tell Windows to always skip driver signing, but Vista SP1 put an end to that -- and besides, I don't want Windows to ignore checking the signatures on all drivers, I just want it to allow me to run the occasional unsigned driver.

Look, I understand the whole thought process behind this totalitarian approach, which I understand runs something like this:

  • Unsigned drivers cause the vast majority of Windows bluescreens.
  • Unknowing users don't know that, and so blame Microsoft for blue screens
  • This really irritates people at Microsoft and in particular Dave Cutler, Windows' Architectus Maximus
  • Dave wants to make it easy to finger the culprit of any given blue screen
  • Signing a driver carries with it something of a statement of personal confidence in that driver (and here, I feel, is where the whole thing falls down a bit:  signing a driver says you wrote it, not that it lacks bugs), so...
  • 64-bit Windows requires that all drivers and kernel executables be signed.

It all just seems a bit heavy-handed for my taste -- sort of like, oh, say, scaring a large room full of people into thinking that you've just released a bunch of malaria-infected mosquitoes into the air to make a point about poverty.  Anyway, this month I wanted to offer a workaround for those who run 64-bit systems and really need to run an unsigned driver now and then.  The workaround?  Create your own driver signing certificate and sign the driver or application yourself!  Here are the steps.

Tuesday, March 10, 2009

Installing SQL Server 2008 on a Windows Server 2008 Cluster

In a previous tip on SQL Server 2008 Installation Process, we have seen how different SQL Server 2008 installation is from its previous versions. Now, we have another challenge to face: installing SQL Server 2008 on a Windows Server 2008 Cluster. Windows Server 2008 has a lot of differences from its previous versions and one of them is the clustering feature. How do I go about building a clustered SQL Server 2008 running on Windows Server 2008?

Effective PowerShell: The Free eBook

PowerShell MVP and prodigious PowerShell blogger Keith Hill has converted his very popular Effective PowerShell blog series into a FREE Ebook.  You can download it HERE.

Here is a taste of you'll you'll get:

Table of Contents

Introduction 1 
Item 1: Four Cmdlets that are the Keys to Discovery within PowerShell 1 
Key #1: Get-Command 1 
Key #2: Get-Help 2 
Key #3: Get-Member ..5 
Key #4: Get-PSDrive .6 
PowerShell 2.0 Update 7 
Item 2: Understanding Output 8 
Output is Always a .NET Object 8 
Function Output Consists of Everything That Isn't Captured 9 
Other Types of Output That Can't Be Captured .. 11 
Item 3: Know What Objects Are Flowing Down the Pipeline  12 
Item 4: Output Cardinality - Scalars, Collections and Empty Sets - Oh My! .. 15 
Working with Scalars  15 
Working with Collections .. 16 
Working with Empty Sets .. 17 
Item 5: Use the Objects, Luke. Use the Objects!  19 
Item 6: Know Your Output Formatters . 22 
Item 7: Understanding PowerShell Parsing Modes  31 
Item 8: Understanding ByPropertyName Pipeline Bound Parameters  35 
Item 9: Understanding ByValue Pipeline Bound Parameters  38 
Item 10: Regular Expressions - One of the Power Tools in PowerShell .. 42 
PowerShell 2.0 Update  43 
Item 11: Comparing Arrays  43 
Item 12: Use Set-PSDebug -Strict In Your Scripts - Religiously . 45 
PowerShell 2.0 Update  47 
Item 13: Commenting Out Lines in a Script File .. 47 
PowerShell 2.0 Update  48

Monday, March 9, 2009

Blocking Users by IP

One of the things I like about MySQL is the built-in control over what hosts/IP addresses are allowed to connect into the server. This is granular down to the user (equivalent to SQL Server's login/server principal).

Unfortunately, SQL Server doesn't have the same capabilities with respect to specifying what IPs or hosts a login can come in from, at least nothing built-in that's as clear and simple as with MySQL. I'd like to see something similar to the way MySQL handles it. But until then, there is a way to do this using logon triggers which some folks have hit upon. If you're not familiar with logon triggers, they are similar to DDL triggers, except they fire on a logon event (such as when someone connects to SQL Server). They were quietly introduced in SQL Server 2005 SP2, and they give us the ability to rollback a connection, thereby effectively terminating it. If you're still supporting SQL Server 2000 or below servers, you'll have to use another means to control connections.

Friday, March 6, 2009

SQL Server Reporting Services Fast Guide

Microsoft integrated significant business intelligence reporting enhancements into SQL Server 2005, providing DBAs and company decision makers with all the data they need at their fingertips. This collection of resources will help you on your way to mastering Reporting Services (SSRS) for SQL Server 2005, with tips on proper SSRS installation, performance best practices and more. You'll also find details on what's new with Reporting Services in Microsoft's latest database management system – SQL Server 2008.

Row Level Versioning

The first time I heard the term Row Level Versioning in SQL Server 2005, I had mixed feelings about it. I was a bit confused and I had a pre conceived notion of what it was. When I read more about it I found out I was totally wrong. But I am a type of person who does not take the word of anyone when I can actually try to find out if it is true or not. We will first look at what is Row Level versioning. How it works and what are the advantages. After that, we will try to see if Row Level Version actually works like Microsoft claims.

Thursday, March 5, 2009

Introduction to SQL Server 2008 Report Builder 2.0

I have heard that there is a new version of Report Builder in SQL Server 2008.  Can you provide some details and examples?  What is new with Report Builder 2.0?  How does the new interface look?  What is the learning curve with this tool?


SQL Server 2008 includes a brand new version of the Report Builder which was first introduced in SQL Server 2005.  The key new features in Report Builder 2.0 are:

  • A completely new user interface that conforms to the Office 2007 look and feel
  • A local client install rather than a click-once application that you download and install from Report manager
  • Supports running reports locally or on the server
  • A Report Model is not required; you can create your own queries using a query designer, import queries from existing reports, or manually type in your queries
  • A Tablix report type which is a combination of the matrix and table reports

In this tip we will review installing Report Builder 2.0, the new user interface, developing a sample report, and deploying the report to a SQL Server 2008 report server.  I'll cover the new Tablix report in a future tip.

Wednesday, March 4, 2009

Importing and exporting bulk data with SQL Server's bcp utility

The Bulk Copy Program (bcp) utility in Microsoft SQL Server enables database administrators to import bulk data into a table or export it from a table into a file. It also supports several options that define how data will be exported, where it will be imported and which data will be loaded.

This tip discusses several examples of bcp commands to bulk-copy data in and out of SQL Server tables. The examples have been tested on SQL Server 2005 and SQL Server 2008, and for all examples I used the AdventureWorks sample database.

Perils of adding fields to database tables

Adding a field to a database table is sometimes not as simple as it may seem. If certain situations are not considered when adding fields, you may find yourself looking at some long nights fixing database code. Today, database consultant Tim Chapman looks at two such scenarios, and how you can plan for their occurrence.

Tuesday, March 3, 2009

New Infrastructure Planning and Design Guide: Microsoft SQL Server 2008

The Infrastructure Planning and Design team has released a new guide, Microsoft SQL Server 2008. When used in conjunction with product documentation, this guide will help companies confidently plan the implementation of a SQL Server 2008 infrastructure. Fundamental tasks are addressed to help identify which SQL Server roles will be needed as well as to determine the infrastructure's components, server placement, and the fault-tolerance configuration to meet necessary requirements.

iSCSI configuration in Hyper-V Server 2008 R2

iSCSIcli in Hyper-V Server 2008

In Hyper-V Server 2008 and Server Core Installations of Windows Server 2008 to connect to SAN storage you would use the iscsicli.exe tool. This is the command line equivalent of the iSCSI client configuration tool. This command line tool requires you to utilize your asterisk button a lot. (to accept default values)

iSCSIcpl in Hyper-V Server 2008 R2

To make this crucial step in your cluster setup progress a bit easier, Microsoft has included the graphical version of the iSCSI client configuration tool in Hyper-V Server 2008 R2 and Server Core installations of Windows Server 2008 R2. You no longer have to workiscsicli.exe magic to connect to your SAN; you can click your way through now! Of course, for die hard command line freaks and scripters of all sorts the iscsicli.exe command is still available!

Virtual Machine Disk Options

A review of the virtual machine disk options that are available on Microsoft Windows Server 2008 Hyper-V.

In order to make virtual machine storage portable while also delivering performance, Microsoft developed the Virtual Hard Disk (VHD) Image Format Specification which includes details of how to read and modify data contained in a VHD file. Microsoft provides the VHD file format specification to third-party developers under a royalty-free license, and many vendors, including Citrix, have adopted and use the format for their virtualization products. If you are interested in obtaining more details on the VHD file format, you can download the specification file from the Microsoft website.

Microsoft Windows Server 2008 Hyper-V uses the VHD format to encapsulate virtual machine data (operating system, application, and data files) into one or more files that are equivalent to physical drives associated with a traditional server. Therefore, if you browse the virtual machine folders on a Hyper-V server, a virtual hard disk is simply stored as a file with a .vhd extension on an attached physical disk. Virtual machines connect to a virtual hard disk through a virtualized IDE or SCSI adapter, and Hyper-V provides the mapping between the virtual hard disk and the .vhd file on the physical disk. A VHD can be stored on any IDE, SCSI, iSCSI, SAN, or NAS storage system supported by the Windows Server 2008 operating system.

You can use the Hyper-V Manager MMC or the WMI API to create new virtual hard disks. A virtual machine running on Hyper-V can support a maximum of 260 virtual hard disks through a combination of 4 IDE and 256 SCSI-connected VHDs. The bus type (IDE or SCSI) used to attach a VHD to a virtual machine imposes a size limitation on virtual hard disks. Specifically, IDE-attached VHDs cannot exceed 127 GB, while SCSI-attached VHDs cannot exceed 2 TB.


For those of you who’ve enabled the Hyper-V role in WS08. It has been determined that a certificate error can occur resulting in the inability to start or connect to virtual machines running on Windows Server 2008 or Microsoft Hyper-V Server 2008.  The Hyper-V virtualization host and the existing virtual machines will continue to operate without disruption.  A hotfix designed to prevent/resolve this error has been created and is available for download starting today.  The following is a brief description of the issue as well as a link to the KB Article that provides the resolution.  Even if you are not currently experiencing this issue, we recommend you download and install this update.
  • Windows Server 2008, Standard (Hyper-V role enabled)
  • Windows Server 2008, Enterprise (Hyper-V role enabled)
  • Windows Server 2008, Datacenter (Hyper-V role enabled)
  • Microsoft Hyper-V Server 2008
  • You may be unable to start or connect to virtual machines running on Windows Server 2008 or Microsoft Hyper-V Server 2008. This occurs when connecting using vmconnect. Connections made using remote desktop won't be affected.  
  • KB Article 967902 has been created that details the symptoms and resolution.  This KB article provides a direct link to download the quickfix to resolve this error.

Monday, February 16, 2009

Help, my database is corrupt. Now what?

A corrupt database is probably one of most DBA's worst nightmares. It results in downtime, managers shouting and all other sorts of unpleasant things

In this article, I'm going to explain some of the things not to do to a corrupt database, and then go through some of the things that should be done, some of the scenarios and the fixes for those.

Thursday, February 12, 2009

Microsoft Hyper-V Server 2008 Configuration Guide

Detailed setup & configuration guide for Microsoft Hyper-V Server 2008.

Planning for Hyper-V Security

Once you have updated the Windows Server® 2008 operating system with the Hyper-V™ technology release bits and enabled the Hyper-V role, you are ready to run virtual machines (VMs) on your server, now called a virtualization server (also called a “host”).

How does this change your security? Not much. Hyper-V is designed to be fairly transparent. You secure your VMs the same way that you secure physical machines. For example, if you run antivirus software on the physical machine, run it on the VM (not the host). If you segment the physical server to a particular network, do the same to the VM.

Securing the virtualization server itself involves all the measures you take to safeguard any Windows Server 2008 server role, plus a few extra to help secure the VMs, configuration files, and data. 

Achieving High Availability for Hyper-V

Server virtualization is poised to make a significant impact in enterprise IT departments, and Hyper-V with Windows Server 2008 can make it a reality. The consolidation of servers onto fewer physical machines has huge advantages in resource and cost savings, but two key factors need to be considered during the planning process. Users have increasing expectations regarding the availability of their software, including both line-of-business (LOB) applications and tools such as messaging and collaboration platforms. Furthermore, problems or failure on servers can have a significantly greater impact on operations. Windows Server 2008 and Hyper-V provide solutions that can be implemented to provide high availability (HA) of virtual machines (VMs) as well as to the workloads being hosted inside the VMs.

An Introduction to Hyper-V in Windows Server 2008

There has been quite a lot of talk about virtualization recently, and most of the discussion is specifically about server virtualization. This is one of the most exciting trends in the industry and one that has the potential, over the next few years, to change the paradigm of how IT systems are deployed. But server virtualization will not only change how IT administrators and architects think about servers and system utilization, it is also going to affect the processes and tools used to manage what will certainly become an increasingly dynamic environment.
Virtualization has actually been around for some time now, but the technology is still evolving. In fact, the word itself still means different things to different people. In broad terms, however, virtualization is about abstracting one layer of the technology stack from the next layer, like storage from servers or the OS from the applications. Abstracting the different layers, in turn, enables consolidation and better manageability.
As a concept, virtualization applies to storage, networks, servers, applications, and access. When you look at storage and networks, the goal of virtualization is to aggregate a set of different devices so the total pool of resources looks and acts like a single entity. For example, you can configure a 40TB storage solution instead of a set of 20 2TB storage devices. But with other components, virtualization acts in the opposite direction, helping you to make a single system appear as though there are multiple systems. The most common example of this is server virtualization, where you host multiple OS instances and environments on a single server.
Microsoft has approached virtualization at several different levels, extending from the desktop to the datacenter with solutions for server virtualization, application virtualization, presentation virtualization, and desktop virtualization. The common thread across all of these is the management piece with Microsoft System Center. For this article, I am focusing on the server virtualization component and specifically on how Hyper-V, a key feature of Windows Server 2008, fits into the equation for a dynamic datacenter.

Tuesday, February 10, 2009

Installing and Configuring Openfiler with DRBD and Heartbeat (HA Cluster Setup)

Openfiler is a high performance operating system tailored for use as a SAN/NAS appliance. This configuration will enable two Openfiler appliances to work in an Active/Passive high availability scenario.

Right click to mount/unmount VHD in Windows 7 or Windows Server 2008 R2

Tool to mount / unmount VHDs by right clicking on a VHD file. This new tool will work on Windows 7 or Windows Server 2008 R2 systems with or without Hyper-V role. This one uses diskpart commands available within this new OS and hence there is no dependency on Hyper-V WMI interfaces. So, you can use this new script only if your system has Windows 7 or Windows Server 2008 R2.

Windows Image to Virtual Hard Disk Converter (WIM2VHD)

WIM2VHD is a tool that will create a bootable VHD from a specified Windows 7 or 2008 R2 WIM image (like the INSTALL.WIM file that ships on the installation DVDs) without having to run Windows Setup.  That means that you can a Windows 7 or Windows Server 2008 R2 virtual machine up and running much, much faster.

Powering Server Core - Configuring UPS Devices

Microsoft Windows Server 2003 and Microsoft Windows Server 2003 R2 came with built-in support for serial and USB connected Uninterruptible Power Supply (UPS) devices. From within the Power Options you could manage your UPS and the shutdown behavior of the box.

About UPS Devices

UPS devices help prevent loss of data from power loss (“black-outs) by shutting down the server properly instead of abruptly. The device also helps protect the server hardware from power surges, brown outs, drop outs and voltage fluctuations, extending the life of the hardware.

Continues on...

Monday, February 9, 2009

HOWTO Configure iSCSI CHAP authentication on Microsoft iSCSI Initiator

OpenFiler's implementation of CHAP doesn't seem to work the same as other products I have used (in terms of what you see on the client end).  However, this isn't to say that OpenFiler is implementing it incorrectly, for all I know the other products were!

So, here goes:


First off, I am not going to detail how to install OpenFiler or how to set up a basic disk and turn on iSCSI.  Information on installing OpenFiler can be found in the documentation and David Davis posted a nice article here about how to set up a basic volume for iSCSI use.  I am also not going to discuss how to instal the Microsoft iSCSI intiator, although it is very easy to do and can be downloaded here.

Once you have set up Open Filer for basic iSCSI access and have installed the MS iSCSI Initiator, perform the following steps:

Friday, February 6, 2009

Windows Server 2008 Hyper-V Security Guide – beta now available

For organizations that seek cost-effective operations, the benefits of virtualization are more evident than ever. Microsoft® Hyper-V technology allows consolidation of workloads that are currently spread across multiple underutilized servers onto a smaller number of servers. This capability provides you with a way to reduce costs through lower hardware, energy, and management overhead while creating a more dynamic IT infrastructure.

Virtualization technologies are causing enterprise organizations to shift their thinking about IT. The Hyper-V Security Guide can help you elevate the security of virtualized Windows Server® environments to meet your business-critical needs. This accelerator provides IT professionals like you with recommendations to address your key security concerns around server virtualization. The guide provides authoritative guidance that relates to the following strategies for securing virtualized environments.

Installing Windows Hyper-V Server 2008

How to install Microsoft Hyper-V Server 2008 and use the HVConfig command line configuration tool.

Microsoft Hyper-V Server (HVS) 2008 is a hypervisor solution that is based on Windows Server 2008 and Hyper-V. Unlike Windows Server 2008 which supports the installation of many different roles, Microsoft Hyper-V Server 2008 is standalone virtualization software that does not support any additional roles.

The installation of Microsoft Hyper-V Server 2008 will be very familiar to those of you who have installed a Windows Server 2008 edition because it uses a similar wizard-driven installation. Here are the steps you must follow to install Microsoft Hyper-V Server 2008.

A closer look at the Windows 7 SKUs

Today, I wanted to take a closer look at the Windows 7 SKUs since there has been some discussion about them for the last couple of days. By the end of this post, I want you to know exactly which edition of Windows 7 is right for you and help you understand how we approached addressing the large amount of feedback we received.

Our SKU line-up is based on listening to feedback from customers and partners and here is what they have told us and how we are addressing their feedback in Windows 7:

Customers wanted clarity on which version of Windows is the right version for them.  So…Windows 7 will be offered primarily in 2 editions: Windows 7 Home Premium and Windows 7 Professional.

Continues on...

Tuesday, February 3, 2009

Disk Subsystem Performance Analysis for Windows

Analyzing storage subsystem performance is an art, not a science. Each rule has an exception; each system designer or administrator has a different combination of hardware configurations and software workloads to consider. This paper examines the performance of storage subsystems used by computers running the Microsoft Windows 2000, Windows XP, or Windows Server 2003 family of operating systems.
This paper considers performance from both the hardware and software perspectives. In addition, it discusses tools for storage subsystem analysis and design and provides rules of thumb and guidelines for system design and to solve the performance bottlenecks in specific configurations.

Exchange - How to Calculate Your Disk I/O Requirements

Calculating your disk I/O requirements ultimately allows you to optimize your disk subsystem to best support your users.
Your goal is to provide enough disk I/O performance (measured by the number of I/O operations per second [IOPS] that can be performed) with acceptable latency that allows for efficient Exchange functionality.
Calculating the IOPS per mailbox is a convenient way to measure the profile for a given server based on random database read/write I/O (transaction log I/O is not factored into this equation). The higher the IOPS per mailbox, the more aggressive the mailbox profile is in terms of disk usage.

SQL Server CLR function to improve performance of validating email addresses

When you send e-mail to large lists, validating the e-mail addresses before sending out the e-mail is worth doing to prevent having mail rejection messages clog up your mail server. I had been doing the validation with a T-SQL User Defined Function (UDF), but it was getting too slow as the number of e-mails grew. I needed a faster alternative, what options do I have?

Is it true that Hyper-V Server 2008 R2 will support clustering and live migration?

Yes. Hyper-V Server 2008 R2 instances can form a cluster, which enables live migration. This is a change from the initial version of Hyper-V Server, which is based on Windows Server 2008 R1 Standard Edition and couldn't be clustered.

There are still advantages to using Windows Server 2008 R2 Enterprise Edition over Hyper-V Server 2008 R2 instances, including:
  • Four virtual machine licenses are included with Enterprise edition. Hyper-V doesn't come with any.
  • You can only use the command line and PowerShell to manage Hyper-V Server locally, though you can use the full cluster GUI to remotely manage a Hyper-V Server cluster.
  • Clustering in Hyper-V Server 2008 R2 only supports Hyper-V high availability. You can't make any other applications or services highly available on Hyper-V Server 2008 R2.

Native VHD booting on Windows 7 or Windows Server 2008 R2

If you have been testing Windows 7 or Windows Server 2008 R2, you must have come across native VHD booting feature. This allows us to boot OS from VHD file residing on the hard drive. You don’t need a Hypervisor to boot from VHD. Windows 7 boot architecure changed a bit to accomodate this. In fact, Windows Server 2008 has the option to boot from a file.

Friday, January 30, 2009

Predeployment I/O Best Practices: SQL Server Best Practices Article

The I/O system is important to the performance of SQL Server. When configuring a new server for SQL Server or when adding or modifying the disk configuration of an existing system, it is good practice to determine the capacity of the I/O subsystem prior to deploying SQL Server. This white paper discusses validating and determining the capacity of an I/O subsystem.

CoreConfigurator - use a graphic interface to configure Windows Server 2008 Core edition!

Smart-X has published a new version, of their tool, CoreConfigurator - use a graphic interface to configure Windows Server 2008 Core edition!

CoreConfigurator is free for personal use and free for non commercial use.

Active Directory on separate volumes?

I have seen numerous discussions with people on the benefits and drawbacks of putting Active Directory files and folders on a separate volume or even on several separate volumes. Time to makes some things clear!

Transitioning your Active Directory to Windows Server 2008

You might be running Windows Server 2003 and Windows Server 2003 R2 Domain Controllers at the moment and you're looking to replace these servers with Windows Server 2008 Domain Controllers to utilize the new features of Windows Server 2008. You might also be looking to replace your aging Windows Server 2003 and Windows Server 2003 R2 Domain Controllers with spanking new Windows Server 2008 Domain Controllers, while keeping your Active Directory running smoothly.

This post intends to help you with this transition in a structured, balanced and thorough way.

Virtualizing Exchange 2007 and Exchange 2003 with Hyper-V

Microsoft offers two Hyper-V products—Windows Server 2008 Hyper-V, which is a role in Windows Server 2008, and Microsoft Hyper-V Server 2008, which is a standalone server-virtualization product—that you can use to virtualize Microsoft Exchange Server 2007 and Microsoft Exchange Server 2003 servers. Here's an overview of what you should consider, the processes you can follow, and the requirements you need to meet to virtualize Exchange 2007 and Exchange 2003 with Hyper-V.

Support policy for Microsoft SQL Server products that are running in a hardware virtualization environment

This KB article describes the support policy for Microsoft SQL Server products that are running in a hardware virtualization environment.

Running SQL Server 2008 in a Hyper-V Environment - Best Practices and Performance Considerations

Hyper-V in Windows Server 2008 is a powerful virtualization technology that can be used by corporate IT to consolidate under-utilized servers, lowering TCO and maintaining or improving Quality of Service. Through a series of test scenarios that are representative of SQL Server application fundamentals, this document provides best practice recommendations on running SQL Server in Windows Hyper-V environment.

Exchange Servers in Hardware Virtualization Environments

Microsoft Support Policies and Recommendations for Exchange Servers in Hardware Virtualization Environments

This Technet page provides the Microsoft support policies for running currently supported versions of Microsoft Exchange Server in production in a hardware virtualization environment.

Thursday, January 29, 2009

WinBubble - tweaking tool for Vista

Lawrence Albert has a nice utility for tweaking the Windows Vista, called WinBubble, a great replacement for TweakUI.

Wednesday, January 28, 2009

ASP.NET Tutorial (ro)

ASP.NET tutorials for beginers, in romanian:

Part 1
Part 2
Part 3

Using CROSS JOIN queries to find records out of sequence

This topic is nothing new, but well worth revisiting for those who have not used CROSS JOINS. You may have faced a problem where you need to compare historical records for a particular set of records to ensure that records have been saved in the correct order.

Hierarchies in SQL

One very common structure that needs to be handled in T-SQL is the hierarchy. GSquared, one of the prominent members of the SQL Server Central community discusses how you can handle hierarchies in SQL Server.

Creating OS VHDs from Windows Server 2008 R2 OS media

A tutorial about the procedure of getting the setup image of Windows Server 2008 R2 into a VHD.

And the follow up, Enabling a captured VHD to boot in a Hyper-V Virtual Machine.

Tuesday, January 27, 2009

How do Cluster Shared Volumes work in Windows Server 2008 R2?

I have found today the description of the new Cluster Shared Volumes that will be availabe in Windows Server 2008 R2, a feature designed for Hyper-V 2.0, to remove the need for 1 LUN per VM:

You need to register/login to see the answer.

Hyper-V 2.0 Feature overview has a nice description of features that will be comming with Hyper-V 2.0:

  • Live Migration
  • enhanced Logical Processor Support
  • Hot add remove storage
  • Second Level Translation (SLAT)
  • Dynamic Memory
  • Boot (host) from VHD
  • improved speed of iSCSI storage communication
  • support for multiple network channels (NIC teaming support)
  • Virtualized I/O
more details can be found here:

Update: Sander Berkouwer in his blog "The things that are better left unspoken" is talking about his experience with Hyper-V 2.0 beta and what surprise him.

Monday, January 26, 2009

Auto notification for failover of a server and restart of SQL Server services

Learn how you can monitor the SQL Server instances for failover of a cluster or a restart.

Friday, January 23, 2009

Hyper-V Remote Management Configuration Utility

HVRemote, maintained by John Howard, Senior Program Manager in the Hyper-V Team at Microsoft, is a handy tool that reduces the manual configuration steps needed for Hyper-V Remote Management down to one or two commands.

HVRemote project site is at this address:

and author's blog can be found here.

Hyper-V Server 2008 Local Management scripts / UI

A very nice addition to the configuration script integrated in Hyper-V Server, HVS2008 UI is a CodePlex developed script that helps you manage a Hyper-V Server host.

Is developed by Ravikanth Chaganti's and his blog can be found here.

IIS 7.0 Configuration Reference - online library

The IIS development team has put together a brand new technical reference on IIS 7.0 configuration.
This vast library comprehensively details all IIS 7.0 configuration settings in Windows Server 2008, including configuration collections, elements, and attributes. You can sort the configuration settings alphabetically to easily find what you are looking for or by browsing the schema structure. Each configuration topic provides sections such as an overview, examples of how to configure the configuration, setup instructions, configuration details, and code and script samples – including AppCmd.exe, C# .NET, Visual Basic .NET, JavaScript, and VBScript.
This is the only online reference you’ll need for IIS configuration, so check out the comprehensive documentation at today!

Free eBook: Mastering SQL Server 2005 Profiler, by Brad McGehee, 2009

Thist is the second eBook i have found today, about the Profiler in SQL Server 2005, is also free, and can be downloaded here (PDF, 10MB).

Free eBook: Understanding Microsoft Virtualization Solutions - From the Desktop to the Datacenter, 2009

Today i have found this book about almost all the virtualization products and technologies Microsoft makes, and it seems that is a good book, and best of all, is free!

Highlights: Hyper-V, System Center Virtual Machine Manager (SCVMM) , App-V, Terminal Services, MED-V, VDI, Roaming User Profiles, ...

Here's the download link (PDF, 15MB).

Wednesday, January 21, 2009

Hyper-V 2.0: Live Migration setup on Windows Server 2008 R2 (beta 1)

Now that Windows Server 2008 R2 beta 1 is available, I decided to give it a spin. The installation of the Hyper-V role and the Failover Cluster feature is very similar to the current version and is not discussed in this article. This article does not discuss best practices. It merely illustrates the setup process that enables you to live migrate virtual machines with Hyper-V 2.0.

Tuesday, January 20, 2009

Planning virtualization of servers with Hyper-V, part 2

The part 2 of this kind of tutorial talks about creating the list of applications that need to be virtualized. Part 1 is available here:

Step 2: Create the List of Applications
Before designing and implementing the infrastructure, determine which applications the infrastructure needs to support. This information will be used in later steps to determine resource requirements and, ultimately, to design the physical host infrastructure.

Determine Application Compatibility

The first step in deciding which applications to virtualize is to consider the specific technical requirements for the application or operating system and map that against any constraints in the virtualization technology. Factors include:
  • Processor architecture requirements.
  • The number of required processors.
  • Memory requirements.
  • Graphics adapter requirements.
  • Special hardware requirements.
Windows Server 2008 Hyper-V has the following constraints and limitations:
  • Is available with Windows Server 2008.
  • Requires specialized hardware chipset (Intel VT or AMD-V).
  • No access to USB devices or hardware such as Host Bus Adapters (HBAs).

Document the List of Applications

Most organizations run multiple operating systems, applications, and services that IT may consider moving to a virtual environment. To ensure that no important considerations are overlooked, a spreadsheet or table should be created that lists the applications, whether they are compatible with virtualization, and whether it is appropriate to virtualize them. Such a job aid could also include additional notes, requirements, and concerns. Filling out such a table can provide a very helpful structure to the process of planning for virtualization.

In the next article, i will cover the step 3, Determine Resource Requirements.

How to boot a VM in Hyper-V from iSCSI

Hyper-V virtual machines do not emulate an iSCSI HBA or allow you to pass a physical iSCSI HBA through to the virtual machine. However, as Hyper-V supports booting virtual machines directly off of physical hard disks, you can attach an iSCSI LUN to the parent partition and then boot the virtual machine off of it.
In order to do this you would need to:
  1. Attach the iSCSI LUN to the parent partition.
  2. Create a new virtual machine and opt to configure the hard disk later.
  3. Open the settings for the new virtual machine and select the first IDE controller.
  4. Select to add a disk drive.
  5. On the disk drive configuration page select to use a physical hard disk, and select the iSCSI LUN.
  6. Apply changes and close the virtual machine settings.

Now you can boot the virtual machine directly off the iSCSI LUN by just starting it up...


Hyper-V Quirks That Take Some Getting Used To

Lately, it seems as though everyone that I talk to is interested in virtualizing at least some of the servers in their organization. Although Hyper-V does a great job as a virtual server hosting solution, it does have some quirks that you might not expect. In this article, I want to talk about some of these quirks and how to work around them.

Planning virtualization of servers with Hyper-V, part 1

For a succesful implementation of virtualization of your existing servers you need to plan your moves carefuly. To keep things short, these are the steps you need to take:

  1. Determine the Virtualization Scope
  2. Create the List of Applications
  3. Determine Resource Requirements
  4. Select the Backup Approach for Each Application
  5. Applying Fault Tolerance
  6. Summarize and Analyze the Application Requirements
  7. Select a Form Factor for the Hosts
  8. Map Guests to Hosts
  9. Determine the Host Backup Approach
  10. Design Fault Tolerance
  11. Design the Storage Infrastructure
  12. Design the Network Infrastructure

Starting with step 1, determining the virtualization scope, you have a few options:

  1. Enterprise Deployment - this option involves deployment of virtualization technology to the entire organization, including corporate data centers.
  2. Hub Deployment - this option involves deployment of virtualization technology to one or more hub locations. Hubs are physical locations where there are concentrations of users, computers, and/or network connectivity. Resources within the hub may be provided to additional satellite locations.
  3. Satellite Deployment - this option involves deployment of virtualization technology to one or more satellite locations. Satellite locations are smaller than enterprise or hub environments and often have limited network connectivity to the rest of the environment because of bandwidth constraints.

In part 2, i will examine the next step, creating the list of applications that need to be virtualized.

Managing connections to remote servers

There are a number of ways of managing connections to databases. Configuration files, udls, odbc dsns etc. However when you have set one up to use a remote database how do you test that it is actually making a connection.

Adding a column to every table in a database

Despite the best laid plans, sometimes circumstances or project scope change and the definition of one or more tables in your database must be altered after they have been created. It's just a fact of life for a DBA.

Analyzing the SQL Server Plan Cache

Keeping in mind the importance of the cache mechanism, how could one get the plans and their usage statistics in SQL Server?

Spring Clean Your Database Schema

The utility described in this article will allow you to quickly identify which columns have mismatched datatypes across tables in a database, and should prove valuable in the everyday work of the SQL Server DBA/developer.

Log Management, the easy way

Today i have found an interesting Log Management software, called Splunk. Seems very powerful, and they even have a free version.

Splunk website -

Splunk documentation -

What Splunk can do for you:

With a variety of flexible input methods you can index logs, configurations, traps and alerts, messages, scripts, and code and performance data from all your applications, servers and network devices. Monitor file systems for scripts and configuration changes, capture archive files, find and tail live application logs, connect to network ports to receive syslog, SNMP and other network-based instrumentation. And this is just where it starts.

Fast, free form search on anything, not just a few predetermined fields. Boolean, nested, quoted string and wildcard searches. No knowledge of specific data formats required. Combine time and term searches. Find errors across every tier of your infrastructure and configuration changes in the seconds before a system failure occurred. Fields are identified from your results as you search -- providing much more flexibility than a rigid set of field mapping rules imposed ahead of time.

Any search can be run on a schedule and trigger notifications or actions based on the search results. And because it works across different components and technologies, Splunk is the most flexible monitoring tool in your arsenal. Notifications can be sent via email, RSS or SNMP to other management consoles. Actions trigger scripts performing user described activities like restarting an application, server or network device.

Splunk marries powerful reporting capabilities with the speed, flexibility and scale of IT Search. Search results can be easily summarized as reports with interactive charts, graphs and tables. The simplicity of analyzing massive amounts of data will amaze you (and your boss). And remember, because fields are identified as you search you can specify new fields without re-indexing your data.

Everyone knows IT data is generally poorly documented by vendors, developers and operations staff. With Splunk everyone can add their own knowledge as they go. As you’re saving searches, identifying different types of fields, events and transactions you make the whole system smarter for everyone else. And that knowledge doesn’t walk out the door when someone leaves.

Scale your installation from a single application and just a few data sources to your whole datacenter and thousands of sources. You’ll find a wide range of options to access data, store it, search it and route it to other systems.

Of course you'll need to keep your IT data secure. Especially as you realize what a valuable information asset you have. Splunk gives you secure data handling, fine grain access controls, auditability, assurance of data integrity and integration with existing authentication systems.

When i will be done with the installation and configuration with my new servers i will give it a try, and share my experience with it.