From owner-freebsd-questions@freebsd.org Tue Jan 29 12:35:16 2019 Return-Path: Delivered-To: freebsd-questions@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 8062514BC2B1 for ; Tue, 29 Jan 2019 12:35:16 +0000 (UTC) (envelope-from freebsd@qeng-ho.org) Received: from bede.qeng-ho.org (bede.qeng-ho.org [217.155.128.241]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E351784E7D for ; Tue, 29 Jan 2019 12:35:15 +0000 (UTC) (envelope-from freebsd@qeng-ho.org) Received: from arthur.home.qeng-ho.org (arthur.home.qeng-ho.org [172.23.1.2]) by bede.qeng-ho.org (Postfix) with ESMTP id 57BEC1064F; Tue, 29 Jan 2019 12:35:14 +0000 (GMT) Subject: Re: Replacing base commands with pkg versions To: Lorenzo Salvadore , FreeBSD Questions References: <2WSWeqA769U9_j-YlfypjYKPgycGgCJH_5-w2PzJSegmBaHtZtTie7Kht_IANZU2s9xDJSE8kiDBP_9EvUj7ccQa1uevCPPiyoOAIm03fPo=@protonmail.ch> From: Arthur Chance Message-ID: Date: Tue, 29 Jan 2019 12:35:14 +0000 User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:60.0) Gecko/20100101 Thunderbird/60.4.0 MIME-Version: 1.0 In-Reply-To: <2WSWeqA769U9_j-YlfypjYKPgycGgCJH_5-w2PzJSegmBaHtZtTie7Kht_IANZU2s9xDJSE8kiDBP_9EvUj7ccQa1uevCPPiyoOAIm03fPo=@protonmail.ch> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: E351784E7D X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of freebsd@qeng-ho.org designates 217.155.128.241 as permitted sender) smtp.mailfrom=freebsd@qeng-ho.org X-Spamd-Result: default: False [-2.83 / 15.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-0.94)[-0.941,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:217.155.128.240/29]; NEURAL_HAM_LONG(-1.00)[-0.998,0]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[qeng-ho.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; TO_DN_ALL(0.00)[]; MX_GOOD(-0.01)[cached: mx1.mythic-beasts.com]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.19)[-0.193,0]; IP_SCORE(-0.39)[asn: 13037(-1.83), country: GB(-0.09)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:13037, ipnet:217.155.0.0/16, country:GB]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Jan 2019 12:35:16 -0000 On 29/01/2019 12:31, Lorenzo Salvadore via freebsd-questions wrote: >> What is the recommended way of dealing with the base versions of >> commands when installing a package version instead? Should I chmod -x >> the base executable(s), delete them or rename them? What happens if I >> subsequently do a freebsd-update - do the base executables get >> reinstated or are they ignored? >> >> The specific case I'm interested in is unbound under 11.2, but this >> applies to a variety of programs (CUPS vs base lpr, or base vs pkg llvm >> come to mind) and if there's any official guidance on this I've missed it. > > I cannot give you an official answer, but if you always want to have the pkg > version getting precedence on the base version, I would reorder the PATH > variable. > > If instead you want to mix versions, I would not change the base system, I > would rather create aliases for the shell. In this case I specifically want to disable the base commands, and want them to be disabled under all circumstances, hence the suggestions of chmod -x, etc. -- Always learn from the mistakes of others, because you won't live long enough to learn from making all possible mistakes yourself.