Setup VNC on Ubuntu Hardy PV DomU at Solaris Nevada Dom0 (build 98)

This posting mostly deals with utilizing same image file for loading HVM and PV Ubuntu Hardy DomUs at SNV_98 Dom0. Due to ongoing issue with “rge” driver Solaris Nevada (98) causes faillure to run “apt-get install” at Ubuntu (Debian) PV DomUs, until checksums offloading at DomU will get disabled via “ethtool” ( for instance). It also provides a workaround to get Gnome Desktop working stable at Ubuntu PV DomU no matter on Xen Release (>=3.1.2) and OS (Solaris,Linux) running at Dom0. Install Ubuntu Hardy HVM DomU via virt-manger. Login to HVM console and run as in [1] :-
# apt-get install linux-image-xen
# apt-get install vim
********************************************
Add one more entry to /boot/grub/menu.lst
*********************************************
default 0
# hidemenu
timeout 10

title Ubuntu 8.04.1, kernel 2.6.24-21-xen
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-21-xen root=UUID=d60fdbd1-29a5-452e-81b8-20af8423cb33 ro
initrd /boot/initrd.img-2.6.24-21-xen

title Ubuntu 8.04.1, kernel 2.6.24-19-generic
root (hd0,0)
kernel /boot/vmlinuz-2.6.24-19-generic root=UUID=d60fdbd1-29a5-452e-81b8-20af8423cb33 ro quiet splash
initrd /boot/initrd.img-2.6.24-19-generic
quiet
. . . . . .
:wq
Add a console on xvc0:
# sed -e ‘s/tty1/xvc0/’ /etc/event.d/tty1 | tee /etc/event.d/xvc0
Shutdown HVM DomU.
Create Ubuntu PV DomU profile at Dom0, referencing same image file as Ubuntu HVM DomU:-
bash-3.2# cat ub8.cfg
memory = 2048
name = “U8PV”
vif = [ ‘mac=00:16:3e:00:00:00’ ]
disk = [ ‘file:/export/home/images/ubdisk.img,xvda,w!’]
****************
Start PV DomU
****************
# xm create -c ub8.cfg





********************************
When logged in as root run :-
********************************
# apt-get remove network-manager
# vi /etc/network/interfaces
auto lo
iface lo inet loopback
auto eth0
iface eth0 inet dhcp
:wq
************************************************************
Obtain IP address for PV DomU without network-manager
************************************************************
# /etc/init.d/networking restart
Listening on LPF/eth0/00:16:3e:00:00:00
Sending on LPF/eth0/00:16:3e:00:00:00
Sending on Socket/fallback
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 5
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 9
DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 11
DHCPOFFER of 192.168.1.60 from 192.168.1.1
DHCPREQUEST of 192.168.1.60 on eth0 to 255.255.255.255 port 67
DHCPACK of 192.168.1.60 from 192.168.1.1
bound to 192.168.1.60 — renewal in 103564 seconds.
*********************************************************************
Next step is required if SNV Dom0 has RTL 8169SC,8110SC NIC
It disables checksums offloading at Ubuntu Hardy DomU
**********************************************************************
# /usr/local/sbin/ethtool -K eth0 tx off
Install of gcc,build-essentials and ethtool-6 has been done via apt-get install in Ubuntu HVM DomU.
That’s a tricky place , because broken driver for RTL Gibatit NIC at SNV Dom0 have us to use same image file for HVM and PV DomUs to be able run “apt-get install gcc build-essentials” and any other stuff until the point when “ethtool” gets built and checksums offloading may be disabled at PV DomU . It might appear impossible to run “apt-get install” at Ubuntu (Debian) PV DomU in case when NIC at SNV Dom0 has a broken driver like “rge”.
****************************************
Setup VNC at Ubuntu Hardy PV DomU
****************************************
# apt-get install vnc4server xinetd

# vi /etc/gdm/gdm.conf
Uncomment this line
RemoteGreeter=/usr/lib/gdm/gdmlogin
Enable xdmcp, look for [xdmcp] and change Enable to true.
[xdmcp]
Enable=true
************
Restart gdm
************
# /etc/init.d/gdm restart
Setup xinetd
************************************
Create a new service file for xinetd
************************************
# vi /etc/xinetd.d/Xvnc
service Xvnc
{
type = UNLISTED
disable = no
socket_type = stream
protocol = tcp
wait = no
user = nobody
server = /usr/bin/Xvnc
server_args = -inetd -query localhost -geometry 1024×768 -depth 16 -cc 3 -once -SecurityTypes=none -extension XFIXES
port = 5901
}
**************
Restart xinetd
**************
# /etc/init.d/xinetd restart

When connect via vncviewer from Dom0, getting Error Window “Gnome Setting Daemon failed to start”. To fix Gnome Setting Daemon failures to start, open vnc session with DomU ([2]) and run in gnome terminal ([3]):-
$ gconf-editor
and disable mouse and keyboard plugins.
Relogin to Ubuntu PV DomU via vncviewer.
Gnome Desktop should be working fine.







References.
1.http://blog.bashton.com/2008/running-an-ubuntu-hardy-xen-domu-under-a-centos-dom0/
2.http://lxer.com/module/newswire/view/110161/index.html
3.https://bugs.launchpad.net/ubuntu/+source/gnome-settings-daemon/+bug/199245

Leave a comment