0

I am new to linux and have been trying to connect ssh for a whole day but it is just not working:

I am using VMware to host virtual linux.

  1. Initially I discovered that my virtual linux is not on the same ip as my Windows, where My Windows ip address is:192.168.1.79, so I changed my internet configuration of Linux to the following:

    TYPE=Ethernet
    PROXY_METHOD=none
    BROWSER_ONLY=no
    BOOTPROTO=static
    DEFROUTE=yes
    IPV4_FAILURE_FATAL=no
    IPV6INIT=yes
    IPV6_AUTOCONF=yes
    IPV6_DEFROUTE=yes
    IPV6_FAILURE_FATAL=no
    IPV6_ADDR_GEN_MODE=stable-privacy
    NAME=ens33
    UUID=b5b31e0a-6326-4130-b7a3-8621377a9817
    DEVICE=ens33
    ONBOOT=yes
    DNS1=8.8.8.8
    IPADDR=192.168.1.188
    NETMASK=255.255.255.0
    GATEWAY=192.168.1.1
    
  2. I also changed form NAT to Bridged

  3. After doing 1, where I changed the ip address of my linux to 192.168.1.188, I can successfully ping 192.168.1.188 on my Windows. But I cannot ping anything in linux.

  4. I also notice that my setting of Adapter Vmnet8 is set to obtain an IP address automatically, and my current ip address for Vmnet8 is 192.168.238.1

Any help will be deeply appreciated!!! Have been working on this forever and could not get it working.

0

1 Answer 1

3

The easiest solution would be to stick with standard setup and have your Linux VM obtain its IP address automatically via DHCP. That way, VMware (in NAT mode) or your router or DHCP server (in bridged mode) will take care of setting an IP address, netmask and default gateway that will allow the VM to communicate.

If for some reason you don't want to use automatic configuration, you have to choose a free IP address from the network you're connecting the VM to, and set the correct default gateway of that network. As you didn't share any information on your network setup I cannot help you with that.

8
  • May I ask what setup information you need? Commented Jun 6, 2020 at 17:21
  • As for automatic setup, I need static ip, is that doable through automatic setup? Commented Jun 6, 2020 at 17:22
  • Basic information for a network: gateway IP address and netmask, plus IP addresses of relevant systems - in this case, the address of the Windows machine which you did share already. Commented Jun 6, 2020 at 17:27
  • Static address: most routers or DHCP servers do have an option to assign a given machine a fixed address, but it depends on the router or DHCP server. Commented Jun 6, 2020 at 17:29
  • Ideally you should add such information to your question by editing it, so it can be referenced in the answer. While you're at it, also add what type of router you have, and mention if you have a separate DHCP server. Commented Jun 6, 2020 at 17:52

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.