diff --git a/main/.#views.py b/main/.#views.py new file mode 120000 index 0000000..d645fd0 --- /dev/null +++ b/main/.#views.py @@ -0,0 +1 @@ +root@pydash.hostechs.com.30609 \ No newline at end of file diff --git a/main/views.py b/main/views.py index 43e5d33..6bc5dd3 100755 --- a/main/views.py +++ b/main/views.py @@ -299,11 +299,12 @@ def get_netstat(): Get ports and applications """ try: - pipe = os.popen("netstat -tlnp |" + "grep 'LISTEN' |" + "awk '{print $4, $5, $7}'") + pipe = os.popen("ss -tlnp | awk '{print $4, $5, $6}'") data = pipe.read().strip().split('\n') pipe.close() data = [i.split(None, 3) for i in data] + del data[0] except Exception, err: data = str(err) diff --git a/templates/main.html b/templates/main.html index edbbdc0..39264df 100644 --- a/templates/main.html +++ b/templates/main.html @@ -289,8 +289,8 @@
| Local Address | -Foreign Address | +Local | +Foreign | PID/Program Name |
|---|