Ubuntu 12.04 under Configure NVC to share desktop to Windows

Source: Internet
Author: User

original link:http://www.faceye.net/search/143315.html

Recently in a project, need to use Android emulator, usually with the PC is Win7, there is a computer installed Ubuntu 12.04, but no monitor, found by remote connection to the Ubuntu machine, emulator run up, error, look for experts to see, It should be OpenGL not supported.
Then the display, too occupy the place, think of desktop sharing, that is, the use of NVC.

The configuration of the NVC is also very simple.

First, go to the gnome classical interface, and on the desktop share, preferences, tools----check the appropriate options.
All of my options are on the default tick, so this step just turns on validation.

The second step is to install NVC server on Ubuntu using the following command:


This step is performed, it is found that the system has been installed in the original.

The third step is to start NVC server and execute the command: Nvcserver
You will be prompted to enter your desktop login password and prompt for your desktop number.

The fourth step is to download a NVC viewer on Windows, or you can use other tools.
NVC Viewer:

Fifth Step Open NVC Viewer, enter the server address and desktop number, such as: 172.26.18.72:2, and then enter the desktop login password.
But when opened, found that the desktop is rather ugly, only one terminal.
After searching the internet, I found that we need to modify the configuration of NVC server on Ubuntu.

Sixth step, modify the NVC server configuration.
After the NVC server is installed, a. NVC directory is created under the user's root directory, which has a xstartup file, before modification, with the following contents:

#!/bin/sh# uncomment the following and lines for normal desktop:# unset session_manager# exec/etc/x11/xinit/xinitrc[-X/ Etc/vnc/xstartup] && exec/etc/vnc/xstartup[-R $HOME/. Xresources] && Xrdb $HOME/. Xresourcesxsetroot-solid greyvncconfig-iconic &x-terminal-emulator-geometry 80x24+10+10-ls-title "$VNCDESKTOP Desktop "&x-window-manager &


Reference
Say to modify the last line according to the desktop environment:
? If it's a gnome desktop, change to Gnome-session &;
? If it's KDE desktop, change to Startkde &;
If it's a unity desktop, first go to/usr/share/gnome-session/sessions/to see the name of the desktop session, and if it is ubuntu-2d, change the last line to:

Export startup= "/usr/bin/gnome-session--session=ubuntu-2d" $STARTUP


But after the change, it's still not working.

Find the information again, some people say that need to

# unset Session_manager

Comment, and add the following line:

Unset dbus_session_bus_address

The final modified file is as follows:

#!/bin/sh# uncomment the following and lines for normal desktop:unset session_managerunset dbus_session_bus_address# exec /etc/x11/xinit/xinitrc[-x/etc/vnc/xstartup] && exec/etc/vnc/xstartup[-R $HOME/. Xresources] && Xrdb $HOME/. Xresourcesxsetroot-solid greyvncconfig-iconic &x-terminal-emulator-geometry 80x24+10+10-ls-title "$VNCDESKTOP Desktop "Startkde gnome_session x-window-manager &export desktop_session=ubuntu-2dexport Gdmsession=ubuntu-2dexport startup= "/usr/bin/gnome-session--session=ubuntu-2d" $STARTUP


This time OK, on the Win7 through the NVC viewer to see the same interface with Ubuntu.

original link:http://www.faceye.net/search/143315.html

Ubuntu 12.04 under Configure NVC to share desktop to Windows

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.