0

I am trying to make a Linux Mint virtual machine with XAMPP and Vsftpd. I am using Windows 11 Hyper-v Manager as virtualization software.

The problem is that when I try to watch my virtual machine's webserver files with other computer on the same network as the virtual machine, the other machine can not connect to virtual machine's ip. Virtual machine's firewall is off.

The virtual machine's ip address is weird, it is 172.24.158.8. The network where the virtual machine's host computer is connected uses 10.0.0.0, so I tried to make NAT to virtual machine, but it did not connected to internet.

So, I would also want that the virtual machine uses 10.0.0.0 or 192.168.0.0 ip.

Have somebody a good tip how to make Linux virtual machine webserver with XAMPP, Vsftpd and 10.0.0.0 or 192.168.0.0 ip ?

I can tell additional information if needed. Thanks for all answers !

1 Answer 1

1

The problem is that when I try to watch my virtual machine's webserver files with other computer on the same network as the virtual machine, the other machine can not connect to virtual machine's ip. Virtual machine's firewall is off.

Your other computer actually isn't on the same network as the virtual machine. The reason you're seeing an IP address different from your LAN is that Windows 10/11 automatically configures the Hyper-V vSwitch as a separate internal network (with routing and NAT), instead of attaching it to your physical network.

There's nothing wrong with the address itself (172.16.0.0/12 is a completely standard private IP address range, just less commonly seen) – it's just an indication of the VM being in a separate network, and as long as the networks are "physically" separate, changing the address to "192.168" will not help in any way.

The simplest solution is probably to use the Hyper-V Manager to configure a new "external" vSwitch that is directly bridged to your LAN interface – then your VM will be directly placed on the same network.

1
  • Thanks for you ! I made external vSwitch and then the other machines also connected to virtual machine's IP. IP address also changed to 10.0.0.0 when I made external vSwitch, which is completely understandable since using external vSwitch inside 10.0.0.0 network.
    – allu
    Commented Jun 21, 2022 at 18:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .