On Qua, 2016-11-30 at 15:26 +0100, Dominik 'Rathann' Mierzejewski
wrote:
On Tuesday, 29 November 2016 at 22:39, Sérgio Basto wrote:
>
> On Ter, 2016-11-29 at 22:16 +0100, Dominik 'Rathann' Mierzejewski
> wrote:
> >
> > On Tuesday, 29 November 2016 at 19:46, Sérgio Basto wrote:
> > >
> > >
> > > On Ter, 2016-11-29 at 14:17 +0100, Dominik 'Rathann'
> > > Mierzejewski
> > > wrote:
> > > >
> > > >
> > > > could you explain the idea here? Why was there an explicit
> > > > Conflicts:
> > > > before and why is it better to fail the transaction if you're
> > > > not
> > > > running inside VirtualBox or KVM?
> > > It is a long story, bug reports about this [2]. With this
> > > solution
> > > (which took sometime to figure out), we can install VirtualBox-
> > > guest
> > > and VirtualBox in a vm guest [1] I think in middle of bug 3425
> > > , I
> > > realize that the root of the problem is we can't
> > > install VirtualBox-
> > > guest-additions in master (host) system because breaks X11, etc
> > > .
> > > So instead use an artificial rpm conflicts, BTW the solution
> > > *wasn't*
> > > made my me, it was already there when I arrived, I check in
> > > %pre
> > > if
> > >
> > > $(systemd-detect-virt | grep -iP "oracle|kvm" -c) -eq 0
> > >
> > > if systemd-detect-virt doesn't say that is in one oracle or kvm
> > > vm
> > > , I
> > > don't let package (VirtualBox-guest-additions) be installed .
> > >
> > > I also check kvm because in epel7 vbox vm, systemd-detect-virt
> > > says
> > > that is in kvm instead oracle ...
> > >
> > > From now on, we may install VirtualBox and VirtualBox-guest-
> > > additions
> > > under a vm , that is the main goal of this change .
> > >
> > > Have you any suggestion or something where I can improve ?
> > Ok, I read bug 3425. You shouldn't forbid installation of
> > VirtualBox-guest-additions on bare metal by failing in %pre.
> > I still don't understand why it can't be installed. From what was
> > written in the bug report, you only need to make sure that either
> > bothi vboxvideo kmod and X11 driver are present or none of them.
> No, VirtualBox-guest-additions breaks hosts (that is the main
> problem).
> We must forbid installation of VirtualBox-guest-additions on bare
> metal
> else (at least) X11 won't start, that is the point .
Breaks hosts how? Why won't X11 start, then? What about Wayland?
Now it should break less because I add to vboxservice.service the
rules
ConditionVirtualization=|kvm
ConditionVirtualization=|oracle
also vboxvideo.so was remove on fedoras but not in epel7
but try install it in your machine (without these rules) and find out
yourself.
dnf repoquery VirtualBox-guest-additions-5.1.10-1.fc23 -l
/etc/X11/xinit/xinitrc.d/98vboxadd-xclient.sh (bad)
/etc/xdg/autostart/vboxclient.desktop (bad)
/usr/bin/VBoxClient
/usr/bin/VBoxClient-all
/usr/bin/VBoxControl
/usr/lib/modules-load.d/VirtualBox-guest.conf (bad)
/usr/lib/systemd/system-preset/96-vbox.preset
/usr/lib/systemd/system/vboxservice.service (bad)
/usr/lib/udev/rules.d/60-vboxguest.rules (bad)
/usr/lib64/VBoxEGL.so (bad)
/usr/lib64/VBoxOGL.so (bad)
/usr/lib64/VBoxOGLarrayspu.so (bad)
/usr/lib64/VBoxOGLcrutil.so (bad)
/usr/lib64/VBoxOGLerrorspu.so (bad)
/usr/lib64/VBoxOGLfeedbackspu.so (bad)
/usr/lib64/VBoxOGLpackspu.so (bad)
/usr/lib64/VBoxOGLpassthroughspu.so (bad)
/usr/lib64/security/pam_vbox.so (bad)
/usr/sbin/VBoxService (bad)
/usr/sbin/mount.vboxsf
/usr/share/licenses/VirtualBox-guest-additions
/usr/share/licenses/VirtualBox-guest-additions/COPYING
/usr/share/licenses/VirtualBox-guest-additions/COPYING.CDDL
> Previous solution was make VirtualBox conflicts with
VirtualBox-
> guest-
> additions. So end user, ends by choose install VirtualBox in host,
> but
> by that (conflicts solution) both packages can't also be installed
> in a
> guest system, which is fixed with this brilliant solution.
Failing in %pre, which happens during dnf/rpm transation *after* the
package had been downloaded already is not brilliant at all in my
opinion.
I'd like to think there is a better way, but I first need to
understand
the issue.
The only problem is "We should avoid installation of VirtualBox-guest-
additions on bare metal", have you any suggestion that can improve this
solution ?
Regards,
Dominik
--
Sérgio M. B.