VM Fusion does not have vmnet8 and other files, can surf the Internet, how to fix the virtual machine ip

problem description

recently I have been learning to use Hadoop, using macbook. Equipped with three ubuntu virtual machines, but the IP is dynamic beating all the time is very inconvenient, want to be fixed. Found on the Internet is in Mac and other terminals to find the folder under VM Fusion, there will be a vmnet8 file, but my folder only contains preferences and preferences-private files, and
preferences contains some keyboardandmouse settings.
preference-private contains only .codes = "UTF-8" one line of code

I found a lot of things about reinstallation on the Internet, saying that I can"t connect to the Internet without vmnet8 files, but my virtual machine surfing the Internet is normal, and the Hadoop configuration is too troublesome to give up easily. Is there a master who can tell me how to get this file out or directly tell me how to fix IP in this case? It is not useful for me to change it directly in the etc/hosts of the virtual machine

ask the boss for advice. Thank you very much

Jun.29,2022

there are many ways, mainly depending on the "network connection" mode of your virtual machine.

< H2 > method 1: (NAT mode) modify vmware configuration < / H2 >

add

    host vmnet8 {  
            hardware ethernet xx:xx:xx:xx:xx:xx;  
            fixed-address 172.16.103.152;  
            option domain-name-servers 172.16.103.2;  
            option domain-name "";  
            option routers 172.16.103.2;  
    }  

to the configuration file / Library/Preferences/VMware Fusion/vmnet8/dhcpd.conf .
remember to replace your virtual machine mac address.

< H2 > method 2: (NAT mode) set static IP in the virtual machine < / H2 >

set the IP obtained by the virtual machine from DHCP to static IP.

< H2 > method 3: (Bridge mode) use a LAN router to set static IP < / H2 >
Menu