From owner-freebsd-ports@freebsd.org Wed Oct 11 23:15:18 2017 Return-Path: Delivered-To: freebsd-ports@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 663E6E39FCA for ; Wed, 11 Oct 2017 23:15:18 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: from mail-vk0-x22a.google.com (mail-vk0-x22a.google.com [IPv6:2607:f8b0:400c:c05::22a]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G2" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 2B05081911 for ; Wed, 11 Oct 2017 23:15:18 +0000 (UTC) (envelope-from kob6558@gmail.com) Received: by mail-vk0-x22a.google.com with SMTP id 126so1812411vkj.9 for ; Wed, 11 Oct 2017 16:15:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:cc; bh=ORF/4arKGIBVd74OhCsaA29WEyH9yjoki/6gsdDPDrw=; b=IcOnXutMS8hcro9FJLzYni6JIR6cGUGGBzu0pLmikMpxeULjJFqqkZnkK1MFWAbrid DjGt6O8aqChdoSyW0DvLw7R3bRk6jy2XgmbcxkEvw0EKI6oPVVE5YDAbi3L/Xm+s6UdI TFG8G96fDRps5EQglmvy0DYZGDjIGHVcupYUh2JQ8Y/sFwqJxiC1So4NWVd5yROva2qN 0YLITZ27OGbZY9SVB1Yt3yVT3gWJeDpHVPTyylVpmqL90+MApGSoCZ8s72MIKWeH5KUF MEm4BOBvRfFaNs5VA8VWxdqfuKbKgZegY+GmbE0ymWUtucCe0Ln/hOjO7OurKErSuuOp TP3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:sender:in-reply-to:references:from :date:message-id:subject:to:cc; bh=ORF/4arKGIBVd74OhCsaA29WEyH9yjoki/6gsdDPDrw=; b=Ndu9RpolK1keWyn2eGIeMELPk5eOmRiN+lFqsbQecHCxAAYutqvOLGUhtLQv7tO4H4 EIx52rsPQL9cav7X3lhY5IAO31x36gsSMNvDcXz8e6+m5gEx/8UNhbqbLaHLuLUfc67J bh2YS+DEyxqRr6xeX0fsOcQo8yvJYM7bOnW2mmWAJX74zPwxsjnGSFol61mXgBKzZex1 fuOguZ998EjM7276rpgqi12HA2Ktydsv+7ws5MmQAoI1HkWP3xveBIYvSRPRZrBq+coc QMbIzxboZmuBaaWBJZsrrT/JI7baMWyG7KqLYxHzFWRNY5II7cMOqemq02msFDj5brQg oHvw== X-Gm-Message-State: AMCzsaVZ7xYTn9/PqkUCleUWGpiDC3nB/42H21TjwmXfROWLrB4f5J4o Cs2ph9sa2h8XpYUIs9uCEopkuMFRpq9KupNvFf+hahZQ X-Google-Smtp-Source: AOwi7QAlvMe7GicJn9RGpq0lNziG6pAQPQX3GaXTvlWustAL5cU0ybSlf5MyH86GTAK/+QjCLoEZwsHaRB7zhsHWNcE= X-Received: by 10.31.141.206 with SMTP id p197mr1001752vkd.53.1507763717091; Wed, 11 Oct 2017 16:15:17 -0700 (PDT) MIME-Version: 1.0 Sender: kob6558@gmail.com Received: by 10.103.85.8 with HTTP; Wed, 11 Oct 2017 16:15:16 -0700 (PDT) In-Reply-To: References: From: Kevin Oberman Date: Wed, 11 Oct 2017 16:15:16 -0700 X-Google-Sender-Auth: guo5qQ0wgfCvxNtD0xusYuGaJbU Message-ID: Subject: Re: pkg: sqlite error while executing sqlite open in file pkgdb.c:1126: unable to open database file To: Jos Chrispijn Cc: FreeBSD Ports ML Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.23 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Oct 2017 23:15:18 -0000 On Wed, Oct 11, 2017 at 11:15 AM, Jos Chrispijn wrote: > Dear group, > > Apparently I have an issue when finalizing the ports with portmanager. > > When I run this batch to update my ports: > > portmaster -y --clean-distfiles > portmaster -y --clean-packages > portmaster -y --check-depends > portmaster -a > > At the end or the update (everything goes well) I sometimes get this > display: > > --- cut --- > > ===>>> Returning to update check of installed ports > ===>>> Update check of installed ports complete > pkg: sqlite error while executing sqlite open in file pkgdb.c:1126: unable > to open database file > ===>>> Done displaying pkg-message files > ===>>> The following actions were performed: > > < list with ports updates (successful) > > > --- cut --- > > I checked numerous solutions, but most of them refer to a solution done > with the pkg command, while I am using portmaster to upgrade. > > Can someone tell me how I can solve this issue without risking my ports > collection being corrupted by some pkg command? > > Thanks for your help! > Jos Chrispijn > While you are using portmaster(8), portmaster, in turn, uses pkg and the pkg database which is sqlite So the pkg suggestions are likely reasonable. It looks like the db is missing, seriously damaged, has protections that keep portmaster from accessing it, or your db is not in the right pkg is looking for it. That said, it's not clear exactly where in the process these occurred. If you had already installed ports, pkg had already accessed the db several times. If you can't figure out why the db could not be opened, providing a bit more information might help. So might a "pkg check -B" which will read the db many times. If you can narrow it down, you can also use sqlite(1) to issue db queries directly if you are familiar with its commands (mostly SQL, of course). -- Kevin Oberman, Part time kid herder and retired Network Engineer E-mail: rkoberman@gmail.com PGP Fingerprint: D03FB98AFA78E3B78C1694B318AB39EF1B055683