[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] Xen can't work on CentOS 7.



On Tue, 2016-04-26 at 07:17 +0000, Jason Long wrote:
> Hello.
> Hello.
> I have a system with Intel Core i7 and 8GB Ram and CentOS 7 x64 and installed 
> Xen on it via below commands :
> 
> # yum install centos-release-xen
> # yum install kernel-xen xen
> 
> And after it I run "/usr/bin/grub-bootxen.sh" and result is :
> 
> 
> [root@localhost ~]# /usr/bin/grub-bootxen.sh 
> GRUB_CMDLINE_XEN_DEFAULT already set in /etc/default/grub, not touching
> GRUB_CMDLINE_LINUX_XEN_REPLACE_DEFAULT already set in /etc/default/grub, not 
> touching
> Regenerating grub2 config
> Generating grub configuration file ...
> Found linux image: /boot/vmlinuz-3.18.30-20.el7.x86_64
> Found initrd image: /boot/initramfs-3.18.30-20.el7.x86_64.img
> Found linux image: /boot/vmlinuz-3.18.30-20.el7.x86_64
> Found initrd image: /boot/initramfs-3.18.30-20.el7.x86_64.img
> Found linux image: /boot/vmlinuz-3.18.30-20.el7.x86_64
> Found initrd image: /boot/initramfs-3.18.30-20.el7.x86_64.img
> Found linux image: /boot/vmlinuz-3.18.30-20.el7.x86_64
> Found initrd image: /boot/initramfs-3.18.30-20.el7.x86_64.img
> Found linux image: /boot/vmlinuz-3.10.0-327.13.1.el7.x86_64
> Found initrd image: /boot/initramfs-3.10.0-327.13.1.el7.x86_64.img
> Found linux image: /boot/vmlinuz-3.10.0-327.el7.x86_64
> Found initrd image: /boot/initramfs-3.10.0-327.el7.x86_64.img
> Found linux image: /boot/vmlinuz-0-rescue-6d5727843a3e49228409bacb4da76149
> Found initrd image: 
> /boot/initramfs-0-rescue-6d5727843a3e49228409bacb4da76149.img
> done
> Setting Xen as the default
> 
> But when I reboot my system and use Linux Kernel with Xen it just show me a 
> blank Screen. How can I solve it?
> 
> Tnx.
> 
> _______________________________________________
> Xen-users mailing list
> Xen-users@xxxxxxxxxxxxx
> http://lists.xen.org/xen-users


I do CentOS 6 host installs all the time. Maybe Cent 7 is similar enough
that this information would help. 

This is the procedure I use - 

I first run all updates that are normal for the distro, and reboot onto
the new kernel it provides.

Then, after being sure that the xen4 repo is configured and enabled, I
use this for my install commands:

yum install xen libvirt-daemon libvirt virt-install

I then edit /boot/grub/grub.conf such that if it started out like this:

title CentOS (3.18.17-13.el6.x86_64)
      root (hd0,0)
      kernel /vmlinuz-3.18.17-13.el6.x86_64 ro 
root=UUID=c9d14085-f005-45c2-b3d2-a5ee3db4dd32 rd_NO_LUKS rd_NO_LVM 
LANG=en_US.UTF-8 rd_NO_MD SYSFONT=latarcyrheb-sun16 crashkernel=auto  
KEYBOARDTYPE=pc KEYTABLE=us rd_NO_DM rhgb quiet
      initrd /initramfs-3.18.17-13.el6.x86_64.img

it looks like this when I'm done:

title CentOS (3.18.17-13.el6.x86_64)
  root (hd0,0)
  kernel /xen.gz dom0_mem=768M,max:1024M loglvl=all guest_loglvl=all
  module /vmlinuz-3.18.17-13.el6.x86_64 ro 
root=UUID=c9d14085-f005-45c2-b3d2-a5ee3db4dd32 rd_NO_LUKS rd_NO_LVM 
LANG=en_US.UTF-8 rd_NO_MD SYSFONT=latarcyrheb-sun16 crashkernel=auto  
KEYBOARDTYPE=pc KEYTABLE=us rd_NO_DM rhgb quiet
  module /initramfs-3.18.17-13.el6.x86_64.img

(basically - add the xen.gz line, and change everything else to say "module" 
instead of either kernel or initrd)

The above example is for reserving 1 gig of ram for the host, but it does not 
pin any CPUs to the host. You could pin a CPU by changing the one line as below 
(for it to really work right, you also have to tell the guests to not use cpu 0 
within the vcpu placement setting):

  kernel /xen.gz dom0_max_vcpus=1 dom0_vcpus_pin dom0_mem=768M,max:1024M 
loglvl=all guest_loglvl=all

Then I reboot, it boots onto the xen kernel, and I have the beginnings of a 
working xen host.







_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxx
http://lists.xen.org/xen-users

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.