From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47638) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dtAW6-0005YG-HE for guix-patches@gnu.org; Sat, 16 Sep 2017 06:40:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dtAW2-0007CM-Gq for guix-patches@gnu.org; Sat, 16 Sep 2017 06:40:06 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:34691) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dtAW2-0007CI-DK for guix-patches@gnu.org; Sat, 16 Sep 2017 06:40:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dtAW2-0007Q7-1v for guix-patches@gnu.org; Sat, 16 Sep 2017 06:40:02 -0400 Subject: [bug#28399] [PATCH 1/2] services: mysql: Fix missing modules on activation. Resent-Message-ID: Date: Sat, 16 Sep 2017 11:38:11 +0100 From: Christopher Baines Message-ID: <20170916113811.3c7d1b33@cbaines.net> In-Reply-To: <87377nlixr.fsf@gnu.org> References: <20170909153905.087c013f@cbaines.net> <20170909145343.14851-1-mail@cbaines.net> <87shftd67d.fsf@gnu.org> <20170912194825.70eb4436@cbaines.net> <87377nlixr.fsf@gnu.org> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; boundary="Sig_/6sDKgFENeCFZxhb2i645nfO"; protocol="application/pgp-signature" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+kyle=kyleam.com@gnu.org Sender: "Guix-patches" To: Ludovic =?UTF-8?Q?Court=C3=A8s?= Cc: 28399@debbugs.gnu.org --Sig_/6sDKgFENeCFZxhb2i645nfO Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable On Sat, 16 Sep 2017 00:02:08 +0200 ludo@gnu.org (Ludovic Court=C3=A8s) wrote: > Heya, >=20 > Christopher Baines skribis: >=20 > > On Mon, 11 Sep 2017 09:50:46 +0200 > > ludo@gnu.org (Ludovic Court=C3=A8s) wrote: > > =20 > >> Hi Chris, > >>=20 > >> Christopher Baines skribis: > >> =20 > >> > Some systems using the MySQL service would fail to boot, giving > >> > the error: > >> > > >> > ERROR: no code for module (ice-9 popen) =20 >=20 > [...] >=20 > >> The =E2=80=98use-modules=E2=80=99 form should be enough. Does the tes= t you sent > >> reproduce the original problem? =20 > > > > It does for me. If you just revert the commit adding in the > > with-imported-modules bit, running the mysql system test then fails: > > > > ERROR: In procedure scm-error: > > ERROR: no code for module (ice-9 popen) =20 >=20 > The activation script is run by the =E2=80=9Cboot=E2=80=9D script before = it spawns > shepherd. The boot script runs over the initrd=E2=80=99s Guile, which is > statically linked. >=20 > However, (ice-9 popen) starts by dynamically loading libguile and > calling a function therein: >=20 > (eval-when (expand load eval) > (load-extension (string-append "libguile-" (effective-version)) > "scm_init_popen")) >=20 > Dynamic loading is not supposed to work in the statically-linked > Guile, but apparently it does work sometimes: >=20 > --8<---------------cut here---------------start------------->8--- > $ sudo > chroot /gnu/store/3ir873f4dsdl3aaj48iqykn6437ilk0p-guile-static-stripped-= 2.2.2 /bin/guile > guile: warning: failed to install locale GC Warning: > pthread_getattr_np or pthread_attr_getstack failed for main thread GC > Warning: Couldn't read /proc/stat warning: failed to install locale: > Invalid argument GNU Guile 2.2.2 > Copyright (C) 1995-2017 Free Software Foundation, Inc. >=20 > Guile comes with ABSOLUTELY NO WARRANTY; for details type `,show w'. > This program is free software, and you are welcome to redistribute it > under certain conditions; type `,show c' for details. >=20 > Enter `,help' for help. > scheme@(guile-user)> ,use(ice-9 popen) > scheme@(guile-user)> open-pipe* > $1 =3D # > --8<---------------cut here---------------end--------------->8--- >=20 > Perhaps it=E2=80=99s due to the libtool/ltdl preload feature. >=20 > What=E2=80=99s more puzzling though, is that it works in some cases (like > above) and not in others (in the test VM). >=20 > Needs more thought=E2=80=A6 Interesting, thanks for looking in to this Ludo. I've just thought that this could be the cause of my problems in booting one of my GuixSD machines, as I am using the mysql service (with MariaDB). When you say dynamic loading is supposed not to work with a statically linked guile, does this mean that activation scripts should avoid using (ice-9 popen)? Or, given that it works some of the time, it could be made to work reliably...? --Sig_/6sDKgFENeCFZxhb2i645nfO Content-Type: application/pgp-signature Content-Description: OpenPGP digital signature -----BEGIN PGP SIGNATURE----- iQKTBAEBCgB9FiEEPonu50WOcg2XVOCyXiijOwuE9XcFAlm8/xRfFIAAAAAALgAo aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcACgkQXiijOwuE 9XddVg/+Oj5cZHL7s/lXKs6V/IP2RJxCISZAOQKKPbCJhHw1T7QGFlHzoRle5uJ3 3YUlLkV+I/gGsCshPsl5pm3s0x4kXEJSGCE2Va8MZe83D3zve3WJaUKzpY2+zpeM wKk+Y2MDnq1qGNiF+AYgyxZ4jO4vn3AO0JEtEtTot2NfTLFzh3+Gx7mtesf7/BKl KKD5ZgZcjko8WOmbwUCn8Wtl6UAwsJET3yFhNRUqjSAcRvYgChHoN8eLw8Y5FlVh P2UabIpYKOGh/eMfoJd4b6X6HcZAJWGlT6ktGWB1VdZSxTslkSvPHUN/cuBlxXhL azu7kiL1q6t7+ehQOZMhKNW6C56aeSrRQ44g43NpKQBRBCvX/9hBAD1Inw7a1RVu I52f+ONZnIZt51DEDj3wjBBKR+HRzTM6Sd+gUDNFFuwPldArE9/kHiUpRgoAxTYK p4wiwI8Snasujuy72KrAVTOBMUInYGWHLH5lgtFOMShyNQj8n7z/Mhz3712aMFf9 yqI9GjjC7+SCZQHHUjsgSU4LZS/5ogjeUHpCuFptrCgP5n4L5023zlPhR0/4AS+3 BiV+jg+0BnXTb42u9lU7oXUrOPNB8pl/o9fOmcI5KtOO3f+RmANJxUmbo/ckPIty //lhOe2OfrKAX6pYsW96zxebKuvx7UOLdIzzX+EDxtcnCdReTuk= =4qOt -----END PGP SIGNATURE----- --Sig_/6sDKgFENeCFZxhb2i645nfO--