Windows 8: how give Internet connection to Hyper-V machines

I'm currently studying MVC 3 and 4 on the Application Lifecycle Management for TFS 2012 virtual machine, on my client machine that runs Windows 8 with Hyper-V.

If you need to setup Hyper-V on Windows 8, I've followed the guide in the blog post Get started with Windows 8 Client Hyper-V the right way.


Once you run the virtual machine, you can see that it does not have Internet access. That is a problem if you use nuGet to download and update packages.

To solve this problem, I have followed the guide Using Your Windows 8 Wireless Connection Inside Hyper-V.


But even after having Internet access, I see that I can't download or update nuGet packages from online.

Again, luckly I have found the solution online, in the answer to the question Visual Studio 2010 nuget error: The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.

Windows: how make File Explorer Search to work

When searching for content using the File Explorer Search, often it happens that it is not able to find content inside files.

This can be a problem, above all for developers, searching for source files containing some string.

Using the tips in the article How to Make Windows 7 Search File Contents, I've found the following suggestions:

  • from the Folder Options, in the Search tab, avoid using the Index and select use "Always search file names and contents"
  • from Control Panel, Change How Windows searches, press the Advanced button, in the File Types tab, add a new file extension (or edit exisiting ones) selecting "Index Properties and File Contents"

Hiren's BootCD and USB boot

Hiren's BootCD is a particular installation of Windows XP that contains a lot of utilities to recover damanged computers. You can download it directly from the file

To run it from an USB disk, you need the utilities USBFormat and Grub4Dos, after that you can simply follow the simple guide in the page Hiren's BootCD From USB Flash Drive (USB Pen Drive). In the last step, remember to copy the content of the iso file contained in the Hiren's BootCD zip file.

Gmail: reduce non-compliant standard annoyances

Gmail is a rather good email service: it's free, it gives you a lot of space, it's fast, its antispam system is very good.

Here the good points finish; all the problems follow, because, very shortly, some arrogant person in Google chose to alter the Internet standard for his moods.

You can choose to use it (if you are not a very precise person), to avoid (if you want to pay a really good email service) or to tolerate it (like it did). If you are in last category, here are a few tricks for your best setup (but I have to remember you that best in this case is not yet sufficient):

  • first of all, your email is your Gmail login, and you can't change it. So, to avoid all the problems that would rise with the creation of a new login, please do a favor to yourself and choose immediatly your final email address;
  • in Gmail settings, change the language settings to the same of your email client, else you'll have duplicate folders when you connect a client like Outlook;
  • in your email client, choose not to save sent mails, as Gmail will do it already for you and is not enough clever to understand that duplicate mails could be created by this behaviour;
  • in your email client, choose to delete emails moving them in the Trash folder explicitly;
  • incredibly, if you move mails from the Gmail account to your personal mails (for example, in Outlook, a private pst file), mails aren't deleted (i.e.: moved to the Trash folder) but are simply removed the Inbox label. So after you move a mail from Gmail to your private pst file, you need to explicitly delete it from the All Mails folder (and in this case, I use to do it from the web to avoid other synchronization problems that could arise);
  • finally, if you use the iPhone/iPad, after the email account creation, disable the Archive setting, so that when you delete an email, you really delete them moving it in the Trash folder and not simply removing the Inbox tag.

In conclusion, Gmail is a rather good mail system, with some important problems. It's up to you choose to use it; I use it, but sopporting its limits and all the problems it creates with its particular behaviours.

Windows 2008: enabling multiple RDP connections

By default, Windows 2008 disables multiple RDP connections with the same user.

But you can enable them in this way: start up gpedit.msc, go to Computer Configuration\Administrative Templates\Windows Components\Terminal Services\Terminal Server\Connections\, find "Restrict each user to a single session" and disable. You can find more details in the post Enable Multiple Remote Desktop Connections in Window Server 2008.

Of course, if you're on a domain and want to apply it to multiple machines, you obviously need to make it a domain policy.

But if you have installed Terminal Services, please follow the guide in the article Enable Multiple Remote Desktop Sessions on Server 2008.

Converting Hyper-V Machines

In the past days I've downloaded a virtual machine from Microsoft called Information Worker Demo (now it's downloadable from the page 2010 Information Worker Demonstration and Evaluation Virtual Machine (SP1)).

It's very interesting because it contains:

  • Windows 2008 R2 Standard Edition x64, acting as a domain controller
  • SQL Server 2008 R2 Enterprise with Analysis, Notification and Reporting services installed
  • Visual Studio 2010 Professional
  • SharePoint 2010 Enterprise with FAST Search
  • Office 2010 with Visio and Project

After having downloaded a unrared it, I've got a problem: to run it, you need Windows 2008 R2 with Hyper-V role activated, or the free Hyper-V Server, because Windows 7 cannot run Hyper-V virtual machines.

After some (not easy!) searches on Google, I've finally found this fantastic tool: StarWind V2V Converter, which allows you to convert even Hyper-V machines without the need to run them!

Another (silly) problem: the password of the Administrator account is pass@word1, the keyboard is set to American, to to enter the "@" character... press Shift+2


SharePoint 2007 allows you to define job definitions and schedule them, but you have to do it programmatically.

As it's impossible to change the job definition schedules from the UI, the preferred approach is:

  1. Define a feature that writes in the web.config the desired schedule
  2. Define a feature that schedules the job reading the desired schedule from the web.config

For second point, your friend is the SPSchedule.FromString static method, with returns an instace of a SPSchedule from a string that you can save in your web.config.
But how do you build this string?

You can refer to the definition of the method in the documentation page SPSchedule.FromString Method, that at the end of the page forwards you to the fantastic article SPSchedule.FromString(recurrenceValue) - syntax/format for recurrence value!

Order of Installation of SharePoint Patches

The general rule is that you have to install language pack and service pack according the chronological order they have been released (so that: “language pack”, “service pack 1”, “language pack of service pack 1”), keeping in mind that even if MOSS 2007 included WSS 3.0, both its service packs and its language packs don't.

So the order of installation is:

  1. WSS 3.0 language pack Italian
  2. MOSS 2007 language pack Italian
  3. WSS 3.0 service pack 1 English
  4. MOSS 2007 service pack 1 English
  5. WSS 3.0 language pack Italiano service pack 1
  6. MOSS 2007 language pack Italiano service pack 1
  7. WSS 3.0 service pack 2 English
  8. MOSS 2007 service pack 2 English
  9. WSS 3.0 language pack Italian service pack 2
  10. MOSS 2007 language pack Italian service pack 2

I add here recent packages:

  1. WSS 3.0 service pack 3 English x64 (here x86)
  2. MOSS 2007 service pack 3 English x64 (here x86)
  3. WSS 3.0 language pack Italian service pack 3 x64 (here x86)
  4. MOSS 2007 language pack Italian service pack 3 x64 (here x86)

Setup Kerberos Authentication

Kerberos is used when you have Windows authentication with impersonification and the impersonated user needs to access resources outside the web server.
For example, you can use it when from your SharePoint server you need to access an Exchange web-service to get the user mail and calendar.

To enable Kerberos authentication, you need to complete the following tasks:

  1. From the Central Administration, change the web-application settings to use Kerberos (negotiate) authentication insted of NTLM authentication
  2. To add the SPNs for the web-server, from a command line prompt, execute:
    1. setspn -a HTTP/ServerName Domain\ServerName
    2. setspn -a HTTP/ServerName.Domain Domain\ServerName
  3. To add the SPNs for the application pool user, from a command line prompt, execute:
    1. setspn -a HTTP/ServerName Domain\User
    2. setspn -a HTTP/ServerName.Domain Domain\User
  4. Finally, from the Active Directory Users and Computer, check the application pool user as trusted for delegation.

More details in the article How to configure a Windows SharePoint Services virtual server to use Kerberos authentication and how to switch from Kerberos authentication back to NTLM authentication.