Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 13 Jan 2009 20:03:56 +0100
From:      Mister Olli <mister.olli@googlemail.com>
To:        freebsd-xen@freebsd.org, freebsd-questions@freebsd.org
Subject:   Problems with FreeBSD 8-CURRENT as Xen domU
Message-ID:  <1231873436.24899.85.camel@phoenix.blechhirn.net>

Next in thread | Raw E-Mail | Index | Archive | Help

--=-/F0E39/XpYOEhYcp/1Gw
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

hi...

I've managed to compile and setup a paravirtualized domU with FreeBSD 8
(SVN snapshot from 'head').

Currently I'm running into two mayor problems:
- The system time is not behaving as expected.
	Example:
	========
	I fired the domain up at 01:43 in the morning and watch the 
	clock. Time passes normally within the maschine, and the 
	suddenly jumps back to 01:30:<VARIES>. From there on time
	passes normally up to 15 minutes (the latest time I've seen
	is 01:44:52).
	Right now the domain is running for more than 18 hours, and the
	clock still says: Tue Jan 13 01:32:52 CET 2009

	Running 'ntpd' inside the domU doesn't help to solve the 
	problem.

	If found a lot of hints for linux domU's, which say that you
	need to set the sysctl 'xen.independent_wallclock' to '1' and
	run 'ntpd' in the domU to keep time correct.
	Does 'sysctl machdep.independent_wallclock=1' the same in 
	FreeBSD? (If so, this doesn' work.)

- 2-way SMP doesn't work.
	When I put the line
		vcpus=2
	into my config file, I get the following output during
	boot, and the domU is destroyed after the reboot by
	the kernel:
================================================================
# xm create 00_template_8-CURRENT.XENconfig -c
Using config file "./00_template_8-CURRENT.XENconfig".
Started domain template_8-CURRENT
WARNING: loader(8) metadata is missing!
Copyright (c) 1992-2009 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
        The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 8.0-CURRENT #3: Thu Jan  8 04:34:03 CET 2009
    root@template-8_CURRENT.localdomain:/usr/obj/usr/src/sys/freebsd8_XEN
WARNING: WITNESS option enabled, expect reduced performance.
Xen reported: 1600.056 MHz processor.
Timecounter "ixen" frequency 1000000000 Hz quality 0
CPU: AMD Athlon(tm) Processor (1600.06-MHz 686-class CPU)
  Origin = "AuthenticAMD"  Id = 0x662  Stepping = 2
  Features=0x383fbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,MMX,FXSR,SSE>
  AMD Features=0xc0480800<SYSCALL,MP,MMX+,3DNow!+,3DNow!>
real memory  = 671088640 (640 MB)
avail memory = 649625600 (619 MB)
gdtpfn=3edd9 pdptpfn=11113
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
cpu=0 irq=0 vector=0
cpu=0 irq=0 vector=1
cpu=1 irq=0 vector=0
cpu=1 irq=0 vector=1
kbd0 at kbdmux0
xenbus0: <Xen Devices> on motherboard
xc0: <Xen Console> on motherboard
Timecounters tick every 10.000 msec
xbd0: 8192MB <Virtual Block Device> at device/vbd/768 on xenbus0
xbd0: attaching as ad0
GEOM: ad0s1: geometry does not match label (15h,63s != 255h,63s).
xn0: <Virtual Network Interface> at device/vif/0 on xenbus0
xn0: Ethernet address: 00:16:3e:06:c3:80
[XEN] netfront_backend_changed: newstate=2
Spanic: blockable sleep lock (sleep mutex) XCONS LOCK @ /usr/src/sys/dev/xen/console/console.c:290
cpuid = 1
Uptime: 1s
Cannot dump. Device not defined or unavailable.
Automatic reboot in 15 seconds - press a key on the console to abort
--> Press a key on the console to reboot,
--> or switch off the system now.
Rebooting...
================================================================

I've attached my kernelconfig file to this mail, if someone sees a
failure in it.

Any hints on how to solve these 2 problems would be really great. Using
FreeBSD in it's current state as domU really rocks. :-)))


greetz
olli

--=-/F0E39/XpYOEhYcp/1Gw
Content-Disposition: attachment; filename=freebsd8_XEN
Content-Type: text/plain; name=freebsd8_XEN; charset=ISO-8859-15
Content-Transfer-Encoding: 7bit

#
# XEN -- Kernel configuration for i386 XEN DomU
#
# $FreeBSD$

cpu		I686_CPU
ident		XEN

makeoptions	DEBUG=-g		# Build kernel with gdb(1) debug symbols
makeoptions	MODULES_OVERRIDE=""

options 	SCHED_ULE		# ULE scheduler
options 	PREEMPTION		# Enable kernel thread preemption
#options		SCHED_4BSD		 

options 	INET			# InterNETworking
#options 	INET6			# IPv6 communications protocols
#options 	SCTP			# Stream Control Transmission Protocol
options 	FFS			# Berkeley Fast Filesystem
options 	SOFTUPDATES		# Enable FFS soft updates support
options 	UFS_ACL			# Support for access control lists
options 	UFS_DIRHASH		# Improve performance on big directories
#options 	UFS_GJOURNAL		# Enable gjournal-based UFS journaling
#options 	NFSCLIENT		# Network Filesystem Client
#options 	NFSSERVER		# Network Filesystem Server
#options 	NFSLOCKD		# Network Lock Manager
#options 	NFS_ROOT		# NFS usable as /, requires NFSCLIENT
#options 	MSDOSFS			# MSDOS Filesystem
options 	CD9660			# ISO 9660 Filesystem
options 	PROCFS			# Process filesystem (requires PSEUDOFS)
options 	PSEUDOFS		# Pseudo-filesystem framework
options 	GEOM_PART_GPT		# GUID Partition Tables.
options 	GEOM_LABEL		# Provides labelization
options 	COMPAT_43TTY		# BSD 4.3 TTY compat (sgtty)
options 	COMPAT_FREEBSD4		# Compatible with FreeBSD4
options 	COMPAT_FREEBSD5		# Compatible with FreeBSD5
options 	COMPAT_FREEBSD6		# Compatible with FreeBSD6
options 	COMPAT_FREEBSD7		# Compatible with FreeBSD7
options 	KTRACE			# ktrace(1) support
options 	STACK			# stack(9) support
options 	SYSVSHM			# SYSV-style shared memory
options 	SYSVMSG			# SYSV-style message queues
options 	SYSVSEM			# SYSV-style semaphores
options 	_KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
options 	KBD_INSTALL_CDEV	# install a CDEV entry in /dev
options 	AUDIT			# Security event auditing

# Debugging for use in -current
#options 	KDB			# Enable kernel debugger support.
#options 	DDB			# Support DDB.
#options 	GDB			# Support remote GDB.
#options 	INVARIANTS		# Enable calls of extra sanity checking
#options 	INVARIANT_SUPPORT	# Extra sanity checks of internal structures, required by INVARIANTS
options 	WITNESS			# Enable checks to detect deadlocks and cycles
#options 	WITNESS_SKIPSPIN	# Don't run witness on spinlocks for speed

options		PAE
nooption	NATIVE
option		XEN
nodevice	atpic
nodevice	isa
options		MCLSHIFT=12

# To make an SMP kernel, the next two lines are needed
options 	SMP			# Symmetric MultiProcessor Kernel
device		apic			# I/O APIC


device         atkbdc          # AT keyboard controller
device         atkbd           # AT keyboard
device         psm             # PS/2 mouse
device         pci

device		kbdmux		# keyboard multiplexer

# Pseudo devices.
device		loop		# Network loopback
device		random		# Entropy device
device		ether		# Ethernet support
device		tun		# Packet tunnel.
device		pty		# Pseudo-ttys (telnet etc)
#device		md		# Memory "disks"
#device		gif		# IPv6 and IPv4 tunneling
#device		faith		# IPv6-to-IPv4 relaying (translation)

# The `bpf' device enables the Berkeley Packet Filter.
# Be aware of the administrative consequences of enabling this!
# Note that 'bpf' is required for DHCP.
device		bpf		# Berkeley packet filter


--=-/F0E39/XpYOEhYcp/1Gw--




Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?1231873436.24899.85.camel>