aufs hangs on rename() in MID live images

Bug #264048 reported by Emmet Hikory
8
Affects Status Importance Assigned to Milestone
aufs (Debian)
Fix Released
Unknown
linux (Ubuntu)
Fix Released
Medium
Amit Kucheria
Intrepid
Fix Released
Medium
Amit Kucheria
linux-lpia (Ubuntu)
Fix Released
Medium
Amit Kucheria
Intrepid
Fix Released
Medium
Amit Kucheria

Bug Description

On the Ubuntu MID daily images (at least for 20080829 through 20080901), running `apt-get update` from either a Terminal or a VC as either ubuntu (with sudo) or root hangs the system in the rename() syscall, for both KVM and A110 environments.

Revision history for this message
Oliver Grawert (ogra) wrote :

following https://wiki.ubuntu.com/MobileAndEmbedded/ImageModification i see the same behavior in a chrooted call of "apt-get update"

Revision history for this message
Oliver Grawert (ogra) wrote :

on a sidenote kill -9 against the process doesnt work either ...

Revision history for this message
Oliver Grawert (ogra) wrote :
Download full text (12.0 KiB)

execve("/usr/bin/apt-get", ["apt-get", "update"], [/* 19 vars */]) = 0
brk(0) = 0x8237000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
mmap2(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7f34000
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
open("/etc/ld.so.cache", O_RDONLY) = 3
fstat64(3, {st_mode=S_IFREG|0644, st_size=34478, ...}) = 0
mmap2(NULL, 34478, PROT_READ, MAP_PRIVATE, 3, 0) = 0xb7f2b000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/libapt-pkg-libc6.8-6.so.4.6", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\220\261"..., 512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=768668, ...}) = 0
mmap2(NULL, 772128, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7e6e000
mmap2(0xb7f28000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xb9) = 0xb7f28000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/libutil.so.1", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\20\n\0"..., 512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=9692, ...}) = 0
mmap2(NULL, 12428, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7e6a000
mmap2(0xb7e6c000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1) = 0xb7e6c000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/usr/lib/libstdc++.so.6", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0 B\4\000"..., 512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=929912, ...}) = 0
mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0xb7e69000
mmap2(NULL, 952492, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7d80000
mmap2(0xb7e5e000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0xde) = 0xb7e5e000
mmap2(0xb7e63000, 22700, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0xb7e63000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/libm.so.6", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0@4\0\000"..., 512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=149332, ...}) = 0
mmap2(NULL, 151680, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7d5a000
mmap2(0xb7d7e000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x23) = 0xb7d7e000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
open("/lib/libgcc_s.so.1", O_RDONLY) = 3
read(3, "\177ELF\1\1\1\0\0\0\0\0\0\0\0\0\3\0\3\0\1\0\0\0\260\34"..., 512) = 512
fstat64(3, {st_mode=S_IFREG|0644, st_size=50644, ...}) = 0
mmap2(NULL, 53768, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0xb7d4c000
mmap2(0xb7d58000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_F...

Revision history for this message
Oliver Grawert (ogra) wrote :

the above strace triggered me to look into /var/lib/apt/lists/ ... a simple ls /var/lib/apt/lists/ reproduces the hang, it seems to be a filesystem problem (even sudo ls -al /tmp/mergemount/var/lib/apt/ exposes that)

Revision history for this message
Loïc Minier (lool) wrote :

The mmap2 makes me suspicious with the aufs support for this syscall.

Revision history for this message
Loïc Minier (lool) wrote :

Doesn't happen with unionfs.

Revision history for this message
Loïc Minier (lool) wrote :

linux (2.6.27) not affected; linux-lpia is

Amit Kucheria (amitk)
Changed in linux-lpia:
assignee: nobody → amitk
Revision history for this message
Colin Watson (cjwatson) wrote :

It looks like rename, not mmap. (Loïc was confused by the "Read more..." truncation.)

Revision history for this message
Loïc Minier (lool) wrote :

The Debian bug was forwarded to the upstream mailing list:
http://thread.gmane.org/gmane.linux.file-systems.aufs.user/1270

There's a patch from CVS in this message:
http://thread.gmane.org/gmane.linux.file-systems.aufs.user/1287/focus=1291

description: updated
Revision history for this message
Amit Kucheria (amitk) wrote :

The rename bug seems to be fixed upstream. From http://aufs.sourceforge.net/History

20080728
- bugfix: deadlock in rename(2), au_cp_dirs(), reported by Cyril
  Brulebois, Klaus Knopper and Martin Tscholak.

So we should upgrade the aufs code in the Intrepid tree.

Revision history for this message
Matthias Kaehlcke (matthias-kaehlcke) wrote :

i have the same problem with Ubuntu 8.04, but i'm not using aufs. the affected directory (/var/lib/apt) is on an ext3 partition

last lines of strace befure it hangs:

stat64("/var/lib/apt", {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
open("/var/lib/apt", O_RDONLY|O_NONBLOCK|O_LARGEFILE|O_DIRECTORY|0x80000) = 3
fstat64(3, {st_mode=S_IFDIR|0755, st_size=4096, ...}) = 0
fcntl64(3, F_GETFD) = 0x1 (flags FD_CLOEXEC)
getdents64(3,

Changed in aufs:
status: Unknown → Fix Released
Loïc Minier (lool)
Changed in linux-lpia:
milestone: none → ubuntu-8.10-beta
status: New → In Progress
Revision history for this message
Amit Kucheria (amitk) wrote :

Committed to git

Changed in linux-lpia:
importance: Undecided → Medium
status: In Progress → Fix Committed
Revision history for this message
Loïc Minier (lool) wrote :

Included in linux-lpia 2.6.27-3.4.

Changed in linux-lpia:
status: Fix Committed → Fix Released
Changed in linux:
status: New → Fix Committed
Amit Kucheria (amitk)
Changed in linux:
importance: Undecided → Medium
assignee: nobody → amitk
Steve Langasek (vorlon)
Changed in linux-lpia:
milestone: ubuntu-8.10-beta → ubuntu-8.10
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (7.5 KiB)

This bug was fixed in the package linux - 2.6.27-5.8

---------------
linux (2.6.27-5.8) intrepid; urgency=low

  [ Amit Kucheria ]

  * Update AUFS-related Kconfig
    - LP: #264048

  [ Michael Haas ]

  * add proper aufs source tree from 20080922
  * Fix AUFS compilation in vfsub.c
  * Add splice-2.6.23.patch from AUFS to export a symbol needed by AUFS
  * Add put_filp.patch from AUFS to export a symbol needed by AUFS
  * apply (modified) lhash.patch from AUFS to export __lookup_hash()
  * Add deny_write_access.patch from AUFS - export deny_write_access
  * Add sec_perm-2.6.24.patch from AUFS - export security_inode_permission
  * make sure TMPFS_MAGIC is defined in AUFS Makefile

  [ Tim Gardner ]

  * Enabled CONFIG_IPWIRELESS
    - LP: #274748
  * Enabled CONFIG_E1000E, disabled CONFIG_E1000E_NEW
    This takes advantage of the upstream NVM protection fix in
    commit 4a7703582836f55a1cbad0e2c1c6ebbee3f9b3a7.

  [ Upstream Kernel Changes ]

  * Revert "[Bluetooth] Eliminate checks for impossible conditions in IRQ
    handler"
  * [SCSI] qla2xxx: Defer enablement of RISC interrupts until ISP
    initialization completes.
  * PCI: Fix pcie_aspm=force
  * PCI: fix compiler warnings in pci_get_subsys()
  * UBIFS: create the name of the background thread in every case
  * UBIFS: TNC / GC race fixes
  * UBIFS: remove incorrect assert
  * UBIFS: fix printk format warnings
  * AMD IOMMU: set iommu sunc flag after command queuing
  * AMD IOMMU: protect completion wait loop with iommu lock
  * sparc64: Fix disappearing PCI devices on e3500.
  * x86, oprofile: BUG scheduling while atomic
  * ALSA: ASoC: Fix at32-pcm build breakage with PM enabled
  * ath9k: connectivity is lost after Group rekeying is done
  * wireless: zd1211rw: add device ID fix wifi dongle "trust nw-3100"
  * [IA64] Ski simulator doesn't need check_sal_cache_flush
  * [IA64] kexec fails on systems with blocks of uncached memory
  * ath9k: Fix IRQ nobody cared issue with ath9k
  * [Bluetooth] Fix I/O errors on MacBooks with Broadcom chips
  * [Bluetooth] Fix wrong URB handling of btusb driver
  * [Bluetooth] Fix USB disconnect handling of btusb driver
  * sparc64: Fix missing devices due to PCI bridge test in
    of_create_pci_dev().
  * [WATCHDOG] ibmasr: remove unnecessary spin_unlock()
  * [WATCHDOG] wdt285: fix sparse warnings
  * [WATCHDOG] unlocked_ioctl changes
  * x86: fix 27-rc crash on vsmp due to paravirt during module load
  * sched: fix init_hrtick() section mismatch warning
  * clockevents: prevent cpu online to interfere with nohz
  * x86: prevent stale state of c1e_mask across CPU offline/online
  * clockevents: prevent stale tick_next_period for onlining CPUs
  * clockevents: check broadcast device not tick device
  * clockevents: prevent mode mismatch on cpu online
  * x86: prevent C-states hang on AMD C1E enabled machines
  * x86: c1e_idle: don't mark TSC unstable if CPU has invariant TSC
  * timers: fix build error in !oneshot case
  * ALSA: ASoC: maintainers - update email address for Liam Girdwood
  * ibmasr: remove unnecessary spin_unlock()
  * smb.h: do not include linux/time.h in userspace
  * kernel-doc: allow structs whose members are all private
  * ...

Read more...

Changed in linux:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.