landscape-client should close stray inherited file descriptors on startup
Bug #352458 reported by
Christopher Armstrong
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Landscape Client |
Fix Released
|
Critical
|
Christopher Armstrong | ||
Landscape Server |
Fix Released
|
Critical
|
Christopher Armstrong | ||
landscape-client (Ubuntu) |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
During normal startup it's not an issue, but it can become one when landscape-client upgrades itself.
<cjwatson> niemeyer: if a process inherits the fd that's for writing to debconf and doesn't close it on startup, then debconf will hang when it's trying to shut down
<cjwatson> niemeyer: so this isn't for future package installations using smart, it's something that landscape-client needs to do on startup if it's called from a postinst
I have determined that this debconf file descriptor *is* opened in a way that will be inherited by subprocesses, so we really should clean it up. (exec 3>&1)
Changed in landscape-client: | |
assignee: | nobody → radix |
milestone: | none → 1.0.29 |
Changed in landscape: | |
milestone: | none → mountainview-pre-8 |
Changed in landscape: | |
milestone: | mountainview-pre-8 → mountainview |
tags: | added: review |
Changed in landscape: | |
status: | Fix Committed → Fix Released |
Changed in landscape-client: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
[1] getrlimit( resource. RLIMIT_ NOFILE) [1])):
+ min(4096, resource.
Can you create an intermediate variable for the getrlimit value?
[2] tests.helpers import LandscapeTest LandscapeTest) :
+from landscape.
+
+class CleanFDsTests(
Missing a blank line.
[3] fds_sanity( self):
+ clean_fds()
+
+
+ def test_clean_
Extra blank line :).
+1!