On Mon, Aug 19, 2019 at 2:29 AM Raffaele Belardi
<raffaele.bela...@st.com> wrote:
>
> Yesterday I tried to switch my ~amd64 box from Gnome/systemd to Xfce/openrc. 
> I followed
> the wiki [1], [2] to install Xfce from a Gnome terminal:
>
> - switch profile from 17.1/desktop/gnome/systemd to 17.1/desktop
> - emerge xfce4-meta and some xfce4 applications/panels/extras
> - unmerged systemd and emerged OpenRC
> - emerge -uDvN world to account for the different profile flags

Next time you do something like this, keep in mind that Gnome and xfce
can co-exist on the same system, and so can openrc and systemd.

At this point you're probably just going to want to troubleshoot what
you are left with, though you could consider reverting back to your
old config and starting over if you have backups/etc.

I imagine that not many people move from systemd to openrc, since the
latter is basically the default on Gentoo already.  If I were going to
migrate a working system between the two I would probably do it
stepwise:

1.  Rebuild the kernel with support for both systemd and openrc.  Boot
that (under systemd) and confirm it is working.
2.  Install xfce and get that working fine (under systemd).  That
really has no tie-in to the service manager but if you have this
working it is one less thing to mess with and it simplifies your
system.
3.  Install openrc and reboot under systemd just to make sure
everything is still working fine.  I forget what the defaults are but
you might need to tweak your systemd USE flags so that it uses the
sysvinit versions of halt/reboot/poweroff/telinit and so on.  It works
just fine with its own version of these tools or with sysvinit.
4.  Make sure you have your openrc configured the way you want it (I
don't think it has any issues with using rc-update and so on while
systemd is running, but I haven't tried that).
5.  Switch your kernel command line to boot with openrc, and make a
note of what it said before.  If it boots fine you're now running
openrc and just have to clean up the stuff you don't want.  If it
doesn't boot you just have to edit your command line and you're back
up and running with systemd until you sort it out.
6.  Switch your profile, do the -uDvN to rebuild anything impacted,
and depclean the stuff you don't need.  Reboot to test.

By doing it this way you will be just making one change at a time with
a reboot in-between so that you know what broke if something breaks.
The way you did it is potentially more time-efficient, but if
something breaks you are going to be hunting to figure out what it
was.  Since all the packages you're changing are capable of
co-existing there is no reason to switch cold turkey.

Now, on a new install or a host I didn't care so much about uptime for
I'd probably do it your way, and just revert to a backup.  In a
production environment where reboots are a concern I'd be working out
the procedure on a test host.

Oh, yeah, and step 0 is to make a backup...  :)

-- 
Rich

Reply via email to