SharePoint, Office 365, Azure, and Front end JS geek. – Chicago IL
SharePoint, Office 365, Azure, and Front end JS geek. – Chicago IL

Virtualization

I

Let’s get right down to it.  Oracle’s VirtualBox (http://www.virtualbox.org/) application is:

  • Free – Zero cost.  What are you waiting for?  Go download it!
  • Fast – Low performance overhead.  New VT and Nested Paging support take it to the next level.
  • Flexible – Runs on any modern processor.  Support both VHD and VDI disk images.  ISO or physical CD for media.
  • Fun– Support for many powerful features.  Saved state (no IIS cache waiting), host integrated clipboard, default NAT (network address translation) make this a breeze to get started with.   No coding or special tricks required.  It just works.

But don’t just take my word for it.  Eric Harlan thinks it’s cool.   And so does Jeremy Thake.  Of course VM Ware Workstation is a good option and others will work but for the free price VirtualBox is hard to beat.   It’s just plain easy to learn.   Most of my tech friends want to run a SharePoint 2010 DEV server on their personal Windows 7 64-bit laptop as a personal lab to learn with.   I have yet to find a better tool for this.

1 – Create VHD with Windows 7’s Computer Manager

  • Start Run compmgmt.msc
  • Right click “Disk Management” and click “Create VHD”
  • I personally like Dynamic Disks for the extra storage flexibility.  Yes, there is a small performance hit when it expands.
  • Right click “Initialize” on the new disk
  • Right click “New Volume” on the online disk
  • NTFS quick format with a volume name that matches the VHD file.
  • Detach the VHD file
  • Cogratulations!   You’ve creative a Microsoft native format VHD that can be easily managed by many tools.

2 – Create VirtualBox Guest with VHD file and RAM allocation

  • Open Oracle VirtualBox
  • Click “New” to start
  • Select the O/S type for the guest.  Note: this is important for integration (clipboard, file share, network) so please read all choices.  Windows Server 2008 R2 is the “Windows 7” kernel type and typically what I run.
  • Give it as much RAM as possible (max out the green line). 
    Open-mouthed
  • When asked for hard drive click “Use existing” and browse for the VHD file.  You’ll need to register the VHD path in the Media Manager.
  • Finish and check the advanced settings.   I suggest a few changes beyond the default :
    • Enable PAE
    • Enable VT
    • Enable nested paging
    • Set CPU to 2 (or more if you can)
    • Enable 2D video acceleration
    • Increase video RAM to 50% of host.   I use 64MB of the host 128 MB.
  • Now you’re ready to boot install media.
  • Under “Storage” browse for a local .ISO on the host to mount on the virtual CD drive.   When finished click “Start” and you’re all set.

 

image

image

image

image

image

image

 

image
image

image

image

image

image

image

 

image

Hyper-V and Virtual Server 2005 = smart combo!

Unless you’ve been living under a rock the past five years you’ve run a virtual machine.  Yes, we all love them.   They save hardware, energy, time, and even our butts in the event of a rollback.    As a developer or administrator I think it’s best to understand the structure and have many tools available.   Our creativity is our single best long term tool to solve problems.

If you run Hyper-V I still recommend you install Virtual Server 2005.

Why?

  • Great utilities like VHDMOUNT.     Amazing tool that lets you modify VHD files directly without booting anything.   Partition resize, modify contents, etc.
  • Backwards compatibility with older systems (i.e. Virtual PC 2007 on Win XP)
  • Run older VM without upgrading them to Hyper-V.
  • Original source Virtual Machine Additions install media (ISO, VFD)

Keep your options open.  You might need them one day.   Also, don’t forget about Disk2vhd which lets you convert P2V (physical to virtual) by creating a .VHD from a live physical disk.

http://kirkmunro.files.wordpress.com/2008/10/hyper-v-drink.jpg

   

18f4bc49-f2ed-4915-8e7b-9b9193ff9491

Moving .VHD from Hyper-V to Virtual PC 2007 (HAL.DLL replace)

Why would anyone want to do this?   Am I crazy?   Probably, but that’s beside the point.  Hyper-V is amazing and super fast technology that I cannot get enough of.  I formatted my new laptop the day I bought it just so I could run Windows Server 2008 with Hyper-V and never looked back.

So why downgrade to Virtual PC 2007?

  • Backward compatibility for older VM hosts like Virtual PC 2007
  • Allows you to distribute easily for any user to boot
  • Wide compatibility with Windows XP, Vista, etc.
  • It’s just good manners to share in formats people can readily use

I won’t pretend I discovered this on my own and sources are cited at the footer.   My goal is to record the trick and share with others who may do similar VHD migration work.    There are two key changes to execute:  removing the Integration Services and replacing HAL.DLL

  1. Make a copy of the original VHD – Don’t you always?   Backups, backups, backups …
  2. Open Hyper-V MMC and Import the VHD
  3. Boot and install Integration Services
  4. … {enjoy using Hyper-V and adding cool new stuff over time} …
  5. Make a full VHD duplicate copy.   Maybe name it with a “CLEAN” suffix?
  6. Open Hyper-V MMC and Import the duplicate VHD
  7. Boot this and uninstall Integration Services from Add Remove Programs
  8. Shutdown the virtual guest
  9. You’ll need HAL.DLL from the original in #1 from before it went into Hyper-V mode.   This clean HAL.DLL is key to making the VHD boot into older systems like Virtual PC 2007.
  10. Use “VHDMOUNT.EXE /M {file name}” to mount the duplicate VHD file from #5
  11. Open Disk Management MMC and locate the new mounted drive letter
  12. Browse to C:WindowsSystem32HAL.DLL and rename to HAL.HPV.DLL
  13. Copy the clean HAL.DLL into C:WindowsSystem32
  14. Use “VHDMOUNT.EXE /U /C All”  to commit changes and save the VHD
  15. You’re ready to give this VHD file to anyone and they can easily boot it on 32-bit Windows XP with Virtual PC or whatever older VM host they like.

For completeness I must explain that when you first start up in Hyper-V the HAL.DLL layer is changed to give it that gorgeous direct hardware access that makes it run so incredibly fast.  But wait … my friends don’t have that … so it won’t boot on Virtual PC anymore.  Whoops!   That’s the whole challenge we’re trying to work around here.    What is VHDMOUNT.EXE you might ask?   A really cool utility that ships with Virtual Server 2005.    I personally don’t use Virtual Server 2005 directly (Hyper-V is faster) but keep it around anyway because of the helpful utilities that are part of the install folder.  Lastly,  I have included the Windows Server 2003 Enterprise Edition HAL.DLL file from two flavors:

Windows Server 2003 Enterprise Edition – Hyper-V flavor  (HAL.HPV.DLL)

Windows Server 2003 Enterprise Edition – Virtual PC flavor  (HAL.VPC.DLL)

image

image

Sources Cited:

CJG – Chris Givens – Migrating Hyper-V back to VPC! – Hal.dll

The Ultimate SharePoint 2007 Virtual Machine (VHD)

I maintain a local virtual machine on my laptop to evaluate, explore, code, and learn.    It’s one of my best tools and I find it incredibly useful each day.    It also needs refreshing and upkeep like any other technology.    Patches, new features, and experience compel me to make adjustments as time goes forward.   

 

I’ve completed my latest build and wanted to lay out the specifications here in case it’s helpful to other people building a similar virtual machine for their own work.   Admins, developers, and even business analysts can benefit from having a local fully autonomous and fully featured SharePoint server.

 

image

 

VHD Format
Ready for immediate use on any VM system
WinRAR split across 20 files (700 MB) for a total 13.2 GB download with a built in EXE extractor.   No need to have WinRAR for extraction.
NoteNo integration services are pre-loaded.   If you’re using Microsoft Virtual PC, VMWare, or Hyper-V these come with an option to load integration for a smoother experience working inside of the running guest VM (moues pointer, disk drives, keyboard shortcuts, etc.)

Applications Installed
Adobe Reader 9.1.0
Adobe Flash for IE
IE 8.0
IE Developer Toolbar
Notepad 2.0
Performance Point Server 2007 – Planning and Monitoring Servers
Office 2007 Professional
Office Save as PDF Add-In
Office Groove 2007
Outlook 2007 with email profile configured (workflow / alert demos)
SharePoint Designer 2007
Visio 2007
Project Professional 2007
iFilter pack for Office 2007 formats
Visual Studio 2008 Team Suite Edition  (incl Architecture, Database, Development, and Test)
Visual Studio Tools for Office (VSTO)
Visual Studio Add-In for MS Chart 3.5
Visual Studio Add-In for WSS Extensions v1.3
SDK – WSS CHM Documentation
SDK – MOSS CHM Documentation
Exam Diff Pro with right click integration and plugins for comparing PDF, XLS, DOC, etc.
SQL Server 2005 Enterprise Edition – with Database, Analysis, Reporting, and Integration
SQL Server Reporting Servers – BOTH native and integrated instances
SQL Server Management Studio – Full
SQL Profiler
SQL Sample Databases – Adventure Works, Northwind, Pubs
SQLCMD
SharePoint Server 2007 Enterprise Edition
Windows SharePoint Services patched to August 09 Cumulative Update (12.0.6514)
STSADMWin – GUI for STSADM command line to avoid typos and speed up routine tasks
Filezilla – Free FTP client
MagicDisc – Can host ISO files as drive letters
ZoomIt – Great for presentations!   Zooms to one part of the screen for easy back-of-the-room reading
TreeSize Professional – Show disk consumption by folder branch
IIS 6.0 Resource Kit
IIS 6.0 Diagnostic Kit
SharePoint Manager 2007
Stramit CAML Viewer 2007
Enterprise Library 3.1
SpsDev.com ULS Log Reader
SharePoint Skinner

O/S Installed
Windows Server 2003 SP2 Enterprise Edition x86
Single C: partition expandable up to 30GB with 10GB free space
Defragged already
Active Directory
POP3 and SMTP email for local "training.corp" domain
"administrator@training.corp" is the default email address for TRAININGADMINISTRATOR
Netmon 3.3
Visual Round Trip Analyzer
Windows 2003 Server Resource Kit
CmdHere right click menu integration
Windows Automatic Updates are Disabled to avoid surprises and let you manage manually

 

image

 

image

image

image

image

image

image

image

image

image

© Copyright 2016
@ SPJeff

Return to Top ▲Return to Top ▲