Morten Christensen
2006-Apr-14 14:49 UTC
[Xen-users] Error: (2, ''No such file or directory'')
I am completely new to Xen. Trying to run it on a Kubuntu Dapper with packages and kernel from debian.thoughtcrime.co.nz. When I try to start a domU with xm create -c /etc/xen/vm01.cfg it says: Using config file "/etc/xen/vm01.cfg". Error: (2, ''No such file or directory'') I expect it to be a very simple problem, but do not know where to start. /var/log/xend.log says [2006-04-14 16:39:27 xend] INFO (SrvDaemon:278) Xend Daemon started [2006-04-14 16:39:27 xend] INFO (SrvDaemon:282) Xend changeset: Tue Apr 11 04:27:07 2006 +0100 9602:09304a22b8d2. [2006-04-14 16:39:27 xend] ERROR (SrvDaemon:292) Exception starting xend ((2, ''No such file or directory'')) Traceback (most recent call last): File "/usr/lib/python2.4/site-packages/xen/xend/server/SrvDaemon.py", line 286, in run servers = SrvServer.create() File "/usr/lib/python2.4/site-packages/xen/xend/server/SrvServer.py", line 108, in create root.putChild(''xend'', SrvRoot()) File "/usr/lib/python2.4/site-packages/xen/xend/server/SrvRoot.py", line 40, in __init__ self.get(name) File "/usr/lib/python2.4/site-packages/xen/web/SrvDir.py", line 82, in get val = val.getobj() File "/usr/lib/python2.4/site-packages/xen/web/SrvDir.py", line 52, in getobj self.obj = klassobj() File "/usr/lib/python2.4/site-packages/xen/xend/server/SrvDomainDir.py", line 39, in __init__ self.xd = XendDomain.instance() File "/usr/lib/python2.4/site-packages/xen/xend/XendDomain.py", line 582, in instance inst.init() File "/usr/lib/python2.4/site-packages/xen/xend/XendDomain.py", line 70, in init xstransact.Mkdir(VMROOT) File "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", line 317, in Mkdir complete(path, lambda t: t.mkdir(*args)) File "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", line 323, in complete t = xstransact(path) File "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", line 20, in __init__ self.transaction = xshandle().transaction_start() File "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xsutil.py", line 18, in xshandle xs_handle = xen.lowlevel.xs.xs() RuntimeError: (2, ''No such file or directory'') -- Morten Christensen _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Yura Pismerov
2006-Apr-14 17:22 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Morten Christensen wrote:> I am completely new to Xen. Trying to run it on a Kubuntu Dapper with > packages and kernel from debian.thoughtcrime.co.nz. > > When I try to start a domU with > > xm create -c /etc/xen/vm01.cfgDrop the path to the config file.> > it says: > > Using config file "/etc/xen/vm01.cfg". > Error: (2, ''No such file or directory'') > > > I expect it to be a very simple problem, but do not know where to start. > > > /var/log/xend.log says > > [2006-04-14 16:39:27 xend] INFO (SrvDaemon:278) Xend Daemon started > [2006-04-14 16:39:27 xend] INFO (SrvDaemon:282) Xend changeset: Tue > Apr 11 04:27:07 2006 +0100 9602:09304a22b8d2. > [2006-04-14 16:39:27 xend] ERROR (SrvDaemon:292) Exception starting > xend ((2, ''No such file or directory'')) > Traceback (most recent call last): > File > "/usr/lib/python2.4/site-packages/xen/xend/server/SrvDaemon.py", line > 286, in run > servers = SrvServer.create() > File > "/usr/lib/python2.4/site-packages/xen/xend/server/SrvServer.py", line > 108, in create > root.putChild(''xend'', SrvRoot()) > File "/usr/lib/python2.4/site-packages/xen/xend/server/SrvRoot.py", > line 40, in __init__ > self.get(name) > File "/usr/lib/python2.4/site-packages/xen/web/SrvDir.py", line 82, > in get > val = val.getobj() > File "/usr/lib/python2.4/site-packages/xen/web/SrvDir.py", line 52, > in getobj > self.obj = klassobj() > File > "/usr/lib/python2.4/site-packages/xen/xend/server/SrvDomainDir.py", > line 39, in __init__ > self.xd = XendDomain.instance() > File "/usr/lib/python2.4/site-packages/xen/xend/XendDomain.py", line > 582, in instance > inst.init() > File "/usr/lib/python2.4/site-packages/xen/xend/XendDomain.py", line > 70, in init > xstransact.Mkdir(VMROOT) > File > "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", > line 317, in Mkdir > complete(path, lambda t: t.mkdir(*args)) > File > "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", > line 323, in complete > t = xstransact(path) > File > "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", > line 20, in __init__ > self.transaction = xshandle().transaction_start() > File "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xsutil.py", > line 18, in xshandle > xs_handle = xen.lowlevel.xs.xs() > RuntimeError: (2, ''No such file or directory'') > > >-- Yuri Pismerov, System Administrator Armor Technologies (Canada) Inc. P: 905 305 1946 (x.3519) http://www.armorware.net Privacy Protection Guaranteed! _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Morten Christensen
2006-Apr-14 18:56 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Yura Pismerov skrev den 14-04-2006 19:22:> Morten Christensen wrote: > >> I am completely new to Xen. Trying to run it on a Kubuntu Dapper with >> packages and kernel from debian.thoughtcrime.co.nz. >> >> When I try to start a domU with >> >> xm create -c /etc/xen/vm01.cfg >> > > Drop the path to the config file. >Same error without the path.>> it says: >> >> Using config file "/etc/xen/vm01.cfg". >> Error: (2, ''No such file or directory'') >> >> >> I expect it to be a very simple problem, but do not know where to start. >> >> >> /var/log/xend.log says >> >> [2006-04-14 16:39:27 xend] INFO (SrvDaemon:278) Xend Daemon started >> [2006-04-14 16:39:27 xend] INFO (SrvDaemon:282) Xend changeset: Tue >> Apr 11 04:27:07 2006 +0100 9602:09304a22b8d2. >> [2006-04-14 16:39:27 xend] ERROR (SrvDaemon:292) Exception starting >> xend ((2, ''No such file or directory'')) >> Traceback (most recent call last): >> File >> "/usr/lib/python2.4/site-packages/xen/xend/server/SrvDaemon.py", line >> 286, in run >> servers = SrvServer.create() >> File >> "/usr/lib/python2.4/site-packages/xen/xend/server/SrvServer.py", line >> 108, in create >> root.putChild(''xend'', SrvRoot()) >> File "/usr/lib/python2.4/site-packages/xen/xend/server/SrvRoot.py", >> line 40, in __init__ >> self.get(name) >> File "/usr/lib/python2.4/site-packages/xen/web/SrvDir.py", line 82, >> in get >> val = val.getobj() >> File "/usr/lib/python2.4/site-packages/xen/web/SrvDir.py", line 52, >> in getobj >> self.obj = klassobj() >> File >> "/usr/lib/python2.4/site-packages/xen/xend/server/SrvDomainDir.py", >> line 39, in __init__ >> self.xd = XendDomain.instance() >> File "/usr/lib/python2.4/site-packages/xen/xend/XendDomain.py", line >> 582, in instance >> inst.init() >> File "/usr/lib/python2.4/site-packages/xen/xend/XendDomain.py", line >> 70, in init >> xstransact.Mkdir(VMROOT) >> File >> "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", >> line 317, in Mkdir >> complete(path, lambda t: t.mkdir(*args)) >> File >> "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", >> line 323, in complete >> t = xstransact(path) >> File >> "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xstransact.py", >> line 20, in __init__ >> self.transaction = xshandle().transaction_start() >> File "/usr/lib/python2.4/site-packages/xen/xend/xenstore/xsutil.py", >> line 18, in xshandle >> xs_handle = xen.lowlevel.xs.xs() >> RuntimeError: (2, ''No such file or directory'') >>_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Morten Christensen
2006-Apr-14 20:21 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Peter Fokkinga skrev den 14-04-2006 21:22:> Quoting Morten Christensen <mc-xen@mc.cx>: >> I am completely new to Xen. Trying to run it on a Kubuntu Dapper with >> packages and kernel from debian.thoughtcrime.co.nz. >> >> When I try to start a domU with >> >> xm create -c /etc/xen/vm01.cfg >> >> it says: >> >> Using config file "/etc/xen/vm01.cfg". >> Error: (2, ''No such file or directory'') >> > Things to check: > * volume(s) exported to vm01 should NOT be mounted (in dom0 or > other active domU''s) > * bridges referred to in the vm01.cfg should exist in dom0 > (check with ifconfig) > * does directory /var/run/xenstored exist > * does directory /var/lock/subsys exist >I have tried all 4, but none of them helped me. Both directories were missing, but it did not help to create them.> I remember having ''No such file or directory'' problems myself, > and I''ve been bitten by the previous points. Unfortunately, I > can''t remember which problem resulted in ''No such file or > directory'', nor if it was ''xm create'' or a different script > that gave this error. > > Still, can''t hurt to check the things above. > > I''m running Xen 3.0.2-2 on Ubuntu Dapper btw. > > Cheers, PeterGood to know it is possible. Sad that it is not for me. -- Morten Christensen _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Peter Fokkinga
2006-Apr-14 21:54 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Quoting Morten Christensen <mc-xen@mc.cx>:>>> xm create -c /etc/xen/vm01.cfg >>> Using config file "/etc/xen/vm01.cfg". >>> Error: (2, ''No such file or directory'') >>> >> Things to check: >> * volume(s) exported to vm01 should NOT be mounted (in dom0 or >> other active domU''s) >> * bridges referred to in the vm01.cfg should exist in dom0 >> (check with ifconfig) >> * does directory /var/run/xenstored exist >> * does directory /var/lock/subsys exist >> > I have tried all 4, but none of them helped me. > Both directories were missing, but it did not help to create them.I had another look at your /var/log/xend.log (prompted by your statement that both directories were missing), could it be that xend is not running? `ps axu | grep xend` should show a few "python /usr/sbin/xend start" processes. If xend _isn''t_ running then do `/etc/init.d/xend start` and give vm01 another try. Regards, Peter _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Morten Christensen
2006-Apr-15 11:40 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Peter Fokkinga skrev den 14-04-2006 23:54:> Quoting Morten Christensen <mc-xen@mc.cx>: >>>> xm create -c /etc/xen/vm01.cfg >>>> Using config file "/etc/xen/vm01.cfg". >>>> Error: (2, ''No such file or directory'') >>>> >>> Things to check: >>> * volume(s) exported to vm01 should NOT be mounted (in dom0 or >>> other active domU''s) >>> * bridges referred to in the vm01.cfg should exist in dom0 >>> (check with ifconfig) >>> * does directory /var/run/xenstored exist >>> * does directory /var/lock/subsys exist >>> >> I have tried all 4, but none of them helped me. >> Both directories were missing, but it did not help to create them. > > I had another look at your /var/log/xend.log (prompted by > your statement that both directories were missing), could it > be that xend is not running? `ps axu | grep xend` should > show a few "python /usr/sbin/xend start" processes.I have 4 of those running. -- Morten Christensen _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Morten Christensen
2006-Apr-15 12:01 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Peter Fokkinga skrev den 14-04-2006 21:22:> Quoting Morten Christensen <mc-xen@mc.cx>: >> I am completely new to Xen. Trying to run it on a Kubuntu Dapper with >> packages and kernel from debian.thoughtcrime.co.nz. >> >> When I try to start a domU with >> >> xm create -c /etc/xen/vm01.cfg >> >> it says: >> >> Using config file "/etc/xen/vm01.cfg". >> Error: (2, ''No such file or directory'') >> > I remember having ''No such file or directory'' problems myself, > and I''ve been bitten by the previous points. Unfortunately, I > can''t remember which problem resulted in ''No such file or > directory'', nor if it was ''xm create'' or a different script > that gave this error. > > Still, can''t hurt to check the things above. > > I''m running Xen 3.0.2-2 on Ubuntu Dapper btw. > >What kernel are you using ? I have the precompiled kernel from thoughtcrime.co.nz. The only 2.6.16-kernel in /boot is vmlinuz-2.6.16, and vm01.cfg has kernel = "/boot/vmlinuz-2.6.16" -- Morten Christensen _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Peter Fokkinga
2006-Apr-15 13:32 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Quoting Morten Christensen <mc-xen@mc.cx>:> What kernel are you using ? I have the precompiled kernel from > thoughtcrime.co.nz. > The only 2.6.16-kernel in /boot is vmlinuz-2.6.16, and vm01.cfg has > kernel = "/boot/vmlinuz-2.6.16" >I built from source (Xen 3.0.2-2). It''s strange, I get exactly the same traceback in xend.log when I run `/etc/init.d/xend start` when directory /var/run/xenstored is missing. But I get no "xend" processes (just "[xenwatch]" and "[xenbus]"). When you do `xm list`, you don''t get any errors, do you? It would have been nice if ''No such file or directory'' had included the file/directoryname that was missing... Peter _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Morten Christensen
2006-Apr-15 14:36 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Peter Fokkinga skrev den 15-04-2006 15:32:> Quoting Morten Christensen <mc-xen@mc.cx>: >> What kernel are you using ? I have the precompiled kernel from >> thoughtcrime.co.nz. >> The only 2.6.16-kernel in /boot is vmlinuz-2.6.16, and vm01.cfg has >> kernel = "/boot/vmlinuz-2.6.16" >> > I built from source (Xen 3.0.2-2). > > It''s strange, I get exactly the same traceback in xend.log when > I run `/etc/init.d/xend start` when directory /var/run/xenstored > is missing. But I get no "xend" processes (just "[xenwatch]" and > "[xenbus]"). > > When you do `xm list`, you don''t get any errors, do you? >xm list Error: Error connecting to xend: No such file or directory. Is xend running?> It would have been nice if ''No such file or directory'' had > included the file/directoryname that was missing... >Agree ....... -- Morten Christensen _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Peter Fokkinga
2006-Apr-15 14:50 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Quoting Morten Christensen <mc-xen@mc.cx>:>> It''s strange, I get exactly the same traceback in xend.log when >> I run `/etc/init.d/xend start` when directory /var/run/xenstored >> is missing. But I get no "xend" processes (just "[xenwatch]" and >> "[xenbus]"). >> >> When you do `xm list`, you don''t get any errors, do you? >> > xm list > Error: Error connecting to xend: No such file or directory. Is xend running? >That is consistent with what I am seeing. Could you try: 1. /etc/init.d/xendomains stop ; /etc/init.d/xend stop 2. mkdir /var/run/xenstored 3. rm /var/log/xen* 4. /etc/init.d/xend start Now check /var/log/xen/xend.log and/or try `xm list` again. If this still doesn''t help then I''m out of ideas :-( Peter _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Morten Christensen
2006-Apr-16 13:24 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Peter Fokkinga skrev den 15-04-2006 16:50:> Quoting Morten Christensen <mc-xen@mc.cx>: >>> It''s strange, I get exactly the same traceback in xend.log when >>> I run `/etc/init.d/xend start` when directory /var/run/xenstored >>> is missing. But I get no "xend" processes (just "[xenwatch]" and >>> "[xenbus]"). >>> >>> When you do `xm list`, you don''t get any errors, do you? >>> >> xm list >> Error: Error connecting to xend: No such file or directory. Is xend >> running? >> > > That is consistent with what I am seeing. Could you try: > > 1. /etc/init.d/xendomains stop ; /etc/init.d/xend stop > 2. mkdir /var/run/xenstored > 3. rm /var/log/xen* > 4. /etc/init.d/xend start > > Now check /var/log/xen/xend.log and/or try `xm list` again. > > If this still doesn''t help then I''m out of ideas :-( > > PeterNow I have come a bit further. If I: Stop xend Create /var/run/xenstored Start xend Run ''xm list'' or '' xm crate -c vmo0.cfg'' then I do not get the error. Every time I reboot, then /var/run/xenstored is deleted. If xend is started without an existing xenstored, than it does not work. If I stop xend, create xenstored and start xend, then I do not get theis error. How are you starting xend ? Thank you for your help. -- Morten Christensen _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Peter Fokkinga
2006-Apr-16 13:50 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
Quoting Morten Christensen <mc-xen@mc.cx>:> Every time I reboot, then /var/run/xenstored is deleted. > If xend is started without an existing xenstored, than it does not > work. If I stop xend, create xenstored and start xend, then I do not > get theis error. > > How are you starting xend ? >I modified /etc/init.d/xend, adding these lines # on Ubuntu (Debian too?) /var/run/xenstored does not exist after reboot if [ ! -d /var/run/xenstored ] ; then mkdir /var/run/xenstored fi and in /etc/init.d/xendomains I changed LOCKFILE=/var/lock/subsys/xendomains to LOCKFILE=/var/lock/xendomains Peter _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Andrew Thompson
2006-Apr-16 14:22 UTC
Re: [Xen-users] Error: (2, ''No such file or directory'')
On Sun, Apr 16, 2006 at 03:24:23PM +0200, Morten Christensen wrote:> Every time I reboot, then /var/run/xenstored is deleted. > If xend is started without an existing xenstored, than it does not work. > If I stop xend, create xenstored and start xend, then I do not get > theis error.This is a *feature* of your particular distribution. There is another reply with a fix. I would suggest you add it to your init.d such that the directory is recreated before the "xend start" happens. That way if you upgrade Xen and it rewrites all your Xen-related scripts, it doesn''t wipe out the fix. xend really ought to create the directory itself... -- Andrew Thompson http://aktzero.com/ _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users