Answer the question
In order to leave comments, you need to log in
How to define remote_addr in virtual box behind NAT?
There is a computer win7 in which virtualbox (debian nginx php) is installed in order to develop php scripts.
NAT is selected in the network settings and port 80 is forwarded.
PHP $_SERVER['REMOTE_ADDR'] all the time '10.0.2.2'
how to get the real REMOTE_ADDR of the client?
Answer the question
In order to leave comments, you need to log in
from the command line, execute
VBoxManage modifyvm "virtual_machine_name" --nataliasmode1 proxyonly
command line must be run not from the admin, but from under your user. the virtual machine must be stopped.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question