** Description changed: http://lists.gnu.org/archive/html/qemu-devel/2012-01/msg02053.html Upstream QEMU commit: eed968607d656a218712df47a5e0432c21fd6994 hw/9pfs: Remove O_NOATIME flag from 9pfs open() calls in readonly mode When a 9p filesystem is exported with the readonly flag, QEMU adds the O_NOATIME flag to all accesses. This causes all reads to fail when qemu is run as non-root and the runas user doesn't own the files being accessed. The patch is a one-liner; please add it to the distribution patches. Steps to reproduce: 1. Download ubuntu-12.04.1-desktop-amd64.iso 2. As a non-root user, $ mkdir testdir $ echo "value" > testdir/testfile $ sudo chown -R root:root testdir 3. Start the VM, again as a non-root user: $ qemu-system-x86_64 -cdrom /path/to/ubuntu-12.04.1-desktop-amd64.iso -vga std -m 2048 \ -fsdev local,id=foo,path=testdir,security_model=none,readonly \ -device virtio-9p-pci,fsdev=foo,mount_tag=foo 4. Inside the VM, select "Try Ubuntu", open a terminal, and run: $ sudo mount -t 9p -o trans=virtio,version=9p2000.L,ro foo /mnt $ ls /mnt testfile $ cat /mnt/testfile Expected results: value Actual results: cat: /mnt/testfile: operation not permitted + + ======================= + SRU Justification: + 1. Impact: cannot use 9p fs in ro mode as nonroot. + 2. Development fix: a patch upstream fixes the attempt to use a flag which only root may use (when not needed) + 3. Stable fix: cherrypick of development fix + 4. Test case: detailed above + 5. Regression potential: this patch only affects 9pfs, and is cherrypicked from upstream, so should have no adverse effect on any other qemu code. + ======================
-- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1091430 Title: 9p fails with readonly+non-root due to O_NOATIME To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/qemu-kvm/+bug/1091430/+subscriptions -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs