Date: Thu, 20 Jul 2023 09:22:29 -0400 From: "Naman Sood" <mail@nsood.in> To: "Baptiste Daroussin" <bapt@freebsd.org> Cc: freebsd-pkg@freebsd.org Subject: Re: Why did pkg delete mysql80-server here? Message-ID: <a4ae2441-2017-4ef6-b17b-e47182854a47@app.fastmail.com> In-Reply-To: <2tt66xyidpyk6cxqstovqzwklp5zq6y74rfv3pzsceoptrp7ju@ubhtobnmhew2> References: <d7bd4b00-b0d4-4d2c-999b-dae183effa1e@app.fastmail.com> <2tt66xyidpyk6cxqstovqzwklp5zq6y74rfv3pzsceoptrp7ju@ubhtobnmhew2>
index | next in thread | previous in thread | raw e-mail
[-- Attachment #1 --]
Unfortunately I did hit y instead of N, so I've lost that information for now. If this happens again, I'll come back with this info. Thanks!
Thanks,
Naman.
(they/them)
On Thu, Jul 20, 2023, at 05:18, Baptiste Daroussin wrote:
> On Wed, Jul 19, 2023 at 07:07:34PM -0400, Naman Sood wrote:
> > Hi,
> >
> > I just started using FreeBSD 13.2 for a personal storage server. I had this extremely surprising interaction with pkg today:
> >
> > nsood@silicon:~ % sudo pkg install rclone
> > Password:
> > Updating FreeBSD repository catalogue...
> > Fetching packagesite.pkg: 100% 7 MiB 465.6kB/s 00:15
> > Processing entries: 100%
> > FreeBSD repository update completed. 33793 packages processed.
> > All repositories are up to date.
> > New version of pkg detected; it needs to be installed first.
> > The following 1 package(s) will be affected (of 0 checked):
> >
> > Installed packages to be UPGRADED:
> > pkg: 1.19.1_1 -> 1.19.2
> >
> > Number of packages to be upgraded: 1
> >
> > 8 MiB to be downloaded.
> >
> > Proceed with this action? [y/N]: y
> > [1/1] Fetching pkg-1.19.2.pkg: 100% 8 MiB 1.7MB/s 00:05
> > Checking integrity... done (0 conflicting)
> > [1/1] Upgrading pkg from 1.19.1_1 to 1.19.2...
> > [1/1] Extracting pkg-1.19.2: 100%
> > Updating FreeBSD repository catalogue...
> > FreeBSD repository is up to date.
> > All repositories are up to date.
> > The following 2 package(s) will be affected (of 0 checked):
> >
> > Installed packages to be REMOVED:
> > mysql80-server: 8.0.32
> >
> > New packages to be INSTALLED:
> > rclone: 1.62.2
> >
> > Number of packages to be removed: 1
> > Number of packages to be installed: 1
> >
> > The operation will free 138 MiB.
> > 12 MiB to be downloaded.
> >
> > Proceed with this action? [y/N]: y
> > [1/1] Fetching rclone-1.62.2.pkg: 100% 12 MiB 3.1MB/s 00:04
> > Checking integrity... done (0 conflicting)
> > [1/2] Deinstalling mysql80-server-8.0.32...
> > [1/2] Deleting files for mysql80-server-8.0.32: 100%
> > ==> You should manually remove the "mysql" user.
> > ==> You should manually remove the "mysql" group
> > [2/2] Installing rclone-1.62.2...
> > [2/2] Extracting rclone-1.62.2: 100%
> > You may need to manually remove /usr/local/etc/mysql/my.cnf if it is no longer needed.
> >
> > It's definitely on me to have not read the message carefully before saying yes, but also extremely unintuitive that installing rclone, presumably an unrelated package, caused mysql80-server to be uninstalled. Reinstalling mysql80-server worked fine, and did not remove rclone, so it wasn't a package conflict. Thankfully the mysqld process in memory kept running while I reinstalled the package so I did not experience any downtime, but I would still like to avoid a heart attack in the future. So can someone explained what I did wrong here that caused mysql80-server to be uninstalled?
> >
> > Thanks,
> > Naman.
> > (they/them)
> >
>
> Very hard to determine, without the debug output, somehow the solver considered
> there was a conflict in the process.
>
> Partial update (aka installing something on a new repo without upgrading all the
> packages at once) is fragile, and pkg needs to become more robust here.
>
> I don't know what is the best here, before we were forbidding it and forcing the
> user to update everything. but this was not convenient for plenty of users as
> most of the time it works as expected.
>
> So yes this a bug on pkg side, usually hard to debug when it happens, if you
> have a reproducible way to make it happen I will be more han happy if you can
> provide me your /var/db/pkg (the whole thing if you hit N instead of y).
>
> I will then be able to reproduce locally and try to fix.
>
> Another way to help me is when it happens, hit N and rerun with pkg -o
> DEBUG_LEVEL=4 which will be very verbose and provide me the output so I can
> analyze.
>
> Best regards,
> Bapt
>
[-- Attachment #2 --]
<!DOCTYPE html><html><head><title></title><style type="text/css">p.MsoNormal,p.MsoNoSpacing{margin:0}</style></head><body><div>Unfortunately I did hit y instead of N, so I've lost that information for now. If this happens again, I'll come back with this info. Thanks!</div><div><br></div><div id="sig128512984"><div class="signature">Thanks,<br></div><div class="signature">Naman.<br></div><div class="signature">(they/them)<br></div></div><div><br></div><div>On Thu, Jul 20, 2023, at 05:18, Baptiste Daroussin wrote:<br></div><blockquote type="cite" id="qt" style=""><div>On Wed, Jul 19, 2023 at 07:07:34PM -0400, Naman Sood wrote:<br></div><div>> Hi,<br></div><div>> <br></div><div>> I just started using FreeBSD 13.2 for a personal storage server. I had this extremely surprising interaction with pkg today:<br></div><div>> <br></div><div>> nsood@silicon:~ % sudo pkg install rclone<br></div><div>> Password:<br></div><div>> Updating FreeBSD repository catalogue...<br></div><div>> Fetching packagesite.pkg: 100% 7 MiB 465.6kB/s 00:15 <br></div><div>> Processing entries: 100%<br></div><div>> FreeBSD repository update completed. 33793 packages processed.<br></div><div>> All repositories are up to date.<br></div><div>> New version of pkg detected; it needs to be installed first.<br></div><div>> The following 1 package(s) will be affected (of 0 checked):<br></div><div>> <br></div><div>> Installed packages to be UPGRADED:<br></div><div>> pkg: 1.19.1_1 -> 1.19.2<br></div><div>> <br></div><div>> Number of packages to be upgraded: 1<br></div><div>> <br></div><div>> 8 MiB to be downloaded.<br></div><div>> <br></div><div>> Proceed with this action? [y/N]: y<br></div><div>> [1/1] Fetching pkg-1.19.2.pkg: 100% 8 MiB 1.7MB/s 00:05 <br></div><div>> Checking integrity... done (0 conflicting)<br></div><div>> [1/1] Upgrading pkg from 1.19.1_1 to 1.19.2...<br></div><div>> [1/1] Extracting pkg-1.19.2: 100%<br></div><div>> Updating FreeBSD repository catalogue...<br></div><div>> FreeBSD repository is up to date.<br></div><div>> All repositories are up to date.<br></div><div>> The following 2 package(s) will be affected (of 0 checked):<br></div><div>> <br></div><div>> Installed packages to be REMOVED:<br></div><div>> mysql80-server: 8.0.32<br></div><div>> <br></div><div>> New packages to be INSTALLED:<br></div><div>> rclone: 1.62.2<br></div><div>> <br></div><div>> Number of packages to be removed: 1<br></div><div>> Number of packages to be installed: 1<br></div><div>> <br></div><div>> The operation will free 138 MiB.<br></div><div>> 12 MiB to be downloaded.<br></div><div>> <br></div><div>> Proceed with this action? [y/N]: y<br></div><div>> [1/1] Fetching rclone-1.62.2.pkg: 100% 12 MiB 3.1MB/s 00:04 <br></div><div>> Checking integrity... done (0 conflicting)<br></div><div>> [1/2] Deinstalling mysql80-server-8.0.32...<br></div><div>> [1/2] Deleting files for mysql80-server-8.0.32: 100%<br></div><div>> ==> You should manually remove the "mysql" user. <br></div><div>> ==> You should manually remove the "mysql" group <br></div><div>> [2/2] Installing rclone-1.62.2...<br></div><div>> [2/2] Extracting rclone-1.62.2: 100%<br></div><div>> You may need to manually remove /usr/local/etc/mysql/my.cnf if it is no longer needed.<br></div><div>> <br></div><div>> It's definitely on me to have not read the message carefully before saying yes, but also extremely unintuitive that installing rclone, presumably an unrelated package, caused mysql80-server to be uninstalled. Reinstalling mysql80-server worked fine, and did not remove rclone, so it wasn't a package conflict. Thankfully the mysqld process in memory kept running while I reinstalled the package so I did not experience any downtime, but I would still like to avoid a heart attack in the future. So can someone explained what I did wrong here that caused mysql80-server to be uninstalled?<br></div><div>> <br></div><div>> Thanks,<br></div><div>> Naman.<br></div><div>> (they/them)<br></div><div>> <br></div><div><br></div><div>Very hard to determine, without the debug output, somehow the solver considered<br></div><div>there was a conflict in the process.<br></div><div><br></div><div>Partial update (aka installing something on a new repo without upgrading all the<br></div><div>packages at once) is fragile, and pkg needs to become more robust here.<br></div><div><br></div><div>I don't know what is the best here, before we were forbidding it and forcing the<br></div><div>user to update everything. but this was not convenient for plenty of users as<br></div><div>most of the time it works as expected.<br></div><div><br></div><div>So yes this a bug on pkg side, usually hard to debug when it happens, if you<br></div><div>have a reproducible way to make it happen I will be more han happy if you can<br></div><div>provide me your /var/db/pkg (the whole thing if you hit N instead of y).<br></div><div><br></div><div>I will then be able to reproduce locally and try to fix.<br></div><div><br></div><div>Another way to help me is when it happens, hit N and rerun with pkg -o<br></div><div>DEBUG_LEVEL=4 which will be very verbose and provide me the output so I can<br></div><div>analyze.<br></div><div><br></div><div>Best regards,<br></div><div>Bapt<br></div><div><br></div></blockquote></body></html>
help
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?a4ae2441-2017-4ef6-b17b-e47182854a47>
