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

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?

Submit an answer

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!

Sign In or Sign Up to Answer

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.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

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.