Howto install and configure VNC Server on Ubuntu 12 or Debian

Howto install and configure VNC Server on Ubuntu 12 or Debian

1. Install Desktop Environment for vnc server:

root@ubuntu1204:~# apt-get install gnome-core

………………………………………………………………………………………………..

Setting up xserver-xorg-video-openchrome (1:0.2.904+svn1050-1) …
Setting up xserver-xorg-video-qxl (0.0.16-2) …
Setting up xserver-xorg-video-s3 (1:0.6.3-4build2) …
Setting up xserver-xorg-video-savage (1:2.3.3-1ubuntu1) …
Setting up xserver-xorg-video-siliconmotion (1:1.7.5-1build2) …
Setting up xserver-xorg-video-sis (1:0.10.3-3build2) …
Setting up xserver-xorg-video-sisusb (1:0.9.4-2build2) …
Setting up xserver-xorg-video-tdfx (1:1.4.3-4build2) …
Setting up xserver-xorg-video-trident (1:1.3.4-2build2) …
Setting up xserver-xorg-video-vesa (1:2.3.0-7build2) …
Setting up xserver-xorg-video-vmware (1:12.0.1-1ubuntu1.1) …
Setting up xserver-xorg-video-all (1:7.6+12ubuntu1) …
Setting up xserver-xorg-input-evdev (1:2.7.0-0ubuntu1.2) …
Setting up xserver-xorg-input-synaptics (1.6.2-1ubuntu1~precise2) …
Setting up xserver-xorg-input-mouse (1:1.7.1-1build3) …
Setting up xserver-xorg-input-vmmouse (1:12.9.0-0ubuntu0.1) …
Setting up xserver-xorg-input-wacom (1:0.14.0-0ubuntu2.1) …
Setting up xserver-xorg-input-all (1:7.6+12ubuntu1) …
Setting up xserver-xorg (1:7.6+12ubuntu1) …
Setting up zeitgeist-datahub (0.8.2-1ubuntu2) …
Setting up zeitgeist (0.9.0-1ubuntu1) …
Setting up aptdaemon (0.43+bzr805-0ubuntu7) …
Setting up cups-pk-helper (0.2.1.2-1ubuntu0.1) …
Setting up indicator-sound (0.8.5.0-0ubuntu2.1) …
Setting up libprotoc7 (2.4.1-1ubuntu2) …
Setting up mobile-broadband-provider-info (20120410-0ubuntu1) …
Setting up protobuf-compiler (2.4.1-1ubuntu2) …
Setting up python-packagekit (0.7.2-4ubuntu3) …
Setting up python-aptdaemon.pkcompat (0.43+bzr805-0ubuntu7) …
Setting up ubuntuone-installer (3.0.2-0ubuntu1.1) …
Processing triggers for dictionaries-common …
aspell-autobuildhash: processing: en [en-common]
aspell-autobuildhash: processing: en [en-variant_0]
aspell-autobuildhash: processing: en [en-variant_1]
aspell-autobuildhash: processing: en [en-variant_2]
aspell-autobuildhash: processing: en [en_CA-w_accents-only]
aspell-autobuildhash: processing: en [en_CA-wo_accents-only]
aspell-autobuildhash: processing: en [en_GB-ise-w_accents-only]
aspell-autobuildhash: processing: en [en_GB-ise-wo_accents-only]
aspell-autobuildhash: processing: en [en_GB-ize-w_accents-only]
aspell-autobuildhash: processing: en [en_GB-ize-wo_accents-only]
aspell-autobuildhash: processing: en [en_US-w_accents-only]
aspell-autobuildhash: processing: en [en_US-wo_accents-only]
Setting up aspell (0.60.7~20110707-1) …
Setting up hunspell-en-us (20070829-4ubuntu3) …
Setting up libenchant1c2a (1.6.0-7) …
Setting up libwebkitgtk-3.0-0 (1.8.3-0ubuntu0.12.04.1) …
Setting up libgoa-1.0-0 (3.4.0-0ubuntu1) …
Setting up libyelp0 (3.4.1-0ubuntu1) …
Setting up yelp (3.4.1-0ubuntu1) …
Setting up ubuntu-docs (12.04.6) …
Setting up gir1.2-webkit-3.0 (1.8.3-0ubuntu0.12.04.1) …
Setting up python-ubuntu-sso-client (3.0.2-0ubuntu3) …
Setting up ubuntu-sso-client (3.0.2-0ubuntu3) …
Setting up enchant (1.6.0-7) …
Setting up librhythmbox-core5 (2.96-0ubuntu4.2) …
Setting up gir1.2-rb-3.0 (2.96-0ubuntu4.2) …
Setting up ubuntuone-client (3.0.2-0ubuntu1) …
Setting up libsyncdaemon-1.0-1 (3.0.2-0ubuntu1) …
Setting up libubuntuoneui-3.0-1 (3.0.1-0ubuntu1) …
Setting up gir1.2-ubuntuoneui-3.0 (3.0.1-0ubuntu1) …
Setting up zenity (3.4.0-0ubuntu4) …
Setting up gnome-user-guide (3.4.1-1) …
Setting up gnome-online-accounts (3.4.0-0ubuntu1) …
Setting up ubuntu-sso-client-gtk (3.0.2-0ubuntu3) …
Processing triggers for dictionaries-common …
Setting up aspell-en (6.0-0-6ubuntu2) …
Processing triggers for dictionaries-common …
Setting up libgs9 (9.05~dfsg-0ubuntu4.2) …
Setting up gconf-service-backend (3.2.5-0ubuntu2) …
Setting up gconf-service (3.2.5-0ubuntu2) …
Setting up libgconf2-4 (3.2.5-0ubuntu2) …
Setting up gconf2 (3.2.5-0ubuntu2) …
update-alternatives: using /usr/bin/gconftool-2 to provide /usr/bin/gconftool (g conftool) in auto mode.
Setting up gnome-session-bin (3.2.1-0ubuntu8) …
update-alternatives: using /usr/bin/gnome-session to provide /usr/bin/x-session- manager (x-session-manager) in auto mode.
Setting up gdm (3.0.4-0ubuntu15) …
Adding group `gdm’ (GID 121) …
Done.
Warning: The home dir /var/lib/gdm you specified already exists.
Adding system user `gdm’ (UID 111) …
Adding new user `gdm’ (UID 111) with group `gdm’ …
The home directory `/var/lib/gdm’ already exists. Not copying from `/etc/skel’.
adduser: Warning: The home directory `/var/lib/gdm’ does not belong to the user you are currently creating.
usermod: no changes
usermod: no changes
usermod: no changes
Adding group `nopasswdlogin’ (GID 122) …
Done.
Setting up libgnome-media-profiles-3.0-0 (3.0.0-1) …
Setting up gstreamer0.10-gconf (0.10.31-1ubuntu1) …
Setting up gnome-media (3.4.0-0ubuntu3.1) …
Setting up gnome-icon-theme (3.4.0-0ubuntu1.1) …
Setting up gnome-icon-theme-full (3.4.0-0ubuntu1.1) …
update-alternatives: using /usr/share/icons/gnome/scalable/places/ubuntu-logo.sv g to provide /usr/share/icons/gnome/scalable/places/start-here.svg (start-here.s vg) in auto mode.
update-alternatives: warning: skip creation of /usr/share/icons/gnome/256×256/pl aces/start-here.png because associated file /usr/share/icons/gnome/256×256/place s/ubuntu-logo.png (of link group start-here.svg) doesn’t exist.
update-alternatives: warning: skip creation of /usr/share/icons/gnome/48×48/plac es/start-here.png because associated file /usr/share/icons/gnome/48×48/places/ub untu-logo.png (of link group start-here.svg) doesn’t exist.
Setting up gnome-screensaver (3.4.1-0ubuntu1) …
Setting up libqt4-declarative (4:4.8.1-0ubuntu4.3) …
Setting up libqtgui4 (4:4.8.1-0ubuntu4.3) …
Setting up libdbusmenu-qt2 (0.9.2-0ubuntu1) …
Setting up appmenu-qt (0.2.6-0ubuntu1) …
Setting up brasero (3.4.1-0ubuntu1.1) …
Setting up metacity-common (1:2.34.1-1ubuntu11) …
Setting up libmetacity-private0 (1:2.34.1-1ubuntu11) …
Setting up libcompizconfig0 (0.9.7.0~bzr428-0ubuntu6) …
Setting up compizconfig-backend-gconf (0.9.5.92-0ubuntu5) …
Setting up compiz-gnome (1:0.9.7.12-0ubuntu1) …
Setting up compiz-plugins-main-default (1:0.9.7.0~bzr19-0ubuntu10) …
Setting up compiz (1:0.9.7.12-0ubuntu1) …
Setting up libedataserver-1.2-15 (3.2.3-0ubuntu7) …
Setting up libcamel-1.2-29 (3.2.3-0ubuntu7) …
Setting up libebook-1.2-12 (3.2.3-0ubuntu7) …
Setting up libfolks25 (0.6.8-2) …
Setting up libfolks-telepathy25 (0.6.8-2) …
Setting up empathy (3.4.2.3-0ubuntu1) …
Setting up eog (3.4.2-0ubuntu1.1) …
Setting up epiphany-browser (3.4.1-0ubuntu1) …
update-alternatives: using /usr/bin/epiphany-browser to provide /usr/bin/x-www-b rowser (x-www-browser) in auto mode.
update-alternatives: using /usr/bin/epiphany-browser to provide /usr/bin/gnome-w ww-browser (gnome-www-browser) in auto mode.
Setting up libspectre1 (0.2.6-1build1) …
Setting up libevince3-3 (3.4.0-0ubuntu1.4) …
Setting up evince (3.4.0-0ubuntu1.4) …
Setting up libebackend-1.2-1 (3.2.3-0ubuntu7) …
Setting up libecal-1.2-10 (3.2.3-0ubuntu7) …
Setting up libedata-book-1.2-11 (3.2.3-0ubuntu7) …
Setting up libedata-cal-1.2-13 (3.2.3-0ubuntu7) …
Setting up libgweather-common (3.4.1-0ubuntu1) …
Setting up libgweather-3-0 (3.4.1-0ubuntu1) …
Setting up evolution-data-server (3.2.3-0ubuntu7) …
Setting up geoclue (0.12.0-1ubuntu12) …
Setting up geoclue-ubuntu-geoip (0.0.2-0ubuntu6) …
Setting up gir1.2-gconf-2.0 (3.2.5-0ubuntu2) …
Setting up mutter-common (3.4.1-0ubuntu1) …
Setting up libmutter0 (3.4.1-0ubuntu1) …
Setting up gir1.2-mutter-3.0 (3.4.1-0ubuntu1) …
Setting up libpanel-applet-4-0 (1:3.4.1-0ubuntu1.1) …
Setting up gir1.2-panelapplet-4.0 (1:3.4.1-0ubuntu1.1) …
Setting up gnome-applets-data (3.4.1-0ubuntu1) …
Setting up libedataserverui-3.0-1 (3.2.3-0ubuntu7) …
Setting up gnome-icon-theme-symbolic (3.4.0-1) …
Setting up gnome-panel-data (1:3.4.1-0ubuntu1.1) …
Setting up gnome-panel (1:3.4.1-0ubuntu1.1) …
Setting up gnome-applets (3.4.1-0ubuntu1) …
Setting up libfolks-eds25 (0.6.8-2) …
Setting up gnome-contacts (3.4.0-1) …
Setting up libnm-gtk0 (0.9.4.1-0ubuntu2) …
Setting up gnome-settings-daemon (3.4.2-0ubuntu0.6) …
Setting up gnome-control-center (1:3.4.2-0ubuntu0.7) …
Setting up gnome-icon-theme-extras (3.4.0-1) …
Setting up gnome-power-manager (3.4.0-0ubuntu1.1) …
Setting up gnome-session (3.2.1-0ubuntu8) …
Setting up libgnome2-common (2.32.1-2ubuntu1.1) …
Setting up metacity (1:2.34.1-1ubuntu11) …
update-alternatives: using /usr/bin/metacity to provide /usr/bin/x-window-manage r (x-window-manager) in auto mode.
Setting up gnome-session-fallback (3.2.1-0ubuntu8) …
Setting up gnome-shell (3.4.1-0ubuntu2) …
Setting up gnome-terminal-data (3.4.1.1-0ubuntu1) …
Setting up gnome-terminal (3.4.1.1-0ubuntu1) …
update-alternatives: using /usr/bin/gnome-terminal.wrapper to provide /usr/bin/x -terminal-emulator (x-terminal-emulator) in auto mode.
Setting up gnome-themes-standard (3.4.1-0ubuntu1.2) …
Setting up gnome-user-share (3.0.2-0ubuntu1) …
Setting up gnome-search-tool (3.4.0-1) …
Setting up network-manager-gnome (0.9.4.1-0ubuntu2) …
Setting up totem (3.0.1-0ubuntu21.1) …
Setting up gnome-core (1:3.0+6ubuntu3) …
Setting up indicator-applet-complete (0.5.0-0ubuntu1) …
Setting up indicator-datetime (0.3.94-0ubuntu2) …
Setting up indicator-power (2.0-0ubuntu1) …
Setting up indicator-session (0.3.96-0ubuntu1) …
Setting up libcanberra-gtk-module (0.28-3ubuntu3) …
Setting up unity-services (5.18.0-0ubuntu1) …
Setting up libunity-core-5.0-5 (5.18.0-0ubuntu1) …
Setting up nautilus-sendto-empathy (3.4.2.3-0ubuntu1) …
Setting up python-gconf (2.28.1+dfsg-1) …
Setting up rhythmbox (2.96-0ubuntu4.2) …
Setting up rhythmbox-mozilla (2.96-0ubuntu4.2) …
Setting up rhythmbox-plugin-cdrecorder (2.96-0ubuntu4.2) …
Setting up rhythmbox-plugin-zeitgeist (2.96-0ubuntu4.2) …
Setting up rhythmbox-plugins (2.96-0ubuntu4.2) …
Setting up system-config-printer-gnome (1.3.8+20120201-0ubuntu8.1) …
Setting up totem-mozilla (3.0.1-0ubuntu21.1) …
Setting up totem-plugins (3.0.1-0ubuntu21.1) …
Setting up unity-common (5.18.0-0ubuntu1) …
Setting up unity-asset-pool (0.8.23-0ubuntu1) …
Setting up unity (5.18.0-0ubuntu1) …
Setting up unity-lens-applications (5.18.0-0ubuntu1) …
Setting up rhythmbox-ubuntuone (3.0.0-0ubuntu1) …
Setting up unity-scope-musicstores (5.12.0-0ubuntu2) …
Setting up libcanberra-gtk3-module (0.28-3ubuntu3) …
Setting up ghostscript (9.05~dfsg-0ubuntu4.2) …
Setting up gs-cjk-resource (1.20100103-3) …
Setting up cups-filters (1.0.18-0ubuntu0.1) …
Setting up cups (1.5.3-0ubuntu6) …
cups start/running, process 27977
Updating PPD files for cups …
Updating PPD files for cups-filters …
Updating PPD files for foomatic-db-compressed-ppds …
Updating PPD files for foomatic-db-engine …
Updating PPD files for ghostscript-cups …
Updating PPD files for gutenprint …
Updating PPD files for hpijs …
Setting up humanity-icon-theme (0.5.3.11) …
Setting up ghostscript-cups (9.05~dfsg-0ubuntu4.2) …
Setting up printer-driver-gutenprint (5.2.8~pre1-0ubuntu2.1) …
Setting up printer-driver-pnm2ppa (1.13+nondbs-0ubuntu1) …
Setting up indicator-printers (0.1.6-0ubuntu1) …
Processing triggers for libc-bin …
ldconfig deferred processing now taking place
Processing triggers for libgdk-pixbuf2.0-0 …
root@ubuntu1204:~#

2. Now we start to install VNC Server for Ubuntu 12.04:

root@ubuntu1204:~# apt-get install vnc4server

………………………………………………………………………………………………..

Setting up python-ubuntu-sso-client (3.0.2-0ubuntu3) …
Setting up ubuntu-sso-client (3.0.2-0ubuntu3) …
Setting up enchant (1.6.0-7) …
Setting up librhythmbox-core5 (2.96-0ubuntu4.2) …
Setting up gir1.2-rb-3.0 (2.96-0ubuntu4.2) …
Setting up ubuntuone-client (3.0.2-0ubuntu1) …
Setting up libsyncdaemon-1.0-1 (3.0.2-0ubuntu1) …
Setting up libubuntuoneui-3.0-1 (3.0.1-0ubuntu1) …
Setting up gir1.2-ubuntuoneui-3.0 (3.0.1-0ubuntu1) …
Setting up zenity (3.4.0-0ubuntu4) …
Setting up gnome-user-guide (3.4.1-1) …
Setting up gnome-online-accounts (3.4.0-0ubuntu1) …
Setting up ubuntu-sso-client-gtk (3.0.2-0ubuntu3) …
Processing triggers for dictionaries-common …
Setting up aspell-en (6.0-0-6ubuntu2) …
Processing triggers for dictionaries-common …
Setting up libgs9 (9.05~dfsg-0ubuntu4.2) …
Setting up gconf-service-backend (3.2.5-0ubuntu2) …
Setting up gconf-service (3.2.5-0ubuntu2) …
Setting up libgconf2-4 (3.2.5-0ubuntu2) …
Setting up gconf2 (3.2.5-0ubuntu2) …
update-alternatives: using /usr/bin/gconftool-2 to provide /usr/bin/gconftool (g conftool) in auto mode.
Setting up gnome-session-bin (3.2.1-0ubuntu8) …
update-alternatives: using /usr/bin/gnome-session to provide /usr/bin/x-session- manager (x-session-manager) in auto mode.
Setting up gdm (3.0.4-0ubuntu15) …
Adding group `gdm’ (GID 121) …
Done.
Warning: The home dir /var/lib/gdm you specified already exists.
Adding system user `gdm’ (UID 111) …
Adding new user `gdm’ (UID 111) with group `gdm’ …
The home directory `/var/lib/gdm’ already exists. Not copying from `/etc/skel’.
adduser: Warning: The home directory `/var/lib/gdm’ does not belong to the user you are currently creating.
usermod: no changes
usermod: no changes
usermod: no changes
Adding group `nopasswdlogin’ (GID 122) …
Done.
Setting up libgnome-media-profiles-3.0-0 (3.0.0-1) …
Setting up gstreamer0.10-gconf (0.10.31-1ubuntu1) …
Setting up gnome-media (3.4.0-0ubuntu3.1) …
Setting up gnome-icon-theme (3.4.0-0ubuntu1.1) …
Setting up gnome-icon-theme-full (3.4.0-0ubuntu1.1) …
update-alternatives: using /usr/share/icons/gnome/scalable/places/ubuntu-logo.sv g to provide /usr/share/icons/gnome/scalable/places/start-here.svg (start-here.s vg) in auto mode.
update-alternatives: warning: skip creation of /usr/share/icons/gnome/256×256/pl aces/start-here.png because associated file /usr/share/icons/gnome/256×256/place s/ubuntu-logo.png (of link group start-here.svg) doesn’t exist.
update-alternatives: warning: skip creation of /usr/share/icons/gnome/48×48/plac es/start-here.png because associated file /usr/share/icons/gnome/48×48/places/ub untu-logo.png (of link group start-here.svg) doesn’t exist.
Setting up gnome-screensaver (3.4.1-0ubuntu1) …
Setting up libqt4-declarative (4:4.8.1-0ubuntu4.3) …
Setting up libqtgui4 (4:4.8.1-0ubuntu4.3) …
Setting up libdbusmenu-qt2 (0.9.2-0ubuntu1) …
Setting up appmenu-qt (0.2.6-0ubuntu1) …
Setting up brasero (3.4.1-0ubuntu1.1) …
Setting up metacity-common (1:2.34.1-1ubuntu11) …
Setting up libmetacity-private0 (1:2.34.1-1ubuntu11) …
Setting up libcompizconfig0 (0.9.7.0~bzr428-0ubuntu6) …
Setting up compizconfig-backend-gconf (0.9.5.92-0ubuntu5) …
Setting up compiz-gnome (1:0.9.7.12-0ubuntu1) …
Setting up compiz-plugins-main-default (1:0.9.7.0~bzr19-0ubuntu10) …
Setting up compiz (1:0.9.7.12-0ubuntu1) …
Setting up libedataserver-1.2-15 (3.2.3-0ubuntu7) …
Setting up libcamel-1.2-29 (3.2.3-0ubuntu7) …
Setting up libebook-1.2-12 (3.2.3-0ubuntu7) …
Setting up libfolks25 (0.6.8-2) …
Setting up libfolks-telepathy25 (0.6.8-2) …
Setting up empathy (3.4.2.3-0ubuntu1) …
Setting up eog (3.4.2-0ubuntu1.1) …
Setting up epiphany-browser (3.4.1-0ubuntu1) …
update-alternatives: using /usr/bin/epiphany-browser to provide /usr/bin/x-www-b rowser (x-www-browser) in auto mode.
update-alternatives: using /usr/bin/epiphany-browser to provide /usr/bin/gnome-w ww-browser (gnome-www-browser) in auto mode.
Setting up libspectre1 (0.2.6-1build1) …
Setting up libevince3-3 (3.4.0-0ubuntu1.4) …
Setting up evince (3.4.0-0ubuntu1.4) …
Setting up libebackend-1.2-1 (3.2.3-0ubuntu7) …
Setting up libecal-1.2-10 (3.2.3-0ubuntu7) …
Setting up libedata-book-1.2-11 (3.2.3-0ubuntu7) …
Setting up libedata-cal-1.2-13 (3.2.3-0ubuntu7) …
Setting up libgweather-common (3.4.1-0ubuntu1) …
Setting up libgweather-3-0 (3.4.1-0ubuntu1) …
Setting up evolution-data-server (3.2.3-0ubuntu7) …
Setting up geoclue (0.12.0-1ubuntu12) …
Setting up geoclue-ubuntu-geoip (0.0.2-0ubuntu6) …
Setting up gir1.2-gconf-2.0 (3.2.5-0ubuntu2) …
Setting up mutter-common (3.4.1-0ubuntu1) …
Setting up libmutter0 (3.4.1-0ubuntu1) …
Setting up gir1.2-mutter-3.0 (3.4.1-0ubuntu1) …
Setting up libpanel-applet-4-0 (1:3.4.1-0ubuntu1.1) …
Setting up gir1.2-panelapplet-4.0 (1:3.4.1-0ubuntu1.1) …
Setting up gnome-applets-data (3.4.1-0ubuntu1) …
Setting up libedataserverui-3.0-1 (3.2.3-0ubuntu7) …
Setting up gnome-icon-theme-symbolic (3.4.0-1) …
Setting up gnome-panel-data (1:3.4.1-0ubuntu1.1) …
Setting up gnome-panel (1:3.4.1-0ubuntu1.1) …
Setting up gnome-applets (3.4.1-0ubuntu1) …
Setting up libfolks-eds25 (0.6.8-2) …
Setting up gnome-contacts (3.4.0-1) …
Setting up libnm-gtk0 (0.9.4.1-0ubuntu2) …
Setting up gnome-settings-daemon (3.4.2-0ubuntu0.6) …
Setting up gnome-control-center (1:3.4.2-0ubuntu0.7) …
Setting up gnome-icon-theme-extras (3.4.0-1) …
Setting up gnome-power-manager (3.4.0-0ubuntu1.1) …
Setting up gnome-session (3.2.1-0ubuntu8) …
Setting up libgnome2-common (2.32.1-2ubuntu1.1) …
Setting up metacity (1:2.34.1-1ubuntu11) …
update-alternatives: using /usr/bin/metacity to provide /usr/bin/x-window-manage r (x-window-manager) in auto mode.
Setting up gnome-session-fallback (3.2.1-0ubuntu8) …
Setting up gnome-shell (3.4.1-0ubuntu2) …
Setting up gnome-terminal-data (3.4.1.1-0ubuntu1) …
Setting up gnome-terminal (3.4.1.1-0ubuntu1) …
update-alternatives: using /usr/bin/gnome-terminal.wrapper to provide /usr/bin/x -terminal-emulator (x-terminal-emulator) in auto mode.
Setting up gnome-themes-standard (3.4.1-0ubuntu1.2) …
Setting up gnome-user-share (3.0.2-0ubuntu1) …
Setting up gnome-search-tool (3.4.0-1) …
Setting up network-manager-gnome (0.9.4.1-0ubuntu2) …
Setting up totem (3.0.1-0ubuntu21.1) …
Setting up gnome-core (1:3.0+6ubuntu3) …
Setting up indicator-applet-complete (0.5.0-0ubuntu1) …
Setting up indicator-datetime (0.3.94-0ubuntu2) …
Setting up indicator-power (2.0-0ubuntu1) …
Setting up indicator-session (0.3.96-0ubuntu1) …
Setting up libcanberra-gtk-module (0.28-3ubuntu3) …
Setting up unity-services (5.18.0-0ubuntu1) …
Setting up libunity-core-5.0-5 (5.18.0-0ubuntu1) …
Setting up nautilus-sendto-empathy (3.4.2.3-0ubuntu1) …
Setting up python-gconf (2.28.1+dfsg-1) …
Setting up rhythmbox (2.96-0ubuntu4.2) …
Setting up rhythmbox-mozilla (2.96-0ubuntu4.2) …
Setting up rhythmbox-plugin-cdrecorder (2.96-0ubuntu4.2) …
Setting up rhythmbox-plugin-zeitgeist (2.96-0ubuntu4.2) …
Setting up rhythmbox-plugins (2.96-0ubuntu4.2) …
Setting up system-config-printer-gnome (1.3.8+20120201-0ubuntu8.1) …
Setting up totem-mozilla (3.0.1-0ubuntu21.1) …
Setting up totem-plugins (3.0.1-0ubuntu21.1) …
Setting up unity-common (5.18.0-0ubuntu1) …
Setting up unity-asset-pool (0.8.23-0ubuntu1) …
Setting up unity (5.18.0-0ubuntu1) …
Setting up unity-lens-applications (5.18.0-0ubuntu1) …
Setting up rhythmbox-ubuntuone (3.0.0-0ubuntu1) …
Setting up unity-scope-musicstores (5.12.0-0ubuntu2) …
Setting up libcanberra-gtk3-module (0.28-3ubuntu3) …
Setting up ghostscript (9.05~dfsg-0ubuntu4.2) …
Setting up gs-cjk-resource (1.20100103-3) …
Setting up cups-filters (1.0.18-0ubuntu0.1) …
Setting up cups (1.5.3-0ubuntu6) …
cups start/running, process 27977
Updating PPD files for cups …
Updating PPD files for cups-filters …
Updating PPD files for foomatic-db-compressed-ppds …
Updating PPD files for foomatic-db-engine …
Updating PPD files for ghostscript-cups …
Updating PPD files for gutenprint …
Updating PPD files for hpijs …
Setting up humanity-icon-theme (0.5.3.11) …
Setting up ghostscript-cups (9.05~dfsg-0ubuntu4.2) …
Setting up printer-driver-gutenprint (5.2.8~pre1-0ubuntu2.1) …
Setting up printer-driver-pnm2ppa (1.13+nondbs-0ubuntu1) …
Setting up indicator-printers (0.1.6-0ubuntu1) …
Processing triggers for libc-bin …
ldconfig deferred processing now taking place
Processing triggers for libgdk-pixbuf2.0-0 …
root@ubuntu1204:~# apt-get install vnc4server
Reading package lists… Done
Building dependency tree
Reading state information… Done
The following extra packages will be installed:
cpp cpp-4.6 libfs6 libmpc2 x11-apps x11-session-utils x11-xfs-utils x11-xserver-utils xbase-clients xbitmaps xinit
Suggested packages:
cpp-doc gcc-4.6-locales vnc-java mesa-utils nickle cairo-5c xorg-docs-core
The following NEW packages will be installed:
cpp cpp-4.6 libfs6 libmpc2 vnc4server x11-apps x11-session-utils x11-xfs-utils x11-xserver-utils xbase-clients xbitmaps xinit
0 upgraded, 12 newly installed, 0 to remove and 32 not upgraded.
Need to get 7,856 kB of archives.
After this operation, 20.4 MB of additional disk space will be used.
Do you want to continue [Y/n]? y
Get:1 http://us.archive.ubuntu.com/ubuntu/ precise/main libmpc2 i386 0.9-4 [40.7 kB]
Get:2 http://us.archive.ubuntu.com/ubuntu/ precise/main cpp-4.6 i386 4.6.3-1ubuntu5 [4,659 kB]
Get:3 http://us.archive.ubuntu.com/ubuntu/ precise/main cpp i386 4:4.6.3-1ubuntu5 [27.6 kB]
Get:4 http://us.archive.ubuntu.com/ubuntu/ precise/main libfs6 i386 2:1.0.3-1 [24.6 kB]
Get:5 http://us.archive.ubuntu.com/ubuntu/ precise/main x11-apps i386 7.6+5ubuntu1 [695 kB]
Get:6 http://us.archive.ubuntu.com/ubuntu/ precise/main x11-session-utils i386 7.6+2 [74.9 kB]
Get:7 http://us.archive.ubuntu.com/ubuntu/ precise/main x11-xfs-utils i386 7.6+1 [26.6 kB]
Get:8 http://us.archive.ubuntu.com/ubuntu/ precise/main x11-xserver-utils i386 7.6+3 [173 kB]
Get:9 http://us.archive.ubuntu.com/ubuntu/ precise/main xinit i386 1.3.1-1 [18.2 kB]
Get:10 http://us.archive.ubuntu.com/ubuntu/ precise/main xbase-clients all 1:7.6+12ubuntu1 [2,320 B]
Get:11 http://us.archive.ubuntu.com/ubuntu/ precise/universe vnc4server i386 4.1.1+xorg4.3.0-37ubuntu4 [2,087 kB]
Get:12 http://us.archive.ubuntu.com/ubuntu/ precise/main xbitmaps all 1.1.1-1 [27.5 kB]
Fetched 7,856 kB in 18s (421 kB/s)
Selecting previously unselected package libmpc2.
(Reading database … 103303 files and directories currently installed.)
Unpacking libmpc2 (from …/libmpc2_0.9-4_i386.deb) …
Selecting previously unselected package cpp-4.6.
Unpacking cpp-4.6 (from …/cpp-4.6_4.6.3-1ubuntu5_i386.deb) …
Selecting previously unselected package cpp.
Unpacking cpp (from …/cpp_4%3a4.6.3-1ubuntu5_i386.deb) …
Selecting previously unselected package libfs6.
Unpacking libfs6 (from …/libfs6_2%3a1.0.3-1_i386.deb) …
Selecting previously unselected package x11-apps.
Unpacking x11-apps (from …/x11-apps_7.6+5ubuntu1_i386.deb) …
Selecting previously unselected package x11-session-utils.
Unpacking x11-session-utils (from …/x11-session-utils_7.6+2_i386.deb) …
Selecting previously unselected package x11-xfs-utils.
Unpacking x11-xfs-utils (from …/x11-xfs-utils_7.6+1_i386.deb) …
Selecting previously unselected package x11-xserver-utils.
Unpacking x11-xserver-utils (from …/x11-xserver-utils_7.6+3_i386.deb) …
Selecting previously unselected package xinit.
Unpacking xinit (from …/xinit_1.3.1-1_i386.deb) …
Selecting previously unselected package xbase-clients.
Unpacking xbase-clients (from …/xbase-clients_1%3a7.6+12ubuntu1_all.deb) …
Selecting previously unselected package vnc4server.
Unpacking vnc4server (from …/vnc4server_4.1.1+xorg4.3.0-37ubuntu4_i386.deb) …
Selecting previously unselected package xbitmaps.
Unpacking xbitmaps (from …/xbitmaps_1.1.1-1_all.deb) …
Processing triggers for man-db …
Setting up libmpc2 (0.9-4) …
Setting up cpp-4.6 (4.6.3-1ubuntu5) …
Setting up cpp (4:4.6.3-1ubuntu5) …
Setting up libfs6 (2:1.0.3-1) …
Setting up x11-apps (7.6+5ubuntu1) …
Setting up x11-session-utils (7.6+2) …
Setting up x11-xfs-utils (7.6+1) …
Setting up x11-xserver-utils (7.6+3) …
Setting up xinit (1.3.1-1) …
Setting up xbase-clients (1:7.6+12ubuntu1) …
Setting up vnc4server (4.1.1+xorg4.3.0-37ubuntu4) …
update-alternatives: using /usr/bin/vnc4server to provide /usr/bin/vncserver (vncserver) in auto mode.
update-alternatives: using /usr/bin/Xvnc4 to provide /usr/bin/Xvnc (Xvnc) in auto mode.
update-alternatives: using /usr/bin/x0vnc4server to provide /usr/bin/x0vncserver (x0vncserver) in auto mode.
update-alternatives: using /usr/bin/vnc4passwd to provide /usr/bin/vncpasswd (vncpasswd) in auto mode.
update-alternatives: using /usr/bin/vnc4config to provide /usr/bin/vncconfig (vncconfig) in auto mode.
Setting up xbitmaps (1.1.1-1) …
Processing triggers for libc-bin …
ldconfig deferred processing now taking place

3. In order to use VNC, we need to setup a password using the following command:

root@ubuntu1204:~# vncserver

You will require a password to access your desktops.

Password:
Verify:
xauth: file /root/.Xauthority does not exist

New ‘ubuntu1204:1 (root)’ desktop is ubuntu1204:1

Creating default startup script /root/.vnc/xstartup
Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/ubuntu1204:1.log

4. Now we need to edit VNC configure file by vi command:

root@ubuntu1204:~# vi .vnc/xstartup
#!/bin/sh
# Uncomment the following two lines for normal desktop:
unset SESSION_MANAGER
#exec /etc/X11/xinit/xinitrc
gnome-session –session=gnome-classic &

[ -x /etc/vnc/xstartup ] && exec /etc/vnc/xstartup
[ -r $HOME/.Xresources ] && xrdb $HOME/.Xresources
xsetroot -solid grey
vncconfig -iconic &
#x-terminal-emulator -geometry 1280×1024+10+10 -ls -title “$VNCDESKTOP Desktop” &
#x-window-manager &

5. Create the VNC Session:

root@ubuntu1204:~# vncserver –geometry 1024×600

New ‘ubuntu1204:1 (root)’ desktop is ubuntu1204:1

Starting applications specified in /root/.vnc/xstartup
Log file is /root/.vnc/ubuntu1204:1.log

6. Open VNC Viewer and connect using ServerIP/Hostname:1/2…In my case it is 192.168.1.101:1

That’s all. Thanks for using IThelpblog.com.

Leave a reply

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>