Access to the Internet through VMware + Ubuntu configuration under WIN7 (also effective for wireless networks)

Source: Internet
Author: User
This method has been tested and feasible on Ubuntu9.1011.10 first, please make sure that Vmware's Networkconnection is selected for Host-only1. edit the DHCP configuration in Ubuntu, delete all content in DHCP, and save # sudogedit/etc/dhcpd. conf if dhcpd. if conf does not exist, create one by yourself. in the host, the network and sharing center can see

This method has been tested on Ubuntu 9.10 11.10.

First, make sure that the Network connection of Vmware is Host-only.

1. Edit the DHCP configuration under Ubuntu, delete all content under DHCP, and save

# Sudo gedit/etc/dhcpd. conf

If dhcpd. conf does not exist, create

2. In the host, the network and sharing center can see

The local connection is the network connection of my host. The local connection 2 corresponds to the local connection 3, and the local connection 2 in my computer corresponds to VMnet1, view the VMnet1 IP address (192.138.137.1 ). Set shared to VWnet in the local connection attributes.

3. Enter the VM, set the nic ip address in the VM to a CIDR block with the VMnet1 IP address, and set the gateway to the IP address of vmnet1.

# Sudo gedit/etc/network/interfaces

Auto eth0

Iface eth0 inet static

Address 192.168.137.X

Gateway 192.168.137.1

Netmask 255.255.255.0

(Note that the value 0 in eth0 is zero .)

The Virtual Machine's DNS is also set to the VMnet1 IP address.

# Sudo gedit/etc/resolv. conf

Nameserver 192.168.137.1

4. Finally, # sudo/etc/init. d/networking restart. You can access the Internet.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.