VMware-Perfect Combination of virtualization and reality

Source: Internet
Author: User
Article Title: VMware-Perfect Combination of virtualization and reality. Linux is a technology channel of the IT lab in China. Includes basic categories such as desktop applications, Linux system management, kernel research, embedded systems, and open source.
   Environment:
1. the Windows 2000 Advanced Server used in the notebook can access the Internet through the company's LAN.
2. In the actual LAN, the IP address of Win2000 is 192.168.0.240, the gateway is 192.168.0.254, And the DNS is 210.52.149.2;
3. I am using vmware3, VMNet1 IP address is 192.168.171.1, and DHCP server address is 192.168.171.254;
The IP address of VMNet8 is 192.168.34.1, And the IP address of the DHCP server is 192.168.34.254;
4. the IP address of FreeBSD installed in Brigde mode is 192.168.0.179, the gateway is 192.168.0.254, And the DNS is 210.52.149.2;
  
   Functions:
1. I use FreeBSD to maintain a PHPBB forum in the company's LAN;
2. FreeBSD needs to be able to access the Internet and install FTP and Ports software in the company;
3. Win2000 and FreeBSD are required to connect to the home;
4. Back home, you need to maintain the PHPBB forum and its database, and use Win2000 IE for browsing;
  
   Problem 1:
Careful friends may find contradictions in the above requirements. The guestos in vmware can communicate with the outside world in three ways: Bridge, Nat, and Host-Only. If you want FreeBSD forums to be accessible by other machines in the company's Lan, FreeBSD must use the Bridge method in vmware. If Win2000 can be connected to FreeBSD in an environment without an actual LAN, FreeBSD must use the Host-Only method in vmware. At this time, if we want to use Win2000 to browse the PHPBB forum without a physical network, that is, access the FreeBSD installed in Bridge mode, we say this is impossible, the Bridge method in vmware cannot communicate with the outside world without a LAN, because the FreeBSD and Win2000 installed in the Bridge method are equivalent to two independent machines in the LAN, therefore, we can't communicate between two independent machines without a network cable. How can this problem be solved?
  
Solution:
  
From the above requirements, we can see that the focus is on how to enable Win2000 to access the PHPBB forum without a physical network. At this time, Win2000 can Only use the Host-Only method to install FreeBSD. In this way, we will convert our Bridge-based FreeBSD into the Host-Only method. First, create a new virtual machine, select Custom installation, and choose FreeBSD for Guest OS; give a name that is easy to recognize for the new virtual machine;
Select the "Host-Only" Mode for network connection. On the disk selection page, select an existing disk. In this case, find the FreeBSD mode installed previously in the Bridge mode according to the actual path. vmdk file. At this time, note that the installed virtual machine files usually have approximately FreeBSD. vmdk, FreeBSD-02.vmdk and other sequential naming files, here we choose FreeBSD. vmdk, select FreeBSD-02.vmdk or something based on my experiment results. the vmdk file does not work. The system will prompt "The specified file is not a valid VMware disk. ", I think this may be FreeBSD. vmdk and others. what is the difference between vmdk files? On the Disk Mode interface, I choose Persistent to change permanently, the other two options are Undoable, that is, whether to save the modification to the borrowed Bridge Mode FreeBSD Virtual Machine file before shutting down the virtual machine, and Nonpersistent, that is, disable This VM does not save changes to the borrowed Bridge Mode FreeBSD VM file. After selecting the files, click Finish. So far, we have created a Host-Only FreeBSD.
  
Effect description:
  
After repeated experiments, we can prove that the content of FreeBSD created using the above method is completely consistent with that of the original Bridge method, including an important parameter of the original FreeBSD-IP address. You can use it with confidence. Pai_^
  
   Problem 2:
The Host-Only mode of FreeBSD still cannot provide WEB browsing service for Win2000. FreeBSD retains the original IP address 192.168.0.179, while Win2000 uses VMNet1 to communicate with FreeeBSD. The IP address is 192.168.171.1. So our second problem is the IP address.
  
Solution:
  
Remove the DHCP service of VMNet1 from the Win2000 network and dial-up connections, and assign it an IP address of the 192.168.0.0 network segment.
  
Effect description:
  
In this way, the IP addresses bound to the physical network card of Win2000, the IP addresses of FreeBSD, And the IP addresses of vmnet1. This makes it much easier. Some may ask what if the IP address of VMNet1 conflicts with the existing IP address in the company. After my experiment, I can prove that, the IP address of VMNet1 does not conflict with the IP address of the actual physical network, because VMNet does not participate in communication in the physical network, so you can use it as you like.
  
Well, it's done. Haha, If You Want To fulfill the requirements described above, you Only need to enable FreeBSD in Bridge Mode at your company, and enable FreeBSD in Host-Only mode at home. The results are exactly the same.
  
The original intention of writing this article is that the biggest obstacle I encountered when studying BSD was that I did not have a good network environment. I used to worry about how to implement communication between HOSTOS and GUESTOS without a physical network. Now, not only does HOSTOS and GUESTOS communicate smoothly, the same FreeBSD can be operated in different environments. Friends who have the conditions to use the real environment may not feel this kind of feeling ^_^. I think many of my friends may have encountered the same problems as me in many bsders. Please refer to them and I hope you will have some gains. I also hope that all vmware experts will criticize and correct it.
  
   Summary:
This article solves the problem of connecting the physical network and the virtual network created using vmware software. Therefore, it is named "vmware-Perfect Combination of virtualization and reality ".
Related Article

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.