I have Windows 7. Installed VirtualBox and Ubuntu 11.04 as guest OS.
Networking is done by NAT.
Everything is fine: I have internet on Ubuntu.
I can access Windows from Ubuntu by its ip.
But i can't access Ubuntu by it's ip which is shown by ifconfig.
I run rails on Ubuntu.
How can I solve this problem: connect to Ubuntu/Rails server on ort 3000 from my Windows?
By default, VirtualBox's NAT allows the virtual machine to access the Internet ; but doesn't allow the physical machine to access the Virtual one.
The simplest solution would be to use another networking setting than NAT, for your Virtual Machine -- for instance, bridge should work fine (your VM would be visible on your network, though).
Another solution would be to use port forwarding ; about that, this article might help : Howto Access via ssh a Virtualbox Guest machine.
I used to struggle with configuring a similar setup until I found Vagrant. Vagrant makes it very simple to setup, connect to and work with a Linux virtual machine. After Vagrant is configured you can just type vagrant ssh to enter the virtual machine and your account has automatic sudo rights and everything works as expected - you don't even have to deal with logging into the vm. The initial setup for ssh does look to be a little more work under Windows though as you need to configure Putty before you can connect.
There is a simple configuration file in Vagrant that you use to specify which ports from the VM you want forwarded to your machine using a syntax like:
config.vm.forward_port("rails", 80, 3000)
config.vm.forward_port("tomcat", 8000, 8080)
and everything is taken care of. Details are here
If, for example, you are using Rails and you start vagrant with the command vagrant up in your Rails project directory than that directory is available on the VM. Since it is the same shared directory between machines, any changes you make in your Rails project directory on your machine using your regular editor is seen on the VM also. This makes testing in other environments very easy.
Instructions for setting Vagrant up with Windows are here and a RailsCast about it is here. Note that Vagrant has nothing to do directly with Rails - you can use it for setup of any virtual machine environment you need.
In short, you can't.
It is a local host not a public domain therefore not publicly accessible outside of your virtualbox environment.
Maybe someone has a clever hack for this but why would you want to do this in the first place?
Your solution is to either use firefox to browse to your localhost within your virtualbox linux session or develop on windows.
Personally I work the other way round I run Ubuntu 11.04 and I have virtualbox installations of xp, 2,000, me, vista and 7 so I can test in different environments. Inevitably I end up sharing my project folder from Ubuntu so that I can run the project in whatever OS I am testing for.
Related
I am new to Hadoop and the Big Data world...
I have installed the Hortonworks Sandbox VM in Virtual Box. It's working great...
Can someone tell me how to install Firefox within the VM? I need it to use NIFI
Thanks a lot for any help!
Installing a browser on the VM and using it through VNC will typically be very slow. The best option is to set up an SSH Tunnel and do a local forward. If you use the PuTTy ssh client on windows then you can follow the following instructions on setting up the local forward which will allow you to use your browser on the host operating system to connect to the NIFI instance running in your VM.
I am currently running two virtual machines using virtualbox, one is an ubuntu 14.04 and the other one is a centOS7 on a redhat (64 bit) system. What I am trying to do is to write a shell script that simply copies a file to my centOS7 machine, I am running this script in my ubuntu machine and the file is on the Ubuntu virtual hard drive. I have so far set the IP in my CentOS7 to be static to xxx.xxx.xxx and the script is simply written as scp file_to_move username#xxx.xxx.xxx:/here/.
but it does not work I wonder is there something I need to configure in my virtualbox or is the script plain wrong?
1) Have you installed ssh-server on your ubuntu machine
2) Have you generated the public/private e.g. RSA keys pair to enable the batch usage of ssh client in your script
3) Have you properly configured the VirtualBox eth cards so that both your machines are in the same network (machines can ping one another)
...
As you can see there may be a lot of reasons why you cannot copy files between your machines and without additional environment information it is hard to say what is causing the issue in your case.
I am running a virtual machine in Bluemix and want to open the OS's desktop GUI. How do I do this? Thanks for your help.
I've edited your question to what I think you're asking: How can I open the desktop GUI on my virtual machine in Bluemix?
Assuming I understand the question correctly:
To open the desktop GUI on a remote virtual machine, use Virtual Network Computing (VNC). This solution is not specific to Bluemix; it'll work with a VM running on any platform, as long as the VM is running an OS that supports VNC.
To use VNC, you need to have a VNC server running in your VM's OS. You will then run a VNC client (a.k.a. viewer) on your computer to display the VM's desktop. The specific instructions depend on the OS running in the VM and on your computer.
For example, assuming your VM is running Ubuntu v14.04, these resources explain what to do (and a search will find other resources):
"How to Install and Configure VNC on Ubuntu 14.04" -- Installs XFCE4 as the VNC server
"How To Install And Configure VNC On Ubuntu 14.04" -- Also installs XFCE4.
"How to Install VNC Server on Ubuntu 14.04 LTS" -- Installs TightVNC as the VNC server
For a VNC client, I actually connect to remote VMs via a local VM running Ubutu 14.04, so I use Vinagre (a.k.a. the Remote Desktop Viewer app). Options listed by other authors include TightVNC, RealVNC, or UltraVNC.
Good luck and thanks for using Bluemix.
From what I understand, you need some remote desktop tool to get to the UI of the OS of your virtual machine. Some tools available: http://www.techradar.com/us/news/software/applications/7-of-the-best-linux-remote-desktop-clients-716346
On my OSX machine I have two VM's running:
Development Environment (aka DE) (Linux)
Testing Environment (aka TE) (Win7 IE9)
In my TE, I would like to be able to access a server running on my DE. Pretty straight forward sounding but I'm sort of new.
I'm using Virtualbox as my client on both machines. My dev environment is a vagrant box setup with puppet. I can modify it with virtualbox as well for now. SIMPLEST solution wins. I have tried nested-boxing, it doesn't work :P
I was able to achieve the desired results much more easily than I had anticipated. I had to add the same lines I added to my local machine to my VM.
Here is the situation:
-Using VMWare Workstation, set the network adapter to bridge.
-Host os is winxp, guest os is CentOS 5
-Apache server installed in guest (centos) os
-Say my host ip:172.19.20.100, my guest ip:172.19.20.101
My host installed rails, so I just type 'rails server' in command line, it started up a server.I can access that in my guest os when I typing 172.19.20.100:3000 into the browser.
But when I started Apache server in guest, I can't access that in host when I typing 172.19.20.101 into the browser. If I type 172.19.20.101 in the guest, it does work...And ping 172.19.20.101 in the host command line also works.
So I guess something goes wrong in the apache server. But I comapred the httpd.conf with some tutorials and didn't see anything unusual.
Please give some advice.
There is a Windows Installer for rails, and xampp as apache server for windows, both as installer.
It might take a moment or two to get them installed, but it's well worth the effort, since you wouldn't have to deal with virtualization-related problems that way.