Charlie Reddington
2008-Aug-29 15:17 UTC
[Xen-users] virtual machine lvm issues during install
Hi everyone, I think I know what the issue is here but I''m looking for some confirmation. I setup a fresh system, and I made one large lvm for my system just thinking it''d be easier overall, and since this is more of a test system, it wouldn''t be a big deal. I can get all the way to the point of the install, to where it starts to format the system with the ''default layout''. But it throws the error - "RuntimeError: Error running lvm: Cannot allocate space" Is this because I''m trying to install the img to a ''file'' instead of a separate block? I have the images going to /var/lib/xen/ THanks for any help, Charlie _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Joseph L. Casale
2008-Aug-29 15:36 UTC
RE: [Xen-users] virtual machine lvm issues during install
>But it throws the error - "RuntimeError: Error running lvm: Cannot >allocate space"Post your disk line in your vm config. You trying to export a file as a disk I presume as yo mention /var/lib/xen but you suggest an lvm error is thrown. This isn''t consistent. jlc _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Joseph L. Casale
2008-Aug-29 16:16 UTC
RE: [Xen-users] virtual machine lvm issues during install
>disk = [ "tap:aio:/var/lib/xen/images/vm-01-dns-2.img,xvda,w" ]I haven''t used tap:aio, and I also use '' not " but looks fine I guess? Using SELinux I presume:)>It goes through and I just pick the default layout, which sets it up >with an LVM. (this is where I think I may be wrong in doing so?)Ahh, so it''s the guest vm that gives the error?>After the point of setting up my disk space it goes on to format the >filesystem, and fails almost immediately with a somewhat large dump >ending with that origanl message.It obviously sees the disc but pukes on writing to it? So you have exported it *into* your guest correctly, but it has issues writing which leads me to maybe an SELinux issue? Go into /var/lib/xen/images and do an ll -Z. Look at your image file, does it have the right context? Go here for explanation, http://wiki.centos.org/TipsAndTricks/Xen HTH, jlc _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Charlie Reddington
2008-Aug-29 16:38 UTC
Re: [Xen-users] virtual machine lvm issues during install
Thanks for the reply I''ll fill in some blanks..... I normally disable selinux accross the board but I haven''t done so yet. I have however set it to permissive, assuming it would let things slide but only complain about it. I''ll give it a whack with selinux disabled and see if it has any changes for me..... On Aug 29, 2008, at 11:16 AM, Joseph L. Casale wrote:>> disk = [ "tap:aio:/var/lib/xen/images/vm-01-dns-2.img,xvda,w" ] > > I haven''t used tap:aio, and I also use '' not " but looks fine I guess? > Using SELinux I presume:) > >> It goes through and I just pick the default layout, which sets it up >> with an LVM. (this is where I think I may be wrong in doing so?) > > Ahh, so it''s the guest vm that gives the error? > >> After the point of setting up my disk space it goes on to format the >> filesystem, and fails almost immediately with a somewhat large dump >> ending with that origanl message. > > It obviously sees the disc but pukes on writing to it?Correct> > So you have exported it *into* your guest correctly, but it has > issues writing > which leads me to maybe an SELinux issue? Go into /var/lib/xen/ > images and do an ll -Z.I get this for all my images... -rwxrwxr-x root root system_u:object_r:xen_image_t vm-01-dns-2.img> > Look at your image file, does it have the right context? > Go here for explanation, http://wiki.centos.org/TipsAndTricks/XenAnd it appears that I have the right context from my understanding of it.> > > HTH, > jlc > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Jock Coats
2008-Aug-29 19:21 UTC
Re: [Xen-users] virtual machine lvm issues during install
I''m no expert and completely new to all this too, but the one part of installing Xen I didn''t have trouble with was LVM. I''m not sure you''ve got the whole idea of LVM right here. It shouldn''t be creating an .img file at all. You don''t create a logical volume, that''s what Xen creates when it creates the machine. You give it a Volume Group into which it creates a logical volume of the size dictated by your virtual machine creation parameters. Or have I got the wrong end of the stick of your question? So, by all means create a Volume Group using your entire disk space (in fact I created several physical partitions, one volume group and added all those partitions to that group, because I was advised that LVM drops partitions if they ever begin to get bad sectors so I didn''t want it to drop my entire disk in such an eventuality). Then (I was using xen-tools) put the name of that Volume Group in the xen- tools.conf file and then, when I invoke the creation script it creates a new logical volume (two if you also want it to have a swap partition). Those resultant logical volumes appear in /dev/<volume group>/ as new block devices and not as .img files. Does that give any clues? Jock On 29 Aug 2008, at 17:38, Charlie Reddington wrote:> Thanks for the reply I''ll fill in some blanks..... I normally > disable selinux accross the board but I haven''t done so yet. I have > however set it to permissive, assuming it would let things slide but > only complain about it. > > I''ll give it a whack with selinux disabled and see if it has any > changes for me..... > > On Aug 29, 2008, at 11:16 AM, Joseph L. Casale wrote: > >>> disk = [ "tap:aio:/var/lib/xen/images/vm-01-dns-2.img,xvda,w" ] >> >> I haven''t used tap:aio, and I also use '' not " but looks fine I >> guess? >> Using SELinux I presume:) >> >>> It goes through and I just pick the default layout, which sets it up >>> with an LVM. (this is where I think I may be wrong in doing so?) >> >> Ahh, so it''s the guest vm that gives the error? >> >>> After the point of setting up my disk space it goes on to format the >>> filesystem, and fails almost immediately with a somewhat large dump >>> ending with that origanl message. >> >> It obviously sees the disc but pukes on writing to it? > > Correct >> >> So you have exported it *into* your guest correctly, but it has >> issues writing >> which leads me to maybe an SELinux issue? Go into /var/lib/xen/ >> images and do an ll -Z. > > I get this for all my images... > > -rwxrwxr-x root root system_u:object_r:xen_image_t vm-01-dns-2.img > >> >> Look at your image file, does it have the right context? >> Go here for explanation, http://wiki.centos.org/TipsAndTricks/Xen > > And it appears that I have the right context from my understanding > of it. >> >> >> HTH, >> jlc >> >> _______________________________________________ >> Xen-users mailing list >> Xen-users@lists.xensource.com >> http://lists.xensource.com/xen-users > > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Joseph L. Casale
2008-Aug-29 19:46 UTC
RE: [Xen-users] virtual machine lvm issues during install
>I''m not sure you''ve got the whole idea of LVM right here. It >shouldn''t be creating an .img file at all.He has exported an image file from Dom0 into DomU as its only HD.>From there, the Linux installer has attempted to create a file systeminside LVM. Its there his issues seem to exist. It appears as if the installer is having issues writing to "its" hard drive or the file as it is in Dom0. Charlie, What OS is your Dom0/U? jlc _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Charlie Reddington
2008-Aug-29 21:03 UTC
Re: [Xen-users] virtual machine lvm issues during install
Running CentOS 5.2 x86_64 But it looked like the issue was with my SELINUX, I disabled it and everything started working fine, even though it was in permissive mode. Charlie On Aug 29, 2008, at 2:46 PM, Joseph L. Casale wrote:>> I''m not sure you''ve got the whole idea of LVM right here. It >> shouldn''t be creating an .img file at all. > > He has exported an image file from Dom0 into DomU as its only HD. >> From there, the Linux installer has attempted to create a file system > inside LVM. Its there his issues seem to exist. > > It appears as if the installer is having issues writing to "its" > hard drive > or the file as it is in Dom0. > > Charlie, > What OS is your Dom0/U? > > jlc > > _______________________________________________ > Xen-users mailing list > Xen-users@lists.xensource.com > http://lists.xensource.com/xen-users_______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users