Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 1473944 Details for
Bug 1612914
[autofs]Removed entries still can be accessed
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch - mark removed cache entry negative
autofs-5.1.4-mark-removed-cache-entry-negative.patch (text/plain), 2.17 KB, created by
Ian Kent
on 2018-08-07 10:14:35 UTC
(
hide
)
Description:
Patch - mark removed cache entry negative
Filename:
MIME Type:
Creator:
Ian Kent
Created:
2018-08-07 10:14:35 UTC
Size:
2.17 KB
patch
obsolete
>autofs-5.1.4 - mark removed cache entry negative > >From: Ian Kent <raven@themaw.net> > >When re-reading a map entries that have been removed are detected >and deleted from the map entry cache by lookup_prune_cache(). > >If a removed map entry is mounted at the time lookup_prune_cache() >is called the map entry is skippedi. This is done becuase the next >lookup (following the mount expire, which needs the cache entry to >remain) will detect the stale cache entry and a map update done >resulting in the istale entry being removed. > >But if a map re-read is performed while the cache entry is mounted >the cache will appear to up to date so the removed entry will remain >valid even after it has expired. > >To cover this case it's sufficient to mark the mounted cache entry >negative during the cache prune which prevent further lookups from >using the stale entry. > >Signed-off-by: Ian Kent <raven@themaw.net> >--- > CHANGELOG | 1 + > daemon/lookup.c | 12 +++++++++--- > 2 files changed, 10 insertions(+), 3 deletions(-) > >--- autofs-5.0.7.orig/CHANGELOG >+++ autofs-5.0.7/CHANGELOG >@@ -302,6 +302,7 @@ > - add units After line to include statd service. > - use systemd sd_notify() at startup. > - fix update_negative_cache() map source usage. >+- mark removed cache entry negative. > > 25/07/2012 autofs-5.0.7 > ======================= >--- autofs-5.0.7.orig/daemon/lookup.c >+++ autofs-5.0.7/daemon/lookup.c >@@ -1411,15 +1411,21 @@ void lookup_prune_one_cache(struct autof > if (valid && valid->mc == mc) { > /* > * We've found a map entry that has been removed from >- * the current cache so it isn't really valid. >+ * the current cache so it isn't really valid. Set the >+ * mapent negative to prevent further mount requests >+ * using the cache entry. > */ >+ debug(ap->logopt, "removed map entry detected, mark negative"); >+ if (valid->mapent) { >+ free(valid->mapent); >+ valid->mapent = NULL; >+ } > cache_unlock(valid->mc); > valid = NULL; > } > if (!valid && > is_mounted(_PATH_MOUNTED, path, MNTS_REAL)) { >- debug(ap->logopt, >- "prune check posponed, %s mounted", path); >+ debug(ap->logopt, "prune posponed, %s mounted", path); > free(key); > free(path); > continue;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1612914
: 1473944