You are not logged in.

#1 2012-12-03 16:58:14

ebal
Member
From: Athens, GReece
Registered: 2009-05-26
Posts: 213
Website

archlinux release

There are two files to verify an archlinux installation:

etc/arch-release

&&

etc/os-release

arch-release is an empty file, i believe that this is according to other distros that have a /etc/distro-release file.

right ?

Is this the "official" way to verify an archlinux installation ?

Searching through arch-wiki-docs didnt find anything about os-release


http://Ευάγγελος.Μπαλάσκας.gr
Unix System Engineer - Registered Linux User #420129

Offline

#2 2012-12-03 17:26:33

drcouzelis
Member
From: Connecticut, USA
Registered: 2009-11-09
Posts: 3,424
Website

Re: archlinux release

ebal wrote:

Is this the "official" way to verify an archlinux installation?

I think so.

Both "/etc/os-release" and "/etc/arch-release" are from the "filesystem" package.

The PKGBUILD file for the "filesystem" package creates an empty file named "/etc/arch-release". On Red Hat, I use the file "/etc/redhat-release" to know which version of Red Hat I'm using. Since Arch Linux doesn't have versions, it makes sense that it's empty. smile

I supposed you should be careful in regards to distributions that are based on Arch Linux. If the developers are sloppy then they might not rename that file, so there might be a "/etc/arch-release" file on an Arch Linux based distribution.

Offline

#3 2012-12-03 17:36:32

ebal
Member
From: Athens, GReece
Registered: 2009-05-26
Posts: 213
Website

Re: archlinux release

thanks drcouzelis,

i came up with those two files, from filesystem package (it was my first thought).
although i knew about arch-release already, i didnt know about os-release.


http://Ευάγγελος.Μπαλάσκας.gr
Unix System Engineer - Registered Linux User #420129

Offline

#4 2012-12-03 21:45:00

fschiff
Member
Registered: 2011-10-06
Posts: 71

Re: archlinux release

os-release was a systemd suggestion

Offline

#5 2012-12-03 22:57:03

WorMzy
Forum Moderator
From: England
Registered: 2010-06-16
Posts: 5,059

Re: archlinux release

As a system administrator on hundreds of PCs+servers, I use 'cat /etc/*release' to check what OS the machine I'm currently ssh'd into uses.

systemd wants to make os-release the standard, but I don't think that'll ever be adopted by every distro, simply because it's a "systemd" proposal, and that causes knee-jerk reactions in some communities.

Last edited by WorMzy (2012-12-03 22:57:39)


Sakura:-
Mobo: ASUS P8Z77-V PRO // Processor: Intel Core i7-3770K 3.4GHz // GFX: nVidia GeForce GTX 970 Ti // RAM: 32GB (4x 8GB) Corsair DDR3 (@ 2133MHz) // Storage: 1x 3TB Seagate SATAII 5x 1TB Samsung SATAII, 2x 120GB Corsair SSD

Offline

#6 2012-12-04 10:36:40

brain0
Developer
From: Aachen - Germany
Registered: 2005-01-03
Posts: 1,382

Re: archlinux release

Even if people hate systemd, they have to agree that the standardizes /etc/os-release is a pretty good idea. The old /etc/arch-release is only present for backward-compatibility with broken third-party tools. I expect that to go away at some point. If you implement something that tests if you run Arch, look at /etc/os-release.

Offline

#7 2012-12-04 13:24:33

x33a
Forum Moderator
Registered: 2009-08-15
Posts: 3,252
Website

Re: archlinux release

@ brain0

Yeah I hate systemd, and didn't even know about os-release, but indeed it makes sense, as you don't need to keep guessing the name of the file for different distros.

Offline

Board footer

Powered by FluxBB