Sunday, August 22, 2010

Creating A Bootable Windows 7 USB Flash Drive

In this post, I am going to emphasize on how to create a bootable USB drive with the Windows 7 installer. It's a pretty simple and straight-forward process. There are several advantages of doing this -

  • Installing Windows 7 on computers without an Optical CD/DVD Drive. Many of the new laptops/desktops come without the CD/DVD drive. Using a bootable USB is very helpful here
  • Installing from the USB drive is typically faster than installing from a DVD drive
  • OS disc images (.iso, .nrg) need not be burned onto a CD/DVD to use them. You can make a bootable USB drive from the image and install the OS from the USB

There are two phases involved in the process - "Formatting the USB drive" and "Copying the installation files and making it bootable".

Formatting the USB drive

I am using the Diskpart command line utility in the following steps to format the USB drive. I guess even the Right-click and Format option can be used, but I haven't tried it. If you get into any trouble using the Format from the Right-click menu, put in a comment and I will look into it.

  1. Open the command prompt as an Administrator
  2. Start the DiskPart utility by typing in "diskpart". This will show a list of all the drives connected to the system. Identify the disk corresponding to the USB drive
  3. Select the USB drive using the "select ###" command
  4. Clean it using the "clean" command
  5. Create a primary partition on the USB using the "create partition primary" command. This is where we will be copying the installation files
  6. Select the partition using the "select partition 1" command
  7. Make it active by typing "active"
  8. Format the drive and create an NTFS filesystem on it using the "format fs=ntfs" command
  9. Assign a drive letter to the USB disk using the "assign" command
  10. Exit the DiskPart utility using the "exit" command

The USB is now formatted and is ready for the transfer.

Copying the installation files and making it bootable

The following steps are the crux of the process.

  1. Insert the Windows 7 DVD
  2. Navigate to the boot directory of the DVD
  3. There is a utility "Bootsect" which comes bundled in the Windows 7 DVD. This does the entire work for us
  4. Run the utility from the command line and specify the drive letter of the USB drive. bootsect.exe /NT60 X:
  5. The utility adds the appropriate boot-code to the USB drive
  6. Copy the contents of the DVD onto the USB drive

That's it, reboot the system, make sure that the USB boot is given the highest priority and the installation starts.

Saturday, August 07, 2010

Community TechDays August 2010

I spent my entire day today at Microsoft IDC, Hyderabad where I had a wonderful experience at Community TechDays organized by the Microsoft User Group, Hyderabad (MUGH). For people wondering what Community TechDays is - It is a multi-city event conducted quarterly by the technology community for Developers, Infrastructure Professionals, Architects, Project Managers and Students. This was the fourth Community TechDays series in India but the first one I attended.

The event started at around 9:30 and there were two parallels tracks - one for the Developers and another for the IT Professionals. Having registered for both, I attended the sessions which I found interesting in the two tracks. On a whole there were 5 sessions which I attended. I will give a brief description of the sessions I attended and will try to get the technical details on my Tech Blog sometime soon. But no promises on that :)

The first session was on the Data compression options in SQL Server 2008 by Arun Shankar which was pretty good. It covered how the database can be compressed during backup and various data compression techniques like row level compression and page level compression to reduce the size taken up the database. Following that was a session on IIS End to End by Muqeet Khan. To be honest, I didn't have much experience on IIS but had a reasonable exposure to web servers as a whole. So learnt a lot through the session and loved the concept of running languages like PHP and Java in IIS 7.0.

The next session I attended was on Cloud Services with Windows Azure Platform by Arun Ganesh. This was one session where content was very good but time was a major constraint. Initially he started with an introduction on Cloud Computing and a live demo on developing and deploying a sample application on Windows Azure. He also covered Azure Storage - Tables, Blobs and Queues with a live example. Though he introduced SQL Azure and Azure Services like Service Bus and Access Control, he couldn't cover a live example there. As I had prior experience in developing and deploying an Azure app, I was really looking forward for the demo on Service Bus and Access Control but was a bit disappointed at the end.

Post lunch, there was a session on WCF in .NET 4.0 and Windows Server AppFabric by Phani Kumar. This was a bouncer for me. With negligible hands-on experience on WCF, the session was way above my head. Though the speaker was explaining it well, me and my friends had a tough time co-relating it to what we did. The last session was more like an open discussion again with Muqeet Khan. It started with batch processing admin tasks in Power Shell and soon moved on how Windows works. It was more like a refresher of my OS class at college but more entertaining :D

The day ended with a curtain raiser of XBox Project Natal (more popularly known as Kinect for XBox 360) at around 4:30. I can't wait to get my hands on it when it comes to India in December this year.

Oh, the best part of the day - I guess we were among the youngest developers who came for the event today. It was actually interesting sitting in a crowd with people with work-experience of around 2-3 years with our work-experience of around 2-3 months ;)