Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
I have a host on ubuntu and i think i would like to virtualize my web-server. So, to be more clear i have for instance the ip 92.124.74.8 to the main server (where virtualbox will be installed)
After i will install the web-server into virtualbox it will have the address 196.168.1.10
So, how can i specify on the main server 92.124.74.8 that all the requests on port 80 to be transfered on 196.168.1.10 (virtual machine). The problem is that on 92.124.74.8 i don't have access to the router/switch.
Is there a possibility to make this forward from the main machine 92.124.74.8 ?
As I can understand you want http machine requested by the clients to be forwarded to guest machine by the host machine. Can you let us know as to which type of ethernet configuration you are using for guest machine whether NAT or Bridge?
Also it would be good to know which VM solution you are using (Virtual Box or VMware)?
You can forward the http request by enabling IP forwarding on the host machine and then creating a rule in iptables to match the request for http and forward it to guest machine.
I am still interested in knowing the ethernet configuration and VM solution in use and also the guest OS on which you will configure web server :-)
You can setup the connection as per your requirement. NAT is used when you want to share the guest machine IP with the host machine whereas you use Bridge network setting if you want the guest to be directly connected to the physical network.
If VirtualBox shows several adapter types for the bridge (it would be under the "advanced" itme on the network adapter page), you may have to test each type to find out which adapter type works.
Once the bridge is established, the port forwarding to the virtual machine can be configured in your router, because the virtual machine will be connecting directly to the router via the bridge.
I have not used these settings for hosting purposes, but, with these settings, I have ssh'd and scp'd into a virtual machine on one computer from separate physical computers on my network.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.