Skip to content

Port forwarding with NAT

manaswis edited this page Mar 25, 2013 · 9 revisions

In order to use your Virtual Machine (VM) as a server so that WSN Nodes can send requests to it, you need to setup NAT Settings. Follow these instructions below for a Windows 7 Machine:

Prerequisites

On the host machine Make sure VMnet1 and VMnet8 adapters are enabled.

  1. Open Control Panel
  2. Open Network and Sharing Center
  3. Select "Change adapter settings"
  4. Right click VMNet8 network adapter and enable. Repeat the same for VMNet1 network adapter.

In the Virtual Machine: Make sure your VM is using NAT type of network connection.

  1. Start VM.
  2. In the terminal, type ipconfig.
  3. Note down your VM's IP address.
  4. Shut down the virtual machine.

On the host machine:

  1. Open command prompt with administrator access.
    • Click Start button.
    • Type cmd or Command Prompt in the Search box.
    • Right click and press "Run As Administrator"
  2. In the command prompt, go to the directory where VMware Player is installed. C:\Program Files\ and so on..
  3. Run the following command: rundll32.exe vmnetui.dll VMNetUI_ShowStandalone This will open the network editor.
  4. Select VMnet8 option from the list in the top most box.
  5. Go to NAT Settings->Add.
  6. In the Map Incoming Port dialog box, enter the following details:
    • Host Port: 9000
    • Type: TCP
    • Virtual Machine IP Address: Enter the IP address of the VM
    • Virtual Machine port: 9000
    • Description : SensorActVPDS In the similar way, add two more entries for the following ports: * 9001 - For SensorActBroker * 9003 - For SensorActUI
  7. Click OK in the dialog boxes open.

Then start the whole SensorAct system (mongo on the host machine and SensorAct on the VM).