Bug 726025 - Stale mounts after closing schroot
Summary: Stale mounts after closing schroot
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: schroot
Version: 15
Hardware: x86_64
OS: Linux
unspecified
unspecified
Target Milestone: ---
Assignee: Zach Carter
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-07-27 10:50 UTC by Andris Pavenis
Modified: 2011-08-26 19:06 UTC (History)
1 user (show)

Fixed In Version: schroot-1.4.23-1.fc15
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-08-26 19:06:56 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
schroot configuration file (805 bytes, application/octet-stream)
2011-07-27 10:55 UTC, Andris Pavenis
no flags Details

Description Andris Pavenis 2011-07-27 10:50:12 UTC
Description of problem:

Schroot works OK (I have CentOS in chroots under F15), but when I close shell,
I'm getting error messages:

E: 10mount: umount: /var/lib/schroot/mount/centos-i386-45be89ec-a808-4083-aa9a-f33b6ca7c87d/dev/hugepages: Too many levels of symbolic links
E: centos-i386-45be89ec-a808-4083-aa9a-f33b6ca7c87d: Chroot setup failed: stage=setup-stop

and df shows that following mounts are not closed:
/dev/sda5             62955112  26189816  33515752  44% /var/lib/schroot/mount/centos-i386-45be89ec-a808-4083-aa9a-f33b6ca7c87d
tmpfs                  1992432         0   1992432   0% /var/lib/schroot/mount/centos-i386-45be89ec-a808-4083-aa9a-f33b6ca7c87d/sys/fs/cgroup
udev                   1983192         0   1983192   0% /var/lib/schroot/mount/centos-i386-45be89ec-a808-4083-aa9a-f33b6ca7c87d/dev
tmpfs                  1992432      3256   1989176   1% /var/lib/schroot/mount/centos-i386-45be89ec-a808-4083-aa9a-f33b6ca7c87d/dev/shm

I can of course unmount them manually:

for x in /var/lib/schroot/mount/*; do umount -l $x; done

(dos not work without command line parameter -l), but perhaps some resource leak still remains

Running schroot more than once stale directories accumulates.



Version-Release number of selected component (if applicable):

kernel 2.6.38.8-5.x86_64
schroot-1.4.21-1.fc15.x86_64

How reproducible:

Always


Steps to Reproduce:
1. Create some chroot using schroot configuration (if not already done)
2. from shell 'schroot -pc <chroot_name>'
3. close schroot
  
Actual results:

Error messages like mentioned above
Directories not unmounted

Expected results:

No error messages
/var/lib/schroot/mounts/* which belongs to the current session being unmounted

Comment 1 Andris Pavenis 2011-07-27 10:55:50 UTC
Created attachment 515471 [details]
schroot configuration file

Comment 2 Zach Carter 2011-07-27 15:52:48 UTC
I have a feeling you've hit this bug:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=622756

To confirm, can you please edit the /etc/schroot/default/fstab file, change all entries from rbind to bind, and see if the problem goes away?

thanks.

Comment 3 Andris Pavenis 2011-07-27 17:10:02 UTC
Tried. It fixes problem.

Changes below:

*** fstab.orig  2011-07-27 20:04:43.000000000 +0300
--- fstab       2011-07-27 20:07:52.000000000 +0300
***************
*** 3,10 ****
  # (CHROOT_PATH)
  #
  # <file system>       <mount point>   <type>  <options>       <dump>  <pass>
! /proc         /proc           none    rw,rbind        0       0
! /sys          /sys            none    rw,rbind        0       0
! /dev            /dev            none    rw,rbind        0       0
  /home         /home           none    rw,bind         0       0
  /tmp          /tmp            none    rw,bind         0       0
--- 3,10 ----
  # (CHROOT_PATH)
  #
  # <file system>       <mount point>   <type>  <options>       <dump>  <pass>
! /proc         /proc           none    rw,bind        0       0
! /sys          /sys            none    rw,bind        0       0
! /dev            /dev            none    rw,bind        0       0
  /home         /home           none    rw,bind         0       0
  /tmp          /tmp            none    rw,bind         0       0

Comment 4 Fedora Update System 2011-07-27 20:40:27 UTC
schroot-1.4.23-1.fc15 has been submitted as an update for Fedora 15.
https://admin.fedoraproject.org/updates/schroot-1.4.23-1.fc15

Comment 5 Andris Pavenis 2011-07-28 06:54:01 UTC
Installed a new RPM package downloaded from koji.fedoraproject.org.
Seems OK for me.

Comment 6 Fedora Update System 2011-07-31 04:02:53 UTC
Package schroot-1.4.23-1.fc15:
* should fix your issue,
* was pushed to the Fedora 15 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing schroot-1.4.23-1.fc15'
as soon as you are able to.
Please go to the following url:
https://admin.fedoraproject.org/updates/schroot-1.4.23-1.fc15
then log in and leave karma (feedback).

Comment 7 Fedora Update System 2011-08-26 19:06:51 UTC
schroot-1.4.23-1.fc15 has been pushed to the Fedora 15 stable repository.  If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.