mirror of
https://github.com/unraid/webgui.git
synced 2026-01-28 12:39:20 -06:00
Nchan implementation
This commit is contained in:
@@ -24,6 +24,7 @@ if (!function_exists('_')) {
|
||||
function _($text) {return $text;}
|
||||
}
|
||||
function ports() {
|
||||
global $net;
|
||||
exec("ls $net|grep -Po '^(lo|(bond|eth)\d+)$'",$ports);
|
||||
return $ports;
|
||||
}
|
||||
@@ -38,7 +39,6 @@ foreach (ports() as $port) {
|
||||
while (true) {
|
||||
$echo = $mode = $rxtx = $stat = [];
|
||||
$ts = $time - $time0;
|
||||
exec("ls $net|grep -Po '^(lo|(bond|eth)\d+)$'",$ports);
|
||||
foreach (ports() as $port) {
|
||||
// inbound + outbound speed
|
||||
$rx = (float)file_get_contents("$net/$port/statistics/rx_bytes");
|
||||
|
||||
Reference in New Issue
Block a user