Re: [gentoo-user] Making XEN functional

2014-03-23 Thread J. Roeleveld
On Sunday, March 23, 2014 07:53:22 AM Facundo Curti wrote:
 Hi list! :) First at all, I apologize if my english is not perfect,
 I know i'm not the only non-english speak on list, but I apologize any
 way jeje :P
 
 I'm trying to install XEN for first time on my gentoo desktop machine.
 my hardware specs to take into consideration are:
 i7 proccessor - 4GB ram
 SDD disk parted using GPT
 EFI mother. But also supports boot like BIOS.
 
 I'm following the guide from wiki for firsts steeps [1], but having in
 consideration the xen doc [2] and arch wiki [3].
 
 The question is that I'm having 2 problems :/
 
 First: I installed xen, and xen-tools. But I don't know why now I cant
 recompile xen-tools ._. The output is [tmp1]. I just can see a econf
 failed, but I cant find how to fix it. My
 emerge --info '=app-emulation/xen-tools-4.3.1-r5::gentoo' is [tmp2]
 emerge -pqv '=app-emulation/xen-tools-4.3.1-r5::gentoo' is [tmp3]
 /var/tmp/portage/app-emulation/xen-tools-4.3.1-r5/temp/build.log [tmp4]
 /var/tmp/portage/app-emulation/xen-tools-4.3.1-r5/temp/environment[tmp5]

I see this in tmp:
*
checking whether the C compiler works... no
configure: error: in `/var/tmp/portage/app-emulation/xen-tools-4.3.1-
r5/work/xen-4.3.1/tools':
configure: error: C compiler cannot create executables
**

Please fix your C-compiler. What does the following command return?
# gcc-config -L

 But really, this is my minor problem :/ XEN does not work at all :P
 
 I re-emerged all my system with emerge -e world, compiled my kernel,
 and configured grub. The system looks like starts with XEN. (When I
 boot the system, shows something about XEN that I cant read, and next
 starts loading the kernel).
 
 Once in the system, I try to make a xm list, xm show and also I try to
 execute xend from a console. But every one says:
 
 Traceback (most recent call last):
   File /usr/sbin/xend, line 36, in module
 from xen.xend.server import SrvDaemon
 ImportError: No module named xen.xend.server
 
 Looks like XEN can't find the modules, but I cant find where XEN stores
 it :/ I made a
   find / xen.xend

Please use the  xl  command set.  xm is deprecated.

Please also ensure you start the xen services:
# /etc/init.d/xencommons start
# /etc/init.d/xenstored start
# /etc/init.d/xenconsoled start

before trying the xl commands.

 and this give me 0 results. maybe this wasn't installed?
 
 My .config from kernel is [configKernel] and my [grub.cfg]

I will check those if the above didn't solve it.

I have the following installed on my server:
[I] app-emulation/xen   


   
 Installed versions:  4.3.1-r5^t{tbz2}(12:09:22 PM 02/21/2014)
(efi -custom-cflags -debug -flask -xsm) 

 
  
[I] app-emulation/xen-tools 


   
  Installed versions:  4.3.1-r5^t{tbz2}(12:14:51 PM 02/21/2014)
(api hvm pam qemu screen -custom-cflags -debug -doc -flask -ocaml -pygrub -
python -static-libs -xend 
PYTHON_SINGLE_TARGET=python2_7 -python2_6 PYTHON_TARGETS=python2_7 -
python2_6)  

--
Joost



Re: [gentoo-user] Making XEN functional

2014-03-23 Thread Nilesh Govindrajan
On 23-Mar-2014 5:46 pm, J. Roeleveld jo...@antarean.org wrote:

 On Sunday, March 23, 2014 07:53:22 AM Facundo Curti wrote:
  Hi list! :) First at all, I apologize if my english is not perfect,
  I know i'm not the only non-english speak on list, but I apologize any
  way jeje :P
 
  I'm trying to install XEN for first time on my gentoo desktop machine.
  my hardware specs to take into consideration are:
  i7 proccessor - 4GB ram
  SDD disk parted using GPT
  EFI mother. But also supports boot like BIOS.
 
  I'm following the guide from wiki for firsts steeps [1], but having in
  consideration the xen doc [2] and arch wiki [3].
 
  The question is that I'm having 2 problems :/
 
  First: I installed xen, and xen-tools. But I don't know why now I cant
  recompile xen-tools ._. The output is [tmp1]. I just can see a econf
  failed, but I cant find how to fix it. My
  emerge --info '=app-emulation/xen-tools-4.3.1-r5::gentoo' is [tmp2]
  emerge -pqv '=app-emulation/xen-tools-4.3.1-r5::gentoo' is [tmp3]
  /var/tmp/portage/app-emulation/xen-tools-4.3.1-r5/temp/build.log [tmp4]
  /var/tmp/portage/app-emulation/xen-tools-4.3.1-r5/temp/environment[tmp5]

 I see this in tmp:
 *
 checking whether the C compiler works... no
 configure: error: in `/var/tmp/portage/app-emulation/xen-tools-4.3.1-
 r5/work/xen-4.3.1/tools':
 configure: error: C compiler cannot create executables
 **

 Please fix your C-compiler. What does the following command return?
 # gcc-config -L

  But really, this is my minor problem :/ XEN does not work at all :P
 
  I re-emerged all my system with emerge -e world, compiled my kernel,
  and configured grub. The system looks like starts with XEN. (When I
  boot the system, shows something about XEN that I cant read, and next
  starts loading the kernel).
 
  Once in the system, I try to make a xm list, xm show and also I try to
  execute xend from a console. But every one says:
 
  Traceback (most recent call last):
File /usr/sbin/xend, line 36, in module
  from xen.xend.server import SrvDaemon
  ImportError: No module named xen.xend.server
 
  Looks like XEN can't find the modules, but I cant find where XEN stores
  it :/ I made a
find / xen.xend

 Please use the  xl  command set.  xm is deprecated.

 Please also ensure you start the xen services:
 # /etc/init.d/xencommons start
 # /etc/init.d/xenstored start
 # /etc/init.d/xenconsoled start

 before trying the xl commands.

  and this give me 0 results. maybe this wasn't installed?
 
  My .config from kernel is [configKernel] and my [grub.cfg]

 I will check those if the above didn't solve it.

 I have the following installed on my server:
 [I] app-emulation/xen
  Installed versions:  4.3.1-r5^t{tbz2}(12:09:22 PM 02/21/2014)
 (efi -custom-cflags -debug -flask -xsm)

 [I] app-emulation/xen-tools
   Installed versions:  4.3.1-r5^t{tbz2}(12:14:51 PM 02/21/2014)
 (api hvm pam qemu screen -custom-cflags -debug -doc -flask -ocaml -pygrub
-
 python -static-libs -xend
 PYTHON_SINGLE_TARGET=python2_7 -python2_6 PYTHON_TARGETS=python2_7 -
 python2_6)

 --
 Joost


I'm not meaning to hijack this thread, but isn't KVM a better option? The
difference between Xen and KVM is tiny I think, no?


Re: [gentoo-user] Making XEN functional

2014-03-23 Thread J. Roeleveld
On Sunday, March 23, 2014 05:47:53 PM Nilesh Govindrajan wrote:
 I'm not meaning to hijack this thread, but isn't KVM a better option? The
 difference between Xen and KVM is tiny I think, no?

Yes and no:

If you simpy look at the basics, like running virtual machines, then KVM is a 
valid option.

But, if you are running VMs to test stuff, you want to take valid snapshots of 
the current status.
That means disk AND memory.

I have not been able to find any information on how to make a snapshot of the 
memory used by a VM running under KVM. If there is a method, please point me 
in the right direction.

With Xen, it's really easy to do:
# xl  save   Domain FileWhereMemoryIsSaved 
-- make a snapshot of the disk(s),
--   either by copying the file or using LVM snapshots
# xl restore FileWhereMemoryIsSaved

Or using any of the front-ends. XCP has it all built-in and allows usage of 
the Citrix client tool.

--
Joost



Re: [gentoo-user] Making XEN functional

2014-03-23 Thread Facundo Curti
2014-03-23 9:35 GMT-03:00 J. Roeleveld jo...@antarean.org:
 On Sunday, March 23, 2014 05:47:53 PM Nilesh Govindrajan wrote:
 I'm not meaning to hijack this thread, but isn't KVM a better option? The
 difference between Xen and KVM is tiny I think, no?

What I see on web, is that XEN uses paravirtualization. If you have
the correct hardware (like i have), XEN have better perfonmance. My
intel i7 have virtualization instructions. See [1][2] y [3]

I'm new in virtualization, i'm doing this for a desktop machine. Just
for learn. Instead of use VirtualBOX or VMware, I'm installing XEN.
Best perfonmance, and I can learn in the process.


2014-03-23 9:14 GMT-03:00 J. Roeleveld jo...@antarean.org:

 I see this in tmp:
 *
 checking whether the C compiler works... no
 configure: error: in `/var/tmp/portage/app-emulation/xen-tools-4.3.1-
 r5/work/xen-4.3.1/tools':
 configure: error: C compiler cannot create executables
 **

 Please fix your C-compiler. What does the following command return?
 # gcc-config -L


/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3:/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3/32

 Please use the  xl  command set.  xm is deprecated.

:O I didn't know it was deprecated.

 Please also ensure you start the xen services:
 # /etc/init.d/xencommons start
 # /etc/init.d/xenstored start
 # /etc/init.d/xenconsoled start

 before trying the xl commands.

I'm using systemd, so I tried to start this way:
   systemctl enable xencommons
   systemctl enable xenstored
   systemctl enable xencosnsoled
And none exists :P (No such file or directory)

Instead, if I make it with /etc/init.d/xenstored start
it says:
WARNING: xenstored is already starting
(the same with xencommons and xenconsoled)

So, I try do xl list, and says:

libxl: error: libxl.c:87:libxl_ctx_alloc: Is xenstore daemon running?
failed to stat /var/run/xenstored.pid: No such file or directory
cannot init xl context

The correct way is start it from systemd? Or through /etc/init.d ?

 My .config from kernel is [configKernel] and my [grub.cfg]

 I will check those if the above didn't solve it.

 I have the following installed on my server:
 [I] app-emulation/xen
  Installed versions:  4.3.1-r5^t{tbz2}(12:09:22 PM 02/21/2014)
 (efi -custom-cflags -debug -flask -xsm)

 [I] app-emulation/xen-tools
   Installed versions:  4.3.1-r5^t{tbz2}(12:14:51 PM 02/21/2014)
 (api hvm pam qemu screen -custom-cflags -debug -doc -flask -ocaml -pygrub -
 python -static-libs -xend
 PYTHON_SINGLE_TARGET=python2_7 -python2_6 PYTHON_TARGETS=python2_7 -
 python2_6)
I have:

o.o. I dont have xen installed. ¿Is that possible? ._.

[ebuild  N ] app-emulation/xen-4.3.1-r5  USE=efi xsm
-custom-cflags -debug -flask

I'm trying to install it but says:

!!! copy 
/var/tmp/portage/app-emulation/xen-4.3.1-r5/image/boot/efi/gentoo/xen-4.3.1.efi
- /boot/efi/gentoo/xen-4.3.1.efi failed.
!!! [Errno 28] No space left on device

Maybe is because I tried to re-emerge this? o.o


 --
 Joost


Thank you for help!


[1] 
http://www.linux.com/news/enterprise/systems-management/327628-kvm-or-xen-choosing-a-virtualization-platform
[2] 
http://iopscience.iop.org/1742-6596/219/4/042005/pdf/1742-6596_219_4_042005.pdf
[3] 
http://ark.intel.com/es/products/75122/intel-core-i7-4770-processor-8m-cache-up-to-3_90-ghz



Re: [gentoo-user] Making XEN functional

2014-03-23 Thread J. Roeleveld
On Sun, March 23, 2014 19:26, Facundo Curti wrote:
 2014-03-23 9:35 GMT-03:00 J. Roeleveld jo...@antarean.org:
 On Sunday, March 23, 2014 05:47:53 PM Nilesh Govindrajan wrote:
 I'm not meaning to hijack this thread, but isn't KVM a better option?
 The
 difference between Xen and KVM is tiny I think, no?

 What I see on web, is that XEN uses paravirtualization. If you have
 the correct hardware (like i have), XEN have better perfonmance. My
 intel i7 have virtualization instructions. See [1][2] y [3]

 I'm new in virtualization, i'm doing this for a desktop machine. Just
 for learn. Instead of use VirtualBOX or VMware, I'm installing XEN.
 Best perfonmance, and I can learn in the process.

On desktop, I would recommend something like Virtualbox.
Xen works best with a minimal host environment on a dedicated machine.

 2014-03-23 9:14 GMT-03:00 J. Roeleveld jo...@antarean.org:

 I see this in tmp:
 *
 checking whether the C compiler works... no
 configure: error: in `/var/tmp/portage/app-emulation/xen-tools-4.3.1-
 r5/work/xen-4.3.1/tools':
 configure: error: C compiler cannot create executables
 **

 Please fix your C-compiler. What does the following command return?
 # gcc-config -L


 /usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3:/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3/32

what about gcc-config -l (sorry, meant lower-case in previous email)

 Please use the  xl  command set.  xm is deprecated.

 :O I didn't know it was deprecated.

 Please also ensure you start the xen services:
 # /etc/init.d/xencommons start
 # /etc/init.d/xenstored start
 # /etc/init.d/xenconsoled start

 before trying the xl commands.

 I'm using systemd, so I tried to start this way:
systemctl enable xencommons
systemctl enable xenstored
systemctl enable xencosnsoled
 And none exists :P (No such file or directory)

I don't use systemd. You will need to find the correct unit-files for Xen.
Alternatively, use OpenRC.

 Instead, if I make it with /etc/init.d/xenstored start
 it says:
 WARNING: xenstored is already starting
 (the same with xencommons and xenconsoled)

 So, I try do xl list, and says:

 libxl: error: libxl.c:87:libxl_ctx_alloc: Is xenstore daemon running?
 failed to stat /var/run/xenstored.pid: No such file or directory
 cannot init xl context

 The correct way is start it from systemd? Or through /etc/init.d ?

Correct way depends on the init-system you are using. Systemd does things
differently compared to OpenRC.

 My .config from kernel is [configKernel] and my [grub.cfg]

 I will check those if the above didn't solve it.

 I have the following installed on my server:
 [I] app-emulation/xen
  Installed versions:  4.3.1-r5^t{tbz2}(12:09:22 PM 02/21/2014)
 (efi -custom-cflags -debug -flask -xsm)

 [I] app-emulation/xen-tools
   Installed versions:  4.3.1-r5^t{tbz2}(12:14:51 PM 02/21/2014)
 (api hvm pam qemu screen -custom-cflags -debug -doc -flask -ocaml
 -pygrub -
 python -static-libs -xend
 PYTHON_SINGLE_TARGET=python2_7 -python2_6 PYTHON_TARGETS=python2_7 -
 python2_6)
 I have:

 o.o. I dont have xen installed. ¿Is that possible? ._.

Yes, xen-tools can be installed seperately.
You need xen installed to be able to boot with it.

 [ebuild  N ] app-emulation/xen-4.3.1-r5  USE=efi xsm
 -custom-cflags -debug -flask

 I'm trying to install it but says:

 !!! copy
 /var/tmp/portage/app-emulation/xen-4.3.1-r5/image/boot/efi/gentoo/xen-4.3.1.efi
 - /boot/efi/gentoo/xen-4.3.1.efi failed.
 !!! [Errno 28] No space left on device

 Maybe is because I tried to re-emerge this? o.o

Actually, you haven't got xen installed yet.
And the install fails because your EFI-boot partition is full.
Also, you need to ensure you boot correctly using Xen. The Linux kernel
should be loaded and started by Xen as the primary domain.

--
Joost




Re: [gentoo-user] Making XEN functional

2014-03-23 Thread Facundo Curti
2014-03-23 16:03 GMT-03:00 J. Roeleveld jo...@antarean.org:
 On Sun, March 23, 2014 19:26, Facundo Curti wrote:
 2014-03-23 9:35 GMT-03:00 J. Roeleveld jo...@antarean.org:
 On Sunday, March 23, 2014 05:47:53 PM Nilesh Govindrajan wrote:
 I'm not meaning to hijack this thread, but isn't KVM a better option?
 The
 difference between Xen and KVM is tiny I think, no?

 What I see on web, is that XEN uses paravirtualization. If you have
 the correct hardware (like i have), XEN have better perfonmance. My
 intel i7 have virtualization instructions. See [1][2] y [3]

 I'm new in virtualization, i'm doing this for a desktop machine. Just
 for learn. Instead of use VirtualBOX or VMware, I'm installing XEN.
 Best perfonmance, and I can learn in the process.

 On desktop, I would recommend something like Virtualbox.
 Xen works best with a minimal host environment on a dedicated machine.

Thank you for advice. I'm reading about so I can take a choice.

 2014-03-23 9:14 GMT-03:00 J. Roeleveld jo...@antarean.org:

 I see this in tmp:
 *
 checking whether the C compiler works... no
 configure: error: in `/var/tmp/portage/app-emulation/xen-tools-4.3.1-
 r5/work/xen-4.3.1/tools':
 configure: error: C compiler cannot create executables
 **

 Please fix your C-compiler. What does the following command return?
 # gcc-config -L


 /usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3:/usr/lib/gcc/x86_64-pc-linux-gnu/4.7.3/32

 what about gcc-config -l (sorry, meant lower-case in previous email)


 [1] x86_64-pc-linux-gnu-4.7.3 *

 Please use the  xl  command set.  xm is deprecated.

 :O I didn't know it was deprecated.

 Please also ensure you start the xen services:
 # /etc/init.d/xencommons start
 # /etc/init.d/xenstored start
 # /etc/init.d/xenconsoled start

 before trying the xl commands.

 I'm using systemd, so I tried to start this way:
systemctl enable xencommons
systemctl enable xenstored
systemctl enable xencosnsoled
 And none exists :P (No such file or directory)

 I don't use systemd. You will need to find the correct unit-files for Xen.
 Alternatively, use OpenRC.


yep, but I cant find this. Maybe is because XEN is not installed rigth now.

 Instead, if I make it with /etc/init.d/xenstored start
 it says:
 WARNING: xenstored is already starting
 (the same with xencommons and xenconsoled)

 So, I try do xl list, and says:

 libxl: error: libxl.c:87:libxl_ctx_alloc: Is xenstore daemon running?
 failed to stat /var/run/xenstored.pid: No such file or directory
 cannot init xl context

 The correct way is start it from systemd? Or through /etc/init.d ?

 Correct way depends on the init-system you are using. Systemd does things
 differently compared to OpenRC.

 My .config from kernel is [configKernel] and my [grub.cfg]

 I will check those if the above didn't solve it.

 I have the following installed on my server:
 [I] app-emulation/xen
  Installed versions:  4.3.1-r5^t{tbz2}(12:09:22 PM 02/21/2014)
 (efi -custom-cflags -debug -flask -xsm)

 [I] app-emulation/xen-tools
   Installed versions:  4.3.1-r5^t{tbz2}(12:14:51 PM 02/21/2014)
 (api hvm pam qemu screen -custom-cflags -debug -doc -flask -ocaml
 -pygrub -
 python -static-libs -xend
 PYTHON_SINGLE_TARGET=python2_7 -python2_6 PYTHON_TARGETS=python2_7 -
 python2_6)
 I have:

 o.o. I dont have xen installed. ¿Is that possible? ._.

 Yes, xen-tools can be installed seperately.
 You need xen installed to be able to boot with it.

I have xen-tools. But I dont have xen.

 [ebuild  N ] app-emulation/xen-4.3.1-r5  USE=efi xsm
 -custom-cflags -debug -flask

 I'm trying to install it but says:

 !!! copy
 /var/tmp/portage/app-emulation/xen-4.3.1-r5/image/boot/efi/gentoo/xen-4.3.1.efi
 - /boot/efi/gentoo/xen-4.3.1.efi failed.
 !!! [Errno 28] No space left on device

 Maybe is because I tried to re-emerge this? o.o

 Actually, you haven't got xen installed yet.
 And the install fails because your EFI-boot partition is full.
 Also, you need to ensure you boot correctly using Xen. The Linux kernel
 should be loaded and started by Xen as the primary domain.


Yes. I had xen installed. I booted from grub with it, and XEN loaded
my system. But once inside, I tried to re-emerge. So, XEN was
unistalled, and right now it can't be emerged any more ._.

I didn't shutdown my computer yet, So I still using a kernel XEN, in a domain0.

I dont know why i dont have space on EFI anymore ._. If I installed it
once, why I cant do this twice? ._. I cleaned, on efi, the files from
old install xen.

This is all i have:

/boot/efi:
EFI
tmp

/boot/efi/EFI:
gentoo

/boot/efi/EFI/gentoo:
grubx64.efi

df -h:
/dev/sdb12,0M   124K  1,9M   7% /boot/efi

It just have 2MB space, because I do it following the gentoo handbook
that recommends 4MB of space (less 2 from filesystem).

Is that enough space? Any way to fix it Without changing the
partitions? I dont use LVM :/

Thank you for help!



Re: [gentoo-user] Making XEN functional

2014-03-23 Thread Facundo Curti
Solved the lack of space. I modified my partitions. and xen is back
again :) Now I'm going to reboot with xen, start the services and try
with xl.

Thank you for help. I will keep in contact



Re: [gentoo-user] Making XEN functional

2014-03-23 Thread Facundo Curti
It works! :)
Thank you for you help! Now I just need to install my hosts jeje. I'll
try XEN, if I see performance is not good, I will change to VirtualBox
as you suggested.

Thanks again! :)