Virtual server


I am setting up my development environment in which I need two servers. I have a rather strong physical sevrer and I was thinking that both my servers could reside on this one. I need a domain controller and a server for SharePoint.

Which would be my best approach?

To install Hyper-V and my servers on top of that?

Install a server with the domain controller and then my other server using virtal PC or virtual server?

In my development machine I am working on a WPF application where I need to call the AD using LDAP - se the code snippet. What do I need to do to get this working? Any ports that needs to be opened? Does my development machine need to be in the Domain?

I would greatly appreciate advice in this matter since I am a roukie when it comes to setting up servers.

Best regards
public MainWindow()

            //Establish the user identity
            WindowsIdentity currIdentity = WindowsIdentity.GetCurrent();
            string NtAccountName = currIdentity.Name;

            //Search in the active directory
            DirectoryEntry entry = new DirectoryEntry("LDAP://", "DOMAIN\\Administrator", "Password");
            DirectorySearcher ADSearch = new DirectorySearcher(entry);
            ADSearch.Filter = "(&(objectClass=user))";

            string loginname = String.Empty;
            string firstname = String.Empty;
            string lastname = String.Empty;
                foreach (SearchResult resultSet in ADSearch.FindAll())
                    //Login Name
                    loginname += GetProperty(resultSet, "cn") + "¤";

                    //First Name
                    firstname += GetProperty(resultSet, "cn") + "¤";

                    //Last Name
                    lastname += GetProperty(resultSet, "cn") + "¤";
            catch (Exception ex)
                string mess = ex.Message;

        public static string GetProperty(SearchResult resultSet, string PropertyName)
            if (resultSet.Properties.Contains(PropertyName))
                return resultSet.Properties[PropertyName][0].ToString();
                return string.Empty;

Open in new window

Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

hello. what is the os of your app machine
Adrian CantrillSolutions ArchitectCommented:
I would tend to install windows 2008 and the hyperV role on the physical machine. This will install the hypervisor ( the bit that runs the VM's ) below the traditional windows layer and allow as many virtual machines as the host can deal with.

You can setup each of the VM;s you need ontop of this i.e your DC and other VM you need. If you want to isolate this further you can define a virtual network using its own set of isolated IP's to make it a true development network and control the level of access needed between them.

I would always go on the site of virtualising all roles, if you install the DC on the physical machine its a lot harder to maintain than having it virtualised :)
Adrian CantrillSolutions ArchitectCommented:
If you virtualise both, you have the option of having a 'development' domain - so you can be more experimental which what ports you use and what you allow the software to do - and can then lock it down for live use. Thats even more reason to have both of the machines virtualised.
C++ 11 Fundamentals

This course will introduce you to C++ 11 and teach you about syntax fundamentals.

RTSolAuthor Commented:
Ok - Hyper-V then. I downloaded the installer her for this. I have never done this before - is there anything I need to think of or is it just to go ahead and install. Any good sites to look on? My physical server runs on a CI7 2.8 with 8 GB of memory. My virtual servers will run server 2008 R2.

Any comments on my LDAP call?
Adrian CantrillSolutions ArchitectCommented:
If your a beginner then i suggest 2008R2 server and then install the hyperV role . The download you have, while better for heavy enterprise environments isnt so 'friendly' and manageable.

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
RTSolAuthor Commented:
Thanks a lot - this will get me going for a while :-) I might need to get back on this issue later.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.