<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:copyright="http://blogs.law.harvard.edu/tech/rss" xmlns:image="http://purl.org/rss/1.0/modules/image/">
    <channel>
        <title>Misc.</title>
        <link>http://www.rickgaribay.net/category/7.aspx</link>
        <description>Misc.</description>
        <language>en-US</language>
        <copyright>Rick G. Garibay</copyright>
        <managingEditor>rick@rickgaribay.net</managingEditor>
        <generator>Subtext Version 1.9.5.176</generator>
        <item>
            <title>Paul Newman Jan 26, 1925 - Sept 26, 2008</title>
            <link>http://rickgaribay.net/archive/2008/09/27/paul-newman-jan-26-1925---sept-26-2008.aspx</link>
            <description>&lt;p&gt;I very seldom write on personal topics here, but I am very saddened to make an exception today.&lt;/p&gt;  &lt;p&gt;Paul Newman was a remarkable human being that I have admired as long as I can remember. His wit, charm, kindness and humility are traits that I have always looked up to him for (OK, he was very, very cool too). &lt;/p&gt;  &lt;p&gt;In addition to being a fantastic actor, starring in some of my favorite films such as "Butch Cassidy and the Sundance Kid", "Cool Hand Luke" and "The Sting" (if you haven't seen these, I highly recommend you do one day), he was an avid philanthropist, founding The &lt;a href="http://newmansown.com"&gt;Newman's Own Foundation&lt;/a&gt; in 1982. The Newman's Own Foundation oversees the "&lt;a href="http://newmansown.com"&gt;Newman's Own&lt;/a&gt;" product line which donates every dime of profit to charity, with donations in excess of $250 million. He also founded the "&lt;a href="http://www.holeinthewallcamps.org/"&gt;Hole in the Wall Camps&lt;/a&gt;", which offers a respite for very ill children who can go to camp to forget about their illness and just be kids for a few days.&lt;/p&gt;  &lt;p&gt;I remember watching an interview on Letterman a couple of years ago. David was asking him about some of his passions, which included automobile racing and beer. In that interview, Paul referred to beer as "the common man's drink". This is what always impressed me the most about Paul Newman. Despite his tremendous success as an actor in the hay day of Hollywood, he never lost touch with himself, his family or his place on this earth. He had this keen awareness that in addition to very hard work, success can be attributed to luck just as much as one's own efforts.&lt;/p&gt;  &lt;p&gt;So today, with great sadness, I raise a pint to celebrate the life and light of Paul Newman who despite being deeply missed, has left a lasting impression in my life and a legacy that will continue to give for years to come.  &lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/205.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/09/27/paul-newman-jan-26-1925---sept-26-2008.aspx</guid>
            <pubDate>Sat, 27 Sep 2008 15:53:08 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/205.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/09/27/paul-newman-jan-26-1925---sept-26-2008.aspx#feedback</comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/205.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/205.aspx</trackback:ping>
        </item>
        <item>
            <title>Using PowerShell to Manage Network Interfaces and Windows Services</title>
            <link>http://rickgaribay.net/archive/2008/09/26/using-powershell-to-manage-network-interfaces-and-windows-services.aspx</link>
            <description>&lt;p&gt;PowerShell is a new scripting language that allows you to interact with applications, services and objects as objects. It is a .NET application which shells commands out on your behalf. This is very powerful, because it allows you to leverage the strengths of an object oriented model within your scripting tasks with a very terse, yet simple scripting language. Because it is written in .NET, you can access .NET types, objects and WMI objects from a command prompt.&lt;/p&gt;  &lt;p&gt;My current workstation runs Windows Server 2008 Standard Edition with Hyper-V. I use the host/parent partition as my office, and have a number of child partitions that are integrated into a Windows Server 2008 Domain. Needless to say, this configuration gives me everything I need to develop, test and integrate multiple Server OS', platforms and technologies, and is my environment of choice for developing production code. It still amazes me how far we've come in such a short period of time. Not too long ago, I remember setting up similar lab environments at home running Windows NT 4 and Windows Server 2000 on dedicated physical machines.&lt;/p&gt;  &lt;p&gt;Anyway, I have to say that I am absolutely delighted with my environment, but it took me some time and effort to learn how to tune Server 2008, and this is all well documented in previous posts. One of the the things that I do to keep performance high is that I only have the 3 services required for Hyper-V running when I need them. In other words, if I am only working with email and writing documents or design drawings, I don't need to have the Hyper-V services running because they are resource intensive. In addition, I only want my loopback adapter (that provides me with a virtual LAN for all of the child partitions on my domain to communicate) enabled when I need it to be. One reason for this, is that if I leave my loopback on and reboot, boot times can take up to 10 minutes because the loopback is configured to use my domain controller as the primary DNS server, which is a VM. Because the DNS Server only runs when my Domain Controller VM  is up and running, the VM will only come up when I start it. As a result, Windows tries and tries to reach the DNS server for the Loopback adapter until it finally gives up (If anyone knows how to change this timeout, please shoot me a note or post a comment).&lt;/p&gt;  &lt;p&gt;So, I only want Hyper-V services running when I need to work in my development environment, and I don't want my loopback enabled unless it needs to be. For a while, I was managing this as follows...&lt;/p&gt;  &lt;p&gt;First, I set the following services to "Manual", so that they do not start automatically:&lt;/p&gt;  &lt;ul&gt;   &lt;li&gt;vmms: Hyper-V Virtual Machine Management &lt;/li&gt;    &lt;li&gt;vhdsvc: Hyper-V Image Management Service &lt;/li&gt;    &lt;li&gt;nvspwmi: Hyper-V Networking Management Service &lt;/li&gt; &lt;/ul&gt;  &lt;p&gt;The service names are a bit obscure, but the "friendly" names are pretty self explanatory. When I need to start my development environment, I would go into Server Manager, and start each service one by one.&lt;/p&gt;  &lt;p&gt;Next, I would enable my loopback adapter so that my child partitions can communicate with each other.&lt;/p&gt;  &lt;p&gt;All together, this resulted in a number of clicks, which was somewhat mundane to do every time. Worse, once I enabled the loopback, I often would forget to disable it before shutting down (remember, servers running Hyper-V do not support hibernation). For a while, I thought about writing myself a sticky note and posting it to my forehead so that I would not forget to disable the loopback, and finally, I decided to create an easy button for starting and stopping my development environment.&lt;/p&gt;  &lt;p&gt;This is where Powershell comes in.&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Using PowerShell to Query and Manage Network Adapters&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;The first thing I did was figure out how to talk to my network adapters so that I could enable and disable my loopback as needed. It turns out that Microsoft provides a WMI object called &lt;strong&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/aa394216(VS.85).aspx"&gt;Win32_NetworkAdapter&lt;/a&gt;. &lt;/strong&gt;The object exposes a bunch of properties for working with an instance of a Win32_NetworkAdapter:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="358" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;In addition, there are 4 public methods that are exposed, and well &lt;a href="http://msdn.microsoft.com/en-us/library/aa394216(VS.85).aspx"&gt;documented&lt;/a&gt; as shown below:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_3.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="100" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_3.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;To enumerate all network adapters on my host/parent partition, I issued the following command:&lt;/p&gt;  &lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, 'Courier New', courier, monospace; background-color: #f4f4f4"&gt;   &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, 'Courier New', courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;     &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, 'Courier New', courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&lt;span style="color: #606060"&gt;   1:&lt;/span&gt; Get-wmiobject win32_NetworkAdapter | format-table &lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;PowerShell lists each adapter and certain properties in a tabular format because I added a pipe and format-table parameter:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_4.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="265" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_4.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;To identify the instance that corresponds to my loopback, I simply need to find the "Internal VLAN" instance above, which has a DeviceID of 17:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_5.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="155" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_5.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Next, I want to retrieve an instance of the adapter with a DeviceId of 17, so I issue the following statement:&lt;/p&gt;

&lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, 'Courier New', courier, monospace; background-color: #f4f4f4"&gt;
  &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, 'Courier New', courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;
    &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, 'Courier New', courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&lt;span style="color: #606060"&gt;   1:&lt;/span&gt; Get-WmiObject win32_networkadapter | where {$_.DeviceId -eq 17}&lt;/pre&gt;
  &lt;/div&gt;
&lt;/div&gt;

&lt;p&gt;The where keyword uses a bracketed expression to evaluate the condition. The "$" is a temporary variable, which is similar to the "this" keyword in C#, which provides context for the current instance. The "-eq" operator is the equality operator in PowerShell. So, we are querying all adapters for the adapter with a DeviceID equal to 17. The above command returns the following:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_6.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="171" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_6.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Notice that each property is an actual documented property of the WIN32_NetworkAdapter object. If we have access to properties, it would be helpful to determine if the adapter is enabled or disabled. To do this, I assign the adapter to a variable called $adapter as shown below, and then I get the value of the Availability property:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_7.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="62" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_7.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;The value of the Availability property is 3. Referring to the WIN32_NetworkAdapter documentation, I can see that a status of 3 indicates that adapter is on, and running on full power.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_8.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="421" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_8.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Are you getting the hang of it yet? Hopefully, the interaction with PowerShell should feel object-oriented because it is! We are getting a reference to the WMI shell of the adapter and then using it's get accessors to get the value of the public properties. So, if we can get a reference to the adapter, get properties, we should be able to call methods on it, right?&lt;/p&gt;

&lt;p&gt;To disable the adapter, I simply call the Disable() method on my $adapter variable:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_9.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="247" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_9.png" width="360" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Now, to confirm that the adapter is disabled, you can look at Network Connections and you will see that the Status is in fact Disabled. To do this programmatically via PowerShell, you can use the ConfigManagerErrorCode property which is also documented. Get a new instance of the adapter, and call the ConfigManagerErrorCode property on it as shown below:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_10.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="74" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_10.png" width="471" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;A return code of 22 can be matched to the table in the MSDN documentation:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_11.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="51" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_11.png" width="625" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;Now, enable the adapter by calling the Enable() method:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_12.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="209" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_12.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;A return code of 0 indicates that the adapter is enabled, and working properly:&lt;/p&gt;

&lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_13.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="141" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_13.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;As you can see, PowerShell is a very easy to use, yet powerful tool for managing system objects in an object-oriented manner. You don't need to worry about writing VBScript or C# to accomplish simple administrative tasks such as enabling and disabling a network adapter. As you might imagine, the real power comes in being able to run a series of PowerShell commands in a batch, perhaps at the click of the button. This is exactly what I'll cover next. &lt;/p&gt;

&lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Using PowerShell to Query and Manage Windows Services&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;You'll recall that I only want the 3 Hyper-V services to run when I need them, so what I want to do is create an "easy button" to toeggle my development environment on and off.&lt;/p&gt;

&lt;p&gt;The "On" should:&lt;/p&gt;

&lt;ul&gt;
  &lt;li&gt;Enable my Internal VLAN Adapter &lt;/li&gt;

  &lt;li&gt;Start the Hyper-V Virtual Machine Management &lt;/li&gt;

  &lt;li&gt;Start the Hyper-V Image Management Service &lt;/li&gt;

  &lt;li&gt;Start the Hyper-V Networking Management Service &lt;/li&gt;

  &lt;li&gt;Get me a cup of Starbucks coffee &lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The "Off" Button should:&lt;/p&gt;

&lt;li&gt;Disable my Internal VLAN Adapter &lt;/li&gt;

&lt;li&gt;Disable the Hyper-V Virtual Machine Management &lt;/li&gt;

&lt;li&gt;Disable the Hyper-V Image Management Service &lt;/li&gt;

&lt;li&gt;Disable the Hyper-V Networking Management Service 
  &lt;p&gt; &lt;/p&gt;

  &lt;p&gt;I've already covered how to manage network adapters using PowerShell as a primer, so I'll jump right into working with Windows Services. As with any program, sometimes it is helpful to group commands into a subroutine. In PowerShell, these functions are referred to as cmdlets (prounounced "commandlets"). You may not realize this, but you've already been working with cmdlets if you've tried the commands I covered above on your own machine. The get-wmiobject command is actually a cmdlet that provides a reference to the WMI object specified as the parameter. You could accomplish this without the cmdlet, but why would you want to?&lt;/p&gt;
&lt;/li&gt;

&lt;li&gt;
  &lt;p&gt;Fortunately, a cmdlet is also available for working with Windows Services: get-service.&lt;/p&gt;

  &lt;p&gt;To get information about a particular service, simply call get-service with the service name. The actual service name of the Hyper-V Virtual Machine Management service is "vmms", so issuing the get-service vmms command returns a few properties including the Name, DisplayName and Status of the service.&lt;/p&gt;

  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_14.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="92" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_14.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

  &lt;p&gt;Starting and stopping the Hyper-V Virtual Machine Management service is as simple as calling the appropriate method: Stop() to stop the service and Start() to start it. While you could use a variable called $service to store the reference to the service object, an abbreviated way to accomplish this is shown below:&lt;/p&gt;

  &lt;div style="border-right: gray 1px solid; padding-right: 4px; border-top: gray 1px solid; padding-left: 4px; font-size: 8pt; padding-bottom: 4px; margin: 20px 0px 10px; overflow: auto; border-left: gray 1px solid; width: 97.5%; cursor: text; max-height: 200px; line-height: 12pt; padding-top: 4px; border-bottom: gray 1px solid; font-family: consolas, 'Courier New', courier, monospace; background-color: #f4f4f4"&gt;
    &lt;div style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, 'Courier New', courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;
      &lt;pre style="padding-right: 0px; padding-left: 0px; font-size: 8pt; padding-bottom: 0px; margin: 0em; overflow: visible; width: 100%; color: black; border-top-style: none; line-height: 12pt; padding-top: 0px; font-family: consolas, 'Courier New', courier, monospace; border-right-style: none; border-left-style: none; background-color: #f4f4f4; border-bottom-style: none"&gt;&lt;span style="color: #606060"&gt;   1:&lt;/span&gt; (get-service vmms).Stop()&lt;/pre&gt;
    &lt;/div&gt;
  &lt;/div&gt;

  &lt;p&gt; &lt;/p&gt;

  &lt;p&gt;Now, when you issue the get-service vmms command, you can see that the Status property is "Stopped":&lt;/p&gt;

  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_15.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="165" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_15.png" width="640" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

  &lt;p&gt;Starting the service back up is as simple as calling Start() on the cmdlet expression:&lt;/p&gt;

  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_16.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="123" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_16.png" width="510" border="0" /&gt;&lt;/a&gt;  &lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt;

  &lt;p&gt;&lt;strong&gt;&lt;font size="3"&gt;Building the "Easy Buttons"&lt;/font&gt;&lt;/strong&gt;&lt;/p&gt;

  &lt;p&gt;There may very well be a more sophisticated way to do this, but I created two batch files, one called "Start.bat" and the other called "Stop.bat" and placed them in my documents folder. Each file contains the appropriate PowerShell syntax as shown below:&lt;/p&gt;

  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_17.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="107" alt="image" src="http://rickgaribay.net/Images/CustomContent/UsingPowerShelltoManageNetworkInterfaces_10DB3/image_thumb_17.png" width="716" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;

  &lt;p&gt;&lt;font size="1"&gt;Note, to re-use variables across PowerShell sessions, you must first configure a PowerShell profile: &lt;/font&gt;&lt;a title="http://msdn.microsoft.com/en-us/library/bb613488(VS.85).aspx" href="http://msdn.microsoft.com/en-us/library/bb613488(VS.85).aspx"&gt;&lt;font size="1"&gt;http://msdn.microsoft.com/en-us/library/bb613488(VS.85).aspx&lt;/font&gt;&lt;/a&gt;&lt;/p&gt;

  &lt;p&gt;Next I created two desktop shortcuts, appropriately named "Start" and "Stop" and set the target to each corresponding file.&lt;/p&gt;

  &lt;p&gt;Now, I have two "Easy Buttons" for toggling my development environment on and off. While I can't guarantee that I won't forget to press the "off  button" before shutting down, it is a heck of a lot easier than going through the contortions manually.&lt;/p&gt;

  &lt;p&gt;One last note. If anyone finds or builds a cmdlet that runs to Startbucks and picks up a medium drip with 1.5 Sweet &amp;amp; Low and delivers it to my client site, please let me know :-)&lt;/p&gt;
&lt;/li&gt;&lt;img src="http://rickgaribay.net/aggbug/204.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/09/26/using-powershell-to-manage-network-interfaces-and-windows-services.aspx</guid>
            <pubDate>Fri, 26 Sep 2008 22:02:26 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/204.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/09/26/using-powershell-to-manage-network-interfaces-and-windows-services.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/204.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/204.aspx</trackback:ping>
        </item>
        <item>
            <title>Hyper-V Parent Partition Filesytem Access Not Working?</title>
            <link>http://rickgaribay.net/archive/2008/09/05/hyper-v-parent-partition-filesytem-access-not-working.aspx</link>
            <description>&lt;p&gt;With Hyper-v, if you want to access the parent partition (host) file system, or attached USB drives, the only way to do so is through a UNC or IP connection from the child partition (guest) to the parent (host). To do so, you will have to create a network and bind it. You can read about how to setup an Internal Network in a previous post.&lt;/p&gt;  &lt;p&gt;At times, you may find that despite being able to ping the parent from the child, and even resolve DNS names, you get a networking error:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/HyperVParentPartitionNetworking_845E/image.png"&gt;&lt;img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="76" alt="image" src="http://rickgaribay.net/Images/CustomContent/HyperVParentPartitionNetworking_845E/image_thumb.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;For whatever reason, I have found that restarting the "Server" service on the parent resolves the issue. As you might imagine, the Server service is responsible for managing file sharing, among other things.  What is strange is that it is already running, but every time I run into this issue, restarting the service is the fix.&lt;/p&gt;  &lt;p&gt;Hope this helps someone out who could otherwise spend hours pulling their hair out debugging networking issues.&lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/201.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/09/05/hyper-v-parent-partition-filesytem-access-not-working.aspx</guid>
            <pubDate>Fri, 05 Sep 2008 16:30:27 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/201.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/09/05/hyper-v-parent-partition-filesytem-access-not-working.aspx#feedback</comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/201.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/201.aspx</trackback:ping>
        </item>
        <item>
            <title>Hyper-V Internal Virtual Network- The New Loopback</title>
            <link>http://rickgaribay.net/archive/2008/08/22/hyper-v-internal-virtual-network--the-new-loopback.aspx</link>
            <description>&lt;p&gt;In Virtual PC and Virtual Server, one way to build a private network of VMs was to create a loopack adapter using the Microsoft Loopback Adapter. This allowed you to specify an internal IP address (such as 192.168.1.1) and as long as the IP and subnet mask on the VMs were configured properly, you could communicate from one VM to another. This is such a common scenario, that I often wondered why one had to go through the contortion of creating a loopback adapter. I am not a Virtual PC/Server or Hyper-V expert, but the need for this seems to be quite common.&lt;/p&gt;  &lt;p&gt;Well, leave it to Microsoft to eventually comooditize key user stories. &lt;/p&gt;  &lt;p&gt;With Hyper-V, creating a network of VMs is as simple as creating an Internal Virtual Network and binding it to each of the child partitions. When you do this, an internal virtual NIC is created on the parent partition which you can then configure with the appropriate subnet. Match the settings to each child partition in your network, and viola, you are golden.&lt;/p&gt;  &lt;p&gt;To create an Internal Virtual Network, click on "Virtual Network Manager" in Hyper-V manager.&lt;/p&gt;  &lt;p&gt;In Virtual Network Manager, select Internal in the list of network types and click Add:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/InternalVirtualNetworkTheNewLoopback_E451/image.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="227" alt="image" src="http://rickgaribay.net/Images/CustomContent/InternalVirtualNetworkTheNewLoopback_E451/image_thumb.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;Give the new Virtual Network a name and click OK.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/InternalVirtualNetworkTheNewLoopback_E451/image_3.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="226" alt="image" src="http://rickgaribay.net/Images/CustomContent/InternalVirtualNetworkTheNewLoopback_E451/image_thumb_3.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;That's it. You're done.&lt;/p&gt;  &lt;p&gt;Of course, you must bind the new Virtual Network to your Virtual Machine. To do so, select the Virtual Machine within Hyper-V Manager, click Settings, and select the name of the network you just created.&lt;/p&gt;  &lt;p&gt;On a side note, I learned about this by unlearning what I had already learned with Virtual PC. I had actually gone through the process of creating a loopback adapter when I realized that I get one for free by creating an Internal Virtual Network. It is amazing how so often, to get the most out of new technology, you must first unlearn old tricks.&lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/196.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/08/22/hyper-v-internal-virtual-network--the-new-loopback.aspx</guid>
            <pubDate>Sat, 23 Aug 2008 05:36:20 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/196.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/08/22/hyper-v-internal-virtual-network--the-new-loopback.aspx#feedback</comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/196.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/196.aspx</trackback:ping>
        </item>
        <item>
            <title>Merging Differencing Disks with Hyper-V</title>
            <link>http://rickgaribay.net/archive/2008/08/15/merging-differencing-disks-with-hyper-v.aspx</link>
            <description>&lt;p&gt;A differencing disk is a disk that is a child of a parent disk. Differencing disks are very helpful in keeping disk images small, manageable and consistent, because you can create a base parent disk- such as a Windows 2008 Standard base image- and use it as the foundation for all other guest virtual machines and disks that will be based on Windows Server 2008. For example, I have a Windows Server 2008 guest that I use exclusively as sandbox for development. I am in the process of building out another guest based on Windows Server 2008 that will be for some TFS 2008 demos that I am working on for an upcoming series of talks. Rather than copy the Windows Server 2008 guest VPC over and over again, I can simply create one differencing disk for my development environment role and one for my TFS role. The result is a VHD that represents the intersection of the base/parent disk (in this case, a barebones install of Windows Server 2008 Standard) and any additional software I've installed or configuration changes I have made. This not only conserves disk space, but also saves me a lot of time in copying hefty giga-some-odd vhds around.&lt;/p&gt;  &lt;p&gt;Sometimes it is necessary to merge a differencing disk back to it's parent or into a new disk. For example, you may be moving VHDs around as I did recently to a new, high speed E-SATA drive. My old drive hosted a vhd that I used as my development sandbox that used a parent on the old disk. I certainly don't want to depend on my clunky old USB 2.0 drive for the parent (the IO cost alone would be just silly), and at a minimum, there is state on the differenced guest OS that I do not want to lose.  &lt;/p&gt;  &lt;p&gt;The first thing to do is copy over the parent VHD, create a new differencing disk based on the same parent, but in the new location.&lt;/p&gt;  &lt;p&gt;Next, since the differenced guest VHD has state that you want to move over (lest you lose it), it is necessary to merge the state of the "old" differenced guest VHD with the new copy. To do so, under Server Manager, in the Hyper-V Manager, click "Edit Disk", and locate the disk that you want to merge into a new differenced disk:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image.png"&gt;&lt;img style="border-right: 0px; border-top: 0px; border-left: 0px; border-bottom: 0px" height="193" alt="image" src="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_thumb.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;On the next screen, under Action, select "Merge":&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_3.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="179" alt="image" src="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_thumb_3.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;Select "To a new virtual disk", and choose a name and path for the new disk that you created in the initial copy:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_4.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="178" alt="image" src="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_thumb_4.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt; The "old" differenced disk, which is based on the original parent disk plus state from the "old" differenced disk is merged into the new disk on the drive you specified:&lt;/p&gt;  &lt;p&gt;&lt;a href="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_5.png"&gt;&lt;img style="border-top-width: 0px; border-left-width: 0px; border-bottom-width: 0px; border-right-width: 0px" height="178" alt="image" src="http://rickgaribay.net/Images/CustomContent/MergingDifferencingDiskswithHyperV_11893/image_thumb_5.png" width="244" border="0" /&gt;&lt;/a&gt; &lt;/p&gt;  &lt;p&gt;That's all there is to it. Differencing is a powerful feature in virtualization, and there is very nice support for migration of differenced disks right within the Server Manager.&lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/195.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/08/15/merging-differencing-disks-with-hyper-v.aspx</guid>
            <pubDate>Sat, 16 Aug 2008 06:26:51 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/195.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/08/15/merging-differencing-disks-with-hyper-v.aspx#feedback</comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/195.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/195.aspx</trackback:ping>
        </item>
        <item>
            <title>Windows Server 2008 Update</title>
            <link>http://rickgaribay.net/archive/2008/07/25/windows-server-2008-update.aspx</link>
            <description>&lt;p&gt;OK. Honeymoon is over. I have been experiencing some degradation in performance/responsiveness recently, so started looking for optimizations which have had a positive result.&lt;/p&gt;  &lt;p&gt;Here is what I have done:&lt;/p&gt;  &lt;ol&gt;   &lt;li&gt;Set any non-essential services to "Manual" and stop them. This has been somewhat of a trial and error exercise, but I've been able to free up some memory and CPU utilization in the process.&lt;/li&gt;    &lt;li&gt;Adjust Visual Effects for Best Performance. This can be accomplished by going to to System Settings-&amp;gt;Advanced -&amp;gt;Performance Tab-&amp;gt;Settings Button-&amp;gt; Visual Effects. The only visual effect that I couldn't live without was smooth fonts, so I turned it on.&lt;/li&gt;    &lt;li&gt;Uninstalled Trillian. This thing does not seem to play well with Windows Server 2008 64-bit as it was constantly churning CPU and memory. I noticed a marked improvement in CPU utilization when I turned it off, and have since removed it thanks to this &lt;a href="http://www.techspot.com/blog/129/how-to-run-windows-live-messenger-on-windows-xp-x64/"&gt;post&lt;/a&gt; which pointed me to a previous version of Windows Live Messenger which installed just fine.&lt;/li&gt;    &lt;li&gt;I also enabled "Superfetch" per this &lt;a href="http://blogs.msdn.com/vijaysk/archive/2008/02/11/using-windows-server-2008-as-a-super-desktop-os.aspx"&gt;post&lt;/a&gt;.&lt;/li&gt; &lt;/ol&gt;  &lt;p&gt;I am also finding that my USB 2.0 hardrive is becoming a bottleneck since I use it to store all of my VHD files. I might go out and get an ESATA drive this weekend and see if I notice a difference.&lt;/p&gt;  &lt;p&gt;I will report back in a few days with an update.&lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/194.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/07/25/windows-server-2008-update.aspx</guid>
            <pubDate>Fri, 25 Jul 2008 15:46:43 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/194.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/07/25/windows-server-2008-update.aspx#feedback</comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/194.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/194.aspx</trackback:ping>
        </item>
        <item>
            <title>Changing the Internet Explorer Homepage on Windows Mobile 6 ATT&amp;T Devices</title>
            <link>http://rickgaribay.net/archive/2008/04/04/ie-homepage-on-windows-mobile-6-attt-devices.aspx</link>
            <description>&lt;p&gt;A very annoying problem I encountered with my BlackJack II device is that the IE homepage is locked to a crappy ATT&amp;amp;T media net portal. There is no UI option to change it, and this is really aggrevating.&lt;/p&gt;
&lt;p&gt;Anyway, I figured out how to change the home page to whatever I want, and thought I'd share with anyone else who might be as frustrated as I was.&lt;/p&gt;
&lt;p&gt;First, download a Windows Mobile registry editor like the one found here: &lt;font face="Arial"&gt;&lt;a href="http://www.breaksoft.com/Blog/Utilities/2005/1/Mobile_Registry_Editor.aspx"&gt;http://www.breaksoft.com/Blog/Utilities/2005/1/Mobile_Registry_Editor.aspx&lt;/a&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Once you install the editor, connect your mobile device via USB cable and ensure you can establish an activesync connection. &lt;/p&gt;
&lt;p&gt;Next, launch the editor and browse to HKEY_LOCAL_MACHINE\Software\Microsoft\Internet Explorer\AboutURLs in the registry editor.&lt;/p&gt;
&lt;p&gt;Update the \home and home_0409 keys to any URL you'd like.&lt;/p&gt;
&lt;p&gt;I think Windows Mobile 6 is a great improvement over Windows Mobile 5, but I would like to understand the rationale for locking out the ability to change the home page URL on the BlackJack 2. I imagine it is an ATT&amp;amp;T tweak, and nothing to do with Windows Mobile 6, but if anyone has any insight here, I'd appreciate it.&lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/174.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay - The more I learn, the less I kno</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/04/04/ie-homepage-on-windows-mobile-6-attt-devices.aspx</guid>
            <pubDate>Sat, 05 Apr 2008 04:11:11 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/174.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/04/04/ie-homepage-on-windows-mobile-6-attt-devices.aspx#feedback</comments>
            <slash:comments>5</slash:comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/174.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/174.aspx</trackback:ping>
        </item>
        <item>
            <title>Silverlight 2.0 Service Integration: Three Steps Forward, Two Steps Back</title>
            <link>http://rickgaribay.net/archive/2008/03/07/silverlight-2.0-service-integration-three-steps-forward-two-steps-back.aspx</link>
            <description>&lt;p&gt;&lt;font face="Verdana"&gt;Every time a brand new technology comes out, the focus is always on the problems that it is specifically designed to solve. Beneath the patina of a sexy new technology are the result of compromises that had to be made for which very mature, sophisticated stories already exist.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;Such is the case, in my opinion with Silverlight 2.0. While the new version boasts some significant improvements with new controls, improved designer tool support and richer FCL support, the integration story is still a bit weak. Although there are some very important key improvements since 1.1, including WCF support (which is limited as we'll see later), there are some aspects of integration that are confusing, if not downright frustrating.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt; &lt;br /&gt;
&lt;strong&gt;WCF SOAP Support&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;Silverlight 2.0 now supports Windows Communication Foundation, and allows you to add a reference to a service endpoint using the same convention for any client. Unfortunately, the only binding currently supported for working with SOAP services is BasicHttpBinding. While embracing WS-I Basic Profile 1.0 is great from a standardization perspective, it is unfortunate that some of the WS-* features that I have come to take for granted including WS-AtomicTransactions and WS-Reliable Messaging are neither supported, nor officially planned for support. I am confident that this is coming; it is just not high enough on the team's product backlog.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;What did very much interest me is that only asynchronous invocation of WCF proxies is supported. This is interesting to me on two levels. First, because Silverlight CLR runs on the browser thread, the team was rightfully concerned with long running synchronous calls that would essentially block the UI thread. However, when I asked the Product Manager leading the talk if the threads for doing background work come from the thread pool or are marshaled back and forth from the browser to native threads, he wasn't sure. This leads me to the second interesting point which is this. If Microsoft is prescribing an asynchronous programming model for WCF because it simply has an opportunity to do so, then I half-heartedly applaud them for doing so if it due to architectural limitation of Silverlight. What I mean is that I think it is time for all architects and developers to think more about pub-sub, and if this is Microsoft putting a stake in the ground, then that is fine, but you should still give developers the option to go synchronous. I'd be interested in anyone's thoughts on this because it is a bit irksome:&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt; var proxy = new ShoppingServiceClient();&lt;br /&gt;
proxy.GetProductsCompleted += new EventHandler&amp;lt;GetProductsCompletedEventArgs&amp;gt;(proxy_GetProductsCompleted);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;proxy.GetProductsAsync(“book”);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;void proxy_GetProductsCompleted(object sender, GetProductsCompletedEventArgs e)&lt;br /&gt;
{&lt;br /&gt;
 // Process response…&lt;br /&gt;
}&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt; From an encoding perspective, WCF support is strictly SOAP based which makes sense. However, keep in mind that in Silverlight 1.1, JSON was the first-class seralization format and this is a clear departure from that. Again, this begs the question as to whether the choice to support SOAP natively was intentional, or a direct result of providing a WCF integration story. To be honest, JSON doens't make sense in pure Silverlight scenarios because there is no JavaScript interop happening. It’s all Silverlight CLR. That said, there are some significant performance benefits to JSON which leaves me guessing as to whether it will be supported as an alternative WCF encoding in the future.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;Unfortunately, Faults are not supported, and I don't really understand why.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt; &lt;strong&gt;HTTP &amp;amp; REST Support&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;I have some opinions on REST that are probably quite bellicose, so I will save them for another post. That said, Silverlight 2.0 does support basic HTTP invocation via GET and POST for low-REST scenarios. The weapon of choice for "Human Readable Documentation" services is a class called WebClient in the System.Net namespace which basically takes a URL and returns a response. While there is no hard and fast rule about what a REST service provides, assuming that it is XML you can use XMLReader and XMLWriter along with Linq to XML to work with XML results. Now, if you are really a contortionist, are using REST and want serialization support, you can of course build out your entities to map to the XML coming back and deserialize the response stream using XmlSerializer, but I just don't understand why you would go through all this trouble when SOAP tooling does it all for you. OK, I slipped. I couldn't help myself, sorry.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;&lt;strong&gt;Sockets/TCP Support&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;Scott Guthrie makes mention of support for sockets on his blog (http://weblogs.asp.net/scottgu/archive/2008/02/22/first-look-at-silverlight-2.aspx ), but this wasn't covered at any of the sessions I attended. &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;&lt;strong&gt;Security&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;This was the most vague aspect of the sessions I attended because the focus was not on authentication or authorization, but rather on a flavor of code access security that determines whether a service can be called from a client from another domain and vice-a-versa. &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;There was mention that if you enable ASP.NET Compatibility in your WCF service, you can glean the identity of the user running the browser via the canonical HttpContext.CurrentUser property, but it was unclear to me if the browser identity is that of the user logged in to the machine, what the implications of enabling/disabling Integrated Windows Authentication on IE browsers, and how this would work with non-IE browsers.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;This is important to me from a resource access perspective. If I am using Silverlight to communicate with a service that isn't just wide open, I am going to want to perform some authorization to ensure that at the very least, I can support a trusted subsystem model, because I don't want to deal with n potential users.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;&lt;strong&gt;Summary&lt;/strong&gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt;To wrap up, I think there are exciting things to come with Silverlight 2.0, and I think it is going to challenge many of us to think about how we integrate with the cloud. I see a trade-off, if not a gamble happening between SOAP and REST within the Silverlight team, and the winner may depend on which standard is considered the most "weby". This concerns me because of how fickle the web can be, and I'd hate to see the tremendous gains made around integration and SOA, particularly with WCF, get lost in the hype. In the end, I think that this one will be ultimately decided by the constituents that make up this new landscape of information democratization known as Web 2.x.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt; &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Verdana"&gt; &lt;br /&gt;
&lt;/font&gt;&lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/171.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay - The more I learn, the less I kno</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/03/07/silverlight-2.0-service-integration-three-steps-forward-two-steps-back.aspx</guid>
            <pubDate>Fri, 07 Mar 2008 16:30:19 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/171.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/03/07/silverlight-2.0-service-integration-three-steps-forward-two-steps-back.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/171.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/171.aspx</trackback:ping>
        </item>
        <item>
            <title>Silverlight 2.0 &amp; The Future of Software as a Service</title>
            <link>http://rickgaribay.net/archive/2008/03/05/silverlight-2.0--the-future-of-software-as-a-service.aspx</link>
            <description>&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;First and foremost, I am not a UI expert, and to be honest, I don't remember the last time I wrote UI code for production. I gravitated to the cloud a couple of years ago. Like most developers, I started out building primitive front-end applications that got more sophisticated over time. Whether that meant moving from VBScript to .NET components, or .NET components to WS-* services, my passion today is distributed enterprise architecture vis-a-vis SOA. I *could* do UI development if I had to. I might recommend some patterns such as output caching and MVC, but from an implementation and design perspective, I would not be the strongest contributor on your team.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;So, what is a SOA guy doing at MIX 08? Good question.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;strong&gt;&lt;font face="Verdana"&gt;Silverlight 2.0&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;A lot has happened since I was out here in 07, and the Sliverlight platform has matured in many areas, including controls, UI and Framework Class Library support. As a SOA guy, my biggest interest is around how the integration story has matured in the last 12 months or so.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;font face="Verdana"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;According to Scott G's &lt;/span&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;a href="http://weblogs.asp.net/scottgu/archive/2008/02/22/first-look-at-silverlight-2.aspx"&gt;&lt;span style="COLOR: blue"&gt;blog&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style="FONT-SIZE: 9pt"&gt;, Silverlight 2 includes now includes out of the box support for calling REST, WS*/SOAP, POX, RSS, and standard HTTP services. As a WCF guy, I am particularly interested in how the WCF story has matured.&lt;/span&gt;&lt;/font&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;I also want to understand what all the REST fuss is about, and where Redmond's head is with regards to who gets the first class seat when it comes to Silverlight.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;font face="Verdana"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;Some who frequent my blog (all 3 of you) may be asking, why should I care about Silverlight? As I mentioned &lt;/span&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;a href="http://rickgaribay.net/archive/2007/01/19/UI-Matters.aspx"&gt;&lt;span style="COLOR: blue"&gt;here&lt;/span&gt;&lt;/a&gt;&lt;/span&gt;&lt;span style="FONT-SIZE: 9pt"&gt;, User Experience is going to be at the top of most CIO's hit list, just like Java, .NET, SOA and BPM have been. In addition to pillars of enterprise architecture like availability, scalability, performance, security and reliability, UX will become a competitive differentiator both in Line of Business (LOB) application scenarios as well as Business to Consumer scenarios. &lt;/span&gt;&lt;/font&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;The reason for this is ROI. If you can get a team that really understands UX to help build your user interface, your customers are going to either save money or make more money as a result of a more efficient and effective UI. &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;strong&gt;&lt;font face="Verdana"&gt;Convergence&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;We are witnessing a convergence in many dimensions. Agile development methodology recognizes how critical collaboration between customer and delivery roles is for delivering business value. Designers are joining the TEAM. Whereas in the past, a designer would throw together some wire frames and toss them over the wall to the engineering team, these role are converging, both from an individual core competency perspective as well as from a team perspective. The best designers typically come from advertising and marketing firms. They get business value because they think in terms of metrics such as impressions and click throughs. Do you see the alignment with business value? I do.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;So how does this convergence happen? Tools, tools, tools! Well, not just tools, but that is a big part of it. You need smart, capable people, and a process/methodology that supports the fluidity of interdependent disciplines.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;strong&gt;&lt;font face="Verdana"&gt;User Experience &lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;And it is not all just about eye candy either. Silverlight and WPF will make for gorgeous UIs, and that will certainly help to position UX as a critical part of any application design, but that is really more of psychological by product than a functional one. &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;For example, I can't tell you how annoying I find "Death by Flash" websites that try so hard to look sexy and cool, but have a HORRIBLE user interface. I hate them. I will choose the "low bandwidth" option any time I have a choice because I don't want to settle for form and give up function.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;User Experience is all about balancing form and function. Sounds simple, doesn't it?&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;So why Silverlight? &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;Simple. HTTP, web servers, the web, internet and intranet have become widely adopted by corporations as well as consumers for consuming and working with data. For these reasons, Click Once never really had the footprint that I would have hoped to see. If you do a comparison of the capabilities that Smart Client Click Once applications provide against a web server hosted model, particularly in intranet, enterprise scenarios, Smart Client is a no-brainer (see &lt;/font&gt;&lt;a href="http://reddevnews.com/news/devnews/article.aspx?editorialsid=255"&gt;&lt;font face="Verdana"&gt;http://reddevnews.com/news/devnews/article.aspx?editorialsid=255&lt;/font&gt;&lt;/a&gt;&lt;font face="Verdana"&gt; for my quote from MIX 07), especially from a productivity stand point. No offense to my ASP.NET and AJAX friends and colleagues, but I would rather crank out a Windows Forms app over an AJAX enabled ASP.NET app any day, especially if I am managing to my team's budget. Regardless, the reason that Silverlight is important is that CIOs and consumers understand the web. CIOs understand the deployment and hosting models and they are tried and true. Consumers understand Google and URLs. &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;For better or for worse, we will be on the web for a very long time and Microsoft gets this. Some will accuse Microsoft of being late to the game (again), but to be fair, the industry as a whole has learned much in just the last year or two. This thing called Web 2.0 apparently happened, that consumers get, but geeks such as myself tend to scratch our heads asking what this Web 2.0 thing is all about when we've been doing this stuff for years?&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;strong&gt;&lt;font face="Verdana"&gt;The Road to Software as a Service&lt;/font&gt;&lt;/strong&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;If we accept Web 2.0 for whatever it is, then I can tell you that Web 3.0 is coming, and Microsoft is ahead of the curve this time. Way ahead. &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;Why? Because CIOs are not going to give up pillars of enterprise architecture in favor of eye candy, and consumers are going to come to expect eye candy and useful user experiences the same way that CIOs expect their applications and systems to be available.&lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;Perceptions drive adoption and evangelism, and the psychological impact of a really intuitive and sexy UI cannot be underestimated. But gorgeous UIs are not enough. You need a strong services story behind it. &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;&lt;font face="Verdana"&gt;That is the key to Software and Services, which is really only a stepping stone towards truly making the transition to software as a service. &lt;/font&gt;&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 10pt; LINE-HEIGHT: normal"&gt;&lt;font face="Verdana"&gt;&lt;span style="FONT-SIZE: 9pt"&gt;I cannot think of a more productive, robust or powerful framework for realizing this vision than the .NET Framework, and slowly but surely, it will, literally be, everywhere.&lt;/span&gt; &lt;/font&gt;&lt;/div&gt;&lt;img src="http://rickgaribay.net/aggbug/170.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay - The more I learn, the less I kno</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/03/05/silverlight-2.0--the-future-of-software-as-a-service.aspx</guid>
            <pubDate>Wed, 05 Mar 2008 20:22:03 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/170.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/03/05/silverlight-2.0--the-future-of-software-as-a-service.aspx#feedback</comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/170.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/170.aspx</trackback:ping>
        </item>
        <item>
            <title>Resizing Virtual PC VHD Disks</title>
            <link>http://rickgaribay.net/archive/2008/03/03/resizing-virtual-pc-vhd-disks.aspx</link>
            <description>&lt;p&gt;I hit a wall with a VPC Virtual Hard Disk (VHD) where apparently it had expanded as far as it was going to. I am not sure why a Dynamic disk would not continue to expand dynamically, but it hit 20 GB and that was it.&lt;/p&gt;
&lt;p&gt;So, there were several options that were proposed, including ghosting the old VHD to a new VHD, as well as just adding a new "data" VHD. &lt;/p&gt;
&lt;p&gt;In the end, the one I liked best came from my good friend Todd Sussman.&lt;/p&gt;
&lt;p&gt;It was quick, painless and worked like a charm...&lt;/p&gt;
&lt;ol&gt;
    &lt;li&gt;Backup (copy) your VHD file &lt;/li&gt;
    &lt;li&gt;Download and install VHDResize (google it). Run it on the host, point to the VHD and select the appropriate size (i.e. 30 GB) &lt;/li&gt;
    &lt;li&gt;It will take a while, but once complete, re-mount the VHD to your VMC and boot into the Guest hosting the resized VHD. &lt;/li&gt;
    &lt;li&gt;Install a parition management tool such as Partition Magic or Partition Manager, which will detect the available space that is unallocated and allow you to extend it. &lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;That's it.&lt;/p&gt;
&lt;p&gt;If anyone would like to educate me on the difference between "Dynamic" and "Fixed" disks in Virtual PC 2007, or have an even simpler suggestion than the one above, please feel free to comment.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;&lt;img src="http://rickgaribay.net/aggbug/169.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Rick G. Garibay - The more I learn, the less I kno</dc:creator>
            <guid>http://rickgaribay.net/archive/2008/03/03/resizing-virtual-pc-vhd-disks.aspx</guid>
            <pubDate>Tue, 04 Mar 2008 04:06:50 GMT</pubDate>
            <wfw:comment>http://rickgaribay.net/comments/169.aspx</wfw:comment>
            <comments>http://rickgaribay.net/archive/2008/03/03/resizing-virtual-pc-vhd-disks.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://rickgaribay.net/comments/commentRss/169.aspx</wfw:commentRss>
            <trackback:ping>http://rickgaribay.net/services/trackbacks/169.aspx</trackback:ping>
        </item>
    </channel>
</rss>