[Arm-dev] Bug: Missing symlink /etc/redhat-release

Mon Jul 25 09:48:10 UTC 2016
Zdenek Sedlak <dev at apgrco.com>

On 2016-07-25 10:17, Artem Sidorenko wrote:
> From the commit message:
>> In newer CentOS 7 versions /etc/redhat-release says that the distro is
>> derived from RHEL, so we need to look at /etc/centos-release for
>> actually identifying it as CentOS.
> If I understand this right, this is not a bug related to ARM images, but
> a general change in CentOS?
>
> Artem
>
> On 07/24/2016 04:13 PM, Richard W.M. Jones wrote:
>> On Sun, Jul 24, 2016 at 12:31:37PM +0200, Artem Sidorenko wrote:
>>> Hey Centos ARM list,
>>>
>>> As requested via twitter today [1],
>>>
>>> On the current Raspberry Pi 3 image the /etc/redhat-release isn't a
>>> symlink to centos-release like on x86, but a file with "Derived from Red
>>> Hat Enterprise Linux 7.2 (Source)" [2].
>>>
>>> This might lead to errors in the OS auto detection, like with Chef [3].
>> Yup, this affected libguestfs
>> (https://github.com/libguestfs/libguestfs/commit/1ff463e8692aae4313bd5b42bb6f09932bb63392).
>>
>> IMHO it's up to Chef to fix their OS detection like we did.
>>
>> Rich.
>>
> _______________________________________________
> Arm-dev mailing list
> Arm-dev at centos.org
> https://lists.centos.org/mailman/listinfo/arm-dev
Hi,


wouldn't be the checking of /etc/os-release file a better way, how to
detect the distro, since CentOS/RHEL/OEL/SC 7 is using systemd?

See: http://0pointer.de/blog/projects/os-release.html


//Zdenek