#3575 PR merged: Update Linux.conf to make vi working with SLES 16

Labels: enhancement, fixed / solved / done

jsmeix opened issue at 2026-02-27 13:30:

On SLES 16 vi in the recovery system also needs
/usr/share/libalternatives/vi and vim-nox11, see
https://github.com/rear/rear/issues/3567#issuecomment-3933265707

svlv commented at 2026-02-27 15:53:

Just a question: there is usr/share/rear/conf/SUSE_LINUX.conf, when it should be used for such changes?
I mean, maybe all SUSE-specific things should be added there?

jsmeix commented at 2026-03-02 08:30:

@svlv
regarding your question
https://github.com/rear/rear/pull/3575#issuecomment-3973688452

Yes and no.
Or: It depends.

If something happens for sure only on a specific distribution
then a distribution specific script directory could be used.

But usually things are not distribution specific.

Usually things are different for different software versions
so software version specific script directories would be needed.
But that doesn't work in practice because complicated code
is needed to generate software version specific directory names.
In general testing for versions or distribution names or
whatever name- or label-like values is indirect testing
which never ever can work as good as testing "a real thing".
Think about a software version upgrade in a specific distribution
or think about something backported into a specific software version.
The distribution name/version or the software version doesn't change
(distribution patches for a software don't change its version)
so tests for such indirect values would then have false results,
see also
"Testing for version values is almost always plain wrong"
in
https://github.com/rear/rear/issues/3149#issuecomment-1972786350

What does work in practice is testing "some real thing".
I.e. testing the real difference, not a name or a number.

In this case here a test could be used which tests
whether or not /usr/share/libalternatives/vi
and vim-nox11 are needed to make vi work.

But - as far as I can imagine - in this case here
such a test is not needed because both COPY_AS_IS
and PROGS ignore when something which is specified
does not exist.

So what happens is that on systems where
/usr/share/libalternatives/vi and/or vim-nox11 exist,
what exists gets copied into the ReaR recovery system
and nothing happens for what does not exist.

As far as I can imagine this current behaviour should not
cause issues on systems when some of those don't exist.

I don't know if there are systems where only one of
/usr/share/libalternatives/vi and vim-nox11 exist.
I assume when only one exists, vi works with only one.

In practice it is not possible with reasonable effort
to research and verify all theoretically possible combinations.

In any case the user who uses ReaR must test and
verify that ReaR works with his ReaR configuration
on his system(s) in his environment(s), see
https://en.opensuse.org/SDB:Disaster_Recovery
therein in particular the sections
https://en.opensuse.org/SDB:Disaster_Recovery#Inappropriate_expectations
and
https://en.opensuse.org/SDB:Disaster_Recovery#Recommendations

svlv commented at 2026-03-02 10:02:

@jsmeix

Yes, I got your point. Agree. Thank you for the explanation!

jsmeix commented at 2026-03-02 12:40:

@rear/contributors
I would like to merge it today in about one hour or so
unless an objection appears.


[Export of Github issue for rear/rear.]