in reply to system command question

It is fairly easy to translate your system call to pure perl:

use strict; use warnings; open my $dev, "<", "/proc/net/dev" or die $!; my ($eth0) = grep {/eth0/} <$dev>; close $dev; my $k = (split /\s+/,$eth0)[1]; $k =~ s/eth0://g; print "$k\n";

Outputs:

190722498