Received: from out1.migadu.com (out1.migadu.com [91.121.223.63]) by nld3-dev1.alpinelinux.org (Postfix) with ESMTPS id 0DBA6781994 for <~alpine/users@lists.alpinelinux.org>; Tue, 4 Aug 2020 04:51:31 +0000 (UTC) Subject: Re: How to address apk file conflicts? DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dereferenced.org; s=default; t=1596516689; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=bg+wRSrrOQfu1KdjHrlsdP+kYR8DxjhyL1aTi4iurAc=; b=bzGOm/CQ3wn1c1B74Z8sxkY2xlAgzJhQCAD3B/9lebTXN+R2LkZNWTLuENjaQzuQYQTVqw Zkx/cd/htQxhHXC4Z7oocLNkLJEKttAfSL+mU6Yfhn3EWZ52hZJI6ZD2WtP8mSuSyb7JSC RX65TP8wn6/p21q3BkCh8Lpc3C8Hsrg= To: Winston Weinert , ~alpine/users@lists.alpinelinux.org References: <20200804043531.ltdodl7vps2cywns@ml1.net> X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Ariadne Conill Message-ID: <2c3496cd-ce61-c912-cb16-7399dda05c15@dereferenced.org> Date: Mon, 3 Aug 2020 22:51:22 -0600 MIME-Version: 1.0 In-Reply-To: <20200804043531.ltdodl7vps2cywns@ml1.net> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Spam-Score: 0.90 Hello, On 2020-08-03 22:35, Winston Weinert wrote: > Sometimes I encounter an alpine box with apk errors: > > / # apk add nethack > (1/1) Installing nethack (3.6.6-r0) > Executing busybox-1.31.1-r16.trigger > 1 error; 28 MiB in 23 packages > > My usual approach to fixing these issues is to run "apk > fix". Sometimes it fixes it, other times it isn't fixable due to a > file conflict: > > / # apk fix > (1/1) Reinstalling perl-doc (5.30.3-r0) > ERROR: perl-doc-5.30.3-r0: trying to overwrite usr/share/man/man3/Data::Dumper.3pm.gz owned by perl-data-dumper-doc-2.173-r3. > 1 error; 23 MiB in 19 packages > > In a situation such as the above, my solution is to delete one of the > affected packages, and report the conflict to > https://gitlab.alpinelinux.org/alpine/aports/-/issues This is the correct thing to do. Especially with perl, it is easy to wind up in a situation where perl itself now ships a module that used to be out-of-tree. > Is there a better recourse than deleting one of the conflicting > packages? Is there a mechanism in apk to manually resolve file > conflicts? Unfortunately not, but if you open an issue against apk-tools, it is something we could investigate implementing in apk-tools 3. > Unfortunately things like "abuild -r" and ansible's apk module will > fail when apk fails even if the overall operation was a success. > > Happy apk-ing, > Winston Weinert > winny.tech Ariadne