Dual-nic configuration for Ubuntu in Vmware Virtual Machine

Source: Internet
Author: User


In the virtual machine Vmware, Ubuntu is configured with dual NICs. in Vmware, Ubuntu is configured with two NICs, one for accessing the Internet (Host-Only mode ), A fixed IP address is used to communicate with the host machine and other virtual machines-SSH and FTP (NAT mode) Specific configuration: 1. In Windows, prepare: a. Enable the TCP/IP forwarding function of Windows. In the registry, locate and click the following items: HKEY_LOCAL_MACHINE \ SYSTEM \ CurrentControlSet \ Services \ Tcpip \ Parameters \ IPEnableRouter value changed to 1 www.2cto.com B. In the network adapter, right-click Properties → share → Select Internet share, select VMware Network Adapter VMnet1 (Host-Only NIC generated by VMware by default) in the drop-down box. In this case, Windows will prompt that the IP address of VMnet1 will be fixed to 192.168.137.1 (different machines may be different) C. Set the IP address of the VMware Network Adapter VMnet8 (NAT Nic generated by VMware by default), for example, 192.168.2.1 2 and Vmware: menu → Edit → Virtual NetWork Editor → VMnet1 check Connect a host... and Use local DHCP service... 3. Ubuntu settings: Open the sudo gedit/etc/network/interfaces file and add the following content: auto lo iface lo inet loopback auto eth0 iface eth0 inet static address 192.168.137.8 gateway 192.168.137.1 netmask 255.255.255.0 network 192.168.137.0 broadcast 192.168.1 37.255 www.2cto.com auto eth1 iface eth1 inet static address 192.168.2.8 gateway 192.168.2.1 netmask 255.255.255.0 network 192.168.2.0 broadcast 192.168.2.255 where lo is a local loop, eth0 is Host-Only, eth1 is NAT, and then restart the network: sudo/etc/init. d/networking restart last set DNS: sudo gedit/etc/resolv. add the conf file: nameserver 192.168.137.1 search localdomain and then you can access the Internet. The two NICs can be pinged to each other, and the NAT Nic can be pinged to other virtual machines. Refer to blog: http://www.bkjia.com/os/201211/165390.html

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.