crc-org / osp4

Proof of Concept repository of CodeReady Containers [Archived]
Apache License 2.0
26 stars 16 forks source link

Installation doesn't work for Red Hat Enterprise Linux Workstation release 7.5 #45

Open lgarciaaco opened 5 years ago

lgarciaaco commented 5 years ago

When using minishift.sh in Red Hat Enterprise Linux Workstation release 7.5, there is not qemu-kvm package to install, instead, qemu-kvm-rhev is installed:

16     sudo yum install -y libvirt libvirt-devel libvirt-daemon-kvm qemu-kvm

Output:

/dev/kvm
Loaded plugins: changelog, fs-snapshot, priorities, product-id, refresh-packagekit, rhnplugin, rpm-warm-cache, search-disabled-repos, subscription-manager, verify
This system is receiving updates from RHN Classic or Red Hat Satellite.
12744 packages excluded due to repository priority protections
Package libvirt-3.9.0-14.el7_5.8.x86_64 already installed and latest version
Package libvirt-devel-3.9.0-14.el7_5.8.x86_64 already installed and latest version
Package qemu-kvm is obsoleted by qemu-kvm-rhev, trying to install 10:qemu-kvm-rhev-2.9.0-16.el7_4.13.x86_64 instead
Resolving Dependencies
--> Running transaction check
---> Package libvirt-daemon-kvm.x86_64 0:3.9.0-14.el7_5.8 will be installed
---> Package qemu-kvm-rhev.x86_64 10:2.9.0-16.el7_4.13 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

==================================================================================================================================================================================================================$
 Package                                       Arch                              Version                                            Repository                                                                Size
==================================================================================================================================================================================================================$
Installing:
 libvirt-daemon-kvm                            x86_64                            3.9.0-14.el7_5.8                                   production-rhel-x86_64-workstation-7.5                                   173 k
 qemu-kvm-rhev                                 x86_64                            10:2.9.0-16.el7_4.13                               production-rhel-x86_64-server-7.5-openstack-6                            2.9 M

Transaction Summary
==================================================================================================================================================================================================================$
Install  2 Packages

Total download size: 3.0 M
Installed size: 11 M
Downloading packages:
(1/2): libvirt-daemon-kvm-3.9.0-14.el7_5.8.x86_64.rpm                                                                                                                                       | 173 kB  00:00:00    
(2/2): qemu-kvm-rhev-2.9.0-16.el7_4.13.x86_64.rpm                                                                                                                                           | 2.9 MB  00:00:02    

The binary installed is referenced in master-0.xml and installation fails.

21   <devices>
 22     <emulator>/usr/bin/qemu-kvm</emulator>
 23     <disk type='volume' device='disk'>

I tried installing latest (3.1.0) qemo from source, and after compiling, there is not qemu-kvm binary. I start wondering, is that file is only present in older versions of qemu. qemu-ga, qemu-img and few others are present:

$ find . -executable | grep qemu-img
./qemu-img
$ find . -executable | grep qemu-kvm
$
anjannath commented 5 years ago

I found this old BZ report which mentions that the qemu-kvm binary location changed to /usr/libexec/qemu-kvm.

https://bugzilla.redhat.com/show_bug.cgi?id=817562

lgarciaaco commented 5 years ago

yes I tried changing master-0.xml pointing to /usr/libexec/qemu-kvm, but in test1-worker-0-vqgct.xml there is a reference to qemu-system-x86_64 which also doesn't exist.

  <devices>
    <emulator>/usr/bin/qemu-system-x86_64</emulator>

So basically I came forward with qemu-kvm but now hit the problem with qemu-system-x86_64

anjannath commented 5 years ago

@lgarciaaco Give it a try by changing both to /usr/libexec/qemu-kvm, also for the worker.

anjannath commented 5 years ago

@lgarciaaco This is actually a duplicate see https://github.com/code-ready/osp4/issues/29#issuecomment-460205638

anjannath commented 5 years ago

Maybe we can avoid this by using virt-install.

lgarciaaco commented 5 years ago

Ok I tried replacing /usr/bin/qemu-system-x86_64 for /usr/libexec/qemu-kvm but it didn't work neither.

$ ./minishift.sh create                                                                                                                                              [2/1606]
/dev/kvm
Loaded plugins: changelog, fs-snapshot, product-id, refresh-packagekit, rhnplugin, rpm-warm-cache, search-disabled-repos, subscription-manager, verify
There was an error communicating with RHN.
Red Hat Satellite or RHN Classic support will be disabled.
Error communicating with server. The message was:
Unable to connect to the host and port specified
No package libvirt-daemon-kvm available.
No package qemu-kvm available.
Nothing to do
net.ipv4.ip_forward = 1
active
Warning: ZONE_ALREADY_SET: '192.168.126.0/24' already bound to 'public'
success
Warning: ALREADY_ENABLED: '16509:tcp' already in 'public'
success
Network test1 defined from ./network.xml

Network test1 started

Vol test1-base created

Vol test1-master-0 created

Vol test1-worker-0-vqgct created

error: Failed to define domain from ./master-0.xml
error: invalid argument: could not find capabilities for arch=x86_64

error: Failed to define domain from ./test1-worker-0-vqgct.xml
error: invalid argument: could not find capabilities for arch=x86_64

Cluster created successfully use './minishift.sh start' to start it
[$ ./minishift.sh start
[sudo] password for lgarciaa:
error: failed to get domain 'test1-master-0'
error: Domain not found: no domain with matching name 'test1-master-0'

error: failed to get domain 'test1-worker-0-vqgct'
error: Domain not found: no domain with matching name 'test1-worker-0-vqgct'

You need to wait around 4-5 mins till cluster is in healthy state
Use provided kubeconfig to check pods status before using this cluster

$
praveenkumar commented 5 years ago

@lgarciaaco Hi, with new poc (based on 0.16.1 tag) we have removed platform specific bits so can you please try it again and let us know if you still face same issue?