when stopped, automount orphans some mounts

Bug #578536 reported by Adar Dembo
32
This bug affects 3 people
Affects Status Importance Assigned to Milestone
autofs5 (Ubuntu)
Fix Released
Medium
Ubuntu Server
Lucid
Won't Fix
Medium
Dave Walker
Maverick
Won't Fix
Medium
Dave Walker
Natty
Won't Fix
Medium
Unassigned
Oneiric
Fix Released
Medium
Ubuntu Server

Bug Description

Binary package hint: autofs5

[Impact]
Running reload autofs on a release with this issue creates automount maps and can cause the automounter to hang. This will prevent logins via ssh for users (due to NFS mounted home directories).

I have an automount setup containing a large number of NIS-provided maps, all derived from an NIS-provided master map (yp:auto.master). When I stop automount using "stop autofs", I noticed that some mounts have been unmounted while a non-deterministic number of mounts have been orphaned and need to be cleaned up using "umount":

[Test]

adar@adar-lx:~$ sudo start autofs && sudo stop autofs && grep autofs /proc/mounts
autofs start/running, process 13152
autofs stop/waiting
auto.home /exit14 autofs rw,relatime,fd=19,pgrp=13152,timeout=60,minproto=5,maxproto=5,indirect 0 0
/etc/auto.build /build autofs rw,relatime,fd=6,pgrp=13152,timeout=300,minproto=5,maxproto=5,indirect 0 0
auto.exit15 /exit15 autofs rw,relatime,fd=31,pgrp=13152,timeout=60,minproto=5,maxproto=5,indirect 0 0
auto.scripts /scripts autofs rw,relatime,fd=73,pgrp=13152,timeout=60,minproto=5,maxproto=5,indirect 0 0

adar@adar-lx:~$ sudo start autofs && sudo stop autofs && grep autofs /proc/mounts
autofs start/running, process 13198
autofs stop/waiting
/etc/auto.build /build autofs rw,relatime,fd=6,pgrp=13198,timeout=300,minproto=5,maxproto=5,indirect 0 0
auto.scripts /scripts autofs rw,relatime,fd=73,pgrp=13198,timeout=60,minproto=5,maxproto=5,indirect 0 0
auto.mts-tlv /mts-tlv autofs rw,relatime,fd=67,pgrp=13198,timeout=60,minproto=5,maxproto=5,indirect 0 0
auto.mts-sof /mts-sof autofs rw,relatime,fd=79,pgrp=13198,timeout=60,minproto=5,maxproto=5,indirect 0 0
auto.mts-cm /mts-cm autofs rw,relatime,fd=85,pgrp=13198,timeout=60,minproto=5,maxproto=5,indirect 0 0

adar@adar-lx:~$ sudo start autofs && sudo stop autofs && grep autofs /proc/mounts
autofs start/running, process 13244
autofs stop/waiting
auto.mts-sof /mts-sof autofs rw,relatime,fd=79,pgrp=13244,timeout=60,minproto=5,maxproto=5,indirect 0 0
auto.buildmap /bldmnt autofs rw,relatime,fd=49,pgrp=13244,timeout=60,minproto=5,maxproto=5,indirect 0 0
auto.exit26home /exit26 autofs rw,relatime,fd=55,pgrp=13244,timeout=60,minproto=5,maxproto=5,indirect 0 0

I suspect this is due to the transition to upstart but I'm not 100% sure.

[Regression Potential]
Issue was known and resolved upstream, and has been carried in later releases of Ubuntu. The patch coming untouched from upstream indicates that the regression potential is low.

Tags: server-o-rs
Revision history for this message
Adar Dembo (adar-deactivatedaccount) wrote :

I forgot to mention that this is with autofs5 in Lucid Lynx, package version version 5.0.4-3.1ubuntu5.

Revision history for this message
Chuck Short (zulcss) wrote :

Thanks Ill take a look at this for maverick.

chuck

Changed in autofs5 (Ubuntu):
importance: Undecided → Low
status: New → Triaged
Changed in autofs5 (Ubuntu):
assignee: nobody → Ubuntu Server Team (ubuntu-server)
importance: Low → Medium
Changed in autofs5 (Ubuntu Oneiric):
status: New → Triaged
importance: Undecided → Medium
assignee: nobody → Ubuntu Server Team (ubuntu-server)
Chuck Short (zulcss)
Changed in autofs5 (Ubuntu Maverick):
status: New → Triaged
importance: Undecided → Medium
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

This bug needs to be fixed in Oneiric, and a full SRU justification added to the bug description before the upload made to maverick-proposed can go into maverick-updates. In particular I'm interested in the regression potential involved with removing this patch. I'm going to hold off accepting it until the regression potential is documented.

Revision history for this message
Martin Pitt (pitti) wrote :

Server team ping?

Changed in autofs5 (Ubuntu Maverick):
status: Triaged → Incomplete
Changed in autofs5 (Ubuntu Oneiric):
status: Triaged → Incomplete
Revision history for this message
Dave Walker (davewalker) wrote :

This is believed to be resolved in Oneiric (5.0.6), and I am attempting to confirm with upstream the commit which did this. Once I have clariffication, I will update the status as suitable.

Thanks.

tags: added: server-o-rs
Dave Walker (davewalker)
Changed in autofs5 (Ubuntu):
milestone: none → oneiric-alpha-3
Changed in autofs5 (Ubuntu Oneiric):
milestone: oneiric-alpha-3 → ubuntu-11.10-beta-1
Changed in autofs5 (Ubuntu Oneiric):
status: Incomplete → In Progress
Changed in autofs5 (Ubuntu Maverick):
status: Incomplete → In Progress
Revision history for this message
Dave Walker (davewalker) wrote :

This is fixed in Oneiric via autofs5 5.0.6 via:
From 52b4b907f4b41b09bde71da43b0325f4659d7e37 Mon Sep 17 00:00:00 2001
From: Ian Kent <email address hidden>
Date: Mon, 4 Apr 2011 15:42:01 +0800
Subject: [PATCH 1/1] autofs-5.0.5 - fix stale map read

A previous patch to fix direct maps not updating on re-read has
a side effect of causing maps to always be re-read on lookup.
This is because, following the application of the previous patch,
the map stale status is no longer being updated on a successful
map read.

Changed in autofs5 (Ubuntu Oneiric):
status: In Progress → Fix Released
Changed in autofs5 (Ubuntu Maverick):
assignee: nobody → Dave Walker (davewalker)
Dave Walker (davewalker)
Changed in autofs5 (Ubuntu Lucid):
assignee: nobody → Dave Walker (davewalker)
status: New → In Progress
importance: Undecided → Medium
Dave Walker (davewalker)
description: updated
Dave Walker (davewalker)
Changed in autofs5 (Ubuntu Natty):
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Clint Byrum (clint-fewbar) wrote : Please test proposed package

Hello Adar, or anyone else affected,

Accepted autofs5 into maverick-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in autofs5 (Ubuntu Maverick):
status: In Progress → Fix Committed
tags: added: verification-needed
Changed in autofs5 (Ubuntu Lucid):
status: In Progress → Fix Committed
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Hello Adar, or anyone else affected,

Accepted autofs5 into lucid-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Revision history for this message
Leonardo Borda (lborda) wrote :

@Clint Byrum (clint-fewbar)

This issue is also seen in Natty, could we also see this in the natty-propose so we can validate if it fixes the issue?

Leonardo

Chris J Arges (arges)
Changed in autofs5 (Ubuntu Natty):
assignee: nobody → Chris J Arges (christopherarges)
Revision history for this message
Chris J Arges (arges) wrote :

This debdiff backports 52b4b907f4b41b09bde71da43b0325f4659d7e37 from upstream to the natty version.
This should fix it for natty.

Changed in autofs5 (Ubuntu Natty):
status: Confirmed → In Progress
Revision history for this message
Marc Deslauriers (mdeslaur) wrote :

Chris,

A couple of comments on your debdiff:

1- Could you change the version to 5.0.5-0ubuntu6.1
2- Could you add some tags to your patch to explain it's provenance (See http://dep.debian.net/deps/dep3/)

Thanks.

Revision history for this message
Chris J Arges (arges) wrote :

Fixed the changelog and added some tags to the patch.

Revision history for this message
James Page (james-page) wrote :

Hi Chris

Thanks for the updated debdiff.

I've reviewed - I updated the changelog entry to have a bit more detail and uploaded to natty-proposed.

Cheers

James

Revision history for this message
Leonardo Borda (lborda) wrote :

@Chris/James

Could you please confirm which Lucid package version includes this fix in proposed?

Is the one below?
pool/main/a/autofs5/autofs5_5.0.4-3.1ubuntu5.2_amd64.deb

Leonardo

Revision history for this message
Chris J Arges (arges) wrote :
Revision history for this message
Jonathan Riddell (jr) wrote :

In natty-proposed Unapproved queue, waiting on approval from ubuntu-sru

Revision history for this message
Chris J Arges (arges) wrote :

@jr / @james-page:

Can you give me a link to where the Natty package is published?

Revision history for this message
Chris J Arges (arges) wrote :

I was wondering if the natty patch has landed in -proposed yet?

Revision history for this message
Chris Halse Rogers (raof) wrote :

Sorry for the delay in review. The changes look good, and I'm happy to accept them into -proposed, with the exception of the changelog; the changelog should be “human readable”, and so needs a brief summary of the user-visible behaviour it fixes (in addition to the bug link). Something along the lines of “Fixes orphaning of mounts when stopping autofs” would be fine.

I've rejected this from the natty-proposed queue; please upload again with the more verbose changelog.

Revision history for this message
James Page (james-page) wrote :

@Chris

I've re-uploaded to natty-proposed with a much more verbose changelog entry.

Revision history for this message
Chris J Arges (arges) wrote :

@james
Cool thanks. Will make sure my changelogs are more verbose in the future. : )

Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Hello Adar, or anyone else affected,

Accepted autofs5 into natty-proposed. The package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in autofs5 (Ubuntu Natty):
status: In Progress → Fix Committed
Revision history for this message
BrandonS (brandonsqc) wrote :

This doesn't look like it's fixed for me in natty:

$ grep autofs /proc/mounts | wc -l
361
$ sudo stop autofs
autofs stop/waiting
$ grep autofs /proc/mounts | wc -l
273
$ dpkg -l | grep autofs5
ii autofs5 5.0.5-0ubuntu6.1 kernel-based automounter for Linux, version 5
ii autofs5-ldap 5.0.5-0ubuntu6.1 LDAP map support for autofs, version 5
$ lsb_release -d
Description: Ubuntu 11.04

Revision history for this message
Adam Stokes (adam-stokes) wrote :

This problem needs additional patches that can be found in my related branch. My understanding is that testing with that patched autofs5 is proven positive. I will have an SRU written up once I receive a final confirmation today.

tags: added: verification-failed
Revision history for this message
Adam Stokes (adam-stokes) wrote :

The merge proposal has been confirmed and verified on lucid.

description: updated
Changed in autofs5 (Ubuntu Lucid):
status: Fix Committed → Confirmed
milestone: none → ubuntu-10.04.4
milestone: ubuntu-10.04.4 → lucid-updates
tags: added: verification-done-lucid
removed: verification-failed
Revision history for this message
Brian Murray (brian-murray) wrote :

The bug shouldn't be verified until after a package has been uploaded to -proposed and your branch, https://code.launchpad.net/~adam-stokes/ubuntu/lucid/autofs5/null-cache-remap-fix-578536/+merge/114664, hasn't made into -proposed as far as I can tell so I'm changing the tag back to verification-needed.

Additionally, comment 23 indicates that it failed on natty so it seems like it should also be fixed there.

tags: removed: verification-done-lucid
Revision history for this message
Brian Murray (brian-murray) wrote : Verification still needed

The fix for this bug has been awaiting testing feedback in the -proposed repository for lucid for more than 90 days. Please test this fix and update the bug appropriately with the results. In the event that the fix for this bug is still not verified 15 days from now, the package will be removed from the -proposed repository.

tags: added: removal-candidate
Revision history for this message
Brian Murray (brian-murray) wrote :

The version of autofs5 in lucid-proposed has been removed as the bugs it was fixing (including this one) were not verified in a timely fashion.

tags: removed: removal-candidate
tags: removed: verification-needed
Chris J Arges (arges)
Changed in autofs5 (Ubuntu Natty):
assignee: Chris J Arges (arges) → nobody
Revision history for this message
Rolf Leggewie (r0lf) wrote :

maverick has seen the end of its life and is no longer receiving any updates. Marking the maverick task for this ticket as "Won't Fix".

Changed in autofs5 (Ubuntu Maverick):
status: Fix Committed → Won't Fix
Revision history for this message
Rolf Leggewie (r0lf) wrote :

natty has seen the end of its life and is no longer receiving any updates. Marking the natty task for this ticket as "Won't Fix".

Changed in autofs5 (Ubuntu Natty):
status: Fix Committed → Won't Fix
Revision history for this message
Rolf Leggewie (r0lf) wrote :

lucid has seen the end of its life and is no longer receiving any updates. Marking the lucid task for this ticket as "Won't Fix".

Changed in autofs5 (Ubuntu Lucid):
status: Confirmed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

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