From owner-freebsd-questions@freebsd.org Fri Feb 5 14:21:40 2016 Return-Path: Delivered-To: freebsd-questions@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 CB8FCA76A60 for ; Fri, 5 Feb 2016 14:21:40 +0000 (UTC) (envelope-from trond@fagskolen.gjovik.no) Received: from smtp.fagskolen.gjovik.no (smtp.fagskolen.gjovik.no [IPv6:2001:700:1100:1:200:ff:fe00:b]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "smtp.fagskolen.gjovik.no", Issuer "Fagskolen i Gj??vik" (not verified)) by mx1.freebsd.org (Postfix) with ESMTPS id 570361277 for ; Fri, 5 Feb 2016 14:21:40 +0000 (UTC) (envelope-from trond@fagskolen.gjovik.no) Received: from mail.fig.ol.no (localhost [127.0.0.1]) by mail.fig.ol.no (8.15.2/8.15.2) with ESMTPS id u15ELVAD022567 (version=TLSv1.2 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Fri, 5 Feb 2016 15:21:31 +0100 (CET) (envelope-from trond@fagskolen.gjovik.no) Received: from localhost (trond@localhost) by mail.fig.ol.no (8.15.2/8.15.2/Submit) with ESMTP id u15ELVMB022564; Fri, 5 Feb 2016 15:21:31 +0100 (CET) (envelope-from trond@fagskolen.gjovik.no) X-Authentication-Warning: mail.fig.ol.no: trond owned process doing -bs Date: Fri, 5 Feb 2016 15:21:31 +0100 (CET) From: =?ISO-8859-1?Q?Trond_Endrest=F8l?= Sender: Trond.Endrestol@fagskolen.gjovik.no To: Marius Schamschula cc: freebsd-questions@freebsd.org Subject: Re: mysql57 upgrade issue In-Reply-To: <9EE3E5E5-F717-4536-9EEB-C0CD07A190A8@schamschula.com> Message-ID: References: <71862CB3-F0C9-4981-9730-2C1054C3E572@schamschula.com> <9EE3E5E5-F717-4536-9EEB-C0CD07A190A8@schamschula.com> User-Agent: Alpine 2.20 (BSF 67 2015-01-07) Organization: Fagskolen Innlandet OpenPGP: url=http://fig.ol.no/~trond/trond.key MIME-Version: 1.0 X-Spam-Status: No, score=-1.0 required=5.0 tests=ALL_TRUSTED, AWL autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on mail.fig.ol.no Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Feb 2016 14:21:41 -0000 On Fri, 5 Feb 2016 07:42-0600, Marius Schamschula wrote: > Trond, > > Apparently there is something amiss here, I probably should open a ticket. > > portupgrade -fprv databases/mysql57-server databases/mysql57-client You can't run that as a single invocation. portupgrade would then determine that upgrading the client should precede the upgrading of the server, and you'll be back at square one. > also failed with the same error, just leaving mysql57-client uninstalled. > > I ended up running the following: > > cd /usr/ports/databases/mysql57-server > > make deinstall > make install > > This left me with a working mysql-client/server-5.7.10_2 > > On Feb 5, 2016, at 3:57 AM, Trond Endrestøl wrote: > > > On Thu, 4 Feb 2016 19:26-0600, Marius Schamschula wrote: > > > >> While running portmaster I found this failure: > >> > >> ===> Registering installation for mysql57-client-5.7.10_2 > >> Installing mysql57-client-5.7.10_2... > >> pkg-static: mysql57-client-5.7.10_2 conflicts with mysql57-server-5.7.10_1 (installs files into the same place). Problematic file: /usr/local/include/mysql/binary_log_types.h > >> *** Error code 70 > >> > >> Stop. > >> > >> What to do? Manually, uninstall mysql57-server-5.7.10_1? > > > > I'm using portupgrade, and I had to update databases/mysql57-server > > prior to databases/mysql57-client. > > > > Something along these lines: > > > > portupgrade -fprv databases/mysql57-server > > portupgrade -fprv databases/mysql57-client -- +-------------------------------+------------------------------------+ | Vennlig hilsen, | Best regards, | | Trond Endrestøl, | Trond Endrestøl, | | IT-ansvarlig, | System administrator, | | Fagskolen Innlandet, | Gjøvik Technical College, Norway, | | tlf. mob. 952 62 567, | Cellular...: +47 952 62 567, | | sentralbord 61 14 54 00. | Switchboard: +47 61 14 54 00. | +-------------------------------+------------------------------------+ From owner-freebsd-questions@freebsd.org Fri Feb 5 18:20:23 2016 Return-Path: Delivered-To: freebsd-questions@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 BFEEEA9D817 for ; Fri, 5 Feb 2016 18:20:23 +0000 (UTC) (envelope-from sergeig.public@gmail.com) Received: from mail-vk0-x22f.google.com (mail-vk0-x22f.google.com [IPv6:2607:f8b0:400c:c05::22f]) (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 7C9491C38 for ; Fri, 5 Feb 2016 18:20:23 +0000 (UTC) (envelope-from sergeig.public@gmail.com) Received: by mail-vk0-x22f.google.com with SMTP id c3so15246361vkb.3 for ; Fri, 05 Feb 2016 10:20:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:date:message-id:subject:from:to:content-type; bh=6KTTo8diorUhtYW/pNSpkAaXLjZLRaS2wDZTLWIjFWc=; b=crhSPvImBkiri/Cm7NrORGWcHcZrV0TpYEtea0Czum1hNrZ9kly74DqQkUMngnq0PU /ieNU7SuRAewEgxSeXMclxsT9s1OZCCtS0NldU9qFV3q+zd26VQzT/xke8gcQgteiMCT eedRiTlVkfqIkz2hHgdaVm1Wucr4hG88z9FjBkZrxXgFZgMdrYZoX6ex1psg3MGG2N8V 6KLd2EJcA5fovb4uHsnejpcdTdwviistpMen4ECh/PcvHru14GKIOMe7kxBdYMgo2mnd RjA3oDALJcf4TZM9BH02AvOBvpvGBhOL/2ROboLGk4+5RQW4vMC2h6tk7cZvebfZP5a2 j5Sg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:date:message-id:subject:from:to :content-type; bh=6KTTo8diorUhtYW/pNSpkAaXLjZLRaS2wDZTLWIjFWc=; b=cb+eZoVxbUPaC38R2+CzBJaivj1wGeEdAhWXFGj1lEf9RN5UQ06DHrgZzor2z2gyz0 zP5MjiK21TrYW4tHHTgP/JJppLbvEyW1LPMdfIZ4352B9VmQ3XY91mUK+hVPF7Tadlr0 R8R4sJU1j6XwOvjfsPWv+wIC0m/YpB5piUoI8RQ+lzTPBcJxM5P/HfZb/vNOHfh6byVd tweYz3XJhyhag+IaF7eq/Szfo4glEaQq89wiQrl5+ISlL+DdiB3zmNZ0totlzZ+7M8LA tNIRc48hqNfc4IZHbiscqUvVEx0OBaJeN331qMwFCQsfwY5txAQU/gX7Ya4DkkofDai5 +GWg== X-Gm-Message-State: AG10YOSQQ+ZmEMpC/Zn7F+fKxZJ9EmbAtEHw3lUQCccEw4GYIcCZCrdBAAhBenmDB9xCBKwk0YHv9UvB3kjbOw== MIME-Version: 1.0 X-Received: by 10.31.0.215 with SMTP id 206mr10662598vka.22.1454696422442; Fri, 05 Feb 2016 10:20:22 -0800 (PST) Received: by 10.31.174.132 with HTTP; Fri, 5 Feb 2016 10:20:22 -0800 (PST) Date: Fri, 5 Feb 2016 10:20:22 -0800 Message-ID: Subject: A: ezjail to qjail migration From: Sergei G To: FreeBSD Questions Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.20 X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Feb 2016 18:20:23 -0000 FYI If for watever (in)sane reason you need to migrate your ezjail installation to qjail, here is what appears have worked for me. * stop jails * pkg remove ezjail * comment out your jail related, IP management related /etc/rc.conf entries * move content of /usr/jails/ to some other location. I moved it to /mnt, because of the file system remount. * pkg install qjail (not qjail2) * qjail install Actual jail migration I created a Makefile (it is my personal preference due to ease of named parameters, auto quit on error and ability to create new task quickly) in /usr/jails Here is a relevant Makefile content: name=noname lip=254 oldjails=oldjails oldname=$(name) n=n default: cat Makefile # create jail create: qjail create -n bce0 -4 192.168.3.$(lip) $(name) # make sync oldname=... name=... n= old=/mnt/$(oldname) sync: rsync -aAXSH$(n)v --log-file=sync-$(name).log --exclude-from=sync-excl.txt $(old)/etc $(old)/root $(old)/tmp $(old)/usr $(old)/var $(name) # push update to jail s-resolv: -rm $(name)/etc/resolv.conf cp flavors/hnet/etc/resolv.conf $(name)/etc/resolv.conf And important rsync exclusions file: cat sync-excl.txt /sbin /libexec /sys /lib /usr/libdata /usr/libexec /usr/src /usr/include /usr/bin /usr/share /usr/sbin /usr/lib32 /usr/lib /usr/ports /bin /etc/rc.conf /etc/periodic.conf /etc/resolv.conf For example, if I have wiki-hnet jail in /mnt/wiki-hnet-old and I want to create a new jail wiki-hnet on the same 192.168.3.11 IP I will do: 1. create qjails jail with: make create lip=11 name=wiki-hnet 2. now I need to merge content of wiki-hnet-old jail from /mnt/wiki-hnet-old into new jail: test run: make sync oldname=wiki-hnet-old name=wiki-hnet real run: make sync oldname=wiki-hnet-old name=wiki-hnet n= That uses rsync to copy files, but excludes list of shared jailed directories. Last 3 items in sync-excl.txt are files that I added, because of my configuration differences and need to do manual merge. I had to copy reolv.conf file enough times that there is a custom make target for that: make s-resolv name=wiki-hnet which copies content from flavor directory. The variables have defaults to prevent destruction in case you forget a value. It seems to work for me on fully updated FreeBSD 10.2 release.