DWQA QuestionsCategory: ServerCan two virtual machines in a virtual box communicate in NAT mode
Munch D Ying asked 2 months ago

Virtual box one host and two virtual machines can use NAT mode to realize communication. The IP address dynamically obtained by the two virtual machines is 10.0.2.15!!!,Use port forwarding to expose the service port
图片描述

1 Answers
Yujiaao answered 2 months ago

Use port forwarding to expose the service port
图片描述

Munch D Ying replied 2 months ago

My environment is that a host has two virtual machines. Both virtual machines a and B are NAT mode, and their access to each other is forwarded through the NAT port. Can I fix the NFS service port number and forward it through the NAT port so that a can access the NFS service of B and mount successfully?

Yujiaao replied 2 months ago

tolerable

Munch D Ying replied 2 months ago

Hello, in the article I found, you need to call 4 ports to use NFS. In NAT forwarding, you need to forward 4 ports. When mount is mounted, write IP + which port number

Yujiaao replied 2 months ago

Ports 111 (TCP and UDP) and 2049 (TCP and UDP) of server for NFS.
There are also ports for cluster and client state (Port 1110 TCP and 1110 UDP) and NFS lock manager ports (Port 4045 TCP and UDP).

Munch D Ying replied 2 months ago

The ports listed above, which port should I expose? Then, when the client is mounted, write the mount mapping address: port number / Mount folder