mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-04-08 03:14:21 +00:00
node.py: record pid in twisted log at startup. Closes #476.
This commit is contained in:
parent
d8ba8c2eb5
commit
7950fc0f2e
@ -238,6 +238,11 @@ class Node(service.MultiService):
|
||||
def startService(self):
|
||||
# Note: this class can be started and stopped at most once.
|
||||
self.log("Node.startService")
|
||||
# Record the process id in the twisted log, after startService()
|
||||
# (__init__ is called before fork(), but startService is called
|
||||
# after). Note that Foolscap logs handle pid-logging by itself, no
|
||||
# need to send a pid to the foolscap log here.
|
||||
twlog.msg("My pid: %s" % os.getpid())
|
||||
try:
|
||||
os.chmod("twistd.pid", 0644)
|
||||
except EnvironmentError:
|
||||
|
Loading…
x
Reference in New Issue
Block a user