[ovs-discuss] Problems getting OVS to work on RHEL/KVM

Kyle Mestery (kmestery) kmestery at cisco.com
Wed Jun 5 18:23:13 UTC 2013


On Jun 5, 2013, at 12:24 PM, K.R Kishore <krkishore at yahoo.com> wrote:

> Hi Kyle
> Thanks for responding. 
> I went back and followed the instructions in INSTALL.RHEL again and still no luck..slightly different errors though.
> 
> 1. Step 6 calls for building OpenVswitch userspace: 'rpmbuild -bb rhel/openvswitch.spec'
>     - I get the following error:
> /usr/lib/rpm/find-debuginfo.sh --strict-build-id /root/rpmbuild/BUILD/openvswitch-1.10.0
> extracting debug info from /root/rpmbuild/BUILDROOT/openvswitch-1.10.0-1.x86_64/usr/sbin/ovs-vswitchd
> *** ERROR: No build ID note found in /root/rpmbuild/BUILDROOT/openvswitch-1.10.0-1.x86_64/usr/sbin/ovs-vswitchd
> error: Bad exit status from /var/tmp/rpm-tmp.fNzzkw (%install)
> 
> This is referring to the ovs-switchd it just built
> [root at lab-sj1-140 openvswitch-1.10.0]# ls -l /root/rpmbuild/BUILDROOT/openvswitch-1.10.0-1.x86_64/usr/sbin/
> total 8932
> -rwxr-xr-x 1 root root   44709 Jun  5 09:55 ovs-bugtool
> -rwxr-xr-x 1 root root 3459332 Jun  5 09:55 ovsdb-server
> -rwxr-xr-x 1 root root 5639898 Jun  5 09:55 ovs-vswitchd
> 
> The INSTALL.RHEL indicates that there might be some issues due to buggy or missing kernel-devel package. I followed the instructions in step 1 &2 and undid the link to build dir and redid the link to the /usr/src/kernel/<target>.  Repeated the build and the problem persists. 
> 
I have not seen this error, but I have not built on RHEL 6.4 recently. The build ID note section should be added automatically by gcc during the build process. What version of gcc are you using on this host? And out of curiosity, you aren't overloading LDFLAGS or CFLAGS are you?

> 2. Step 7b (I am using RHEL6.4) calls for using one of several rpmbuild options
>  
> [root at lab-sj1-140 openvswitch-1.10.0]# rpmbuild -bb -D "kversion 2.6.32-131.6.1.el6.x86_64" -D "kflavors default debug kdump" rhel/openvswitch-kmod-rhel6.spec
> error: Failed build dependencies:
>     kernel-kdump-devel is needed by openvswitch-kmod-1.10.0-1.el6.x86_64
> [root at lab-sj1-140 openvswitch-1.10.0]# yum install kernel-kdump-devel
> Loaded plugins: aliases, changelog, downloadonly, kabi, presto, refresh-packagekit, security, tmprepo,
>               : verify, versionlock
> Loading support for Red Hat kernel ABI
> Setting up Install Process
> No package kernel-kdump-devel available.
> Error: Nothing to do
> 
> I removed the debug and kdump flavors and the rpmbuild completed successfully (as it did yesterday). It put a new rpm into $HOME/rpmbuild/RPMS/x86_64/ and I re-installed the packages using 'rpm -ivh --force <...rpm>'
> 
I've not built for those specific kernels, so can't comment here. But unless you need them, excluding the build for them should be ok.

> The problems I have outstanding are:
> 1, userspace rpm did not build correctly at all..how do I resolve this?
> 2. I followed the instructions in INSTALL (not the .RHEL) and did a 'make && make install' and it created the various ovs-xxx binaries

Once you follow this path, you are not going down the RPM path, which will lead to ...

> 3. I do not see the systemd script you mentioned (I presume it gets installed after the userspace rpm is installed?)

… the fact you will only get the integrated systemd script if you build and install RPMs.

> 4. I do not see the 'systemctl enable openvswitch.service' command you mention in either INSTALL.RHEL or INSTALL. Where is the systemctl command? Is it installed as part of a different package?
> 
This is just standard systemctl semantics, the same as for any package you install which requires a daemon to start at boot time. Actualy, it occurs to me that RHEL 6.4 may still use initd instead of systemd, so you will get a /etc/init.d/rc.d/openvswitch file with the RPMs in this case.

Thanks,
Kyle

> Many thanks for your time. 
> Kishore
> 
> From: Kyle Mestery (kmestery) <kmestery at cisco.com>
> To: K.R Kishore <krkishore at yahoo.com> 
> Cc: "discuss at openvswitch.org" <discuss at openvswitch.org> 
> Sent: Wednesday, June 5, 2013 9:00 AM
> Subject: Re: [ovs-discuss] Problems getting OVS to work on RHEL/KVM
> 
> On Jun 4, 2013, at 7:13 PM, K.R Kishore <krkishore at yahoo.com> wrote:
> 
> > Hi
> > I have installed the latest version of OVS (1.10) on RHEL 6.4 with KVM and running two VM's on it. I followed the instructions per  INSTALL.RHEL and INSTALL.KVM but had some problems during the process, but it looks like the install itself was successful.
> > The install problems  were:
> >         • yum install kernel-kdump-devel (Error: no package ..available). This resulted in only one (default) rpm being generated
> >         • make install could not install on /usr/local/bin/ because it was read-only file system (even when I was root). Redid the configure with a different destination and it seemed to work. (not clear if this in itself is a problem.
> > After the install, 
> >     • Started ovsdb server  
> >         • ovsdb-server --remote=punix:/usr/local/var/run/openvswitch/db.sock \ --remote=db:Open_vSwitch,manager_options \ --pidfile --detach
> >         • ovs-vsctl --no_wait init
> >     • Started open vswitch daemon
> >         • ovs-vswitchd --pidfile --detach
> >     • setup the bridge
> >         • ovs-vsctl add-br ovsbr0
> >         • ovs-vsctl add-port ovsbr0 p4p1
> >     •
> >         •
> > 
> > After this I expected to see the bridges on ifconfig output, but I do not. dmesg tail shows:
> > 
> >    openvswitch: Open vSwitch switching datapath 1.10.0, built Jun  3 2013 16:04:10
> > 
> > Looking at the 'ps -ef' output shows ovsdb-server, ovs-vswitchd (2 processes) and [ovs_workq] running. ovs_workq is owned by root, the others by the user.
> > 
> > I went through the discussion archive and suggestions to similar problems were
> >     • Look through ovs-vswitchd.log - I do not find this file anywhere, where is it? did my install go wrong?
> >     • Create a new VM after creating the bridge - I tried that, but there is no bridge with the name I created to assign to the newly created vm
> > ovs-vsctl shows the new interfaces and bridge created, but are these just showing the registered names? how do I debug this?
> > thx,
> > Kishore
> > 
> INSTALL.RHEL indicates you should build RPMs. Did you really follow INSTALL.RHEL? It will also install a systemd script to start/stop OVS during boot. After you install the RPMs built by following the directions in INSTALL.RHEL, make sure to do a "systemctl enable openvswitch.service".
> 
> Thanks,
> Kyle
> 
> > _______________________________________________
> > discuss mailing list
> > discuss at openvswitch.org
> > http://openvswitch.org/mailman/listinfo/discuss
> 
> 




More information about the discuss mailing list