was -> wasn't Re: [VirtualBox] Use systemd-detect-virt to detect if we can install
Dominik 'Rathann' Mierzejewski
dominik at greysector.net
Wed Nov 30 15:26:18 CET 2016
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?
> 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.
Regards,
Dominik
--
Fedora http://fedoraproject.org/wiki/User:Rathann
RPMFusion http://rpmfusion.org
"Faith manages."
-- Delenn to Lennier in Babylon 5:"Confessions and Lamentations"
More information about the rpmfusion-developers
mailing list