From: Peter Teoh
Subject: Re: ERROR: AttributeError: 'module' object has no
attribute 'new'
Date: Thu, 19 Feb 2009 10:09:25 -0500
Message-ID: <804dabb00902190709q6c349275i7d12af75999ef905@mail.gmail.com>
References: <724512.2577.qm@web94208.mail.in2.yahoo.com>
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Return-path:
In-Reply-To: <724512.2577.qm@web94208.mail.in2.yahoo.com>
List-Unsubscribe: ,
List-Post:
List-Help:
List-Subscribe: ,
Sender: xen-devel-bounces@lists.xensource.com
Errors-To: xen-devel-bounces@lists.xensource.com
To: kushalwaikar@yahoo.co.in
Cc: xen-devel@lists.xensource.com
List-Id: xen-devel@lists.xenproject.org
i did not start my xend or hypervisor yet, but just doing a test:
python -d /usr/sbin/xm
ERROR Internal error: Could not obtain handle on privileged command
interface (2 = No such file or directory)
Traceback (most recent call last):
File "/usr/sbin/xm", line 8, in
from xen.xm import main
File "/usr/lib64/python2.5/site-packages/xen/xm/main.py", line 61, in
xc = xen.lowlevel.xc.xc()
xen.lowlevel.xc.Error: (1, 'Internal error', 'Could not obtain handle
on privileged command interface (2 = No such file or directory)')
and immediately u can see which python script it is loading from.
Your problem is mostly that the path is not properly defined/included.
Looking at the "includes" in /usr/sbin/xm,
/usr/lib64/python2.5/site-packages/xen/xm/main.py etc...u can
approximately guess that most of the python scripts are located in
/usr/lib64/python2.5/site-packages/xen/ directory. But then again
yours may differ.
On Wed, Feb 18, 2009 at 10:32 AM, kushal waikar
wrote:
> Hi,
>
> I have "Xen 3.1.13.fc8" installed on FC8 as Dom0..I have written the
> following code in python which is throwing error...I am not getting the
> cause of error...Plz help me for removing error...
>
> CODE :
>
> INPUT test2.py
> "
> import sys
> import curses
> import curses.ascii
> import time
>
> sys.path.append('/usr/lib/python')
> import xen.lowlevel.xc
>
> xc = xen.lowlevel.xc.new()
> "
>
> OUTPUT-->
>
> [root@localhost ~]# python test2.py
> Traceback (most recent call last):
> File "test2.py", line 9, in
> xc = xen.lowlevel.xc.new()
> AttributeError: 'module' object has no attribute 'new'
>
>
>
> Thanks,
> Kushal Waikar
> kushalwaikar@yahoo.co.in
>
>
> ________________________________
> Add more friends to your messenger and enjoy! Invite them now.
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xensource.com
> http://lists.xensource.com/xen-devel
>
>
--
Regards,
Peter Teoh