You can access the services and resources that an Oracle SOA Cloud Service VM provides by logging into the VM through VNC.
You can use any VNC client utility to access a VM. For example, if you are using Windows, you might use RealVNC or TightVNC; if you are using Linux, you might use the
vncviewer utility included with your Linux distribution.
By default, the port used by the VNC server on a Oracle SOA Cloud Service VM is not directly accessible through the Internet. An SSH tunnel enables access to the VNC server port on your local machine. An SSH tunnel also ensures that VNC communication is using a secure channel.
In order create a VNC session on a VM, you must first identify the public IP address and connect to it with SSH:
- Use the
sshcommand to connect to the VM:
ssh -i private_key opc@VM_IP_address
- Change to the
sudo su - oracle
oracleVM user has regular OS user permissions. It is intended to be used to start and stop Oracle products that have been installed on the VM, or to run other Oracle applications and utilities on the VM.
- Disable the desktop screensaver lock for this user:
gconftool-2 -s -t bool /apps/gnome-screensaver/lock_enabled falseThis Linux property controls whether or not the desktop prompts you for the user’s password when in screensaver mode.
- Start the VNC server on the VM:
vncserver :1 -nolisten tcp -localhost -geometry 1680x1050
Use the following command to confirm if the VNC server started:
ps -ef|grep vncserver
The VNC server is not directly accessible from clients outside of this VM. An SSH tunnel will be used to enable external and secure access to the VNC server.
By default, the listen port for VNC session
5902, and so on.
If your local machine has a smaller display resolution, use a different geometry setting such as
- When prompted, enter a password for this VNC session.
- Disconnect from the VM.
- Create an SSH tunnel to
localhost:5901on the VM.
ssh -i path_to_private_key -L 5901:localhost:5901 opc@VM_IP_address -N
ssh -i /home/myuser/id_rsa -L 5901:localhost:5901 firstname.lastname@example.org -N
- Launch your VNC client application and connect to
- When prompted, enter the password that you previously configured for this VNC session.
Note:After your VNC work is complete, you can perform a
<ctrl> Cto shut down the SSH tunnel.
Note:To terminate the VNC server on the VM, run
vncserver —kill :1.