XEN windows elérése VNC-vel

Fórumok

Sziasztok !

Debian alatt próbálok futtatni egy windowsos domaint de sajnos nem tudom elérni. A beállitásokat két howto alapján csináltam:
http://www.howtoforge.com/virtualization-with-xen-on-debian-lenny-amd64
http://www.virtuatopia.com/index.php/Installing_and_Running_Windows_XP_…

xm create windows.cfg után a virtuáis gép látszólag hiba nélül elindul. létrejön a vif interface is, illetve a netstat -tap al látszik egy vnc port a 11001 -en. Ha ehez próbálok meg kapcsolódni akkor "VNC server closed connection" kapok.
Eddig kb 40 oldalt néztem végig és most kifogytam az ötletekből. ha valakinek van ötlete segitsen

előre is köszi Balázs

A windows.cfg jelenlegi állapota :

import os, re
arch = os.uname()[4]
if re.search('64', arch):
arch_libdir = 'lib64'
else:
arch_libdir = 'lib'

kernel = "/usr/lib/xen-3.2-1/boot/hvmloader"
builder='hvm'

memory = 512
# shadow_memory = 8

name = "windows"
vif = [ 'type=ioemu, bridge=xenbr0' ]
disk = [ 'file:/home/Domains/windows/windows.img,hda,w', 'file:/home/ISO/windows_xp_sp3.iso,hdc:cdrom,r' ]
device_model = '/usr/' + arch_libdir + '/xen/bin/qemu-dm'
# vfn = [ 'type=vnc,vncdisplay=10' ]
# boot on floppy (a), hard disk (c) or CD-ROM (d)
# default: hard disk, cd-rom, floppy
boot="dc"

vnc=1
#vncconsole=1
vncviewer=1
vncpasswd='alma'
vnclisten='127.0.0.1'
sdl=0

#stdvga=0
#serial='pty'
#usbdevice='tablet'

Hozzászólások

Honnan szeretnéd elérni?
127.0.0.1-re kiül a vnc?

Én openSuSE-n használok XEN-t, ott rendre megjelennek a virtuális gépek az 5900-as porttól felfelé, de ahhoz, hogy kívülről (nem csak localhost) is el lehessen érni, a konfigban át kell állítani, hogy minden címen figyeljen a VNC. Alapból csak a localhostról érhetőek el.

http://haxel.hu/wodehouse-konyvek.html

A windows.cfg-be ezeket javítsd:

vnc=1
vnclisten = '0.0.0.0'
vncconsole=1

Aztán netstat -tupan | grep 59

és valami hasonlót keressél benne (a lényeg, hogy qemu-dm legyen a sor végén) :

tcp 0 0 0.0.0.0:5900 0.0.0.0:* LISTEN 4366/qemu-dm

és a jelen példában az 5900-as porton csücsül a vnc

import os, re
ezekben mi van?
mi van a xend-config.sxp -ben?

----
概略情報

# The limit (in kilobytes) on the size of the console buffer
#(console-limit 1024)

##
# To bridge network traffic, like this:
#
# dom0: ----------------- bridge -> real eth0 -> the network
# |
# domU: fake eth0 -> vifN.0 -+
#
# use
#
(network-script network-bridge)
#
# Your default ethernet device is used as the outgoing interface, by default.
# To use a different one (e.g. eth1) use
#
# (network-script 'network-bridge netdev=eth1')
#
# The bridge is named xenbr0, by default. To rename the bridge, use
#
# (network-script 'network-bridge bridge=')
#
# It is possible to use the network-bridge script in more complicated
# scenarios, such as having two outgoing interfaces, with two bridges, and
# two fake interfaces per guest domain. To do things like this, write
# yourself a wrapper script, and call network-bridge from it, as appropriate.
#
#(network-script network-dummy)

# The script used to control virtual interfaces. This can be overridden on a
# per-vif basis when creating a domain or a configuring a new vif. The
# vif-bridge script is designed for use with the network-bridge script, or
# similar configurations.
#
# If you have overridden the bridge name using
# (network-script 'network-bridge bridge=') then you may wish to do the
# same here. The bridge name can also be set when creating a domain or
# configuring a new vif, but a value specified here would act as a default.
#
# If you are using only one bridge, the vif-bridge script will discover that,
# so there is no need to specify it explicitly.
#
(vif-script vif-bridge)

## Use the following if network traffic is routed, as an alternative to the
# settings for bridged networking given above.
#(network-script network-route)
#(vif-script vif-route)

## Use the following if network traffic is routed with NAT, as an alternative
# to the settings for bridged networking given above.
#(network-script network-nat)
#(vif-script vif-nat)

# Dom0 will balloon out when needed to free memory for domU.
# dom0-min-mem is the lowest memory level (in MB) dom0 will get down to.
# If dom0-min-mem=0, dom0 will never balloon out.
(dom0-min-mem 196)

# In SMP system, dom0 will use dom0-cpus # of CPUS
# If dom0-cpus = 0, dom0 will take all cpus available
(dom0-cpus 0)

# Whether to enable core-dumps when domains crash.
#(enable-dump no)

# The tool used for initiating virtual TPM migration
#(external-migration-tool '')

# The interface for VNC servers to listen on. Defaults
# to 127.0.0.1 To restore old 'listen everywhere' behaviour
# set this to 0.0.0.0
(vnc-listen '0.0.0.0')

# The default password for VNC console on HVM domain.
# Empty string is no authentication.
(vncpasswd '')

# The VNC server can be told to negotiate a TLS session
# to encryption all traffic, and provide x509 cert to
# clients enalbing them to verify server identity. The
# GTK-VNC widget, virt-viewer, virt-manager and VeNCrypt
# all support the VNC extension for TLS used in QEMU. The
# TightVNC/RealVNC/UltraVNC clients do not.
#
# To enable this create x509 certificates / keys in the
# directory /etc/xen/vnc
#
# ca-cert.pem - The CA certificate
# server-cert.pem - The Server certificate signed by the CA
# server-key.pem - The server private key
#
# and then uncomment this next line
# (vnc-tls 1)

# The certificate dir can be pointed elsewhere..
#
# (vnc-x509-cert-dir /etc/xen/vnc)

# The server can be told to request & validate an x509
# certificate from the client. Only clients with a cert
# signed by the trusted CA will be able to connect. This
# is more secure the password auth alone. Passwd auth can
# used at the same time if desired. To enable client cert
# checking uncomment this:
#
# (vnc-x509-verify 1)

# The default keymap to use for the VM's virtual keyboard
# when not specififed in VM's configuration
#(keymap 'en-us')

# Script to run when the label of a resource has changed.
#(resource-label-change-script '')

lehet hogy nincs minden csomag telepitve ?

apt-get install xen-hypervisor-3.2-1-amd64 xen-linux-system-2.6.26-1-xen-amd64 xen-utils-3.2-1 xenstore-utils xenwatch xen-shell xen-tools

Nekem olyan problémám van, hogy el sem készül a domain.

Config ugyan ez amit te is használsz fent, xen verzió 4.1 amd64

xm create windows.cfg
Using config file "/etc/xen/windows.cfg".
Error: Domain 'windows' does not exist.

Error log:
domid: 25
-c config qemu network with xen bridge for
tap25.0 xenbr0
Using file /var/www/virtual/images/win01.img in read-write mode
Using file /var/www/virtual/cd/windows_xp_image.iso in read-only mode
Watching /local/domain/0/device-model/25/logdirty/cmd
Watching /local/domain/0/device-model/25/command
Watching /local/domain/25/cpu
qemu_map_cache_init nr_buckets = 10000 size 4194304
shared page at pfn feffd
buffered io page at pfn feffb
Guest uuid = 1ebe7db3-8976-3ee3-c2d2-9e04ce37c72f
Time offset set 0
xen be core: xen be core: can't open gnttab device
can't open gnttab device
populating video RAM at ff000000
mapping video RAM from ff000000
Register xen platform.
Done register platform.
platform_fixed_ioport: changed ro/rw state of ROM memory area. now is rw state.
xs_read(/local/domain/0/device-model/25/xen_extended_power_mgmt): read error
Could not read keymap file: '/usr/share/qemu/keymaps/en-us'

Linuxot manuálisan és xen-tools-al is tudok indítani. Intel alapú a gép egyébként.

:D hehe.

kernel="/usr/lib/xen-default/boot/hvmloader"
builder="hvm"
memory=512
name="winxp"
vcpus=1
vif=['type=ioemu,bridge=xenbr0']
disk=['file:/var/www/virtual/images/win01.img,ioemu:sdb1,w']
device_model='/usr/lib/xen-default/bin/qemu-dm'
cdrom ='/dev/cdrom'
vnc=1
vncconsole=1
vncpasswd=1
ne2000=0
boot="c"

Teszteltem egy gépen 12.04 alatt, elindul a konfig, szépen feláll, a VNC-t hostolja az 5900 port-ra ez látszik a netstat-on is, azonban az 5.02-es VNC kifagy kapcsolódás közben. Igazából kilép, megnyitja a portot, be kell ütni a jelszót, minden jó eddig, aztán amikor megnyílna a felület kilép a program.

ötletek esetleg? :)