From owner-freebsd-arch@freebsd.org Fri Nov 8 05:14:20 2019 Return-Path: Delivered-To: freebsd-arch@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 946721A75CD for ; Fri, 8 Nov 2019 05:14:20 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: from mail-qk1-x741.google.com (mail-qk1-x741.google.com [IPv6:2607:f8b0:4864:20::741]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 478T2z3b8Vz3P5X for ; Fri, 8 Nov 2019 05:14:19 +0000 (UTC) (envelope-from wlosh@bsdimp.com) Received: by mail-qk1-x741.google.com with SMTP id q70so4176049qke.12 for ; Thu, 07 Nov 2019 21:14:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bsdimp-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=QvIgJSg4SnpRqc84x14HsRzbwrIHEQ0GUWDg9WB2pgo=; b=Tm2XNkguyqAJBcE4HSrCrNrf/9YQZ6Do+jZ5wLdJaDsQtc6b5AfQEqBWfnJKMF9yGG 9ugEh7w6dx04CLYBe5wM+vib4mYZR/BSNVCt3GqHYjmKwqrRh2CVHrcM/vu3EOOBEsLh yfKwr/gj+6sk86DcYw+tKL7/tkbIf/H0rhVUDU3vRq61r0NuCYlt/hsRZmAuUJL4/LcR 2mYudqYs/XN6eUJVu3MVHvB4tUe5THghA5v07vkQ/GnOEb16AMu4T9yG5opFSnL8/yq5 pGXmnM7gSjc4Ps7L4WTLQ2K+cCYH0qfln/DBwJyTb9890XskjlD/R1uM7taOmB3YFrNi rSPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=QvIgJSg4SnpRqc84x14HsRzbwrIHEQ0GUWDg9WB2pgo=; b=czFpZVvwufc6wLVjkC+0vLqEjBvBDkttZ6lGBo9p9Bvu21hN6kfgjzIkOk6L7ugHAk OIG4j/LWcxAnb6P9bLrwXDneuGeb4Vi6VY/B4bn7YtAgxxX6dLTyAUbycQnxSBgeXnnU pSc81+AFtfjt2tzQpz6AXnrwM+lQPO3BnoeyaCRMwQn2Y/Xba/KYdz7doFWyySTYrxJg 9iDxznvF02txn8fIBq/612Xosc4/pH44jaRJ+EbdyZXho7KeXUKrXSdub37SI4CibrGj C7k41oofDUcc9k5g8diDMfvLlVdp8EfZWSH9hBZ6iGkUaNOnUh/G+3Bpwrma7DsNlaZ3 SfhQ== X-Gm-Message-State: APjAAAUvK9QRi/Y8UQkTZ41dsT+kK9K2ZGNebxcYSUsQzRBdVfOFUbR6 u0y8hZE9qxM/vVJnSJs1WEQ1aWdpP+2/JKQNt5pWOvkTJuY= X-Google-Smtp-Source: APXvYqxHwOuSY0cDXvXuTfkCDBCf8WJtR2wmXuVa/00CdphDoLZbr8Wj6c0nxMUVPwJAlSGhRdol2uwmfBrGY8cI/9M= X-Received: by 2002:a37:b07:: with SMTP id 7mr6435513qkl.240.1573190058004; Thu, 07 Nov 2019 21:14:18 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Warner Losh Date: Thu, 7 Nov 2019 22:14:06 -0700 Message-ID: Subject: Re: Creating /etc/os-release To: MJ Cc: freebsd-arch@freebsd.org X-Rspamd-Queue-Id: 478T2z3b8Vz3P5X X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=bsdimp-com.20150623.gappssmtp.com header.s=20150623 header.b=Tm2XNkgu; dmarc=none; spf=none (mx1.freebsd.org: domain of wlosh@bsdimp.com has no SPF policy when checking 2607:f8b0:4864:20::741) smtp.mailfrom=wlosh@bsdimp.com X-Spamd-Result: default: False [-2.39 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; R_DKIM_ALLOW(-0.20)[bsdimp-com.20150623.gappssmtp.com:s=20150623]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-arch@freebsd.org]; DMARC_NA(0.00)[bsdimp.com]; TO_MATCH_ENVRCPT_SOME(0.00)[]; DKIM_TRACE(0.00)[bsdimp-com.20150623.gappssmtp.com:+]; RCPT_COUNT_TWO(0.00)[2]; RCVD_IN_DNSWL_NONE(0.00)[1.4.7.0.0.0.0.0.0.0.0.0.0.0.0.0.0.2.0.0.4.6.8.4.0.b.8.f.7.0.6.2.list.dnswl.org : 127.0.5.0]; R_SPF_NA(0.00)[]; FORGED_SENDER(0.30)[imp@bsdimp.com,wlosh@bsdimp.com]; FREEMAIL_TO(0.00)[gmail.com]; MIME_TRACE(0.00)[0:+,1:+,2:~]; IP_SCORE(-0.39)[ip: (2.45), ipnet: 2607:f8b0::/32(-2.34), asn: 15169(-2.01), country: US(-0.05)]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; FROM_NEQ_ENVFROM(0.00)[imp@bsdimp.com,wlosh@bsdimp.com]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.29 X-BeenThere: freebsd-arch@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Discussion related to FreeBSD architecture List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Nov 2019 05:14:20 -0000 On Thu, Nov 7, 2019, 3:39 PM MJ wrote: > > On 8/11/2019 5:10 am, Warner Losh wrote: > > Greetings, > > > > A standard has evolved in other communities to communicate certain key > > aspects of the system to interested parties. The /etc/os-release file. > The > > standard is defined here http://0pointer.de/blog/projects/os-release and > > here https://www.freedesktop.org/software/systemd/man/os-release.html . > It > > has become a de-facto standard for the graphical systems. > > First off, I'm not attempting to be antagonistic about this, I have no > horse in this race. However, I am genuinely curious about why this is > needed and to that end why it adds more clutter to the system. > > So, forgive me, but why is this needed? Ok, it's a "standard" but for what > reason is there to add it specifically to FreeBSD? > FreeBSD implements industry standards. This is a new standard that creates friction for our users because they have to do extra things that users of other systems get without doing anything. > > FreeBSD currently tries to address this with a port > > sysutils/etc_os-release, but there's a number of issues with it, see for > > example https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=238953. The > > biggest issue being that we can't install a static file: it has to change > > as the system is updated. > > I see one issue. The issue is with the port itself, not FreeBSD. Does > FreeBSD fail to operate with this file missing? What ports are failing with > this missing? > Lots of desktop programs have issues. In my own use cases, our servers run fine without it. My desktop runs fine > without it. I'm not seeing the compelling reason. Sorry. > You can ignore it. I'm sure there are at least 2 extra firewalls you are ignoring or doing something to disable... > To that end, I propose the following: First, we create a /etc/os-release > > symlink to /var/run/os-release. This will place the file in the standard > > place, but allow its generation on each boot in a friendly to > > read-only-root manner. Second, we create a /etc/rc.d/os-release script > that > > will populate /var/run/os-release. Since this is a standard rc script, we > > can allow people to opt-out of generating this file in a standardized way > > (although it contains information that's available to anybody on the > > system, some reduced configurations may not have all the scripts / > programs > > used to generate it). If the file isn't generated, then opening it will > > return the same not found error as before. Since this is a symlink, it's > > friendly to etcupdate / mergemaster updating schemes. Finally, we'd > > obsolete the port since it is flawed anyway. > > So, the file is not needed, it will be nice to have, but I still can't see > a compelling reason to have it. > You are free to set osrelease_enable=NO in /etc/rc.conf if you don't want it. Just because it's a "standard" in Linux doesn't offer up to me a compelling > reason for its integration into the system. > It is standard on other systems. It causes friction to our users because we don't have it. It fits best into the base due to the location and the need to update when we update the system. Warner I am keen to hear those reasons; genuinely. > > Regards > > Mark > > >