1. Computer problem? Tech Support Guy is completely free -- paid for by advertisers and donations. Click here to join today! If you're new to Tech Support Guy, we highly recommend that you visit our Guide for New Members.

Solved: Virtual Machines and Different Subnets

Discussion in 'Networking' started by Synt4xError, Jan 13, 2013.

Thread Status:
Not open for further replies.
  1. Synt4xError

    Synt4xError Thread Starter

    Joined:
    Jan 23, 2009
    Messages:
    196
    Hello,


    I need some help connecting multiple Virtual Machines to the internet. I have my main computer which is Windows Server 2008R2 that connects to the home router via the wireless network. My home router's DHCP gives off 192.168.1.XXX IP addresses. My Server has 192.168.1.200 as the static IP address.

    I am trying to setup a lab for studying purposes and want to have different subnets for each other server I setup within Hyper-V. I have 4 virtual machines that I want to configure 192.168.0, 192.168.2, 192.168.4, 192.168.6 subnets. When I change the subnets I loose internet.

    When I was studying for my 2003 certifications I remember that there was a way to setup the main computer as a RRAS server so it can act as a router to all the virtual machines. 2008 server is a bit different as far goes the UI and I have completely forgot how to do this since it has been years since I have done this.

    Can anyone help me get this setup to work? I Want each virtual machine to have it's own subnet and to allow it to access the internet and internal VMs so I can replicate DNS and AD.

    Thanks,
    Synt4x
     
  2. Synt4xError

    Synt4xError Thread Starter

    Joined:
    Jan 23, 2009
    Messages:
    196
    I will solve my own question it seems.

    1) I created four internal network adapters within Hyper-V.
    2) I gave each network adapter the IP address on the subnet I wanted.
    - 192.168.0.254
    - 192.168.2.254
    - 192.168.4.254
    - 192.168.6.254
    3) I installed the Network Policy and Access Services role within Server Manager
    4) I Configured and Enabled Routing and Remote Access
    - I chose custom settings and just checked off LAN Routing
    5) I expanded the views of the role and the options below, right clicked on General under IPv4 and selected 'New Routing Protocol" and chose NAT.
    5) Within the NAT section I right clicked and chose 'New Interface', I then started adding my Network Adapters.
    - In my case I have to add 5 things under NAT
    - 1) Private Interface connected to Private Network - Network Adapter Chosen 192.168.0.0
    - 1) Private Interface connected to Private Network - Network Adapter Chosen 192.168.2.0
    - 1) Private Interface connected to Private Network - Network Adapter Chosen 192.168.4.0
    - 1) Private Interface connected to Private Network - Network Adapter Chosen 192.168.6.0
    - 1) Public Interface connected to the Internet - Make sure you select 'Enable NAT on this Interface' - Also, this is where the Network Adapter I use for the internet on the main server where hyper-V is installed.
    6) I assigned each Hyper-V Virtual Machine a NIC card by going to each of their settings and under Network Adapters giving the correct option.
    7) Booted it up each machine and did the following for the static IP address
    - IP: 192.168.0.1
    Subnet Mask: 255.255.255.0
    Default Gateway: 192.168.0.254
    Preferred DNS: 192.168.1.1

    I repeated step 7 four times and used the default gateway as the network adapter I had setup previously in Network Manager. I also used my router as the DNS server, which may change when I install DNS and configure it correctly.

    Thanks,
    Synt4x
     
    ninjatronics likes this.
As Seen On
As Seen On...

Welcome to Tech Support Guy!

Are you looking for the solution to your computer problem? Join our site today to ask your question. This site is completely free -- paid for by advertisers and donations.

If you're not already familiar with forums, watch our Welcome Guide to get started.

Join over 733,556 other people just like you!

Thread Status:
Not open for further replies.

Short URL to this thread: https://techguy.org/1085084

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice