Friday, September 30, 2011

Setting up a domain controller in a virtual machine

If you need to set up any variety of Windows Server Applications such as Active Directory Federation Services, SharePoint, Windows Server Update Services and a whole variety of other applications, there is a high likelihood that you will need to set up a domain controller.

If you are setting up a domain controller on a home network where you have a router performing all of your DHCP operations, it is likely that you will not want to set up your domain controller to act as your DHCP server as well.  Therefore, the easiest thing to do is to simply set aside a block of static IP addresses that you can use to assign for your virtual environments.

Once you have done that, you should be able to follow these steps to install and configure your domain controller.  For this example, I have installed Windows Server 2008 R2 and using this OS as my base configuration.  For ease of use, I also use VMWare Workstation or VMWare Player to build and configure my virtual machines.

  1. Open up the Network Adapter settings and assign a static IP address to the IPv4 configuration from the block of static IP addresses that you have set aside.
  2. If you need to enter a default gateway, configure the default gateway as the IP address of your router (usually something like 192.168.0.1)
  3. If you need to enter a Primary DNS server, you can enter the IP address of your router as well (such as 192.168.0.1)
  4. Once you have entered your settings, click OK to save all of your network adapter settings.
  5. If everything is configured correctly, you should still be able to access the Internet from within your virtual machine using a web browser.
  6. If you have customized or disabled any Windows Services, you will need to ensure that the appropriate Windows services are enabled and started:
    1. Remote Procedure Call (RPC) Service
    2. Remote Registry Service
  7. Now, at the run command, you can run dcpromo
  8. This should now initiate the process to install the Active Directory binaries on your machine as well as launch the Active Directory configuration wizard. 
  9. While configuring Active Directory through the configuration wizard, you will be prompted for setting up a new forest or using an existing forest.  Since you probably do not have an existing domain infrastructure in place, you will want to create a new forest.  In terms of forest compatibility, I would recommend either configuring the compatibility to either Windows Server 2008 or Windows Server 2008 R2 compatibility mode.
  10. After proceeding through several other configuration steps, you will be prompted to configure DNS on the server.  You can allow the domain controller to be configured as its own DNS Server.  This will effectively modify the network adapter settings to include 127.0.0.1 as the Primary DNS Server IP Address.
  11. If there were no hiccups in the configuration wizard process, you should be done with successfully configuring a domain controller within your virtual machine!

Wednesday, September 28, 2011

Deploying SharePoint 2010 Language Packs

If you want to have multilingual support in your SharePoint 2010 site, you will need to deploy the SharePoint 2010 Language Packs.

You can download the SharePoint 2010 Language Packs from here:

SharePoint Server Language Packs
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=3411

SharePoint Foundation Language Packs
http://www.microsoft.com/download/en/details.aspx?displaylang=en&id=4731

One of the key points to note when downloading and installing the language packs is that the default language for downloading the language packs is English.  Therefore, if you simply download the language packs from the respective links, you will  not get the required functionality in your SharePoint site to support multiple languages.  Instead, when you download the individual language packs, you must actually select a different language for downloading the language pack prior to downloading.  For example, if you wish to download the language pack for Spanish, you would have to change the language on the download screen to Spanish.  Changing the language will actually change the resultant download Url such as this one for Spanish:
http://www.microsoft.com/downloads/es-es/details.aspx?familyid=046f16a9-4bce-4149-8679-223755560d54&displaylang=es

You will have to proceed with downloading each of the language packs for each of the languages you wish to support in the application.

Once you have downloaded all of the required languages, you will have to install the individual language packs on your SharePoint instance(s).  This process will also require you to re-run the SharePoint Configuration Wizard tool as part of the installation process. 

Once the installation process is complete, you will then have a new option under Site Settings called Language Settings which will allow you to configure the various installed languages for your SharePoint environment.  Configuring the Language Settings allows an end-user to change their Display Language to an alternative language such as French, German, Spanish etc.

If that is working, you have successfully deployed SharePoint Language Packs!  You can now begin to utilize multilingual variations of a SharePoint site.

Tuesday, September 27, 2011

Firefox v. 7.0 released!

It seems that Mozilla Firefox is now attempting to keep pace with the rapid development and release cycle of Google Chrome and they have recently released v. 7.0 after having released v. 6.0 only several months earlier.

As with all releases of Firefox, it may take several months before the 3rd party plug-in support catches up with the most recent release of Firefox, which may slow the adoption rate of the latest release of the browser.  Of course, if Mozilla Firefox keeps up this fast and furious pace, 3rd party vendors may not be able to keep up at all leaving hundreds of thousands of users with previous versions of the browser in order to maintain plug-in compatibility support.

The improvements in v. 7.0 over the prior release of v. 6.0 remain to be seen.  Only time will tell as to whether or not this new strategy adopted by Mozilla Firefox will be a successful strategy in reducing or diminishing the rapid adoption of Google Chrome as an alternative browser to both Microsoft Internet Explorer as well as Mozilla Firefox.

Saturday, September 24, 2011

Adobe Offline Installers

If you do not want to install Adobe Reader or any of the various Adobe applications via their online Web Installer, you can download their corresponding offline installers simply by using an FTP client such as FireFTP and connecting to ftp.adobe.com.  You can look in the pub directory for the various releases of their software products.

In addition, you can browse the directory structure for the Adobe Installer versions in the Firefox Web Browser as well.

For Adobe version 10.0, the Url is the following:
ftp://ftp.adobe.com/pub/adobe/reader/win/10.x

For previous and potential future versions of Adobe Reader, you can simply use the base Url:
ftp://ftp.adobe.com/pub/adobe/reader/win/

In addition, here are some direct links to the the Adobe Reader X Offline installers:
http://www.ghacks.net/2010/11/22/adobe-reader-x-offline-installers/

Wednesday, September 7, 2011

Deleting individual Internet Explorer Cookies

If you still use Internet Explorer (mostly because you are forced to do so for numerous websites), then there is a high probability that, like me, you are extremely frustrated with Internet Explorer's lack of ability to view and delete individual cookies on the machine.  This feature is missing even in Internet Explorer 9, while it has been present in alternative browsers such as Google Chrome and Mozilla Firefox for a very long time.

Of course, if you visit certain banking websites such as Chase.com nowadays, these websites require the presence of a cookie on your machine in order to verify that you are truly who you say you are.  If that cookie is not present on your machine, you have to go through this tedious process of re-verifying your identity before you can log in once again.  Needless to say, deleting all cookies on your system is NOT an option. 

Fortunately, though, some clever developers have created a tool to allow users like us the ability to easily view and delete individual cookies on our machine in a manner similar to Mozilla Firefox and Google Chrome.

The tool is called IE Cookies View and you can find it available for download from CNET here:
http://download.cnet.com/IECookiesView/3000-2381_4-10457038.html

Alternatively, you can review more information about the tool and download it directly from their website here: http://www.nirsoft.net/utils/iecookies.html

Enjoy!

Sunday, September 4, 2011

LoaderExceptions Error Message

I was recently deploying my web application project which contained the latest version of the Entity Framework (v. 4.1) to a hosting provider and was faced with the following error message:

Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.

After doing a significant amount of digging, I came across this article on how to view the details of the error message:

http://weblogs.asp.net/kencox/archive/2010/08/24/fed-up-with-system-data-metadata-edm-objectitemassemblyloader.aspx

Unfortunately, the sample code provided was in VB.Net, which did not offer much value to me since I wanted it in C#.

Fortunately, I was able to use an online translator and came up with the resultant C# replacement code:

protected void Application_Error(object sender, EventArgs e)

{

StringBuilder sb = new StringBuilder();

Exception objErr;

objErr = Server.GetLastError().GetBaseException();

Server.ClearError();

if (objErr is ReflectionTypeLoadException)

{

ReflectionTypeLoadException reflerror = default(ReflectionTypeLoadException);

reflerror = (ReflectionTypeLoadException)objErr;

foreach (var ex in reflerror.LoaderExceptions)

{

sb.AppendLine(ex.Message);

}
//foreach

}

sb.AppendLine(
"<b>Source:</b>" + Request.RawUrl);

sb.AppendLine("<br><b>Browser:</b>" + Request.UserAgent);

sb.AppendLine("<br><b>IP:</b>" + Request.UserHostAddress.ToString());

sb.AppendLine("<br><b>UserID:</b>" + User.Identity.Name);

sb.AppendLine("<hr><br><b>Error in: </b>" + Request.Url.ToString());

sb.AppendLine("<br><b>Error Message: </b>" + objErr.Message.ToString());

sb.AppendLine("<br><b>Stack Trace: </b><br>" + objErr.StackTrace.ToString());

Response.Write(sb);

}

I was finally able to determine the cause of my assembly loading error message and upload the required assemblies!