[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] Specify domain ID?


  • To: "Henning Sprang" <henning_sprang@xxxxxx>
  • From: "Benet Leong" <benetleong@xxxxxxxxx>
  • Date: Thu, 5 Oct 2006 15:07:19 +0800
  • Cc: "msmith@xxxxxxxxxxxxxx" <msmith@xxxxxxxxxxxxxx>, xen-users@xxxxxxxxxxxxxxxxxxx
  • Delivery-date: Thu, 05 Oct 2006 00:08:28 -0700
  • Domainkey-signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:references; b=ciWqJHtjxoBotZFF86JsH4g/OPeeS5a0LHud+4h/jISv21qD2vi+gdW5Gaq2+rYiATLWNqG/DBPX51vKjaabChifUnKxfL4Ci9OQKe3by6VnAkiv8x4pjS1aQ9QJYjfrs2/HWhmboi8r4n8b818OyeScle/a9ruLvGmVLN87nTY=
  • List-id: Xen user discussion <xen-users.lists.xensource.com>

On 10/5/06, Henning Sprang <henning_sprang@xxxxxx> wrote:
> vncserver :2 -depth 24 -geometry 1024x768

Do you know how to apply this to the vncserver automatically started
when hvm domains start?

I imagine it should be possible, but it's likely that it's not just a
config option but requires understanding the python code of xm and the
other xen-utils (which I don't at the moment).

Henning
 
----------------------------------------------
 
Well, for my current setup where I have my DomU OS installed on Debian 3.1 with XFCE windows package and VNCserver; what I did was to create a startup script and just add it to boot as you would normally do for a Linux box.So, when my domain boot-up; vncserver will automatically start.
 
Here's the general step (if you're interested):
1. In you DomU OS, create a file call vncserver in /etc/init.d
      # vi /etc/init.d/vncserver
 
2. Your script to start VNC would somehow look like this. This is a general script... you should modify it to suit your own preference. :)
 
#!/bin/sh
#
# Start/stops the vnc service.
#

test -x /usr/bin/realvncserver || exit 0
case "$1" in
        start)
                echo -n "Starting vnc server."
                export USER='root'
                su -c "/usr/bin/vncserver :1 -geometry 1024x768 depth 24"
                ;;
        stop)
                su -c "/usr/bin/vncserver -kill :1"
                ;;
        restart|force-reload)
                $0 stop
                sleep 1
                $0 start
                ;;
        *)
                echo "Usage: /etc/init.d/vncserver {start|stop|restart|force-reload}"
                exit 1
                ;;
esac
exit 0

 
3. Save the script and make it executable.
      # chmod +x /etc/init.d/vncserver
 
4. Add it to boot at startup.
      # update-rc.d vncserver defaults

And you're done...
 
Hope this helps. Cheers~!
 
Reference:
http://www.debian.org/doc/debian-policy/ch-opersys.html#s-sysvinit

--
Best regards,
Benet Leong.
On the WWW :http://www.benetleong.com
Strong mind have wills, feeble ones have only wishes.
_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.