Description of problem: Mount an empty filesystem on /tmp/mnt using guestmount, and run the following script, which is adapted from the test-fuse.sh script in the fuse/ directory of the sources. ------------------------------- #!/bin/bash - set -e set -v cd /tmp/mnt while true; do for ts in 12345 1234567 987654321; do touch -a -d @$ts timestamp [ "$(stat -c %X timestamp)" -eq $ts ] touch -m -d @$ts timestamp [ "$(stat -c %Y timestamp)" -eq $ts ] touch -d @$ts timestamp [ "$(stat -c %X timestamp)" -eq $ts ] [ "$(stat -c %Y timestamp)" -eq $ts ] done done ------------------------------- The script may fail with: touch: setting times of `timestamp': Invalid argument Version-Release number of selected component (if applicable): libguestfs 1.7.19 fuse 2.8.4-1.1 (Debian) How reproducible: The failure is unpredictable. On Fedora it doesn't seem to fail at all, whereas on Debian it fails very frequently.
Seems to be a FUSE issue, because at the point where the error occurs we aren't inside any guestmount code. Also small changes to the script make the error go away, eg. adding a sleep before the 'touch' commands.
It appears to fail the first time after the filesystem has been mounted, but not thereafter. $ ./fuse/guestmount -a test1.img -m /dev/sda1 /tmp/mnt $ /tmp/test.sh [fails immediately with ...] touch: setting times of `timestamp': Invalid argument $ /tmp/test.sh [runs fine, however long I run it or however many times I kill and restart it] Then unmount and remount: $ fusermount -u /tmp/mnt $ ./fuse/guestmount -a test1.img -m /dev/sda1 /tmp/mnt $ /tmp/test.sh [fails immediately with ...] touch: setting times of `timestamp': Invalid argument
I think this is a FUSE problem, or at least I can't work out what's going on. Asked on fuse-devel: http://sourceforge.net/mailarchive/message.php?msg_id=26780130
Fixed by https://github.com/libguestfs/libguestfs/commit/1877c106030361821cf36c8873455d0c3d7134d3 which is in libguestfs >= 1.25.14.
Created attachment 846673 [details] Jenkins console output. This error occurs in Jenkins testing (with libguestfs.git) so it looks like it is not actually fixed.
Hopefully fixed for good (I would hope, now) with https://github.com/libguestfs/libguestfs/commit/99d6e2c84ef490feb6ff2e37e4b0684f34bac554 which is in libguestfs >= 1.25.22.