Report this

What is the reason for this report?

Running LAMP in VirtualBox, can't visit IP address on host pc.

Posted on May 29, 2015
Even

By Even

I’m currently running LAMP with gui in VirtualBox. Ive installed phpmyadmin as well. Visiting my IP address and phpmyadmin works in the web browser in the gui in VirtualBox just fine. But i don’t really want a gui with LAMP. I only want the terminal. But i want to be able to use phpmyadmin with my host PC. When i try this it dosen’t work. Why is that? is there something i can do to solve this?



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

By default a new VirtualBox machine will have it’s network interface set to NAT. If you switch this to a bridged adapter, other computers on your local network will be able to access it and it will reach out to your router for it’s own IP. As long as you haven’t set a static IP address you should be able to power off your VM, change this setting and power back on. Your VM will now have a new IP address on the same subnet as your host system and should be reachable via a browser.

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.