ia64/xen-unstable

changeset 19155:7e15ccb7bbd8

xm: Improve xm error if booted native

Signed-off-by: Jim Fehlig <jfehlig@novell.com>
author Keir Fraser <keir.fraser@citrix.com>
date Wed Feb 04 11:58:25 2009 +0000 (2009-02-04)
parents 3e1e87052029
children 6058887e55d7
files tools/python/xen/xm/main.py
line diff
     1.1 --- a/tools/python/xen/xm/main.py	Wed Feb 04 11:57:47 2009 +0000
     1.2 +++ b/tools/python/xen/xm/main.py	Wed Feb 04 11:58:25 2009 +0000
     1.3 @@ -59,7 +59,11 @@ from xen.util.acmpolicy import ACM_LABEL
     1.4  import XenAPI
     1.5  
     1.6  import xen.lowlevel.xc
     1.7 -xc = xen.lowlevel.xc.xc()
     1.8 +try:
     1.9 +    xc = xen.lowlevel.xc.xc()
    1.10 +except Exception, ex:
    1.11 +    print >>sys.stderr, ("Is xen kernel running?")
    1.12 +    sys.exit(1)
    1.13  
    1.14  import inspect
    1.15  from xen.xend import XendOptions