Commit f40e81b5 authored by Mario Hock's avatar Mario Hock
Browse files

deactivate experimental "tcp_probe"

doesn't work as expected
parent 8c7c6d7b
...@@ -14,9 +14,9 @@ import time ...@@ -14,9 +14,9 @@ import time
import os import os
import psutil import psutil
## XXX testing... ## experimental "tcp_probe"
import subprocess #import subprocess
import signal #import signal
from history_store import HistoryStore from history_store import HistoryStore
...@@ -318,8 +318,8 @@ class LoggingManager: ...@@ -318,8 +318,8 @@ class LoggingManager:
filename = filename_prefix + "-" + str(i) + ".cnl" filename = filename_prefix + "-" + str(i) + ".cnl"
i += 1 i += 1
## XXX experimental ## experimental "tcp_probe"
tcpprobe_filename = filename[:-4] + ".tcpprobe" #tcpprobe_filename = filename[:-4] + ".tcpprobe"
print( "Logging to file: " + filename ) print( "Logging to file: " + filename )
...@@ -336,13 +336,13 @@ class LoggingManager: ...@@ -336,13 +336,13 @@ class LoggingManager:
filename) filename)
## XXX testing... ## experimental "tcp_probe"
# test if tcp_probe file is readable ## test if tcp_probe file is readable
PATH_TO_TCP_PROBE = "/proc/net/tcpprobe" #PATH_TO_TCP_PROBE = "/proc/net/tcpprobe"
self.use_tcpprobe = os.access(PATH_TO_TCP_PROBE, os.R_OK) #self.use_tcpprobe = os.access(PATH_TO_TCP_PROBE, os.R_OK)
if ( self.use_tcpprobe ): #if ( self.use_tcpprobe ):
## start "cat /proc/net/tcpprobe > file" in parallel (and send quit signal, when logging is stopped) ### start "cat /proc/net/tcpprobe > file" in parallel (and send quit signal, when logging is stopped)
self.tcpprobe = subprocess.Popen("cat " + PATH_TO_TCP_PROBE + " > " + tcpprobe_filename, shell=True, preexec_fn=os.setsid) #self.tcpprobe = subprocess.Popen("cat " + PATH_TO_TCP_PROBE + " > " + tcpprobe_filename, shell=True, preexec_fn=os.setsid)
...@@ -354,10 +354,10 @@ class LoggingManager: ...@@ -354,10 +354,10 @@ class LoggingManager:
self.measurement_logger = None self.measurement_logger = None
self.auto_comment = None self.auto_comment = None
## XXX experimental ## experimental "tcp_probe"
## kill "cat /proc/net/tcpprobe > file" ## kill "cat /proc/net/tcpprobe > file"
if ( self.use_tcpprobe ): #if ( self.use_tcpprobe ):
os.killpg(self.tcpprobe.pid, signal.SIGTERM) #os.killpg(self.tcpprobe.pid, signal.SIGTERM)
def _is_activity_on_nics(self, measurement): def _is_activity_on_nics(self, measurement):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment