unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#58663: ‘guix shell -C’ regression
@ 2022-10-20 16:26 Ludovic Courtès
  2022-10-21  6:50 ` Ludovic Courtès
  0 siblings, 1 reply; 2+ messages in thread
From: Ludovic Courtès @ 2022-10-20 16:26 UTC (permalink / raw)
  To: 58663; +Cc: pierre-Antoine.Bouttier

Recent ‘guix shell -C’ fails to create a container on a foreign distro:

--8<---------------cut here---------------start------------->8---
~$ guix describe
Generation 7    Oct 20 2022 16:38:27    (current)
  guix 4716cea
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: 4716cea6256523a8ecf90a426d675bfb7620f3e4
~$ strace -o ,,s.bad -f guix shell -C coreutils
guix shell: error: mount: mount "/gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8" on "/tmp/guix-directory.E6yvR8//gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8": Operation not permitted
~$ grep mount.*/gnu/store ,,s.bad
21363 mount("/gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", "/tmp/guix-directory.E6yvR8//gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", 0x11cf6e0, MS_RDONLY|MS_NOATIME|MS_BIND, NULL) = 0
21363 mount("/gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", "/tmp/guix-directory.E6yvR8//gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", 0x11ad160, MS_RDONLY|MS_REMOUNT|MS_NOATIME|MS_BIND, NULL) = -1 EPERM (Operation not permitted)
~$ mount |grep /gnu/store
REDACTED on /gnu/store type nfs (rw,noatime,nodiratime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=REDACTED,mountvers=3,mountport=47613,mountproto=udp,local_lock=none,addr=REDACTED,_netdev)
--8<---------------cut here---------------end--------------->8---

An older generation (from Feb. 2021) does it just fine on the same
machine:

--8<---------------cut here---------------start------------->8---
$ /var/guix/profiles/per-user/lcourtes/current-guix-6-link/bin/guix describe
  guix e7195e8
    repository URL: https://git.savannah.gnu.org/git/guix.git
    branch: master
    commit: e7195e83c85a83131c0981bae2b6e5613669ebd1
~$ strace -f -o ,,s.good /var/guix/profiles/per-user/lcourtes/current-guix-6-link/bin/guix environment -C coreutils -- uname -orv
4.9.0-19-amd64 #1 SMP Debian 4.9.320-2 (2022-06-30) GNU/Linux
~$ grep mount.*/gnu/store ,,s.good |head 
25204 mount("/gnu/store/mmhimfwmmidf09jw1plw3aw1g1zn2nkh-bash-static-5.0.16", "/tmp/guix-directory.erI4qY//gnu/store/mmhimfwmmidf09jw1plw3aw1g1zn2nkh-bash-static-5.0.16", 0x196a8d0, MS_RDONLY|MS_BIND, NULL) = 0
25204 mount("/gnu/store/mmhimfwmmidf09jw1plw3aw1g1zn2nkh-bash-static-5.0.16", "/tmp/guix-directory.erI4qY//gnu/store/mmhimfwmmidf09jw1plw3aw1g1zn2nkh-bash-static-5.0.16", 0x1963e00, MS_RDONLY|MS_REMOUNT|MS_BIND, NULL) = 0
25204 mount("/gnu/store/zzkly5rbfvahwqgcs7crz0ilpi7x5g5p-ncurses-6.2", "/tmp/guix-directory.erI4qY//gnu/store/zzkly5rbfvahwqgcs7crz0ilpi7x5g5p-ncurses-6.2", 0x18bff90, MS_RDONLY|MS_BIND, NULL) = 0
25204 mount("/gnu/store/zzkly5rbfvahwqgcs7crz0ilpi7x5g5p-ncurses-6.2", "/tmp/guix-directory.erI4qY//gnu/store/zzkly5rbfvahwqgcs7crz0ilpi7x5g5p-ncurses-6.2", 0x1943bc0, MS_RDONLY|MS_REMOUNT|MS_BIND, NULL) = 0
25204 mount("/gnu/store/knp4rkdm39ph4brkbzsp07q248nfffi1-readline-8.0.4", "/tmp/guix-directory.erI4qY//gnu/store/knp4rkdm39ph4brkbzsp07q248nfffi1-readline-8.0.4", 0x1960c70, MS_RDONLY|MS_BIND, NULL) = 0
25204 mount("/gnu/store/knp4rkdm39ph4brkbzsp07q248nfffi1-readline-8.0.4", "/tmp/guix-directory.erI4qY//gnu/store/knp4rkdm39ph4brkbzsp07q248nfffi1-readline-8.0.4", 0x19732b0, MS_RDONLY|MS_REMOUNT|MS_BIND, NULL) = 0
25204 mount("/gnu/store/fa6wj5bxkj5ll1d7292a70knmyl7a0cr-glibc-2.31", "/tmp/guix-directory.erI4qY//gnu/store/fa6wj5bxkj5ll1d7292a70knmyl7a0cr-glibc-2.31", 0x19491b0, MS_RDONLY|MS_BIND, NULL) = 0
25204 mount("/gnu/store/fa6wj5bxkj5ll1d7292a70knmyl7a0cr-glibc-2.31", "/tmp/guix-directory.erI4qY//gnu/store/fa6wj5bxkj5ll1d7292a70knmyl7a0cr-glibc-2.31", 0x1949140, MS_RDONLY|MS_REMOUNT|MS_BIND, NULL) = 0
25204 mount("/gnu/store/01b4w3m6mp55y531kyi1g8shh722kwqm-gcc-7.5.0-lib", "/tmp/guix-directory.erI4qY//gnu/store/01b4w3m6mp55y531kyi1g8shh722kwqm-gcc-7.5.0-lib", 0x1974810, MS_RDONLY|MS_BIND, NULL) = 0
25204 mount("/gnu/store/01b4w3m6mp55y531kyi1g8shh722kwqm-gcc-7.5.0-lib", "/tmp/guix-directory.erI4qY//gnu/store/01b4w3m6mp55y531kyi1g8shh722kwqm-gcc-7.5.0-lib", 0x1960c30, MS_RDONLY|MS_REMOUNT|MS_BIND, NULL) = 0
--8<---------------cut here---------------end--------------->8---

Notice that in the first case, we bind-mount and remount with
MS_NOATIME, but not in the second case.

This looks like a regression caused by the fix to
<https://issues.guix.gnu.org/46292> and, viewed from another angle, by
the fact that “nodiratime” is not preserved.

Ludo’.




^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#58663: ‘guix shell -C’ regression
  2022-10-20 16:26 bug#58663: ‘guix shell -C’ regression Ludovic Courtès
@ 2022-10-21  6:50 ` Ludovic Courtès
  0 siblings, 0 replies; 2+ messages in thread
From: Ludovic Courtès @ 2022-10-21  6:50 UTC (permalink / raw)
  To: 58663-done; +Cc: pierre-Antoine.Bouttier

Ludovic Courtès <ludovic.courtes@inria.fr> skribis:

> ~$ strace -o ,,s.bad -f guix shell -C coreutils
> guix shell: error: mount: mount "/gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8" on "/tmp/guix-directory.E6yvR8//gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8": Operation not permitted
> ~$ grep mount.*/gnu/store ,,s.bad
> 21363 mount("/gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", "/tmp/guix-directory.E6yvR8//gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", 0x11cf6e0, MS_RDONLY|MS_NOATIME|MS_BIND, NULL) = 0
> 21363 mount("/gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", "/tmp/guix-directory.E6yvR8//gnu/store/720rj90bch716isd8z7lcwrnvz28ap4y-bash-static-5.1.8", 0x11ad160, MS_RDONLY|MS_REMOUNT|MS_NOATIME|MS_BIND, NULL) = -1 EPERM (Operation not permitted)
> ~$ mount |grep /gnu/store
> REDACTED on /gnu/store type nfs (rw,noatime,nodiratime,vers=3,rsize=1048576,wsize=1048576,namlen=255,hard,proto=tcp,timeo=600,retrans=2,sec=sys,mountaddr=REDACTED,mountvers=3,mountport=47613,mountproto=udp,local_lock=none,addr=REDACTED,_netdev)

[...]

> This looks like a regression caused by the fix to
> <https://issues.guix.gnu.org/46292> and, viewed from another angle, by
> the fact that “nodiratime” is not preserved.

It was lack of MS_NODIRATIME preservation that was causing problems.

Fixed in 6352e3a17b5978cf9af9e1668816d8f47ec85208!

Ludo’.




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-10-21  6:53 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-20 16:26 bug#58663: ‘guix shell -C’ regression Ludovic Courtès
2022-10-21  6:50 ` Ludovic Courtès

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).