Debian Bug report logs - #778462
faketime: does not work in chroot if /run/shm is not mounted as tmpfs inside the chroot ("sem_open: Function not implemented")

version graph

Package: faketime; Maintainer for faketime is Daniel Kahn Gillmor <dkg@fifthhorseman.net>; Source for faketime is src:faketime (PTS, buildd, popcon).

Reported by: Axel Beckert <abe@debian.org>

Date: Sun, 15 Feb 2015 12:06:02 UTC

Severity: minor

Found in version faketime/0.9.6-3

Blocking fix for 779566: zsh: Making the build reproducible

Reply or subscribe to this bug.

Toggle useless messages

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to debian-bugs-dist@lists.debian.org, abe@debian.org, pkg-zsh-devel@lists.alioth.debian.org, reproducible-builds@lists.alioth.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>:
Bug#778462; Package faketime. (Sun, 15 Feb 2015 12:06:07 GMT) (full text, mbox, link).


Acknowledgement sent to Axel Beckert <abe@debian.org>:
New Bug report received and forwarded. Copy sent to abe@debian.org, pkg-zsh-devel@lists.alioth.debian.org, reproducible-builds@lists.alioth.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>. (Sun, 15 Feb 2015 12:06:07 GMT) (full text, mbox, link).


Message #5 received at submit@bugs.debian.org (full text, mbox, reply):

From: Axel Beckert <abe@debian.org>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: faketime: does not work in Jessie/Sid chroots running on Wheezy installations/kernel ("sem_open: Function not implemented")
Date: Sun, 15 Feb 2015 13:02:40 +0100
Package: faketime
Version: 0.9.6-3
Severity: important
User: reproducible-builds@lists.alioth.debian.org
Usertags: toolchain timestamps
Control: affects -1 zsh

Dear Daniel,

running faketime in a Jessie or Sid chroot on a Wheezy installation
fails as follows:

# lsb_release -a
No LSB modules are available.
Distributor ID: Debian
Description:    Debian GNU/Linux 7.8 (wheezy)
Release:        7.8
Codename:       wheezy
# uname -a
Linux jumper 3.2.0-4-686-pae #1 SMP Debian 3.2.65-1+deb7u1 i686 GNU/Linux
# pbuilder login
W: /root/.pbuilderrc does not exist
I: Building the build Environment
I: extracting base tarball [/var/cache/pbuilder/sid-base.tgz]
I: creating local configuration
I: copying local configuration
I: mounting /proc filesystem
I: mounting /dev/pts filesystem
I: policy-rc.d already exists
W: hookdir /etc/pbuilder/hook.d does not exist, skipping
I: Obtaining the cached apt archive contents
I: entering the shell
File extracted to: /var/cache/pbuilder/build//19157

W: no hooks of type F found -- ignoring
[pbuilder] # apt-get install faketime
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following extra packages will be installed:
  libfaketime
The following NEW packages will be installed:
  faketime libfaketime
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 39.7 kB of archives.
After this operation, 108 kB of additional disk space will be used.
Do you want to continue? [Y/n] 
Get:1 http://debian.ethz.ch/mirror/debian/ sid/main libfaketime i386 0.9.6-4 [26.2 kB]
Get:2 http://debian.ethz.ch/mirror/debian/ sid/main faketime i386 0.9.6-4 [13.5 kB]
Fetched 39.7 kB in 0s (278 kB/s) 
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package libfaketime:i386.
(Reading database ... 13109 files and directories currently installed.)
Preparing to unpack .../libfaketime_0.9.6-4_i386.deb ...
Unpacking libfaketime:i386 (0.9.6-4) ...
Selecting previously unselected package faketime.
Preparing to unpack .../faketime_0.9.6-4_i386.deb ...
Unpacking faketime (0.9.6-4) ...
Setting up libfaketime:i386 (0.9.6-4) ...
Setting up faketime (0.9.6-4) ...
[pbuilder] # faketime 'last friday 5 pm' /bin/date
sem_open: Function not implemented
[pbuilder] # echo $?
1
[pbuilder] # 

Initially observed a few days ago (hence reporting against 0.9.6-3 in
Jessie) on Wheezy/Sid amd64 inside a Jenkins job at
http://jenkins.grml.org/view/Debian/job/zsh-binaries/architecture=amd64/174/console
after this commit:
https://anonscm.debian.org/cgit/collab-maint/zsh.git/commit/?id=0dc9a03cbd0520a5566fbb264741d221c7972904

Severity set to important because this may affect the package when being
build on the build daemons as probably most of them run Debian Stable
kernels AFAIK. Feel free to raise or lower the severity if you think the
issue is more or less worse.

Marked as "affects zsh" because it causes FTBFS with the zsh package as
of the current pkg-zsh git HEAD on our jenkins.

If there's anything I can do to avoid this issue in the way the zsh
package uses faketime -- I'm happy about any hint.

-- System Information:
Debian Release: 8.0
  APT prefers testing
  APT policy: (909, 'testing'), (500, 'testing-updates'), (500, 'testing-proposed-updates'), (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 3.16.0-4-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)

Versions of packages faketime depends on:
ii  libc6              2.19-13
ii  libfaketime        0.9.6-3
ii  multiarch-support  2.19-13

faketime recommends no packages.

faketime suggests no packages.

-- no debconf information



Added indication that 778462 affects zsh Request was from Axel Beckert <abe@debian.org> to submit@bugs.debian.org. (Sun, 15 Feb 2015 12:06:07 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>:
Bug#778462; Package faketime. (Sat, 21 Feb 2015 13:03:05 GMT) (full text, mbox, link).


Acknowledgement sent to Ivo De Decker <ivodd@debian.org>:
Extra info received and forwarded to list. Copy sent to Daniel Kahn Gillmor <dkg@fifthhorseman.net>. (Sat, 21 Feb 2015 13:03:05 GMT) (full text, mbox, link).


Message #12 received at 778462@bugs.debian.org (full text, mbox, reply):

From: Ivo De Decker <ivodd@debian.org>
To: Axel Beckert <abe@debian.org>
Cc: 778462@bugs.debian.org
Subject: Re: faketime: does not work in Jessie/Sid chroots running on Wheezy installations/kernel ("sem_open: Function not implemented")
Date: Sat, 21 Feb 2015 13:58:46 +0100
Hi,

On Sun, Feb 15, 2015 at 01:02:40PM +0100, Axel Beckert wrote:
> [pbuilder] # faketime 'last friday 5 pm' /bin/date
> sem_open: Function not implemented

> If there's anything I can do to avoid this issue in the way the zsh
> package uses faketime -- I'm happy about any hint.

This is usually caused by /dev/shm not being world writable in your build
chroot.

I'm not closing this bug, as it might be good to change the output of that
error message, to point people in the right direction.

Cheers,

Ivo




Information forwarded to debian-bugs-dist@lists.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>:
Bug#778462; Package faketime. (Sat, 21 Feb 2015 13:33:10 GMT) (full text, mbox, link).


Acknowledgement sent to Axel Beckert <abe@debian.org>:
Extra info received and forwarded to list. Copy sent to Daniel Kahn Gillmor <dkg@fifthhorseman.net>. (Sat, 21 Feb 2015 13:33:10 GMT) (full text, mbox, link).


Message #17 received at 778462@bugs.debian.org (full text, mbox, reply):

From: Axel Beckert <abe@debian.org>
To: Ivo De Decker <ivodd@debian.org>
Cc: 778462@bugs.debian.org
Subject: Re: faketime: does not work in Jessie/Sid chroots running on Wheezy installations/kernel ("sem_open: Function not implemented")
Date: Sat, 21 Feb 2015 14:28:47 +0100
Hi Ivo,

Ivo De Decker wrote:
> On Sun, Feb 15, 2015 at 01:02:40PM +0100, Axel Beckert wrote:
> > [pbuilder] # faketime 'last friday 5 pm' /bin/date
> > sem_open: Function not implemented
> 
> > If there's anything I can do to avoid this issue in the way the zsh
> > package uses faketime -- I'm happy about any hint.
> 
> This is usually caused by /dev/shm not being world writable in your build
> chroot.

Thanks for that hint. Unfortunately it didn't help for me:

[pbuilder] # faketime 'last friday 5 pm' /bin/date
sem_open: Function not implemented
[pbuilder] # ls -l /dev/shm
lrwxrwxrwx 1 root root 8 Sep 16  2012 /dev/shm -> /run/shm
[pbuilder] # ls -ld /run/shm
drwxr-xr-x 2 root root 4096 Jul 12  2012 /run/shm
[pbuilder] # chmod 777 /run/shm
[pbuilder] # faketime 'last friday 5 pm' /bin/date
sem_open: Function not implemented
[pbuilder] # ls -ld /run/shm
drwxrwxrwx 2 root root 4096 Jul 12  2012 /run/shm
[pbuilder] # 

Anything I oversaw? Any other ideas?

JFTR: /run/shm (via symlink from /dev/shm) was already on rwxrwxrwxt
if I run a Sid "pbuilder login" on a Jessie host and faketime works
fine there out of the box. faketime also still works fine there if I
"chmod 755 /run/shm" there.

		Regards, Axel
-- 
 ,''`.  |  Axel Beckert <abe@debian.org>, http://people.debian.org/~abe/
: :' :  |  Debian Developer, ftp.ch.debian.org Admin
`. `'   |  4096R: 2517 B724 C5F6 CA99 5329  6E61 2FF9 CD59 6126 16B5
  `-    |  1024D: F067 EA27 26B9 C3FC 1486  202E C09E 1D89 9593 0EDE



Added indication that bug 778462 blocks 779566 Request was from Axel Beckert <abe@debian.org> to submit@bugs.debian.org. (Mon, 02 Mar 2015 13:06:08 GMT) (full text, mbox, link).


Removed indication that 778462 affects zsh Request was from Axel Beckert <abe@debian.org> to control@bugs.debian.org. (Sun, 08 Mar 2015 14:57:04 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>:
Bug#778462; Package faketime. (Sun, 08 Mar 2015 15:42:04 GMT) (full text, mbox, link).


Acknowledgement sent to Axel Beckert <abe@debian.org>:
Extra info received and forwarded to list. Copy sent to Daniel Kahn Gillmor <dkg@fifthhorseman.net>. (Sun, 08 Mar 2015 15:42:04 GMT) (full text, mbox, link).


Message #26 received at 778462@bugs.debian.org (full text, mbox, reply):

From: Axel Beckert <abe@debian.org>
To: Ivo De Decker <ivodd@debian.org>, 778462@bugs.debian.org
Cc: Debian Zsh Maintainers <pkg-zsh-devel@lists.alioth.debian.org>
Subject: Re: faketime: does not work in Jessie/Sid chroots running on Wheezy installations/kernel ("sem_open: Function not implemented")
Date: Sun, 8 Mar 2015 16:38:33 +0100
Control: severity -1 minor
Control: retitle -1 faketime: does not work in chroot if /run/shm is not mounted as tmpfs inside the chroot ("sem_open: Function not implemented")

Hi Ivo and Daniel,

Axel Beckert wrote:
> Ivo De Decker wrote:
> > On Sun, Feb 15, 2015 at 01:02:40PM +0100, Axel Beckert wrote:
> > > [pbuilder] # faketime 'last friday 5 pm' /bin/date
> > > sem_open: Function not implemented
> > 
> > > If there's anything I can do to avoid this issue in the way the zsh
> > > package uses faketime -- I'm happy about any hint.
> > 
> > This is usually caused by /dev/shm not being world writable in your build
> > chroot.
> 
> Thanks for that hint. Unfortunately it didn't help for me:
[...]

The relevant difference weren't the permissions but the fact if
/run/shm was bind mounted into the chroot or not:

pbuilder # ls -la /run/shm/
total 8
drwxr-xr-x 2 root root 4096 Jul 12  2012 .
drwxr-xr-x 5 root root 4096 Jul 12  2012 ..
pbuilder # faketime 'last friday 5 pm' /bin/date
sem_open: Function not implemented
pbuilder # 

Now doing "mount -o bind /run/shm
/var/cache/pbuilder/build/4430/run/shm" outside the pbuilder chroot.
Doing "mount -t tmpfs none /run/shm" inside the chroot seems to work
as well.

pbuilder # ls -la /run/shm/
total 4
drwxrwxrwt 2 root root   60 Mar  8 15:10 .
drwxr-xr-x 5 root root 4096 Jul 12  2012 ..
-rw-r--r-- 1 root root    0 Jan 28 10:15 .tmpfs
pbuilder # faketime 'last friday 5 pm' /bin/date
Fri Mar  6 17:00:00 UTC 2015
pbuilder # 

So this looks more like being caused by pbuilder in Wheezy not
mounting /run/shm. This is probably https://bugs.debian.org/700591
which is fixed in Jessie, but not in Wheezy.

I can even reproduce this issue in Jessie by manually doing an "umount
/var/cache/pbuilder/build/18025/run/shm" before exiting pbuilder and
then calling faketime.

Daniel: If faketime in Jessie requires /run/shm to be a tmpfs
whatever, feel free to close this bug report and tag it with wontfix.
There should be enough explanations in here now so that anyone getting
as far as having found this bug report will also know how to fix his
chroot.

Mika: Can we have /run/shm mounted in the chroots of our Jenkins? :-)

		Regards, Axel
-- 
 ,''`.  |  Axel Beckert <abe@debian.org>, http://people.debian.org/~abe/
: :' :  |  Debian Developer, ftp.ch.debian.org Admin
`. `'   |  4096R: 2517 B724 C5F6 CA99 5329  6E61 2FF9 CD59 6126 16B5
  `-    |  1024D: F067 EA27 26B9 C3FC 1486  202E C09E 1D89 9593 0EDE



Severity set to 'minor' from 'important' Request was from Axel Beckert <abe@debian.org> to 778462-submit@bugs.debian.org. (Sun, 08 Mar 2015 15:42:04 GMT) (full text, mbox, link).


Changed Bug title to 'faketime: does not work in chroot if /run/shm is not mounted as tmpfs inside the chroot ("sem_open: Function not implemented")' from 'faketime: does not work in Jessie/Sid chroots running on Wheezy installations/kernel ("sem_open: Function not implemented")' Request was from Axel Beckert <abe@debian.org> to 778462-submit@bugs.debian.org. (Sun, 08 Mar 2015 15:42:05 GMT) (full text, mbox, link).


Information forwarded to debian-bugs-dist@lists.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>:
Bug#778462; Package faketime. (Wed, 20 Apr 2016 11:48:05 GMT) (full text, mbox, link).


Acknowledgement sent to Tobias Frost <tobi@debian.org>:
Extra info received and forwarded to list. Copy sent to Daniel Kahn Gillmor <dkg@fifthhorseman.net>. (Wed, 20 Apr 2016 11:48:05 GMT) (full text, mbox, link).


Message #35 received at 778462@bugs.debian.org (full text, mbox, reply):

From: Tobias Frost <tobi@debian.org>
To: Debian Bug Tracking System <778462@bugs.debian.org>
Subject: Re: faketime: does not work in chroot if /run/shm is not mounted as tmpfs inside the chroot ("sem_open: Function not implemented")
Date: Wed, 20 Apr 2016 13:33:25 +0200
Source: faketime
Followup-For: Bug #778462

Addtional info, after checking on #d-buildd:
sem_open is not supported on hurd, so this will also happen there regardless of /run/shm.

-- 
tobi


-- System Information:
Debian Release: stretch/sid
  APT prefers unstable
  APT policy: (500, 'unstable'), (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.3.0-1-amd64 (SMP w/4 CPU cores)
Locale: LANG=de_DE.UTF-8, LC_CTYPE=de_DE.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)



Information forwarded to debian-bugs-dist@lists.debian.org, Daniel Kahn Gillmor <dkg@fifthhorseman.net>:
Bug#778462; Package faketime. (Mon, 27 Feb 2017 21:57:06 GMT) (full text, mbox, link).


Acknowledgement sent to base@obscurabase.de:
Extra info received and forwarded to list. Copy sent to Daniel Kahn Gillmor <dkg@fifthhorseman.net>. (Mon, 27 Feb 2017 21:57:06 GMT) (full text, mbox, link).


Message #40 received at 778462@bugs.debian.org (full text, mbox, reply):

From: base@obscurabase.de
To: 778462@bugs.debian.org
Subject: Our UPS courier can not contact you (parcel #03216804)
Date: Mon, 27 Feb 2017 21:52:35 +0000
[Message part 1 (text/plain, inline)]
Dear Customer,

UPS courier was unable to contact you for your parcel delivery.

Review the document that is attached to this e-mail!

Thanks,
Jason Greer,
UPS Office Agent.

[UPS-Parcel-ID-03216804.doc.js (text/javascript, attachment)]

Send a report that this bug log contains spam.


Debian bug tracking system administrator <owner@bugs.debian.org>. Last modified: Sat Jan 6 09:22:48 2018; Machine Name: beach

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.